Scale pm-graph item exports and expose pure graph projection - #122
Conversation
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configuration
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
⛔ Files ignored due to path filters (3)
📒 Files selected for processing (3)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. Summary by CodeRabbit
Walkthrough
ChangesGraph projection
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~12 minutes Change: Feature Merge Risk: ⚪ Minimal · up to The projection change has no established merge-blocking defect. The performance threshold remains worth monitoring in normal CI runs. Architecture SummaryArchitecture risk: 🔵 Low · up to The change affects 3 systems. Changed systems: Architecture concerns Review detailsSystems and components
Before / after behavior
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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 |
|
@greptileai please review exact head baabeef, especially edge-order and first-property preservation, the pure API contract, and the scale test. |
|
/gemini review |
|
@coderabbitai full review |
Reviewer's GuideThis PR turns graphFromItems into a packaged pure projection API, clarifies that it requires a prevalidated complete item collection, and replaces repeated item scans and end-of-build deduplication with indexed insertion-time handling; focused tests cover first-edge semantics, external targets, and 3,000-item export-scale behavior. Sequence diagram for insertion-time graph export deduplicationsequenceDiagram
participant Consumer
participant Projection as graphFromItems
participant Index as Item ID index
participant Store as Node and relationship stores
Consumer->>Projection: graphFromItems(items, workspace, depsByItem)
Projection->>Index: Build item ID Set
loop each item relationship
Projection->>Store: addRelationship(from, to, type, properties)
Store->>Store: Check relationship key
alt first relationship key
Store->>Store: Preserve first properties and order
alt target is not indexed
Store->>Store: Add ExternalPmItem node
end
else duplicate relationship key
Store-->>Projection: Skip duplicate
end
end
Projection-->>Consumer: Graph with nodes and relationships
Flow diagram for indexed pure graph projectionflowchart LR
A["Complete authorized item collection"] --> B[graphFromItems]
X["extraDependencies Map"] --> B
W["workspace"] --> B
B --> C["Index item IDs"]
C --> D["Insert nodes and relationships"]
D --> E["Deduplicate relationship keys"]
E --> F["Materialize external target nodes"]
F --> G["Graph: nodes + relationships"]
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
✅ Action performedFull review finished. |
|
Accept Greptile PR #122 finding by asserting the exact node and relationship order of a graph with a duplicate blocker edge and an external target. Preserve first-edge properties. Record the 295-test exact local release gate and remaining measured coverage gap in the package PM item.
|
@greptileai please review exact head d27eefc, including the accepted output-order test fix and any remaining source or contract issues. |
|
/gemini review |
|
@coderabbitai full review |
|
|
Review-round readback for exact heads (each bot comment above has a reaction and a disposition):
The PR remains open for the stacked base, exact-head CI and review, and the separately tracked 100% coverage mandate. |
|
On Sourcery’s exact-head approval: read and upvoted. It covers d27eefc and reports no findings. I also upvoted and dispositioned the earlier Sourcery quota review and Greptile first-head review; Greptile’s actionable inline finding was fixed and answered. CodeRabbit’s d27eefc request was rate limited, so its first-head summary is not carried forward as a new-head approval. The PR stays open for remaining exact-head checks and review receipts. |
|
On review 5350502548: This is a quota/skip notice, not a substantive review. It remains missing review evidence; no implementation finding was delivered. |
|
On review 5350545329: The graph output-order finding was fixed in d27eefc with exact node/edge assertions. Existing inline dispositions remain valid; no new finding is present in this artifact. |
Accept Greptile PR #122 finding by asserting the exact node and relationship order of a graph with a duplicate blocker edge and an external target. Preserve first-edge properties. Record the 295-test exact local release gate and remaining measured coverage gap in the package PM item.
|
@coderabbitai review |
d27eefc to
e5cee3b
Compare
Rate Limit Exceeded
|
|
On issue 5962880460: This is a quota notice, not a substantive review of e5cee3b. The requested review did not run. The full 300-test gate and passing status checks remain separate from missing current-head review. |
Replace repeated item and relationship scans with indexed membership and insertion-time deduplication while preserving first-edge metadata and external nodes. Export the pure projection for future observational consumers and document its authorization boundary. Add a 3,000-item scale and contract test and record PM-linked acceptance. Align the merge-driver launcher with the published pm-ops template so the release gate passes on the certified toolchain.
Accept Greptile PR #122 finding by asserting the exact node and relationship order of a graph with a duplicate blocker edge and an external target. Preserve first-edge properties. Record the 295-test exact local release gate and remaining measured coverage gap in the package PM item.
e5cee3b to
e7d30d4
Compare
|
Rebased onto current @coderabbitai review |
✅ Action performedReview finished.
|
|
On comment 5978265616: the requested CodeRabbit review of the rebased head |
PM ownership
Dependency
This PR is stacked on pm-graph #116, which certifies the CLI/SDK toolchain and canonical pm-ops merge launcher. Its base is
fix/pm-graph-github-extension-cli-compat-2026-09-27; update the base tomainafter #116 merges. Keep this PR open until that dependency and its own review gates close.Change
graphFromItemsnow indexes item IDs and deduplicates relationship keys at insertion. The first edge's properties, node and edge order, and external target nodes are preserved. It is exported as a pure TypeScript API for consumers that already have a certified complete, authorization-scoped item collection. The README documents that caller boundary and corrects the stale description of the SDK read path.Exact-head local evidence
npm run release:check: 295 tests passed, zero failures or skips; 0 duplicated lines; 90 documented declarations; production audit, package dry run, changelog, and release-attestation checks passed.pm test pm-graph-3a1p --run --fail-on-skipped --fail-on-empty-test-runpassed both focused tests.pm health --strict-exit --jsonpassed on the stacked branch with two stale-item advisories.No hosted user data, private repository content, or pm-cli source changes are included. This PR does not certify pm-web graph export parity or hosted deployment.
Summary by Sourcery
Improve graph projection scalability and expose it for direct use by TypeScript consumers.
New Features:
graphFromItemsas a pure TypeScript API for projecting certified item collections into the standard graph shape.Bug Fixes:
Enhancements:
Tests:
Summary by cubic
Scales
graphFromItemsfrom repeated item and edge scans to indexed membership and insertion-time deduplication, and exposes it as a pure TypeScript API for certified, authorization-scoped item collections. The graph keeps the existing export shape, first-edge properties, node order, relationship order, and external target nodes.pm-graphAlign pm-graph GitHub sync extension with compatible PM SDK #116; update the base tomainafter that PR merges.Written for commit 3d97a75. Summary will update on new commits.
Review fix
Greptile's output-order finding was accepted at
d27eefc: the small contract case now asserts exact node and relationship order in addition to first-edge properties. The 295-test full local release gate passed after this change. New-head CI and bot reviews are pending.