You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
mcpx: Phase 2 of #2209 — one predicate vocabulary: route scattered revision comparisons through internal/spec #2211
Phase 2 of design #2209 (origin #1974, ex-nix#307). Independent of Phase 1. Design doc: files/designs/code-mcpx-spec-revision-choice.md in the keep-the-four-repos-healthy goal workspace.
Scope
One predicate vocabulary for revision comparisons, exactly as internal/spec's package comment already prescribes ("Code asks the active Policy … never by comparing date strings in place"). Today the predicates spec.AtOrAfter/Before/Only/Between have zero callers outside internal/spec, and comparisons are scattered:
internal/mcpserver/revisions.go:40-44 defines a package-local AtLeast duplicating spec.AtOrAfter's semantics, used by Defines and internal/mcpserver/conn.go. Make it delegate to spec.AtOrAfter, or delete it in favour of direct predicate use at the call sites. (internal/mcpserver already imports internal/spec — see relay.go.)
internal/mcpserver/server.go:1285Modern() is a raw version >= "2026-07-28" — use spec.AtOrAfter("2026-07-28").
internal/mcpclient/modern.goCallerLegacy uses a raw v < "2026-07-28" — use spec.Before("2026-07-28").
internal/mcpclient/client.go:455 uses a raw ir.ProtocolVersion >= "2025-03-26" — use spec.AtOrAfter.
Semantics are identical today (revisions are ISO dates and compare lexically; both forms reject the empty string), so this is a refactor, not a behaviour change. Out of scope, named deliberately: genuine identity equalities such as internal/mcpclient/request.go:54 (negotiated == one specific revision) stay as they are.
Acceptance criteria
No package outside internal/spec implements its own revision-ordering comparison; mcpserver.AtLeast delegates or is gone
Modern(), CallerLegacy, and the client.go:455 check go through internal/spec predicates
No test changes its verdict (full pkgs/mcpx suite in CI); any test that does change is a stop-and-report, not an adjustment
No behaviour change: nothing about what mcpx sends, accepts, or answers is different
Design #2209 filed today (origin #1974). This phase is a sub-issue of #2209 and is independent of Phase 1. Triage packet enqueued: pilot task 3319 (queue=repo-health-code-pilot, status=queued, verified). Decision is recorded on #2209.
Checked against current origin/main (2026-10-30 ~11:50Z):
spec.AtOrAfter/Before/Only/Between have zero callers outside internal/spec — only spec.Current().Governs() is consulted (relay.go:106, client.go:556) plus Order()/StrictTable() reporting. Confirmed.
All four scattered sites present: package-local AtLeast (mcpserver/revisions.go, keeps empty-returns-false semantics), Modern() as version >= "2026-07-28" (server.go:1311), CallerLegacy as v != "" && v < "2026-07-28" (modern.go:246), >= "2025-03-26" gate in client.go. Confirmed.
Sharp edges for the implementation pass (settled as must-cover, not open):
Empty-string semantics must survive verbatim at every site — AtLeast("")==false, CallerLegacy requires non-empty. Cover each with an edge test; the no-verdict-change acceptance is the gate.
Design line pins drifted since 319e6c2 — re-pin every cited site.
The four design open questions stay explicitly OPEN for implementation judgment; no triage-side shrinking.
Follow-up: implementation packet enqueued as queue task 3939. Lane note: laptop gh token was stale here; notes posted with transient GH_TOKEN from vault key github-cli.hosts-yml.
Expectation: effort/m — done = PR merged with the full pkgs/mcpx suite's verdicts unchanged in CI
Links: PR mcpx: route revision comparisons through internal/spec predicates (#2211) #2849 (branch queue/3952-2211-spec-predicates, commit f1c413a) — AtLeast delegates to spec.AtOrAfter; Modern(), CallerLegacy, the client.go listen check, and elicitModeDeclared (fifth same-pattern site in a triage-named file) converted. daemon/hooks.go:291 deliberately left (empty-Negotiated-passes semantics; outside the named packages) and flagged on the PR.
Activity
developing-today commentedon Oct 29, 2026
CODE-1093
dezren39 commentedon Oct 29, 2026
Design #2209 filed today (origin #1974). This phase is a sub-issue of #2209 and is independent of Phase 1. Triage packet enqueued: pilot task 3319 (queue=repo-health-code-pilot, status=queued, verified). Decision is recorded on #2209.
dezren39 commentedon Oct 30, 2026
Agent note — picked up (queue task 3319, openchamber scheduled lane)
Claimed 2026-10-30 ~11:48Z. Triage pass: Phase 2 scope checked against current origin/main, verdict follows in the next note.
dezren39 commentedon Oct 30, 2026
Agent note — triage verdict: scope CONFIRMED (queue task 3319)
Checked against current origin/main (2026-10-30 ~11:50Z):
spec.AtOrAfter/Before/Only/Betweenhave zero callers outsideinternal/spec— onlyspec.Current().Governs()is consulted (relay.go:106, client.go:556) plusOrder()/StrictTable()reporting. Confirmed.AtLeast(mcpserver/revisions.go, keeps empty-returns-false semantics),Modern()asversion >= "2026-07-28"(server.go:1311),CallerLegacyasv != "" && v < "2026-07-28"(modern.go:246),>= "2025-03-26"gate in client.go. Confirmed.Sharp edges for the implementation pass (settled as must-cover, not open):
AtLeast("")==false,CallerLegacyrequires non-empty. Cover each with an edge test; the no-verdict-change acceptance is the gate.Follow-up: implementation packet enqueued as queue task 3939. Lane note: laptop
ghtoken was stale here; notes posted with transient GH_TOKEN from vault keygithub-cli.hosts-yml.1 remaining item
dezren39 commentedon Oct 30, 2026
🤖 Agent note · triaged
1281cb37. All four sites exist with minor drift:Modern()atserver.go:1311(was :1285), listen check atclient.go:461(was :455),CallerLegacyatmodern.go:246exact,AtLeastatrevisions.go:40exact with 5conn.gocallers +Definesfloors/ceilings. Predicates (spec.go:168-186) have zero outside callers;AtLeast≡AtOrAftersemantically.mcpserveralready importsspec. No competing PR (recent mcpx client: legacy Streamable HTTP and stdio robustness — session 404, GET stream, SSE retry, string ids, stream timeout, version header #1924/mcpx client: cannot reach a conformant 2026-07-28 server #1918 touches merged, unrelated). Independently landable as one refactor — follow-up enqueued (dedupe...:issue:2211).dezren39 commentedon Oct 30, 2026
🤖 Agent note · picked up
queue/3952-2211-spec-predicates, commit f1c413a) — AtLeast delegates to spec.AtOrAfter; Modern(), CallerLegacy, the client.go listen check, and elicitModeDeclared (fifth same-pattern site in a triage-named file) converted. daemon/hooks.go:291 deliberately left (empty-Negotiated-passes semantics; outside the named packages) and flagged on the PR.mcpx: route revision comparisons through internal/spec predicates (#2211
dezren39 commentedon Oct 30, 2026
🤖 Agent note · done