fix: Scope generated graphs provenance per-import#655
Conversation
- Update StatVarGroupGenerator to run globally but propagate provenance dynamically from source SVs (e.g. dc/base/generated/<import_name>). - Update LinkedEdgeGenerator to use dynamic provenance for active imports. - Update AggregationDeleter to clean up the new generated graphs by scoping deletion lists. - Update integration and unit tests to assert the new dynamic provenance format.
Not up to standards ⛔🔴 Issues
|
| Category | Results |
|---|---|
| Documentation | 3 minor |
| CodeStyle | 2 minor |
🟢 Metrics 13 complexity
Metric Results Complexity 13
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
There was a problem hiding this comment.
Code Review
This pull request transitions the aggregation pipeline from using a static, global GeneratedGraphs provenance to dynamic, per-import generated provenances (e.g., dc/base/generated/{import_name}). This involves updating the deleter to support deleting generated graphs separately, modifying SQL queries in linked_edge_generator and stat_var_group_generator to dynamically resolve and propagate the new provenance format, and updating orchestrator logic and tests accordingly. A critical issue was identified in stat_var_group_generator.py where the static check WHERE provenance != generated_provenance in CuratedMemberOf fails to filter out the new scoped generated provenances, which would cause previously generated edges to be incorrectly treated as curated; a dynamic prefix-based filter is recommended to resolve this.
Work in progress. Don't review yet. Created this primarily to get feedback.