Repository navigation
ARCH-04E1B-B2: prepare exact post-submit routing sources - #479
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📒 Files selected for processing (26)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe change adds verified completion facts and prepares detached routing-source proposals from task, submission, and historical policy data. Preparation stages the existing routing request. It does not insert a source or grant authority. ChangesPost-submit routing source preparation
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Feature Sequence Diagram(s)sequenceDiagram
participant Preparer as TaskRoutingSourcePreparer
participant Checkers as EvaluationCoordinationPort
participant TaskDB as TASK database
participant Projects as ProjectLockedPolicyContextPort
participant Staging as routing request staging
Preparer->>Checkers: verify current completion and material
Preparer->>TaskDB: lock task, assignment, and submission
Preparer->>Projects: read locked historical policy context
Preparer->>Staging: stage existing request and verify identifiers
Staging-->>Preparer: request facts and verified completion
Preparer-->>Preparer: build detached source proposal
Merge Risk: ⚪ Minimal · up to No actionable merge-blocking issue remains in the reviewed change; it is ready for normal merge checks. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 47.50% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 40 functions across 16 files. (10 skipped: 10 unsupported.)
✨ Finishing Touches 💡 1📝 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 |
Change
TASK can now prepare an exact post-submit routing source from the existing routing reservation, current CHECKERS completion/material custody and historical PROJECTS policy. This replaces the completion port's version-only return and updates its callers. Proposed source facts have no fabricated creation timestamp; persisted manifest facts retain their database-owned timestamp.
This is ARCH-04E1B-B2, a bounded prerequisite within the existing hidden-handler work. It inserts only the existing routing request reservation. It does not publish a manifest/current pointer, issue authority, change TASK status, create REV/CON effects or register a live handler. No compatibility path or migration is added.
Intent, scope and proof.
Design Chosen
Evidence
Current head:
778ab120b33d0a4351b897b4d5e10565729cc4d7, reconciled with main43afa414. Main's CLI-05 and this PR's ARCH-B2 navigation are both preserved; the reported trailing whitespace is removed. Backend code/tests are byte-identical to reviewed33d7fcf5. Documentation/product-operations reconciliation review passed on778ab120; links, all stale-wording scans, Commitrail andgit diff --checkpassed.Fresh Backend run passed on identical merge tree
98268b33f1b237017e993dcf3b07c42cbc2f7a7a: 8,652 unique completed tests, zero skips/deselections, all nine lane exits zero and cleanup confirmed. Task lifecycle B initially reached the unchanged 1,200s limit; its same-head rerun passed in 1,169.804s. The aggregate selects that complete second attempt and the eight successful first attempts, excluding the interrupted one. No timeout or test selection changed. The independent canonical validator passed (test lane evidence valid). CI integrity review passed on this exact head, including attempt selection, complete inventory, artifact hashes and cleanup.Earlier runtime and internal code-review evidence remains attributed to
33d7fcf5or its stated producer below:700f89aa. The transaction, project-isolation and intermediate currentness paths are unchanged at current head; their execution remains attributed to that earlier commit. The changed source tests were rerun as the five exact-head cases above.4aa53513and candidate share tree77e55ce5d7780b1686017f26e12daa22bdfc3454. Slowest lane 1,116.587s under the unchanged 1,200s cap; the lower diagnostic timing target remains advisory. The superseded candidate run was cancelled.Test Delta
New PostgreSQL source-preparation tests cover full stored facts, valid sibling substitution, independent state/accepted-timestamp requirements, historical policies, replay/rollback, retained locks and genuine version-2 predecessor lineage. Existing root-transaction, project isolation and currentness tests now cover the richer completion contract. Both review-policy boolean values retain strict proposal shapes. No tests removed or skipped.
CI And Gate Integrity
No workflows, caps, lint gates, inventory assertions or package scripts weakened. Exact new-file behavior ownership and lane registration are added; scope and boundary guards remain enforced. Coverage is diagnostic only.
External Review
Human review at
33d7fcf5found no correctness defect and ruled out the suspected deadlock on PostgreSQL (42 focused tests). Both reported documentation/merge corrections are fixed at778ab120. CodeRabbit completed a fresh substantive review of all 26 changed files at778ab120, with no actionable comments. Prior CodeRabbit results were rate-limited and remain historical. Fresh hosted CI passed after the same-head rerun; eligible human approval is required for the changed head.Remaining Risks And Follow-Up Work
This prepares exact facts only. Remaining hidden handlers, mandatory AUTH/database/audit/outbox closure, live composition and remediation are not delivered here. Future false-policy composition must acquire the shared lifecycle fence before TASK. The test's seeded state is not proof of live dispatch or automated acceptance.
Human Review Focus
Check complete historical policy/material matching, TASK-before-CHECKERS custody, and that the proposal cannot be mistaken for published authority. Intent, alternatives, allowed files and acceptance criteria are in the linked bounded change record; no files outside its allowed scope.
Human Merge Ownership
Human review and explicit merge authorization remain required. No merge performed.