Consolidate CLI, core, and config modules; move scope_registry to common#7452
Draft
galvana wants to merge 5 commits intoflatten-api-structurefrom
Draft
Consolidate CLI, core, and config modules; move scope_registry to common#7452galvana wants to merge 5 commits intoflatten-api-structurefrom
galvana wants to merge 5 commits intoflatten-api-structurefrom
Conversation
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
8572883 to
551e7d3
Compare
- Move core/ to cli/core/ and connectors/ to cli/connectors/ - Move common/api/ to fides/api/ (scope_registry, urn_registry) - Extract common utils from core/utils to common/utils - Split config/create.py into cli/create_config.py and config/utils.py - Merge config/helpers.py into config/utils.py - Consolidate config generation logic into config/utils.py - Update all imports across fides src and tests Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
- Move cli/connectors/models.py to config/schemas/credentials.py - Move credential functions from cli/core/utils.py to common/credentials.py - Move full urn_registry from api/v1/ to common/urn_registry.py - Move get_db to common/session, update oauth/utils.py to use it - Use TYPE_CHECKING for FidesConfig in config/utils.py - Update all imports across 73+ files Co-authored-by: Cursor <cursoragent@cursor.com>
09f6ccf to
b6baf7c
Compare
551e7d3 to
8fcef2b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Continues the module structure cleanup from
flatten-api-structure. This PR focuses on three areas:CLI consolidation — Moves
connectors/andcore/modules undercli/, since they are CLI-only functionality with no API/service consumers. Eliminates the top-levelconnectors/andcore/packages.Config cleanup — Merges
config/create.pyandconfig/helpers.pyintocli/create_config.pyandconfig/utils.py, co-locating config generation logic with the CLI that drives it and consolidating shared config utilities.Architectural layering fixes:
scope_registrytofides.common.scope_registryso it can be consumed by both CLI and API without the CLI depending on the API layerV1_URL_PREFIXtofides.common.constants(re-exported fromurn_registryfor backward compatibility)/registrationpath incli/utils.pyto remove the CLI's import dependency onfides.api.v1.urn_registryAlso consolidates shared utility functions (
sanitize_fides_key,get_all_level_fields,FIDES_ASCII_ART, etc.) intofides.common.utils, removing duplicates fromcli/core/utils.py.Test plan
nox -s static_checkspassesnox -s pytest -- tests/ctl/cli/passes (CLI tests)nox -s pytest -- tests/ctl/core/passes (core tests)Made with Cursor