Send added fields to every peer instead of gating them #127
No reviewers
Labels
No labels
Area/ci
Area/cli
Area/client
Area/client-core
Area/daemon
Area/deps
Area/docs
Area/grid
Area/manual
Area/nix
Area/protocol
Area/pty
Area/render
Area/shaping
Area/skills
Area/transport
Area/vt
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Performance
Kind/Security
Kind/Testing
perf-regression-accepted
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Blocked
Status
Need More Info
Status
Upstream
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
felis-terminal/felis!127
Loading…
Reference in a new issue
No description provided.
Delete branch "protocol/ungated-fields"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Split out of #67. Until now, a field added in a later protocol minor had to be stripped at every send site an older peer could be on. This PR sends added fields to every peer by default and keeps the send gate only for a field an older peer must not skip. The OSC 7501
SessionInfo.program_statusfield (PR 4) then needs oneADDED_FIELDSrow instead of three downgrades plus three send sites.Why
An older decoder skips an unknown field number, so a field sent to a peer that predates it lands that peer exactly where leaving the field out would. For a field that only adds detail, the downgrade buys nothing.
It is not safe for every field, and three cases stay gated:
oneof. An older peer skips it, reads the oneof as unset, and rejects the message.SearchQuery.source: an older daemon would skip it and answer a scrollback search, so the client keeps refusing locally.What changes
minor.rs:ADDED_FIELDSlists the ungated fields for the ledger sync test. Today that isImageVirtualPlacement.placement_idandImagePlacement.requested.GatedFieldnow holds onlySearchQuery.source.ImageMsg::for_minorand its daemon fan-out call are gone, andstreaming::body_forno longer takes a minor.Schema tests, which parse
felis.protointo statements rather than matching lines:reserved, and the correlation envelope.Receive-side test: a stand-in for the minor-0 schema reads a virtual placement carrying
placement_idthe same as one without it. The current decoder accepts the body an older sender writes.Docs:
ipc.md: "Versioning" and the minor-1 ledger row.architecture/ipc.md: "The ledger is the review gate".testing.md.extend-ipcskill.A field is ungated only when its ledger row can state a safe outcome for an older peer that skips it, in either direction.
Verification
just checkis green.reserved 99; uint32 extra = 5;to a wrapper, or a new member toImageHeader.target, fails the build.