Skip to content

PLATFORM-TEMIZLIK: macOS/Windows platform verification from 148 failures to 2 (alpha.41 candidate) - #92

Merged
AlbSar merged 15 commits into
mainfrom
platform/temizlik
Oct 15, 2026
Merged

AlbSar merged 15 commits into
mainfrom
platform/temizlik

Conversation

@AlbSar

@AlbSar AlbSar commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

Owner 2026-10-15 "Beta öncesi temizlik"; trial budget 4 hosted runs; 2026-10-16 "Şimdi indir, 2 test açık".

  • Shards: platform verify split into 4 shards per OS×Node (scripts/platform-shard.mjs); ~12 min instead of ~18. Shard 1 runs lint/native/host/smoke. A failed test step no longer hides the later checks.
  • Tests: Linux-only features skip off Linux with [requires Linux …]. Windows product gaps skip only on win32 with [unsupported on Windows: …]. Fixtures are cross-platform: USERPROFILE, host layout platform, no literal /tmp. Timing fixes cover PTY key drivers, the approval R3 race, and hostBound() scaling of fixed waits. No test skips on Linux.
  • Product: BACKUP_IO keeps its cause; the local OS identity is read after the policy loads (socket peer still verified first).
  • deps-watch: an unavailable upstream advisory list or npm metadata keeps the report red but no longer closes the pin gate; signatures, OSV and unknown sources still block. Bounded fetch backoff.
  • Docs: known limits for native Windows and macOS; roadmap PLATFORM-TEMIZLIK + WINDOWS-NATIVE; Astra 2578 P2 notes.

Hosted tries: 38804553793 → 38814829682 → 38816414038 → 38818112622 (14/16 shards green). Two macOS timing tests stay open and are not skipped. Linux full suite on 5db6cc8: 8547 passed, 1 known-env failure.

🤖 Generated with Claude Code

https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP

AlbSar and others added 15 commits October 15, 2026 22:46
… PLATFORM-TEMIZLIK

Owner 2026-10-15 ("Beta öncesi temizlik"): the nightly macOS/Windows
platform verification has been red since at least 2026-10-07 and runs
the whole suite on one runner (8–18 min per job, 20-min step bound).
scripts/platform-shard.mjs keeps every check of `npm run verify`: each
shard runs verify-context, build, the native test variants and its
quarter of Vitest; shard 1 also runs lint:checks, test:native,
test:host and smoke. Unlike verify, a failed test step no longer hides
the later checks; a failed build still stops the shard. The frozen
verify-job guard admits exactly these four edits.
The roadmap gets PLATFORM-TEMIZLIK (pre-beta) and the post-beta
WINDOWS-NATIVE gaps item. Astra 2578 P2 notes: ARCHITECTURE names SDK
2.3.1; dependencies.json names the 4.6.7 core zod.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…product gaps named

PLATFORM-TEMIZLIK worker A. The nightly windows-latest verify (run 38793038837 at b63d92c) failed 118 tests in 37 files. Linux behaviour
is unchanged: every touched file runs the same tests on Linux as before (394 = 392 + 2 new simulation tests, 1 existing skip).

Fixture plumbing (the tests assumed a POSIX host):
- tests/contracts/support/host-platform.ts: hostLayoutPlatform() (the mapping production passes to resolveProductLayout) and homeEnv()
  (HOME + USERPROFILE; the product reads USERPROFILE on native Windows); host-platform-fixture.test.ts simulates both for win32 on any host.
- USERPROFILE beside HOME: query-error-disclosure, config-surface, terminal-delivery-window, init-policy-command, policy-upgrade-command,
  terminal-first-test-fixes, terminal-info-windows-workline (its "timed out waiting for budget choice" was the unresolved home), the
  instruction window CLI test.
- Literal '/tmp' -> os.tmpdir(): source-build-bwrap, config-surface home.
- PATH delimiter/dirname in the config discovery bound test; '/'-normalised source paths in worker-tree-gate-paths; the reader's canonical
  root (8.3 temp names) in the project instruction path assertions.
- worker-tree-gate: no FIFO on win32, so the expected findings drop only the special-file row there (Linux expectation identical).
- audit-checkpoint: the doctor/verify fail-open test registered no `terminal` config section and passed only after an earlier composed
  test (it failed alone on Linux too); it now registers the provider config itself.
- binding-capability: hostBindingStrength() follows the product capture on every host (Windows reaches weak/location, as the doctor
  reports); installationBindingNotRunReason() keeps win32 not-run explicitly, so its consumers are unchanged.
- project instructions: native Windows cannot verify a private trust directory; the fixtures open the reader the way the product does there
  (no directory) and assert that a directory is refused ('unsafe').

Platform skips (Linux never skips; bracketed reason in the title):
- [requires Linux local runtime socket]: the two controlled-socket service tests (also failed on macOS: LOCAL_RUNTIME_UNSUPPORTED).
- [requires POSIX ...] (win32 only): bubblewrap/Landlock view tests, chmod-0 unreadable entry, controlled POSIX Docker daemon (its stale
  win32 pre-check expected SUPERVISOR_OPTIONS_INVALID, which the supervisor no longer raises).
- [unsupported on Windows: ...] product gaps: OS-user identity (backup, identity preview, admission actor), managed private ledger files,
  installation policy template (POSIX layout + OS-user identity), layout resource editor, project instruction trust cache, CLI JSON file
  input (no O_NOFOLLOW).

Not changed: the Windows-only audit-checkpoint claim (product reads the OS identity before refusing POLICY_UNAVAILABLE) and the macOS
backup BACKUP_IO (worker B).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
An untyped storage failure was mapped to BACKUP_IO and the original error was
dropped, so the macOS platform-verify backup failures named no reason. The
original error now travels only as the DeckentError cause; the code, the
localized message and the audit event (code only) are unchanged, and no
surface renders the cause. Vitest prints it as "Caused by", so the next hosted
macOS run shows the real reason.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
… Linux with their reason

run-create-approval-plan opens a live OS session (LocalOsSessionAuthority reads
/proc) and worker-image-cancel runs the Linux process runner; on macOS both
refuse by design (SESSION_REQUIRED, PROCESS_RUNNER_UNSUPPORTED). They now skip
off Linux with a [requires Linux ...] tag instead of failing; Linux runs them
unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
… CoreFoundation encoding variable

The helper is spawned with env {} (helper.ts); on macOS CoreFoundation inside
the child sets __CF_USER_TEXT_ENCODING at startup, so the child's process.env
was never empty there. Only on darwin, and only in CoreFoundation's exact
0x<uid>:0x<enc>:0x<region> form, that one key is set aside; every other key
still fails, and Linux keeps the exact empty-environment equality. The canary
check now runs on the raw helper output.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…xed sleep

terminal-panels-pty (macOS, every run) and config-records-ink (macOS node 24,
once on Windows) sent keys a fixed 60/50 ms apart. On a slow runner the child
reads two keys at once: Ink keeps "\r\r" as one text event (no key), and a
key can reach handlers before the previous key's state is drawn. Reproduced
on Linux: the PTY failure with a CPU-starved child (old driver 3 fail, new
driver pass) and the Ink failure with a 1 ms pause (old 7 fail, new 7 pass).
The PTY driver now sends the next key once the child has drawn and gone quiet
(bounded 1 s); '+' steps still look only at what their keys drew. The Ink
press waits for a drawn frame (bounded 300 ms) and positive port answers wait
via vi.waitFor; every assertion, including the negative ones, is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…n it does not exit

On macOS the compiled MCP server answers over the FIFO but is still alive 10 s
after its input closes (SIGTERM by the test timer); a Linux replay with
process.platform forced to darwin exits in 16 ms, so no JS platform gate holds
it. An unref'd 8.5 s timer preloaded into the child now writes
getActiveResourcesInfo() and stdin end/destroy state to stderr, and the exit
assertion shows that file, so the next hosted macOS run tells a FIFO EOF that
never arrived from a product handle. A prompt exit is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…ORM-TEMIZLIK)

BACKUP_IO now carries its cause (f81f419). These assertions compared
only the code, so a macOS BACKUP_IO would still hide its reason. The
code assertions are unchanged; the cause becomes the assertion message.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
… so backup, monitor, model calls, Brain and acceptance do not run there; green platform skips are not support

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…; macOS MCP proof over a pipe; host tooling not run on Windows

Hosted platform run 38804553793 (try 1 of 4, owner budget):
- macOS backup/restore failed with BACKUP_IO, whose preserved cause is
  LocalRuntimeSocketError LOCAL_RUNTIME_UNSUPPORTED: backup and restore
  coordinate with the runtime service over the Linux-only local socket.
  The 17 tests that failed on macOS now skip off Linux with that reason;
  the backup tests that passed on macOS keep running there.
- macOS MCP identity proof: the server never saw the FIFO EOF
  (MCP_LIVE_HANDLES: PipeWrap only, stdinEnded false), a kqueue FIFO
  transport effect. Linux keeps the FIFO proof; macOS runs the same
  assertions over an ordinary pipe. Both paths pass on Linux.
- Windows shard 1 ran test:host for the first time (verify used to stop
  before it). The .agents/refactor host tooling is Linux/WSL-only, so it
  is reported as not run on Windows.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…orted policy custody refuses POLICY_UNAVAILABLE first

Owner 2026-10-15 ("Sırayı düzelt"). loadConfiguredScopeContext passed
readLocalOsIdentity() as an argument, so the identity was read before
config and policy. On native Windows that refused AUTHENTICATION_REQUIRED
where the existing audit-checkpoint proof requires POLICY_UNAVAILABLE
before any ledger/key/identity access. The local path now reads the
identity after the policy parses. The socket-peer path still verifies
the peer first, so an unauthenticated caller learns nothing about policy
availability. Linux full suite: 8547 passed, 1 failed (the known-env
installation-apply-adoption timeout), 8 skipped.
Known limits: macOS lacks the Linux-only local runtime socket, so the
service transport, backup and restore do not run there.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…s the pin gate; bounded backoff on fetches

Owner 2026-10-15 ("Kapıyı daralt"). In the try-1 dispatch the GitHub
advisories for containers/bubblewrap did not answer; the report counted
that as watch-incomplete and closed the integrity gate. Upstream
repository advisories ("GitHub advisories <repo>") and npm version
metadata ("npm registry") say nothing about the installed tree's
integrity, so they keep the report red but no longer block a verified
pin candidate. Incomplete registry signatures, OSV (which carries npm
malware advisories) and any future source still block (fail closed).
The token stays out of the watch job. Fetches get 3 attempts with 2 s
and 4 s waits instead of an immediate single retry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…cision, not after a fixed 150 ms

Windows node 24 failed "timed out waiting for late refusal of A" in the
analysis run 38793038837 and in try 2 (38814829682). Card A expired
150 ms after it was requested, but the test needs that window for
render + Ctrl+O + 40 ms + 'y'. On a slow runner the keys arrived after
A expired, so A was never decided and no late refusal could come. A
now expires only once its decision is in flight; the scenario (an old
card's late refusal never touches the next card) is unchanged.
Linux with keys slowed by 200 ms: the old version fails with the
Windows signature, the new one passes. 12/12 pass three times as
written.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…t bound on slow hosted runners

Try 3 (38816414038) failed only on macOS node 24 with three
multi-process timeouts. Two had already appeared in try 1:
PURGE_CHILD_BARRIER_TIMEOUT (5 s) and CONCURRENT_SERVICE_TIMEOUT (3 s);
the third was the 60 s allocation timing test. These waits ignored
DECKENT_TEST_TIMEOUT_MS, which the platform cells raise to 120 s because
of their 3–4 vCPU runners. hostBound() scales a fixed wait by that
bound: unchanged at the 30 s default (Linux CI, local), ×4 on macOS and
Windows. A hang still fails, only later.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
…(owner 2026-10-16); CHANGELOG alpha.41

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017uL4HZTS1oaVHovPUKoRXP
@AlbSar
AlbSar merged commit cf8915f into main Oct 15, 2026
42 of 45 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant