Repository navigation
Fix authority-scoped work queue Issue mirror synchronization - #70992
Conversation
Retry transient projection reads, surface pending conclusion writes, and synchronize existing mirrors for exact maintenance/operator terminal requests. Preserve immutable receipts, original run authority and uncertain-write fences. Co-authored-by: Copilot App <[email protected]>
|
✅ Ponytail Reviewer completed successfully! Ponytail ReviewerOutcome: The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible. Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.
|
|
🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅
|
|
✅ Design Decision Gate 🏗️ completed the design decision gate check. See the comment below for the result and any generated ADR draft. Commit pushed:
|
|
✅ Test Quality Sentinel completed test quality analysis. Test Quality SentinelOutcome: The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible. Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.
|
|
✅ PR Code Quality Reviewer completed the code quality review.
|
There was a problem hiding this comment.
Verdict
No actionable blocking issues found in the changed lines.
Review scope
Reviewed the supplied capped diff, changed-file metadata, and existing review comments. Static review only; no tests or repository code were executed, per review instructions. The advisory sub-agent did not produce a usable finding.
🔎 Code quality review by PR Code Quality Reviewer · copilot · gpt50 · 2.41 AIC · ⌖ 0.67 AIC · ⊞ 1.6K
Comment /review to run again
…or synchronization
🏗️ Design Decision Gate — ADR RequiredThis PR adds a lot of new core code (822 new lines in 📄 Draft ADR committed: The draft records the main decision in this PR: Issue mirrors are synchronized for one exact committed terminal request at a time, never through a global sweep. Recovery is an explicit maintainer/admin action through
📋 What to do next
Once an ADR is linked in the PR body, this gate will run again and check that the implementation matches the decision. ❓ Why ADRs Matter
ADRs create a searchable, permanent record of why the codebase looks the way it does. 📋 Michael Nygard ADR Format ReferenceAn ADR must contain these four sections to be considered complete:
All ADRs are stored in
|
There was a problem hiding this comment.
Skills-Based Review 🧠
Applied /diagnosing-bugs and /tdd (per pr-triage classification: bug_fix) to the authority-scoped work-queue Issue mirror synchronization fix.
The core fix itself (issueTransitionTargets authority scoping in pkg/workqueue/issue_transitions.go) is well-designed and thoroughly tested — issue_transitions_test.go is a strong example of /tdd practice, and the new TestOperatorTerminalIssueSynchronization* suite passes cleanly against a real build. Left 3 inline comments on items that affect debuggability and test coverage rather than correctness.
📋 Key Themes & Highlights
Key Themes
- Undocumented magic delay:
branch_issue_sync.go:331adds a hardcoded 3-second sleep before every synchronization write with no comment explaining the race/consistency issue it guards against — a/diagnosing-bugsred flag (undocumented workaround, adds real latency to every call and every test run). - Error detail loss:
projectionFailureReasoninwork_queue_issues.cjsgeneralizes specific error causes into an allowlisted code before the original detail is logged anywhere, and the matching test assertions were weakened from specific regexes to generic code matches — this could make production incidents harder to diagnose. - New CLI surface lacks dedicated tests:
pkg/cli/work_command_issue_sync.go(newsync-issuescommand) is only covered by the generic operator-surface table test, not a focused positive-path test of its own output/error handling, even though the underlying Go package logic is well tested.
Positive Highlights
- ✅
issueTransitionTargets/transitionProjectionTargetsauthority-scoping logic is cleanly mirrored between Go and JS with consistent vocabulary (terminal,projection,mirror,coordination fence), matching the project's existing dual-engine pattern. - ✅ New Go tests (
issue_transitions_test.go) are thorough, covering authority/no-authority/multi-target cases. - ✅ Documentation (
docs/.../work-queue.md,.../work-queue-specification.md) was updated alongside the behavior change.
Investigation Note
Review was bounded per the investigation budget (~25-30 tool calls); the diff/triage/skill guidance were the primary sources of truth and no critical blockers beyond the 3 items above were found in the time allotted.
🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · copilot · sonnet50 · 169 AIC · ⌖ 15.3 AIC · ⊞ 10.2K
Comment /matt to run again
There was a problem hiding this comment.
🟡 Changes recommended
Terminal synchronization can silently skip eligible mirrors or retain permanent locks, blocking the supported recovery path.
10 open issues
Preserve confirmed projection rejections instead of marking them ambiguous · New Release acknowledged locks after caller cancellation · New Handle concurrent duplicate label creation as a confirmed rejection · New Defer pending projections until authoritative compaction completes · New Allow disabled Issue projection during writer-authorized reconciliation · New Run detection reporting even when Issue projection fails · New Preserve summary history and verified outcome links · New Normalize compacted operations before terminal synchronization · New Synchronize eligible mirrors despite unrelated missing receipts · New Tolerate arbitrary Result metadata during descriptor decoding · New
What changed in this PR
Extends gh-aw’s Git-authoritative work queue Issue projection to maintenance and operator terminal transitions, while preserving existing mirror identities and the keep-open policy.
Changes:
- Adds exact-request terminal synchronization with authority checks and shared Work/Issue locks.
- Retries transient metadata reads and explicitly reports pending synchronization.
- Updates regression coverage, documentation, release notes, and generated workflows.
| File | Description |
|---|---|
pkg/workqueue/issue_transitions.go |
Select terminal mirrors and determine their status. |
pkg/workqueue/issue_transitions_test.go |
Cover terminal selection, authority, receipts, and locks. |
pkg/workqueue/branch_test.go |
Mock projection-lock references. |
pkg/workqueue/branch_issue_sync.go |
Implement native exact-request mirror synchronization. |
pkg/workflow/work_queue_issues.go |
Fail conclusion projection when synchronization remains pending. |
pkg/workflow/maintenance_workflow_work_queue_compaction.go |
Enable maintenance Issue projection. |
pkg/workflow/maintenance_workflow_work_queue_compaction_test.go |
Check maintenance permissions and projection invocation. |
pkg/cli/work_command.go |
Register recovery and synchronize reconciliation results. |
pkg/cli/work_command_test.go |
Validate the exact-request recovery command surface. |
pkg/cli/work_command_operations.go |
Synchronize mirrors after operator cancellation. |
pkg/cli/work_command_issue_sync.go |
Add sync-issues and terminal-publication handling. |
pkg/cli/work_command_clear.go |
Synchronize mirrors after queue clearing. |
pkg/cli/work_command_clear_test.go |
Mock verified configuration reads. |
docs/src/content/docs/specs/work-queue-specification.md |
Describe terminal projection authority and compatibility. |
docs/src/content/docs/reference/work-queue.md |
Document synchronization behavior and recovery. |
actions/setup/js/work_queue_issues.cjs |
Support terminal targets and sanitized pending diagnostics. |
actions/setup/js/work_queue_issues_checks.cjs |
Update sanitized error assertions. |
actions/setup/js/work_queue_issues_acceptance_checks.cjs |
Update acceptance assertions for sanitized diagnostics. |
actions/setup/js/work_queue_issue_transitions.test.cjs |
Cover scoped terminal projection and retained fences. |
actions/setup/js/work_queue_issue_transitions.cjs |
Select exact maintenance-owned terminal targets. |
actions/setup/js/work_queue_issue_pacing.test.cjs |
Cover bounded read retries and write non-retries. |
actions/setup/js/work_queue_issue_pacing.cjs |
Retry transient projection metadata reads. |
actions/setup/js/work_queue_issue_api.cjs |
Classify uncertain label mutation outcomes. |
actions/setup/js/work_queue_aw_issues.test.cjs |
Check error-text redaction. |
actions/setup/js/reconcile_work_queue_run.test.cjs |
Cover maintenance terminal projection and pending results. |
actions/setup/js/reconcile_work_queue_run.cjs |
Project terminal requests from the current maintenance run. |
.github/workflows/repo-tree-map.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/eslint-refiner.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/eslint-monster.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/eslint-miner.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/eslint-factory-dispatcher.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-pydantic-ai.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-pi.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-opencode.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-kiro.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-goose.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-gemini.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-dispatcher.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-deepseek-harness.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-cursor.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-crush.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-copilot.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-codex.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-claude.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-aider.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/engine-conformance-agy.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/deep-report.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-token-consumption-report.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-team-evolution-insights.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-secrets-analysis.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-report-dispatcher.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-repo-chronicle.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-regulatory.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-observability-report.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-issues-report.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-firewall-report.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-evals-report.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/daily-compiler-quality.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/artifacts-summary.lock.yml |
Regenerate pending-sync failure handling. |
.github/workflows/agentics-maintenance.yml |
Enable Issue writes and terminal projection during maintenance. |
.github/aw/work-queue.md |
Document scoped recovery constraints. |
.changeset/minor-work-queue-terminal-issue-sync.md |
Add the minor-release note. |
Review effort: Max
|
@copilot address these review comments:
Also run Sous-chef state: 6cd5af51e135772b056f501807fdf7f9523f3737bd5336f7235c0a6a86fca70e
|
Preserve exact publication authority, checkpoint identity, checked summary history, and uncertainty fences. Keep reporting and compaction independent of projection-only failure; add focused native, CLI, and JavaScript regressions and finish ADR-70992. Co-authored-by: Copilot App <[email protected]>
|
Regarding this status: no code change was needed for this informational reported-no-action notification. The actionable feedback is handled in the inline threads; this status was not treated as independent verification. |
|
Regarding this review: addressed the three inline comments with documented mutation pacing, secret-safe diagnostics, and dedicated CLI output/error tests in e18f0b8. The raw-message suggestion was only partially adopted to avoid exposing credentials or task data. |
|
Regarding the generated ADR: finished the draft, removed the unverified decider placeholder, and clarified the exact authority, fencing, checkpoint, and failure-ordering decisions in e18f0b8. It remains Proposed pending maintainer acceptance and is linked in the PR body. |
|
Regarding this status: no code change was needed for this informational reported-no-action notification. Added focused regression coverage for the actionable review findings rather than treating the notification as test evidence. |
|
Regarding this review status: no code change was required by this nonblocking status. The separate actionable threads are addressed with focused regressions and the single combined follow-up commit e18f0b8. |
|
Regarding the ADR requirement: completed ADR-70992 in e18f0b8 and linked it in the PR body. The proposal records request-scoped recovery, authenticated publication authority, checked summaries, safe rejection handling, and reporting/compaction before projection-only failure. |
Co-authored-by: gh-aw-bot <[email protected]>
The branch update |
|
🎉 This pull request is included in a new release. Release: |


Work queue Issues can keep stale Queued or Running labels after authoritative Work becomes terminal: original projection reads can fail without failing the conclusion step, and maintenance/operator terminal transitions previously had no projection hook. This fixes the projection lifecycle without changing the intentional keep-open policy.
ADR: ADR-70992: Request-Scoped Terminal Issue Mirror Synchronization
Approach
work-queue sync-issues --request-id REQUEST_ID.3effd63d23and regenerate workflows, preserving the landed failed-Claim diagnostic retention alongside projection-failure/reporting changes.Review feedback
Addressed the 13 inline comments in follow-up commit
e18f0b8e9b, including dedicated CLI positive/zero/disabled/JSON/error tests, checkpoint replay and authority-denial cases, mixed pending targets, cancellation cleanup, duplicate-label acknowledgement boundaries, reporting order, and summary preservation. Kept secondary-rate mutation pacing with an explicit rationale; adopted safe diagnostic improvements without logging raw external errors. Finished the generated ADR as a proposal pending maintainer acceptance.Validation
Passed: focused native workqueue/compiler/CLI regressions; 308 JavaScript tests across eight projection, maintenance and native-delivery suites; runtime typecheck; build and formatting; JavaScript lint; zero branch-changed-file custom Go analyzer diagnostics; incremental golangci-lint with zero new issues; all 346 workflow drift checks. Verified all 30 overlapping worker uploads retain the landed seven-day failed-diagnostic retention expression.
make agent-report-progressran its impacted tests successfully. The finalmake agent-report-progress-no-teststill fails because its wrapper treats the existing unknown-custom-linter warning (largefunc,tolowerequalfold,uncheckedsliceindex) as a non-diagnostic failure; its custom Go lint and JavaScript lint pass. Separate incremental Go lint reports zero issues. Unrelated gate/source files were not changed.Review and live-repair gates
The single read-only security reviewer passed the earlier implementation with all ten required records YES. Its later combined-base refresh became unavailable after a model DNS failure and loss of the reviewer handle. The subsequent review-feedback changes have focused regression and lint coverage, but this does not claim a fresh combined-snapshot security PASS.
No production Issue edits, queue mutations, workflow dispatches or reruns were performed. Existing stale mirrors remain gated on deployment and the reviewed supported exact-request recovery path; this PR does not authorize live repair.