From 5f6aa716329fddb9e464708f2c47492549ee8969 Mon Sep 17 00:00:00 2001 From: pelikhan Date: Fri, 6 Nov 2026 00:28:51 -0800 Subject: [PATCH] fix(work-queue): warn on pending Issue synchronization Keep Issue projection and coordination cleanup nonfatal after committed queue transitions. Preserve pending diagnostics, fatal Claim verification, and scoped projector credentials. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/workflows/agentics-maintenance.yml | 4 +-- .github/workflows/artifacts-summary.lock.yml | 2 +- .../workflows/daily-compiler-quality.lock.yml | 2 +- .github/workflows/daily-evals-report.lock.yml | 2 +- .../workflows/daily-firewall-report.lock.yml | 2 +- .../workflows/daily-issues-report.lock.yml | 2 +- .../daily-observability-report.lock.yml | 2 +- .github/workflows/daily-regulatory.lock.yml | 2 +- .../workflows/daily-repo-chronicle.lock.yml | 2 +- .../daily-report-dispatcher.lock.yml | 2 +- .../workflows/daily-secrets-analysis.lock.yml | 2 +- .../daily-team-evolution-insights.lock.yml | 2 +- .../daily-token-consumption-report.lock.yml | 2 +- .github/workflows/deep-report.lock.yml | 2 +- .../workflows/engine-conformance-agy.lock.yml | 2 +- .../engine-conformance-aider.lock.yml | 2 +- .../engine-conformance-atomic.lock.yml | 2 +- .../engine-conformance-claude.lock.yml | 2 +- .../engine-conformance-codex.lock.yml | 2 +- .../engine-conformance-copilot.lock.yml | 2 +- .../engine-conformance-crush.lock.yml | 2 +- .../engine-conformance-cursor.lock.yml | 2 +- ...gine-conformance-deepseek-harness.lock.yml | 2 +- .../engine-conformance-dispatcher.lock.yml | 2 +- .../engine-conformance-factory.lock.yml | 2 +- .../engine-conformance-gemini.lock.yml | 2 +- .../engine-conformance-goose.lock.yml | 2 +- .../engine-conformance-kiro.lock.yml | 2 +- .../engine-conformance-opencode.lock.yml | 2 +- .../workflows/engine-conformance-pi.lock.yml | 2 +- .../engine-conformance-pydantic-ai.lock.yml | 2 +- .../eslint-factory-dispatcher.lock.yml | 2 +- .github/workflows/eslint-miner.lock.yml | 2 +- .github/workflows/eslint-monster.lock.yml | 2 +- .github/workflows/eslint-refiner.lock.yml | 2 +- .github/workflows/repo-tree-map.lock.yml | 2 +- .../smoke-work-queue-dispatcher.lock.yml | 2 +- .../smoke-work-queue-worker.lock.yml | 2 +- actions/setup/js/reconcile_work_queue_run.cjs | 2 +- .../js/reconcile_work_queue_run.test.cjs | 27 +++++++++---------- docs/src/content/docs/reference/work-queue.md | 2 +- ...ntenance_workflow_work_queue_compaction.go | 4 +-- ...nce_workflow_work_queue_compaction_test.go | 5 ++-- pkg/workflow/work_queue_issues.go | 2 +- pkg/workflow/work_queue_issues_test.go | 8 ++++-- 45 files changed, 66 insertions(+), 62 deletions(-) diff --git a/.github/workflows/agentics-maintenance.yml b/.github/workflows/agentics-maintenance.yml index 18a8763cb80..815a646ac0c 100644 --- a/.github/workflows/agentics-maintenance.yml +++ b/.github/workflows/agentics-maintenance.yml @@ -2215,11 +2215,11 @@ jobs: const { setupGlobals } = require(path.join(actionsDir, 'setup_globals.cjs')); setupGlobals(core, github, context, exec, io, getOctokit); const { maintenance: reconcile } = require(path.join(actionsDir, 'reconcile_work_queue_run.cjs')); - const reconciliation = await reconcile({ projectIssues: true, deferIssueFailure: true }); + const reconciliation = await reconcile({ projectIssues: true, deferIssueWarning: true }); const { main: plan } = require(path.join(actionsDir, 'work_queue_compaction_plan.cjs')); const result = await plan(); if (result.status === 'planned') { const { main: apply } = require(path.join(actionsDir, 'work_queue_compaction_apply.cjs')); await apply(); } - if (reconciliation.issue_sync_pending?.length) core.setFailed('Work queue reconciliation and compaction completed; Issue synchronization remains pending. Recover the exact terminal requests with work-queue sync-issues --request-id.'); + if (reconciliation.issue_sync_pending?.length) core.warning('Work queue reconciliation and compaction completed; Issue synchronization remains pending. Recover the exact terminal requests with work-queue sync-issues --request-id.'); diff --git a/.github/workflows/artifacts-summary.lock.yml b/.github/workflows/artifacts-summary.lock.yml index 37805c19ce2..511ba9f157f 100644 --- a/.github/workflows/artifacts-summary.lock.yml +++ b/.github/workflows/artifacts-summary.lock.yml @@ -1671,7 +1671,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-compiler-quality.lock.yml b/.github/workflows/daily-compiler-quality.lock.yml index 7f226c917c1..6402f25a87f 100644 --- a/.github/workflows/daily-compiler-quality.lock.yml +++ b/.github/workflows/daily-compiler-quality.lock.yml @@ -1924,7 +1924,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-evals-report.lock.yml b/.github/workflows/daily-evals-report.lock.yml index 9ab68a23143..60718bf4373 100644 --- a/.github/workflows/daily-evals-report.lock.yml +++ b/.github/workflows/daily-evals-report.lock.yml @@ -1730,7 +1730,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-firewall-report.lock.yml b/.github/workflows/daily-firewall-report.lock.yml index a40eecaab57..cd9e64d55c4 100644 --- a/.github/workflows/daily-firewall-report.lock.yml +++ b/.github/workflows/daily-firewall-report.lock.yml @@ -1843,7 +1843,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-issues-report.lock.yml b/.github/workflows/daily-issues-report.lock.yml index 2b9d3282819..287cc3e8be3 100644 --- a/.github/workflows/daily-issues-report.lock.yml +++ b/.github/workflows/daily-issues-report.lock.yml @@ -2057,7 +2057,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-observability-report.lock.yml b/.github/workflows/daily-observability-report.lock.yml index 353262b2da3..1c2efb2faca 100644 --- a/.github/workflows/daily-observability-report.lock.yml +++ b/.github/workflows/daily-observability-report.lock.yml @@ -1705,7 +1705,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-regulatory.lock.yml b/.github/workflows/daily-regulatory.lock.yml index f55e33cd18b..4709f50642d 100644 --- a/.github/workflows/daily-regulatory.lock.yml +++ b/.github/workflows/daily-regulatory.lock.yml @@ -2348,7 +2348,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-repo-chronicle.lock.yml b/.github/workflows/daily-repo-chronicle.lock.yml index adf0f2207be..c80de94654e 100644 --- a/.github/workflows/daily-repo-chronicle.lock.yml +++ b/.github/workflows/daily-repo-chronicle.lock.yml @@ -1757,7 +1757,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-report-dispatcher.lock.yml b/.github/workflows/daily-report-dispatcher.lock.yml index 6534a8961a0..f7e3adbc54a 100644 --- a/.github/workflows/daily-report-dispatcher.lock.yml +++ b/.github/workflows/daily-report-dispatcher.lock.yml @@ -1676,7 +1676,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-secrets-analysis.lock.yml b/.github/workflows/daily-secrets-analysis.lock.yml index 0aec8fe08f6..a1f2c07f6b8 100644 --- a/.github/workflows/daily-secrets-analysis.lock.yml +++ b/.github/workflows/daily-secrets-analysis.lock.yml @@ -1730,7 +1730,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-team-evolution-insights.lock.yml b/.github/workflows/daily-team-evolution-insights.lock.yml index 7194ff2aeaa..661dce183f1 100644 --- a/.github/workflows/daily-team-evolution-insights.lock.yml +++ b/.github/workflows/daily-team-evolution-insights.lock.yml @@ -1757,7 +1757,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/daily-token-consumption-report.lock.yml b/.github/workflows/daily-token-consumption-report.lock.yml index 1c7f030dd6a..ad90a934047 100644 --- a/.github/workflows/daily-token-consumption-report.lock.yml +++ b/.github/workflows/daily-token-consumption-report.lock.yml @@ -1858,7 +1858,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/deep-report.lock.yml b/.github/workflows/deep-report.lock.yml index 8b66671dd45..b5959d567c2 100644 --- a/.github/workflows/deep-report.lock.yml +++ b/.github/workflows/deep-report.lock.yml @@ -2572,7 +2572,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-agy.lock.yml b/.github/workflows/engine-conformance-agy.lock.yml index 2bd046416d4..ef14ddd658e 100644 --- a/.github/workflows/engine-conformance-agy.lock.yml +++ b/.github/workflows/engine-conformance-agy.lock.yml @@ -1759,7 +1759,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-aider.lock.yml b/.github/workflows/engine-conformance-aider.lock.yml index 8ea67e7da06..b8dbd0ff310 100644 --- a/.github/workflows/engine-conformance-aider.lock.yml +++ b/.github/workflows/engine-conformance-aider.lock.yml @@ -2283,7 +2283,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-atomic.lock.yml b/.github/workflows/engine-conformance-atomic.lock.yml index a48838cf17d..39b5d015ff9 100644 --- a/.github/workflows/engine-conformance-atomic.lock.yml +++ b/.github/workflows/engine-conformance-atomic.lock.yml @@ -1803,7 +1803,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-claude.lock.yml b/.github/workflows/engine-conformance-claude.lock.yml index 899de7ef9bc..3ede01143c5 100644 --- a/.github/workflows/engine-conformance-claude.lock.yml +++ b/.github/workflows/engine-conformance-claude.lock.yml @@ -1714,7 +1714,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-codex.lock.yml b/.github/workflows/engine-conformance-codex.lock.yml index 99c470f98ba..1a37397bb9b 100644 --- a/.github/workflows/engine-conformance-codex.lock.yml +++ b/.github/workflows/engine-conformance-codex.lock.yml @@ -1704,7 +1704,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-copilot.lock.yml b/.github/workflows/engine-conformance-copilot.lock.yml index 0115ec957a3..73e90a23c68 100644 --- a/.github/workflows/engine-conformance-copilot.lock.yml +++ b/.github/workflows/engine-conformance-copilot.lock.yml @@ -1717,7 +1717,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-crush.lock.yml b/.github/workflows/engine-conformance-crush.lock.yml index 9cfd693722d..723bf930836 100644 --- a/.github/workflows/engine-conformance-crush.lock.yml +++ b/.github/workflows/engine-conformance-crush.lock.yml @@ -1952,7 +1952,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-cursor.lock.yml b/.github/workflows/engine-conformance-cursor.lock.yml index ca8ba5eb77c..f533693d20e 100644 --- a/.github/workflows/engine-conformance-cursor.lock.yml +++ b/.github/workflows/engine-conformance-cursor.lock.yml @@ -1875,7 +1875,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-deepseek-harness.lock.yml b/.github/workflows/engine-conformance-deepseek-harness.lock.yml index 91b1d6df461..7a8b769c1ef 100644 --- a/.github/workflows/engine-conformance-deepseek-harness.lock.yml +++ b/.github/workflows/engine-conformance-deepseek-harness.lock.yml @@ -1853,7 +1853,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-dispatcher.lock.yml b/.github/workflows/engine-conformance-dispatcher.lock.yml index e18ee3b8452..15642103f66 100644 --- a/.github/workflows/engine-conformance-dispatcher.lock.yml +++ b/.github/workflows/engine-conformance-dispatcher.lock.yml @@ -1669,7 +1669,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-factory.lock.yml b/.github/workflows/engine-conformance-factory.lock.yml index 74f83308782..0b6faa26da5 100644 --- a/.github/workflows/engine-conformance-factory.lock.yml +++ b/.github/workflows/engine-conformance-factory.lock.yml @@ -1746,7 +1746,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-gemini.lock.yml b/.github/workflows/engine-conformance-gemini.lock.yml index 59ab531eb31..a74e2435260 100644 --- a/.github/workflows/engine-conformance-gemini.lock.yml +++ b/.github/workflows/engine-conformance-gemini.lock.yml @@ -1674,7 +1674,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-goose.lock.yml b/.github/workflows/engine-conformance-goose.lock.yml index b001fef630a..3453c64f040 100644 --- a/.github/workflows/engine-conformance-goose.lock.yml +++ b/.github/workflows/engine-conformance-goose.lock.yml @@ -1808,7 +1808,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-kiro.lock.yml b/.github/workflows/engine-conformance-kiro.lock.yml index d5cf0febb10..871bc06b166 100644 --- a/.github/workflows/engine-conformance-kiro.lock.yml +++ b/.github/workflows/engine-conformance-kiro.lock.yml @@ -1857,7 +1857,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-opencode.lock.yml b/.github/workflows/engine-conformance-opencode.lock.yml index 66f197e7881..c090906ee0a 100644 --- a/.github/workflows/engine-conformance-opencode.lock.yml +++ b/.github/workflows/engine-conformance-opencode.lock.yml @@ -1907,7 +1907,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-pi.lock.yml b/.github/workflows/engine-conformance-pi.lock.yml index c61503c3eea..c18dd49d073 100644 --- a/.github/workflows/engine-conformance-pi.lock.yml +++ b/.github/workflows/engine-conformance-pi.lock.yml @@ -1692,7 +1692,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/engine-conformance-pydantic-ai.lock.yml b/.github/workflows/engine-conformance-pydantic-ai.lock.yml index 0ea8dd66c3d..71baa3def34 100644 --- a/.github/workflows/engine-conformance-pydantic-ai.lock.yml +++ b/.github/workflows/engine-conformance-pydantic-ai.lock.yml @@ -2396,7 +2396,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/eslint-factory-dispatcher.lock.yml b/.github/workflows/eslint-factory-dispatcher.lock.yml index 271293a6822..b9b0f491c97 100644 --- a/.github/workflows/eslint-factory-dispatcher.lock.yml +++ b/.github/workflows/eslint-factory-dispatcher.lock.yml @@ -1673,7 +1673,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/eslint-miner.lock.yml b/.github/workflows/eslint-miner.lock.yml index 7b6de862955..ea0dde0531f 100644 --- a/.github/workflows/eslint-miner.lock.yml +++ b/.github/workflows/eslint-miner.lock.yml @@ -1791,7 +1791,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/eslint-monster.lock.yml b/.github/workflows/eslint-monster.lock.yml index 01f13b78a3a..115e708d79f 100644 --- a/.github/workflows/eslint-monster.lock.yml +++ b/.github/workflows/eslint-monster.lock.yml @@ -1852,7 +1852,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/eslint-refiner.lock.yml b/.github/workflows/eslint-refiner.lock.yml index 63467f50a6c..36653c5d078 100644 --- a/.github/workflows/eslint-refiner.lock.yml +++ b/.github/workflows/eslint-refiner.lock.yml @@ -1835,7 +1835,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/repo-tree-map.lock.yml b/.github/workflows/repo-tree-map.lock.yml index 194dcee79ac..6ce17f0b72b 100644 --- a/.github/workflows/repo-tree-map.lock.yml +++ b/.github/workflows/repo-tree-map.lock.yml @@ -1645,7 +1645,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/smoke-work-queue-dispatcher.lock.yml b/.github/workflows/smoke-work-queue-dispatcher.lock.yml index 84fa8d0c2ee..7b0802c0d8d 100644 --- a/.github/workflows/smoke-work-queue-dispatcher.lock.yml +++ b/.github/workflows/smoke-work-queue-dispatcher.lock.yml @@ -1654,7 +1654,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/.github/workflows/smoke-work-queue-worker.lock.yml b/.github/workflows/smoke-work-queue-worker.lock.yml index 161c551ddee..ac1efcd565b 100644 --- a/.github/workflows/smoke-work-queue-worker.lock.yml +++ b/.github/workflows/smoke-work-queue-worker.lock.yml @@ -1654,7 +1654,7 @@ jobs: const actionsDir = path.join(process.env.RUNNER_TEMP, 'gh-aw', 'actions'); const { main } = require(path.join(actionsDir, 'work_queue_issues.cjs')); const result = await main({ core, githubClient: github, context }); - if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); + if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.'); - name: Download activation artifact for work queue summary if: always() continue-on-error: true diff --git a/actions/setup/js/reconcile_work_queue_run.cjs b/actions/setup/js/reconcile_work_queue_run.cjs index 565a1fe1377..86baac89522 100644 --- a/actions/setup/js/reconcile_work_queue_run.cjs +++ b/actions/setup/js/reconcile_work_queue_run.cjs @@ -146,7 +146,7 @@ async function maintenance(options = {}) { } log.diagnostic("maintenance.projection.complete", { pending: pending.length }); if (unresolved) throw reconciliationError("work_queue_maintenance_reconciliation_unresolved"); - if (pending.length && !options.deferIssueFailure) throw reconciliationError("work_queue_issue_synchronization_pending; queue transitions are committed; recover exact requests with work-queue sync-issues --request-id"); + if (pending.length && !options.deferIssueWarning) configured.core?.warning("Work queue transitions are committed; Issue synchronization remains pending. Recover the exact terminal requests with work-queue sync-issues --request-id."); return { ...result, issue_sync_pending: pending }; } diff --git a/actions/setup/js/reconcile_work_queue_run.test.cjs b/actions/setup/js/reconcile_work_queue_run.test.cjs index 0975af91239..c04440f4569 100644 --- a/actions/setup/js/reconcile_work_queue_run.test.cjs +++ b/actions/setup/js/reconcile_work_queue_run.test.cjs @@ -25,7 +25,7 @@ function setup(fixtureOptions = {}) { workflowRef: `${REPOSITORY}/${WORKFLOW}@${REF}`, readWorkQueueLog: vi.fn(fixture.readWorkQueueLog), publishWorkQueueRequest: vi.fn(fixture.publishWorkQueueRequest), - core: { info: vi.fn() }, + core: { info: vi.fn(), warning: vi.fn() }, jobNames: { activation: "activation", agent: "agent", conclusion: "conclusion" }, jobResults: { activation: { result: "success" }, agent: { result: "success" } }, sleepFn: vi.fn(async () => {}), @@ -287,10 +287,10 @@ describe("inline trusted worker termination", () => { describe("scheduled work queue recovery", () => { it.each([ - { pending: false, deferIssueFailure: false }, - { pending: true, deferIssueFailure: false }, - { pending: true, deferIssueFailure: true }, - ])("projects only this maintenance run's committed terminal requests without rollback: %j", async ({ pending, deferIssueFailure }) => { + { pending: false, deferIssueWarning: false }, + { pending: true, deferIssueWarning: false }, + { pending: true, deferIssueWarning: true }, + ])("projects only this maintenance run's committed terminal requests without rollback: %j", async ({ pending, deferIssueWarning }) => { const { fixture, options, nativeRun } = setup({ count: 1 }); const member = fixture.assignment.claims[0]; fixture.append("finish", { dispatch_id: fixture.assignment.dispatch_id, claim_handle: member.handle, outcome: "completed" }, { ...fixture.workerActor, dispatch_id: fixture.assignment.dispatch_id, claim_handle: member.handle }); @@ -306,13 +306,12 @@ describe("scheduled work queue recovery", () => { const configuration = vi.spyOn(require("./cancel_work_queue_closed_issue.cjs"), "readIssuesConfig").mockResolvedValue({ label: "work", title_prefix: "[work queue]" }); const projection = vi.spyOn(require("./work_queue_issues.cjs"), "main").mockResolvedValue({ pending: pending ? [{ reason: "unavailable" }] : [] }); try { - if (pending && !deferIssueFailure) { - await expect(maintenance({ ...options, projectIssues: true, deferIssueFailure })).rejects.toMatchObject({ - message: expect.stringMatching(/^ERR_VALIDATION: work_queue_issue_synchronization_pending; queue transitions are committed/), - code: "work_queue_issue_synchronization_pending", - category: "ERR_WORK_QUEUE_RECONCILIATION", - }); - } else expect(await maintenance({ ...options, projectIssues: true, deferIssueFailure })).toMatchObject({ issue_sync_pending: pending ? [{ reason: "unavailable" }] : [] }); + expect(await maintenance({ ...options, projectIssues: true, deferIssueWarning })).toMatchObject({ issue_sync_pending: pending ? [{ reason: "unavailable" }] : [] }); + if (pending && !deferIssueWarning) { + expect(options.core.warning).toHaveBeenCalledWith(expect.stringContaining("Issue synchronization remains pending")); + } else { + expect(options.core.warning).not.toHaveBeenCalled(); + } expect(projection).toHaveBeenCalledOnce(); const args = projection.mock.calls[0][0]; expect(args.trustedContext).toMatchObject({ role: "reconciler", workflow: publisher.path, event: "schedule" }); @@ -347,7 +346,7 @@ describe("scheduled work queue recovery", () => { }) .mockResolvedValue({ pending: [{ work_id: workId, reason: "second batch pending" }] }); try { - const result = await maintenance({ ...options, projectIssues: true, deferIssueFailure: true }); + const result = await maintenance({ ...options, projectIssues: true, deferIssueWarning: true }); expect(projection).toHaveBeenCalledTimes(2); expect(projection.mock.calls.map(([args]) => args.transitionRequestIds.length)).toEqual([16, 1]); expect(result.issue_sync_pending).toHaveLength(2); @@ -426,7 +425,7 @@ describe("scheduled work queue recovery", () => { const configuration = vi.spyOn(require("./cancel_work_queue_closed_issue.cjs"), "readIssuesConfig").mockResolvedValue({ label: "work" }); const projection = vi.spyOn(require("./work_queue_issues.cjs"), "main").mockResolvedValue({ pending: [{ reason: "mirror pending" }] }); try { - await expect(maintenance({ ...options, projectIssues: true, deferIssueFailure: true })).rejects.toThrow("work_queue_maintenance_reconciliation_unresolved"); + await expect(maintenance({ ...options, projectIssues: true, deferIssueWarning: true })).rejects.toThrow("work_queue_maintenance_reconciliation_unresolved"); expect(projection).toHaveBeenCalledOnce(); } finally { configuration.mockRestore(); diff --git a/docs/src/content/docs/reference/work-queue.md b/docs/src/content/docs/reference/work-queue.md index ef0c9ec1e9a..4e5108f6b6c 100644 --- a/docs/src/content/docs/reference/work-queue.md +++ b/docs/src/content/docs/reference/work-queue.md @@ -183,7 +183,7 @@ Resource hosts must match `GITHUB_SERVER_URL` (default `github.com`). A backing The compiler generates `agentic-workqueue.yml` for Issue events. Closing an exactly bound Issue can cancel unfinished Work after fresh identity and label checks; it cannot revoke completed delivery, stop a worker, or establish Result. -Projection hooks require `contents: write`, `issues: write`, and `actions: read`, with credentials kept outside agent execution. Failed projection does not roll back queue admission or justify rerunning a worker. Ambiguous Issue/comment creation remains pending rather than blindly creating duplicates; automatic recovery of unreceipted creation is not implemented. +Projection hooks require `contents: write`, `issues: write`, and `actions: read`, with credentials kept outside agent execution. Issue updates and coordination-lock cleanup use the same projector token; custom tokens must grant those permissions for every projected repository. Failed projection emits a warning rather than failing worker conclusion or scheduled maintenance; it does not roll back queue admission or justify rerunning a worker. Claim delivery and Result verification failures remain fatal. Ambiguous Issue/comment creation remains pending rather than blindly creating duplicates; automatic recovery of unreceipted creation is not implemented. ### Projector grants diff --git a/pkg/workflow/maintenance_workflow_work_queue_compaction.go b/pkg/workflow/maintenance_workflow_work_queue_compaction.go index b9f0edb4344..f205ed03382 100644 --- a/pkg/workflow/maintenance_workflow_work_queue_compaction.go +++ b/pkg/workflow/maintenance_workflow_work_queue_compaction.go @@ -27,14 +27,14 @@ func buildMaintenanceWorkQueueCompactionJobs(opts buildMaintenanceWorkflowYAMLOp const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs'); setupGlobals(core, github, context, exec, io, getOctokit); const { maintenance: reconcile } = require('${{ runner.temp }}/gh-aw/actions/reconcile_work_queue_run.cjs'); - const reconciliation = await reconcile({ projectIssues: true, deferIssueFailure: true }); + const reconciliation = await reconcile({ projectIssues: true, deferIssueWarning: true }); const { main: plan } = require('${{ runner.temp }}/gh-aw/actions/work_queue_compaction_plan.cjs'); const result = await plan(); if (result.status === 'planned') { const { main: apply } = require('${{ runner.temp }}/gh-aw/actions/work_queue_compaction_apply.cjs'); await apply(); } - if (reconciliation.issue_sync_pending?.length) core.setFailed('Work queue reconciliation and compaction completed; Issue synchronization remains pending. Recover the exact terminal requests with work-queue sync-issues --request-id.'); + if (reconciliation.issue_sync_pending?.length) core.warning('Work queue reconciliation and compaction completed; Issue synchronization remains pending. Recover the exact terminal requests with work-queue sync-issues --request-id.'); `) return b.String() } diff --git a/pkg/workflow/maintenance_workflow_work_queue_compaction_test.go b/pkg/workflow/maintenance_workflow_work_queue_compaction_test.go index f06f6927756..cf8dd72b452 100644 --- a/pkg/workflow/maintenance_workflow_work_queue_compaction_test.go +++ b/pkg/workflow/maintenance_workflow_work_queue_compaction_test.go @@ -19,14 +19,15 @@ func TestMaintenanceWorkQueueCompactionUsesSingleJob(t *testing.T) { assert.Contains(t, jobs, "contents: write") assert.Contains(t, jobs, "actions: read") assert.Contains(t, jobs, "maintenance: reconcile") - assert.Contains(t, jobs, "await reconcile({ projectIssues: true, deferIssueFailure: true })") + assert.Contains(t, jobs, "await reconcile({ projectIssues: true, deferIssueWarning: true })") assert.Contains(t, jobs, "issues: write") assert.Contains(t, jobs, "work_queue_compaction_plan.cjs") assert.Contains(t, jobs, "work_queue_compaction_apply.cjs") assert.Equal(t, 1, strings.Count(jobs, "script: |")) assert.Less(t, strings.Index(jobs, "await reconcile("), strings.Index(jobs, "const result = await plan()")) assert.Less(t, strings.Index(jobs, "await apply()"), strings.Index(jobs, "reconciliation.issue_sync_pending?.length")) - assert.Contains(t, jobs, "core.setFailed(") + assert.Contains(t, jobs, "if (reconciliation.issue_sync_pending?.length) core.warning(") + assert.NotContains(t, jobs, "core.setFailed(") assert.NotContains(t, jobs, "work_queue_compaction_plan:") assert.NotContains(t, jobs, "work_queue_compaction_apply:") assert.NotContains(t, jobs, "work-queue-compaction-plan") diff --git a/pkg/workflow/work_queue_issues.go b/pkg/workflow/work_queue_issues.go index 9eb32b27a47..2a32db4e33e 100644 --- a/pkg/workflow/work_queue_issues.go +++ b/pkg/workflow/work_queue_issues.go @@ -160,6 +160,6 @@ func (c *Compiler) buildWorkQueueIssuesStep(data *WorkflowData) []string { " script: |\n", " const { main } = require('${{ runner.temp }}/gh-aw/actions/work_queue_issues.cjs');\n", " const result = await main({ core, githubClient: github, context });\n", - " if (result.pending?.length) core.setFailed('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.');\n", + " if (result.pending?.length) core.warning('Work queue is committed; Issue synchronization remains pending. Inspect the exact terminal request before using work-queue sync-issues --request-id.');\n", ) } diff --git a/pkg/workflow/work_queue_issues_test.go b/pkg/workflow/work_queue_issues_test.go index bbe40b84e99..d72cf19ac72 100644 --- a/pkg/workflow/work_queue_issues_test.go +++ b/pkg/workflow/work_queue_issues_test.go @@ -139,11 +139,15 @@ func TestWorkQueueIssuesCompilationUsesExistingJobs(t *testing.T) { require.Equal(t, "always()", step["if"]) env := step["env"].(map[string]any) require.JSONEq(t, `{"label":"cookie","title_prefix":"[cookie queue]"}`, env["GH_AW_WORK_QUEUE_ISSUES"].(string)) - require.Contains(t, step["with"].(map[string]any)["script"], "core.setFailed(") + script := step["with"].(map[string]any)["script"].(string) + require.Contains(t, script, "if (result.pending?.length) core.warning(") + require.NotContains(t, script, "core.setFailed(") + require.Equal(t, "${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}", step["with"].(map[string]any)["github-token"]) + require.Contains(t, script, "githubClient: github") seen = true } if step["id"] == "detection_runs" { - require.True(t, seen, "the detection tracker follows the potentially failed Issue projection") + require.True(t, seen, "the detection tracker follows the warning-only Issue projection") require.Equal(t, "always()", step["if"], "pending mirrors must not skip required detection reporting") detectionSeen = true }