Skip to content

feat(server): serve the pane mailbox on agterm-server - #996

Merged
umputun merged 6 commits into
masterfrom
server-msg-bus
Nov 14, 2026
Merged

umputun merged 6 commits into
masterfrom
server-msg-bus

Conversation

@umputun

@umputun umputun commented Nov 14, 2026

Copy link
Copy Markdown
Owner

agterm-server now serves the pane mailbox. msg send, msg read and msg ack work between panes of one agterm-server, with the same addressing, limits and replies as on a Mac.

  • closing or respawning a pane clears its mail: an ended row drops its main and split mailboxes, a closed session or deleted workspace drops its scratch's
  • the server tree reports pendingMessages on surfaces plus scratchPaneID and scratchPendingMessages on the session; the catalog carries the same counts, so a row in an agterm-server window reads them back on the Mac
  • each delivered message reaches every Mac viewing the recipient's session as a message event, from agterm-server and from a Mac origin alike
  • a Mac pane sending to a remote row gets unknown pane with detail: "remote session", a new optional field older CLIs ignore
  • Command is CaseIterable, and a test requires every command to be served on agterm-server, refused as window-only, or on an explicit undecided list

Not in this change, each with a backlog item:

  • messaging between a local Mac pane and an agterm-server pane (docs/backlog/local-to-server-messaging.md)
  • pending counts on rows attached alone with zmx attach or from another Mac; those rows get the event but read nil counts (docs/backlog/pending-counts-on-attached-rows.md)

Mail does not survive a server restart, and a reconnecting Mac gets no replay of past events.

Related to #994

A Mac pane addressing a remote row now gets unknown pane with detail
"remote session" instead of a bare rejection.
…panes

An ended row drops its main and split mail, a closed session its daemon scratch's. The server tree and catalog carry pending counts, which an attached Mac shows on the row, and each delivered message reaches every Mac viewing the recipient's session as a message event.
…er mail

Command is CaseIterable, and a test requires each command to be served, window-only or on an explicit undecided list. Docs cover msg on agterm-server, the new read-back fields and rejection detail; the local-to-server gap goes to the backlog.
…essions

Pending counts on rows attached alone or from another Mac stay unread back and are tracked in docs/backlog.
Copilot AI balanced review requested due to automatic review settings November 14, 2026 04:01

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@umputun
umputun merged commit f61cb00 into master Nov 14, 2026
10 checks passed
@umputun
umputun deleted the server-msg-bus branch November 14, 2026 04:16
umputun added a commit that referenced this pull request Nov 23, 2026
the request in discussion #994 was for messaging within one server, which #996
shipped. A cross-host reply has to reach the Mac pane that sent the message,
even when another viewer leads the server pane.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants