feat: Windows is not an OS grid this product serves - #82
Merged
Conversation
Removes `windows` from the closed token set. A Windows machine now takes the branch a BSD takes: no token, no `os=` on the wire, and D-k's `unsupported_system` sentence naming the set it is outside of — which is more actionable than `not_served`, since that one invites waiting for a deployment that is never coming.⚠️ This is the one token the set has ever LOST rather than never had, and that asymmetry is the whole risk. Every other absence here is one nobody has to remember — `other`, FreeBSD, a frozen build naming no system. `windows` is different: `platform.system()` obviously knows about it, `host.platform_kind()` still carries it (a build target is not a community), and every map in this feature looks incomplete without it. So the removal is stated where somebody editing the map will read it, and pinned by a test that asserts the ABSENCE — no parametrize can fail for a row that is simply no longer there.⚠️ Removing the token does NOT stop an existing Windows grid serving, and the code cannot do that half. The served list governs CREATION only; admission is grid-apis `store.os_gate_for`, which compares a claim against the row's own `access_os` and never consults it. So a CLI old enough to still claim `windows` — v0.3.29 and earlier — keeps being admitted to a `windows` grid that is still `active`. Retiring the OS needs the grid taken out of service too, which is what `os_grids_enabled`'s docstring already said: "drop its token … and stop the grid". Measured today: PROD has no Windows grid; dev has one. Three existing tests lost their MEANING rather than a line, and are rewritten rather than deleted: - `is_served_os_token("windows") is False` under an explicit `GRID_OS_GRID _TOKENS` now reads False whether that list is honoured or ignored. The excluded token has to be one the DEFAULT serves, so it is `omarchy`. - The switch-off test asked with `os=windows`, so `[]` would have had two causes at once and the test would no longer isolate the switch. It asks with `linux`. - The unique-index re-claim test used `windows` as an arbitrary token. The store does not consult the served list so it still passed, but the vocabulary would have told the next reader this product supports Windows. Also fixes a latent version of the hazard the omarchy commit named: `_absence` and `_refresh_body` did not stub `_OS_RELEASE`, so their Linux cases were statements about whatever host ran the suite rather than about the code. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01HXNAadpsFfETXENbie3p91
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.
Removes
windowsfrom the closed OS-token set. Windows is not an operating system this product serves an OS grid for.A Windows machine now takes the branch a BSD takes: no token, no
os=on the wire, and D-k'sunsupported_systemsentence naming the set it is outside of — which is more actionable thannot_served, since that one invites waiting for a deployment that is never coming.The control-plane half is
autonomous-ai/autonomous-grid-be@9f384ed, already on that repo'smain.os=windows→ the Windows gridos=at all → "No OS grid for Windows: grid has one only for macos, linux and omarchy"Every other absence in ADR 0039 is one nobody has to remember —
other, FreeBSD, a frozen build naming no system.windowsis different:platform.system()obviously knows about it,host.platform_kind()still carries it (a build target is not a community), and every map in this feature looks incomplete without it.So the removal is stated where somebody editing the map will read it —
os_grid._BY_SYSTEM,os_networks.DEFAULT_SERVED_OS_TOKENS,_OS_LABELS— and pinned by a test that asserts the absence. No parametrize can fail for a row that is simply no longer there.The code cannot do that half. The served list is consulted only by
ensure_pending_os_network, so it governs creation; admission is grid-apisstore.os_gate_for, which compares a request's claim against the row's ownaccess_osand never consults it.So a CLI old enough to still claim
windows— v0.3.29 and earlier — keeps being admitted to awindowsgrid that is stillactive. Retiring the OS needs the grid taken out of service too, which is exactly whatos_grids_enabled's docstring already said: "drop its token … and stop the grid".Measured today: PROD has no Windows grid; the dev VM has one, and it is being taken down alongside this change.
Three tests lost their MEANING, not a line — rewritten rather than deleted
is_served_os_token("windows") is Falseunder an explicitGRID_OS_GRID_TOKENS: withwindowsgone from the default this readsFalsewhether the explicit list is honoured or ignored, so it proved nothing. The excluded token now has to be one the default does serve —omarchy.GRID_OS_GRID_ENABLED-off test asked foros=windows, so[]would have had two causes at once and the test stopped isolating the switch. It asks forlinux.windowsgrid. The store never consults the served list so it passed either way, but the vocabulary would have told the next reader that Windows is supported.Also fixed here
A latent version of the hazard the omarchy PR named:
_absenceand_refresh_bodydid not stub_OS_RELEASE, so theirLinuxcases were statements about whatever host ran the suite rather than about the code.Rollout
No ordering in either direction, and that is a change from the omarchy PR: removing a token is a narrowing. A Windows machine loses its grid when its own CLI upgrades, not when the control plane deploys; and the grid stays reachable for old CLIs until it is stopped, whichever side ships first.
Test plan
pytest tests/— 0 failures (re-run after mergingmain)pytest tests/— 1157 passed, 0 failedruff— no new findings (98 on the changed files atHEAD, 98 after; the repo-wide 483 is pre-existing baseline)windowsgrids🤖 Generated with Claude Code
https://claude.ai/code/session_01HXNAadpsFfETXENbie3p91