Repository navigation
fix(ci): retry transient npm advisory timeouts - #137716
Conversation
Co-authored-by: Dallin Romney <[email protected]>
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
🦞👀 Re-review progress:
|
|
Codex review: blocked before merge. Reviewed September 3, 2026, 8:52 PM ET / September 4, 2026, 00:52 UTC. ClawSweeper reviewWhat this changesThe PR retries a timed-out npm bulk-advisory request once with a fresh abort controller and timer, while preserving immediate failure for HTTP, malformed-response, and unrelated errors. Merge readiness⛔ Blocked before merge - 3 items remain Keep open. No blocking correctness or security finding was identified: the retry is placed at the shared npm bulk-advisory boundary used by both audit consumers, and current main still has the one-attempt behavior. The protected Priority: P2 Review scores
Verification
How this fits togetherThe dependency-audit tooling sends resolved package versions to npm’s bulk advisory endpoint. Its results feed the pre-commit security gate and the release dependency-vulnerability gate, which fail closed on audit errors. flowchart LR
A[Dependency lockfiles] --> B[Dependency audit]
B --> C[NPM bulk advisory request]
C --> D{Tagged timeout?}
D -->|first timeout| E[Fresh request lifecycle]
D -->|other failure| F[Fail closed]
E --> G[Advisory results]
G --> H[Pre-commit and release gates]
Before merge
Agent review detailsSecurityNone. PR surfaceTests +140, Other +13. Total +153 across 3 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Retain the domain-local, exactly-once retry at the npm bulk-advisory owner; do not generalize retry policy into the timeout helper used by unrelated upstream-advisory requests. Do we have a high-confidence way to reproduce the issue? Yes, source-reproducible: the focused tests induce an aborted five-millisecond request and verify recovery through both the direct owner and release-gate caller. This read-only review did not execute target tests. Is this the best way to solve the issue? Yes. The retry belongs at the shared npm bulk-advisory owner, so pre-commit and release auditing share one bounded policy without altering unrelated upstream-advisory behavior. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against ddb6a70c044c. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Maintainer review complete for the three
No |
…date-command * origin/main: fix(ci): retry transient npm advisory timeouts (#137716) fix: keep restored Usage navigation from being replaced by Chat (#137402) fix: keep Usage day totals within the selected session scope (#137396) refactor: reduce live digest scheduling allocations (#137655) fix(ui): submit selected slash arguments in new sessions (#137571) fix(ui): expand collapsed task progress on final (#137569) fix(test): prevent auth discovery from stalling MCP replacement proof (#137639) test(cli): reuse canonical directory mock call helper (#137640)
Co-authored-by: Dallin Romney <[email protected]>
* fix(cron): allow pinned widget updates * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: 6f3f9c02-ebb9-494d-bf74-e0f2cd28cff7 * fix(cron): keep widget prompt within compact budget Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: b5e9377a-9f92-4e2e-8a88-9ed60172f26e * ci: refresh checks against current main * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: 22166308-a697-45ab-84ca-a425f1513dd8 * fix(ci): retry transient npm advisory timeouts (#137716) Co-authored-by: Dallin Romney <[email protected]> * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: 3b52db99-2781-4524-a579-4878b5923a17 * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: 5505caac-c55a-419b-aff2-7b02575bb186 --------- Co-authored-by: roboclaw-bot <[email protected]> Co-authored-by: Patrick-Erichsen <[email protected]> Co-authored-by: Vincent Koc <[email protected]> Co-authored-by: Dallin Romney <[email protected]>
Co-authored-by: Dallin Romney <[email protected]>
…37666) * fix(cron): allow pinned widget updates * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: 6f3f9c02-ebb9-494d-bf74-e0f2cd28cff7 * fix(cron): keep widget prompt within compact budget Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: b5e9377a-9f92-4e2e-8a88-9ed60172f26e * ci: refresh checks against current main * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: 22166308-a697-45ab-84ca-a425f1513dd8 * fix(ci): retry transient npm advisory timeouts (openclaw#137716) Co-authored-by: Dallin Romney <[email protected]> * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: 3b52db99-2781-4524-a579-4878b5923a17 * fix(cron): let session automations refresh pinned widgets Worked on by: - @Patrick-Erichsen Co-authored-by: Patrick-Erichsen <[email protected]> OpenClaw-Publication: 5505caac-c55a-419b-aff2-7b02575bb186 --------- Co-authored-by: roboclaw-bot <[email protected]> Co-authored-by: Patrick-Erichsen <[email protected]> Co-authored-by: Vincent Koc <[email protected]> Co-authored-by: Dallin Romney <[email protected]>
Supersedes #137615
What Problem This Solves
Fixes an issue where pre-commit and release dependency audits could fail after a single transient timeout from npm's bulk advisory endpoint.
Why This Change Was Made
The shared advisory fetch boundary now retries exactly once only when its own tagged 60-second timeout fires, with a fresh request, abort controller, timer, and response lifecycle. HTTP failures, malformed or oversized responses, and unrelated errors still fail immediately.
This supersedes #137615 because that branch has
maintainerCanModify=falseand its proposed implementation is materially different: it raises the timeout and adds a pre-commit-only exported retry wrapper. This version keeps the existing limits and applies the retry at the shared boundary used by both pre-commit and release audits.Credit to Dallin Romney (@RomneyDa) for identifying the transient advisory timeout and proposing retry behavior.
User Impact
Operators get one bounded recovery attempt for transient npm advisory timeouts without weakening fail-closed dependency checks or delaying other failures.
Evidence
node scripts/check-changed.mjs -- ...was also recorded passing locally before the PR.security-fastjob 100871005983, the audit command ran from00:52:37.003Zthrough successful output at00:53:38.424Z(about 61.4 seconds), demonstrating one 60-second timeout followed by a successful fresh retry.openclaw/ci-gatejob 100871425435 passed.security-fastjob 100870692546 completed the audit command in about 17.5 seconds, confirming npm endpoint recovery. The earlier HTTP 503 failed closed; no unchanged manual retry was used as evidence.git diff --check: passed.+13: the added lines own one bounded retry with fresh request, abort, timer, and response lifecycles for both audit callers.