Repository navigation
Fix #236: a refused computer setup fails the bootstrap with its own error - #241
Merged
Merged
Conversation
…rror The Sky facade's proxy answered every unadvertised member after a failed setup with a function rejecting with it, then included, so the bootstrap's loadComputer (an async function returning the proxy) never settled, and in the own kernel the synthetic then's rejection went unhandled and reset the kernel. The proxy now reads then, toJSON and every symbol as undefined, and exports setupError, which loadComputer throws: the first cell fails with the setup's own sentence instead of an unknown target. A declared difference from the vendor's sky.js, recorded in the own-host spec's Decision Log and in sky.test.mjs's vendor differential. Sminos-Session: cursor235#b93055dd (cua on macbook)
Sminos-Session: cursor235#b93055dd (cua on macbook)
Sminos-Session: cursor235#b93055dd (cua on macbook)
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
SSFSKIM
added a commit
that referenced
this pull request
Nov 1, 2026
Brings main's #235 (cua's own macOS agent cursor, #240), #236's fix (#241), #200 (#243) and #244 (#247) under M3, so M3's gate judges the tree that ships. A merge, not a rebase: the spec and the evidence cite this branch's commit SHAs. The overlapping files and how each was resolved: - src/runtime/launch.mjs (conflict): both sides kept. M3's Linux branch (cua's own service: CUA_SKY_SERVICE, CUA_ENGINE_BIN and CUA_DESKTOP_MODE for the cua selection, the vendor service and helper otherwise) beside #240's macOS branch, which adds the agent cursor's environment (cursorEnv) to cua's engine. The env header comment merged cleanly with both sides' entries. - src/runtime/doctor-engine.mjs (auto-merged): #240's macOS row (the cursor switch in factsReport, cursorWords, settingsOf's cursor check) and M3's Linux row (service cua, capabilities, the IsEnabled row) touch separate functions; kept as merged. - src/cua-api/sky.mjs and test/cua-api/sky.test.mjs (auto-merged): #241's fix for #236 (setupError exported, then/toJSON/symbols read undefined after a failed setup, the declared vendor difference and its settle test) beside M3.2's truncated-field scenario. Compatible by design: cua's Linux service's setup always resolves with the 20 methods and keeps a failure for each method to refuse with, so the facade's setupError stays unset there; a setup that does throw now fails the bootstrap with its own error instead of hanging. - tech-debt-tracker.md (conflict): every row from both sides kept, main's five newer rows first (74 at the base, +2 M3, +6 main = 82). - .claude-plugin/plugin.json, marketplace.json (conflict): main's 0.20.3 here; M3's own bump follows in its own commit. Focused suites (services, facade, doctor, selection, harness, accept, cursor) on the merged tree: 1948 pass, 8 fail; the same 8 fail on both parents in this VM (umask 077 modes, macOS-only and env tests). Sminos-Session: linux171#3c5ca588 (cua on dc-linux171-1e68)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #236
When the computer surface's Sky setup is refused (a broken install, a missing service, a trusted RPC failing at setup), the first cell now fails with the setup's own error. Before, the bootstrap never settled. In the own kernel it was worse: the rejection went unhandled, and the kernel reset with "node_repl kernel unhandled rejection: …". The new kernel test reproduced exactly that on main.
Cause. After a failed setup, the vendor-ported proxy in
src/cua-api/sky.mjsanswered every member it did not have,thenincluded, with a function that rejects with the setup error. That made the proxy look like a promise.create-tinysky-alt.mjs'sloadComputeris an async function that returns the proxy, so returning it called the fakethen. Thatthennever resolved or rejected the outer promise, and the rejected promise it returned had no handler.Fix.
then,toJSONand every symbol-keyed member: the members JavaScript reads on its own, without the agent asking for them. Any other missing member still returns the rejecting function, socua.computer.click()after a failed setup still rejects with the setup error.sky.mjsexportssetupError, andloadComputerthrows it. Fixingthenalone is not enough: the bootstrap's next step would fail on the undefined target withUnreachableCaseErrorinstead of the setup's sentence.sky.js. It is declared intest/cua-api/sky.test.mjs's vendor differential (adiffersfield, asfacade-vendor.test.mjsuses) and in the own-host spec's Decision Log.Tests (written first; they failed on main).
sky.test.mjs: after a failed setup,then,toJSONand the symbols read undefined whileclickis still a function. A separate own-only test checks that a promise resolved with the proxy settles and leaves no unhandled rejection.bootstrap-kernel.test.mjs: the full bootstrap in a real own kernel, with surfacescomputerandbrowser,computer. Each cell fails withsky helper unavailableand the kernel does not reset.CUA_NODE, vendor differential on):test/cua-api/*127 passed, 0 failed (31 skips are the browser-client differential and zod). The parity inventory, capability-api and services-sky suites: 59 passed. The ticket's repro now prints{"state":"resolved","unhandled":[]}.The plugin goes to 0.20.1 (
plugin.jsonandmarketplace.json), in separate commits, following #148's patch bump for a runtime fix.Review and CI. doperpowers:reviewer-medium on 7a24390..c386ee4: "correct", no findings. ci-gate on c386ee4: GREEN (test, plugin, sandbox-live), https://github.com/SSFSKIM/cua/actions/runs/41256497726
Sminos-Session: cursor235#b93055dd (cua on macbook)