Skip to content

Delete the second bus install after a root is claimed - #2862

Merged
trissim merged 3 commits into
mainfrom
fix/drop-second-bus-install
Oct 23, 2026
Merged

trissim merged 3 commits into
mainfrom
fix/drop-second-bus-install

Conversation

@trissim

@trissim trissim commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

wire() claims a root, and claiming creates the root's bus (RootRuntime.adopt, root_runtime.py:69, #2854). So every Bus.install(Bus.path_in(x.root)) written after wire() installs a bus that already exists.

What this deletes

  • 60 calls in tests and tools: 59 Bus.install(Bus.path_in(<comms>.root)) lines, plus native_backend_fixture.py's Bus.install(Bus.path_in(wire(root).root)), which becomes wire(root). None are in src.
  • The two comms(comms) fixtures (test_importing.py, test_turn_goal_account.py) whose only job was that call.
  • The Bus imports those deletions left unused, plus 3 more dead imports in the touched files that ruff flagged.

What it keeps

  • Installs on directories that no wire() has claimed: check_root.py:100 (installs with history), conftest.installed_comms (models what the installer leaves on disk), test_bus*, test_install, test_cli_execution, and similar tests.

Proof (all touched test files, -p no:xdist)

  • Everything passes except reds that also fail on a fresh origin/main 082b42c worktree:
    • test_native_only_execution::test_headless_uses_existing_owner_runtime_and_owner_project and the test_acp::TestHandlers cases (intermittent): PublicationActivationBlocked: requires a private bus root.
    • 2 tests in test_owner_process, which uses the changed fixture: MissingGoalGenerationError.
  • The 12 touched non-test modules (journeys, verifiers, tools) compile, and ruff reports no F401/F811/F821 in them.

🤖 Generated with Claude Code

trissim and others added 2 commits October 23, 2026 14:22
wire() claims the root, and RootRuntime.adopt creates its bus there
(root_runtime.py:69). Sixty Bus.install(Bus.path_in(x.root)) calls after
wire() installed that bus a second time; they are gone, with the two
comms fixtures that existed only to make that call. Tests that build a bus
on a directory no root claims keep their install.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 23, 2026 18:25

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.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

…nstall

# Conflicts:
#	tests/test_acp.py
#	tests/test_command_families.py
#	tests/test_native_only_execution.py
@trissim
trissim merged commit af6dd85 into main Oct 23, 2026
1 check passed
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