You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "Astro-Han (via GitHub)" <gi...@apache.org> on 2026/08/31 15:47:31 UTC

[I] test(runtime): sandbox boundary request wait has no time budget and flakes on CI [maka]

Astro-Han opened a new issue, #4383:
URL: https://github.com/apache/maka/issues/4383

   ## Problem
   
   The `test` job on `main` failed at `6b53667` with a single test failure in `packages/runtime`:
   
   https://github.com/apache/maka/actions/runs/33407294088
   
   ```
   packages/runtime/src/__tests__/tool-runtime-sandbox-boundary.test.ts:359
   ✖ canonicalizes filesystem authority before creating durable pending state
     Error: Sandbox boundary request was not emitted
         at waitForBoundaryRequest (packages/runtime/dist/__tests__/tool-runtime-sandbox-boundary.test.js:1007:11)
   ```
   
   The failure is in the test's wait strategy, not in the code under test. `waitForBoundaryRequest` (same file, lines 1077-1086) polls the collected event array for a fixed count of macrotask ticks:
   
   ```ts
   for (let attempt = 0; attempt < 100; attempt += 1) {
     const event = events.find((candidate) => candidate.type === 'sandbox_boundary_request');
     if (event?.type === 'sandbox_boundary_request') return event;
     await new Promise((resolve) => setTimeout(resolve, 0));
   }
   throw new Error('Sandbox boundary request was not emitted');
   ```
   
   100 ticks is not a time budget. This particular case performs real filesystem work first — `mkdtemp`, `mkdir`, `writeFile`, `symlink`, `realpath` — and only canonicalizes and emits `sandbox_boundary_request` afterwards. On a loaded CI runner that IO spans far more ticks than it does locally, so the helper gives up before the event arrives. The same helper is used by three cases in the file, so any of them can fail this way.
   
   The failing commit (#4286, provider reasoning replay) does not touch sandbox boundaries, and the neighbouring `main` runs for #4323, #4356, and #3129 all passed, which is consistent with load-dependent flakiness rather than a regression.
   
   ## Desired outcome
   
   `waitForBoundaryRequest` waits on an explicit deadline instead of a tick count, so the test fails only when the request is genuinely never emitted. Either is fine:
   
   - poll until a wall-clock deadline (a few seconds) with a small interval, or
   - have the test `eventSink.push` resolve a promise for the first `sandbox_boundary_request`, removing the polling loop entirely.
   
   Production behavior must stay unchanged; this is test-infrastructure only.
   
   ## Alternatives or workarounds
   
   Re-running the job usually passes, but that hides a genuine loss of signal: the current failure message cannot distinguish "the runtime never emitted the request" from "the runner was slow".
   
   ---
   Automated disclosure: this issue was drafted by Claude at @Astro-Han's direction. @Astro-Han remains the human contributor of record.
   


-- 
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.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: [I] test(runtime): sandbox boundary request wait has no time budget and flakes on CI [maka]

Posted by "MarkGus0 (via GitHub)" <gi...@apache.org>.
MarkGus0 commented on issue #4383:
URL: https://github.com/apache/maka/issues/4383#issuecomment-5481008617

   take


-- 
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: [I] test(runtime): sandbox boundary request wait has no time budget and flakes on CI [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han closed issue #4383: test(runtime): sandbox boundary request wait has no time budget and flakes on CI
URL: https://github.com/apache/maka/issues/4383


-- 
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: [I] test(runtime): sandbox boundary request wait has no time budget and flakes on CI [maka]

Posted by "mikemikimike (via GitHub)" <gi...@apache.org>.
mikemikimike commented on issue #4383:
URL: https://github.com/apache/maka/issues/4383#issuecomment-5481338978

   I opened #4390 to address this CI flake. The test helper now waits for a bounded 5-second deadline with short polling instead of assuming 100 macrotask ticks, so slower filesystem setup has time to emit the sandbox boundary request. The focused test passes (15/15), and build, lint, format, and typecheck pass locally. The repository-wide matrix still has unrelated Windows-only failures/timeouts (Rive/remote access/SQLite and PTY/runtime-host suites).


-- 
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: [I] test(runtime): sandbox boundary request wait has no time budget and flakes on CI [maka]

Posted by "mikemikimike (via GitHub)" <gi...@apache.org>.
mikemikimike commented on issue #4383:
URL: https://github.com/apache/maka/issues/4383#issuecomment-5481712481

   Correction: after the PR was prepared, I verified that #4383 had already been claimed and assigned to MarkGus0 before my work began. I have withdrawn and closed #4390 to avoid duplicating that contribution.


-- 
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