feat: add framework-neutral data management evidence profiles - #75
feat: add framework-neutral data management evidence profiles#75seonghobae wants to merge 13 commits into
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Work only on exact head The branch still contains a write-capable one-shot workflow
|
|
Caution Review failedAn error occurred during the review process. Please try again later. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…line)
Applies the route registration that the one-shot apply-data-management-routes
workflow was meant to land, then removes that self-modifying workflow:
- /plane/catalog-objects/{id}/data-owner-assignments (POST)
- /plane/catalog-objects/{id}/critical-data-elements (POST)
- /plane/critical-data-elements/{id}/quality-rules (POST)
- /plane/quality-rules/{id}/observations (POST)
- /plane/catalog-objects/{id}/data-management-profile (GET)
Fixes surfaced by its verify step:
- conftest now snapshot/restores the catalog-plane store so tenant-isolation
tests cannot collide on object_slug with earlier tests.
- migration contract test asserts whitespace-collapsed SQL and the actual
column-level FK form instead of alignment-fragile literals.
Full suite: 286 passed, 9 skipped.
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
- data_management_store._open_engine now enables PRAGMA foreign_keys=ON on SQLite so unit-test engines enforce the same cross-tenant/parent-row guarantees as Postgres in production. - migration 0003 adds a DB-level CHECK for data_classification, matching the DataClassification Literal (public/internal/confidential/restricted_pii/ restricted_financial). - README API list + implementation-compliance matrix now include the five /plane evidence endpoints. - build_data_management_profile documents the contractual factor asymmetry: ownership requires an active effective-time window; CDE/rule require authoritative truth; observations accept observed truth by nature. Full suite: 262 passed.
| def __init__(self, database_dsn: str) -> None: | ||
| """Open the configured relational database.""" | ||
|
|
||
| self._engine = _open_engine(database_dsn) |
There was a problem hiding this comment.
📝 Info: Relational store engines never disposed
RelationalDataManagementStore.__init__ opens a SQLAlchemy engine and never disposes it. The reopen tests build several instances against the same DSN, each leaking a pool. This mirrors the existing catalog_plane_store pattern, so behavior is consistent, but repeated set_data_management_store(...) calls accumulate pools.
Was this helpful? React with 👍 or 👎 to provide feedback.
| "rule_description": record.rule_description, | ||
| "metric_code": record.metric_code, | ||
| "threshold_operator": record.threshold_operator, | ||
| "threshold_value": str(record.threshold_value), |
There was a problem hiding this comment.
📝 Info: SQLite numeric affinity can lose decimal precision
insert_data_quality_rule and insert_data_quality_observation bind str(Decimal) into NUMERIC columns. SQLite gives non-integer values REAL affinity, so a value like 0.50 is stored as a float and re-read via _decimal(str(value)), losing exactness for high-precision decimals. Postgres NUMERIC preserves them; SQLite is only used in tests here.
Was this helpful? React with 👍 or 👎 to provide feedback.
Closes #74.
Intent
Add the first buyer-visible Data Management Evidence Profile above the tenant-bound catalog plane. A buyer can assign a data owner, register Critical Data Elements, define measurable Data Quality rules, record immutable observations, and retrieve an explainable completeness profile with the next missing action.
Dependency and ownership
This PR is stacked on #73 exact source head
bfa409f8971a3b28aac31ec7bca371fa94f7f07f. It writes onlysemantic-data-portaland must not integrate before #73. Any parent movement invalidates descendant evidence and requires a fresh stack candidate.semantic-data-portalowns data-context evidence and the profile read model.enterprise-architecture-corewill own target capability, funding, and improvement initiatives.context-graph-contractswill provide released framework-neutral interoperability contracts after its protected stack integrates.No DAMA-DMBOK or DCAM proprietary prose, official challenge questions, scoring criteria, assessment workbook content, or licensed evidence lists are embedded.
Planned vertical slice
3NF, two-or-more-word
snake_casetables:data_owner_assignmentscritical_data_elementsdata_quality_rulesdata_quality_observationsEndpoints:
/data-management-profilewith factors, counts, policy evidence, and the first exact next actionTDD state
RED acceptance preceded production implementation:
0003 data-management evidence migration is required404 Not Foundfor/data-management-profileContracts, migration, stores, and service behavior are now present. A bounded one-shot branch workflow is applying the small
src/sdp/api.pyregistration patch, running the focused acceptance andcompileall, then deleting itself before committing. This PR remains Draft and non-green until that workflow completes and the exact resulting head passes repository Tests, fuzz, Security Scan, SAST, review, migration, and coverage gates.Non-negotiable behavior