fix(tmux): correct cross-socket sender identity (#808) #809
Reference in New Issue
Block a user
Delete Branch "fix/808-agent-send-false-sender"
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?
Root cause
The sender self-lookup reused the destination tmux socket arguments. For cross-socket sends,
tmux -L "$SOCKET_NAME" display-message -p '#S'therefore asked the destination server for its session and stamped a holder/garbage identity into the preamble. Because that lookup succeeded, the?fallback never ran and flipped replies routed to a non-participant.Fix
MOSAIC_AGENT_NAME, exported into every agent pane, as the authoritative sender session name.tmux display-message -p '#S'on the sender's local/default socket with no destination-Largument, preserving|| echo "?"for genuinely unknown senders.-L "$SOCKET_NAME"behavior unchanged.TDD evidence
RED against the unpatched tool:
bash packages/mosaic/framework/tools/tmux/agent-send.test.shPASS=12 FAIL=3destination-holder.GREEN after the fix:
PASS=15 FAIL=0pnpm typecheck: 42/42 taskspnpm lint: 23/23 taskspnpm format:check: passedAuthor-only lane: independent review and merge are intentionally left to the assigned reviewer and MS Team Lead.
Fixes #808