Skip to content

docs(agents): --takeover only on a user's explicit request - #417

Merged
devswha merged 4 commits into
mainfrom
docs/takeover-on-request
Oct 3, 2026
Merged

devswha merged 4 commits into
mainfrom
docs/takeover-on-request

Conversation

@devswha

@devswha devswha commented Oct 3, 2026

Copy link
Copy Markdown
Owner

Change

The agent and review rules said the bridge never passes --takeover to herdr terminal attach. This changes them to say what the rule was for:

  • Still never automatic. An attach, a retry or a reconnect waits for whoever holds the terminal, as today.
  • Allowed on request. A user's explicit request for that pane, from an interact connection, may take it.

The rule dates from the first PTY attach (394e020), when herdr 0.9.0 let attaches coexist and the point was that the bridge never displaces whoever already has a terminal open. Since #197 a second web bridge on the same herdr waits for the first instead, and it has no way through when the first one's tab stays open on another device (#367).

Files: AGENTS.md, .github/REVIEW.md, .coderabbit.yaml. No code changes, and no behavior changes: nothing on main passes --takeover yet. This makes room for #368, which adds the button.

Left as they are on purpose: docs/guide.md and docs/remote-pcs.md still say no path uses --takeover. They describe what the app does, which stays true until #368 lands, so they change with it.

Validation

  • .coderabbit.yaml parses, and the server/** instruction reads as intended.
  • Docs and review-rule text only; no tests apply.

The rule was "never pass --takeover". It dates from the first PTY attach
(394e020), when herdr 0.9.0 let attaches coexist, and its point was that the
bridge never displaces whoever already has a terminal open. Since #197 a
second web bridge on the same herdr waits for the first one instead, with no
way through when that one's tab stays open on another device (#367).

The rule now says what it was for: no attach, retry or reconnect takes the
slot on the server's own initiative. A user's explicit request for that pane,
from an interact connection, may. No code changes; this makes room for #368.
@coderabbitai

coderabbitai Bot commented Oct 3, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

⚙️ Run configuration
  • Configuration used: Repository: devswha/herdr-web-ui/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: dba15822-a7f1-4e12-afce-9d2e05f3a4c9
📥 Commits

Reviewing files that changed from the base of the PR and between c9f7cc4 and f96a940.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository: devswha/herdr-web-ui/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 98f560a3-cee3-4650-8543-eb9a69879150
📥 Commits

Reviewing files that changed from the base of the PR and between cb29304 and 6700119.

📒 Files selected for processing (3)
  • .coderabbit.yaml
  • .github/REVIEW.md
  • AGENTS.md

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 4 remain after this review.


📝 Summary

Summary by CodeRabbit

  • Documentation
    • Clarified that terminal session takeover is permitted only when explicitly requested for a specific pane through an interact connection.
    • Automatic attaches, retries, and reconnects must continue waiting for the current holder. Existing guidance for terminal environment configuration and output handling remains unchanged.

Walkthrough

Three instruction files now permit --takeover only after an explicit user request for a specific pane. Automatic attaches, retries, and reconnects must wait for the current holder.

Changes

Terminal takeover guidance

Layer / File(s) Summary
Takeover rules
.github/REVIEW.md, AGENTS.md, .coderabbit.yaml
The guidance allows takeover only after an explicit user request for a pane. Automatic attaches, retries, and reconnects must wait for the current holder. Existing restrictions on node-pty, viewport snapshots, and HERDR_SOCKET_PATH remain.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Other

Merge Risk: ⚪ Minimal · up to 67001

This documentation-only change preserves the required safeguards for explicit and automatic terminal takeover.

Security Architecture Review

Security architecture risk: ⚪ Minimal · up to 67001

The change permits requested takeover while preserving the prohibition on automatic takeover. It changes guidance, not executable behavior, and no material security regression was identified in that guidance.

Retained concerns
No architecture-level concerns identified.

Security review details

Security Blast Radius

  • inferred — The authorization exception is scoped to the requested pane, not general terminal takeover authority. This PR changes how future implementations are permitted and reviewed; it does not itself add an executable takeover path.

Trust Boundaries and Controls

  • observed — The server review instruction abbreviates the restriction, omitting explicit references to interact connections and reconnects, but directs reviewers to AGENTS.md and .github/REVIEW.md, where both restrictions are stated. The omission therefore does not establish a conflicting authorization policy.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: takeover is allowed only on a user’s explicit request.
Description check ✅ Passed The description explains the problem and resulting behavior under Change. It lists validation under Validation and states why tests do not apply.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

@devswha
devswha merged commit 66ce861 into main Oct 3, 2026
4 checks passed
@devswha
devswha deleted the docs/takeover-on-request branch October 3, 2026 22:05
devswha added a commit that referenced this pull request Oct 4, 2026
Bumps package.json and herdr-plugin.toml to 0.3.49 and moves the
Unreleased notes under [0.3.49] - 2026-10-04, with the compare link.
Every entry already carries its PR link and contributor credit. Raises
the remote PC bundle to 16: a runtime notice is titled by its own first
line on a remote PC too (`source` on the notice part, #418), and the
Antigravity meter reads the token file on a Linux PC (#399). Push the
`remote-v16` tag and let the bundle workflow publish before running
release.yml.

Carries #357, #399, #411, #413, #415, #414, #416, #417, #418, #346.
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.

1 participant