You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "JasonBuildAI (via GitHub)" <gi...@apache.org> on 2026/10/11 12:16:02 UTC

[PR] ci: bound each Electron install attempt so a stalled download is retried [maka]

JasonBuildAI opened a new pull request, #6064:
URL: https://github.com/apache/maka/pull/6064

   ## Summary
   
   Bound every Electron installer attempt (10 minutes by default, `MAKA_ELECTRON_INSTALL_ATTEMPT_TIMEOUT_MS` to override) and treat a timed-out attempt as retryable, so `npm ci` / `npm install` can no longer hang forever when the release CDN stops progressing mid-download. `scripts/install-electron-with-retry.mjs` previously only retried failures that exited with a structured context line; a stalled download produces neither an exit nor a context line, so the retry wrapper added in #2594 never fired and `spawnSync` blocked indefinitely. Installations on such networks now get the existing five-attempt backoff, and if every attempt stalls the install fails with a diagnostic instead of hanging.
   
   Fixes #6063
   
   ## Verification
   
   - Failing-before / passing-after repro (`node --test` against the wrapper with a timed-out attempt): before the change the wrapper returned the killed attempt immediately (`AssertionError: null !== 0`); after the change it retries and the attempt succeeds.
   - `node --test scripts/install-electron-with-retry.test.mjs` — 4/4 pass, including the new timeout-retry case, a guard that terminal signals (e.g. Ctrl+C) stay immediate, and env-var resolution.
   - End-to-end with a local HTTP server that trickles a few bytes forever (no external network involved): before the change the wrapper sat silent past 120 s with the download stalled and had to be killed externally; with the change and the timeout lowered to 15 s for the demo it aborted each attempt, retried with backoff, and exited 1 after 105.6 s:
   
   ```text
   [install-electron] attempt aborted after 15000ms without completing the download
   [install-electron] attempt 1/5 timed out; retrying in 2000ms
   ...
   [install-electron] attempt 4/5 timed out; retrying in 16000ms
   [BOUNDED] exited code=1 signal=null after 105.6s
   ```
   
   - Healthy path unchanged: a cold-cache download and extract of the real 143.2 MB artifact from a mirror exits 0 in 71.2 s.
   - Machine checks: `npm run lint`, `npm run format:check`, `npm run build`, `npm run typecheck` pass. The CI-planner step (`node --test --test-concurrency=1 scripts/ci-test-plan.test.mjs scripts/ci-workflow-policy.test.mjs scripts/verify-windows-harness.test.mjs scripts/run-workspace-tests-parallel.test.mjs scripts/install-electron-with-retry.test.mjs`) reports 139 tests: 138 pass, 0 fail, 1 skipped. The skip needs a real `bash`; the WSL relay on this host fails that test on unmodified `main` as well.
   
   ## AI use
   
   Select exactly one:
   
   - [ ] No generative tool made a substantive contribution
   - [x] Generative tooling made a substantive contribution
   
   Tool(s) and scope: Codex (OpenAI) drafted the change, its tests, and this description under my direction and review.
   
   Generated-by: Codex
   
   ## Checklist
   
   - [x] Tests cover the change and fail without it
   - [x] Lint, format, typecheck and the affected suites pass locally
   
   Does this PR entail a change in behavior?
   
   - [x] Yes — described under Summary above
   - [ ] No


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] ci: bound each Electron install attempt so a stalled download is retried [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han commented on PR #6064:
URL: https://github.com/apache/maka/pull/6064#issuecomment-6135529017

   Thanks for the contribution! Merging now.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] ci: bound each Electron install attempt so a stalled download is retried [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han merged PR #6064:
URL: https://github.com/apache/maka/pull/6064


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org