bbsbot
2026-03-19
MCP tools rewritten for direct in-process SwarmManager calls with HTTP fallback and auto-start
9 files · 454+ · 391-
MCP tools with direct manager calls and auto-start
2 files changed
control_manager.pyRewritten: direct SwarmManager method calls in-process with HTTP fallback; _ensure_manager() auto-start addedapp_factory.pyGeneric undef-terminal-manager MCP tools wired in (90 lines added)
- Rewrote
src/bbsbot/games/tradewars/mcp_tools/control_manager.py: directSwarmManagermethod calls when running in-process, HTTP fallback when the manager is a separate process harden internal1 file
control_manager.py
- Added
_ensure_manager()auto-start function: spawns the manager subprocess on the first MCP tool call and connects a WebSocket for lifecycle tracking — no manual startup required interface internal1 file
control_manager.py
- Wired generic
undef-terminal-managerMCP tools intosrc/bbsbot/mcp/app_factory.py(90 lines of additions), giving the AI assistant access to pause, resume, restart, and status tools interface internal1 file
app_factory.py
- The
control_manager.pymodule now only adds TradeWars-specific MCP tools; generic operations delegate to the undef-terminal-manager MCP layer interface internal1 file
control_manager.py
Manager plugin and spawn pipeline cleanup
4 files changed
manager_plugin.pygame_type renamed to worker_type; game_letter moved to BotStatusTradeWarsspawn.pygame_letter removed from generic spawn pipeline; game_full abort test removedswarm_manager.pySwarmManager updates for plugin refactormodels.pyModel updates for worker_type rename
- Moved
game_letterfromBotStatusBasetoBotStatusTradeWars(game-specific field no longer on base class) decouple internal2 files
manager_plugin.pymodels.py
- Renamed
game_type→worker_typeinsrc/bbsbot/games/tradewars/manager_plugin.pydecouple internal1 file
manager_plugin.py
- Added
raw_configparameter toconfigure_worker_envfor passing raw config dicts into worker environment setup baseline internal1 file
manager_plugin.py
- Removed
game_letterfrom the generic spawn pipeline insrc/bbsbot/api/swarm/spawn.pyinterface behavioral1 file
spawn.py
- Removed
game_fullabort test (feature removed from the generic manager) qualify behavioral1 file
test_swarm_routes_events.py