From 893172f57d8a0fdab2f3750f89d0f766ab821839 Mon Sep 17 00:00:00 2001 From: l0ng-ai <24760907+l0ng-ai@users.noreply.github.com> Date: Mon, 7 Sep 2026 11:24:37 +0800 Subject: [PATCH] fix(control): raise the dialect to v9 rather than walk it back to 7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reverting the projects layer took CONTROL_VERSION back to 7 with the verbs it had been raised for. The dialect that number describes is correct — this build speaks v7's messages again, one for one — but the number is not, because v8 is already deployed. A version that moves backwards stops being an identity. A 7 on the wire would mean "before projects" or "after them" depending on which build sent it, and the handshake has nothing but the number to tell those apart: a v8 peer would read our 7 as an older server it may keep talking to, and every project verb it pushed would fail to decode and drop the link. v9 is a number no peer has seen, so a v8 peer is turned away at the handshake instead. Nothing else changes; every other reference to the constant is relative to it. Claude-Session: https://claude.ai/code/session_015q6HRem76HYy33T39bp34c --- crates/tty7-core/src/daemon/control.rs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/crates/tty7-core/src/daemon/control.rs b/crates/tty7-core/src/daemon/control.rs index 4172676c..e2ec9f0a 100644 --- a/crates/tty7-core/src/daemon/control.rs +++ b/crates/tty7-core/src/daemon/control.rs @@ -34,7 +34,16 @@ use super::protocol::{MAX_FRAME, read_frame, write_frame}; /// refusing to kill a server it has nothing to replace with — can be exercised /// against the v6 servers already deployed. A number is the only way to reach /// that path, and a mismatch nobody can reproduce is a mismatch nobody can fix. -pub const CONTROL_VERSION: u32 = 7; +/// +/// v8 added the project verbs; v9 takes them back out. The dialect this build +/// speaks is v7's again, message for message, but the number does not go back +/// to 7 with it: v8 is deployed, and a number that moves backwards stops being +/// an identity and becomes a coincidence. A 7 on the wire would then mean +/// either "before projects" or "after them" depending on which build put it +/// there, and the handshake — which has nothing but the number — cannot tell +/// the two apart. A v8 peer meeting this one must be turned away, and only a +/// number it has never seen does that. +pub const CONTROL_VERSION: u32 = 9; const DIALECT_MARKER: &str = "speaks control v";