dave
0dff2d5c47
refactor: split http/mcp/mod.rs into 3 logical files
...
The 1882-line mod.rs is split into:
- tools_list.rs: handle_tools_list — the static schema for every MCP tool (1172 lines)
- dispatch.rs: handle_tools_call — the tool-name → *_tools router (157 lines)
- mod.rs: doc, sub-mod decls, JsonRpc structs, Poem handlers, handle_initialize (586 lines)
Tests stay co-located with the code they exercise.
No behaviour change. All 267 http::mcp tests pass; full suite green
(2635 tests with --test-threads=1).
2026-04-26 21:05:07 +00:00
dave
8f91f55cd1
refactor: split io/fs/scaffold.rs into 4 sub-modules with co-located tests
...
The 2045-line scaffold.rs is split into a sub-module directory:
- templates.rs: STORY_KIT_* and DEFAULT_* template constants (161 lines)
- detect.rs: detect_components_toml + detect_script_{build,lint,test} + tests (989 lines)
- helpers.rs: write_*_if_missing, generate_project_toml, gitignore helpers (166 lines)
- mod.rs: scaffold_story_kit orchestrator + scaffold tests (756 lines)
include_str! paths in templates.rs are adjusted (one extra ../) for the deeper
nesting. Tests stay co-located with the code they exercise per Rust convention.
No behaviour change. All 77 scaffold tests pass; full suite green
(2635 tests with --test-threads=1).
2026-04-26 21:00:31 +00:00
dave
23e22ba49c
refactor: split crdt_state.rs into 6 sub-modules with co-located tests
...
The 2122-line crdt_state.rs is split into a sub-module directory:
- types.rs: CRDT/view types + CrdtEvent (247 lines)
- state.rs: CrdtState struct, statics, init, apply_and_persist (531 lines)
- ops.rs: sync API + apply_remote_op + delta-sync tests (455 lines)
- write.rs: write_item + bug_511 test (273 lines)
- read.rs: read API + dump + dep helpers (469 lines)
- presence.rs: node identity + claim API + heartbeat (176 lines)
- mod.rs: doc, sub-module decls, re-exports, hex helper (53 lines)
Tests are co-located with the code they primarily exercise per Rust convention.
No behaviour change. All 26 crdt_state tests pass; full suite green
(2635 tests with --test-threads=1).
2026-04-26 20:54:15 +00:00
dave
8bdaabd06c
refactor: split crdt_sync.rs into auth/wire/server/dispatch/client modules
...
The 3672-line crdt_sync.rs is split into a sub-module directory with
co-located tests per Rust convention:
- auth.rs: trusted-keys + bearer-token validation (230 lines)
- wire.rs: ChallengeMessage / AuthMessage / SyncMessage types (141 lines)
- server.rs: WebSocket server handler (1680 lines)
- dispatch.rs: incoming-message dispatch + bulk/clock/op handling (1028 lines)
- client.rs: rendezvous client + reconnect/backoff (464 lines)
- mod.rs: doc, cross-cutting constants, re-exports (75 lines)
No behaviour change. All 65 crdt_sync tests pass; full suite green
(2635 tests with --test-threads=1).
2026-04-26 20:36:40 +00:00
dave
795b172bba
Revert "refactor: split top-5 largest files into mod.rs + tests.rs"
...
This reverts commit 65a3767a7a .
2026-04-26 20:15:58 +00:00
dave
65a3767a7a
refactor: split top-5 largest files into mod.rs + tests.rs
...
Five files in server/src/ exceeded 1500 lines, with 50–75% of the line
count being inline `#[cfg(test)] mod tests { ... }` blocks. Agents
working on these files have to navigate huge buffers via Read calls,
costing turn budget that could go toward actual work.
Pattern: convert `foo.rs` to `foo/mod.rs` + `foo/tests.rs`.
Rust resolves `mod foo;` to either form, so no parent-module changes
needed.
Before / after (production-code lines, what an agent has to navigate
when editing the module):
crdt_sync.rs: 3672 → 1003 (mod.rs) + 2667 (tests.rs)
crdt_state.rs: 2122 → 1263 (mod.rs) + 854 (tests.rs)
io/fs/scaffold.rs: 2045 → 702 (mod.rs) + 1342 (tests.rs)
http/mcp/mod.rs: 1882 → 1410 (mod.rs) + 472 (tests.rs)
http/mcp/story_tools.rs: 1864 → 725 (mod.rs) + 1137 (tests.rs)
Side change: scaffold/mod.rs's include_str! paths got an extra `../`
because the file moved one directory deeper.
Tests: full `cargo test` suite passes (2635 passed, 0 failed).
Formatting: cargo fmt --check clean.
Motivation: today's agent thrashing on 644 / 650 / 652 was partly due to
cumulative-counting (now fixed by 650) but also genuinely due to file
size — sonnet's 50-turn budget barely covers reading these files plus
making the change. Smaller production-code files mean more turn budget
left for the actual work.
Committed straight to master because this is an enabling refactor for
agent autonomy work; running it through the normal pipeline would
require an agent that has to navigate the very files it's about to
split, defeating the purpose.
2026-04-26 20:08:24 +00:00
dave
ff51a1a465
huskies: merge 651_bug_remove_git_reset_clean_behaviour_from_bug_645_s_recovery_path_uncommitted_work_in_worktrees_is_never_junk
2026-04-26 16:46:25 +00:00
dave
365b907ba4
huskies: merge 650_bug_watchdog_turns_used_and_budget_used_usd_accumulate_across_all_sessions_restart_counts_against_limits_from_prior_runs
2026-04-26 16:24:10 +00:00
dave
148c88bd40
huskies: merge 646_bug_watchdog_from_bug_624_is_not_actually_enforcing_max_turns_max_budget_usd_in_production
2026-04-26 13:11:48 +00:00
dave
8673e563a9
huskies: merge 643_story_web_ui_consumer_for_the_unified_status_broadcaster
2026-04-26 11:30:32 +00:00
dave
f88bb5f486
huskies: merge 645_bug_agent_runtime_panics_with_output_write_bytes_is_ok_assertion_marking_stories_falsely_blocked
2026-04-26 10:54:58 +00:00
dave
d8f9be5b23
huskies: merge 641_story_unified_status_update_delivery_across_chat_web_ui_and_top_level_agent_context
2026-04-26 02:27:34 +00:00
dave
dc7ae3a23c
huskies: merge 637_story_peer_mesh_discovery_via_crdt_node_presence_list
2026-04-26 01:57:31 +00:00
dave
b84ce1f6bb
huskies: merge 636_story_full_crdt_snapshot_compaction_with_cross_node_coordination
2026-04-26 01:19:05 +00:00
dave
c12a49487e
huskies: merge 634_story_deterministic_claim_priority_via_hash_based_tie_break
2026-04-25 22:27:20 +00:00
dave
7548486a53
huskies: merge 633_story_crdt_sync_bearer_token_connection_auth
2026-04-25 22:13:42 +00:00
dave
d826daaf41
huskies: merge 632_story_crdt_sync_handshake_with_explicit_ready_ack
2026-04-25 21:51:09 +00:00
dave
fd52c29302
huskies: merge 631_story_crdt_delta_sync_via_vector_clocks_replace_full_bulk_dumps
2026-04-25 21:32:39 +00:00
dave
853f53e8e6
huskies: merge 630_story_crdt_sync_websocket_keepalive_ping_pong
2026-04-25 21:10:06 +00:00
dave
14b158d0b2
huskies: merge 629_refactor_migrate_commanddispatch_and_commandcontext_to_services_bundle
2026-04-25 20:41:19 +00:00
dave
2a3f88fdcf
huskies: merge 639_refactor_migrate_whatsapp_transport_to_services_bundle
2026-04-25 19:51:59 +00:00
dave
120745d102
huskies: merge 640_bug_create_story_create_refactor_create_bug_silently_drop_the_depends_on_parameter
2026-04-25 19:37:55 +00:00
dave
e4dd4bbe2c
huskies: merge 638_refactor_migrate_discord_transport_to_services_bundle
2026-04-25 19:33:01 +00:00
dave
33cb2bed3e
huskies: merge 627_refactor_migrate_slack_discord_and_whatsapp_transports_to_services_bundle
2026-04-25 19:01:45 +00:00
dave
4b089c1ed8
huskies: merge 626_refactor_introduce_services_bundle_and_migrate_appcontext_matrix_transport
2026-04-25 15:08:46 +00:00
dave
aeff0b55be
huskies: merge 628_story_websocket_connect_time_mutual_auth_using_node_identity_primitives
2026-04-25 14:33:47 +00:00
dave
9e3d2f6a69
huskies: merge 602_spike_node_identity_keypair_foundation_for_distributed_huskies
2026-04-25 14:03:59 +00:00
dave
61da29a904
huskies: merge 625_bug_cannot_add_acceptance_criteria_to_a_spike_that_s_been_converted_to_a_story
2026-04-25 13:42:56 +00:00
dave
2097787e1f
docs: add pipeline state machine reference (current + planned transitions)
...
Captures the dual representation we have today (legacy filesystem stage
strings + front-matter flags vs the typed Stage/ArchiveReason/ExecutionState
enums in pipeline_state.rs that are defined-but-not-wired) and itemises the
transitions and behaviours we have identified as missing or partially
implemented (first-class supersede/abandon/hold verbs, type-conversion side
effects, pinned-agent honouring under contention, blocked-flag enforcement
beyond auto-assign, ghost-story recovery, etc.).
Section (b) is intended as a living dumping ground — append new
transitions and incidents as they come up so that the state-machine
roadmap (spike 613 in backlog) has a ready-made input.
2026-04-25 13:33:57 +00:00
dave
e20083a283
huskies: merge 624_bug_agent_turn_and_budget_limits_not_enforced_coder_1_ran_5_6x_over_max_turns
2026-04-25 13:11:30 +00:00
dave
b70ee1aa4b
huskies: merge 622_story_wrap_react_state_updates_in_act_to_silence_frontend_test_warnings
2026-04-24 23:02:52 +00:00
dave
e1bfbf4232
huskies: merge 619_story_service_common_consolidation_sweep
2026-04-24 21:36:49 +00:00
dave
c16d9e471d
huskies: merge 618_story_extract_mcp_only_domain_services
2026-04-24 21:16:19 +00:00
dave
360bca45c8
huskies: merge 617_story_split_gateway_into_service_and_transport
2026-04-24 18:43:26 +00:00
dave
271f8ea6a8
huskies: merge 616_story_extract_notifications_service
2026-04-24 18:05:42 +00:00
dave
eca0ef792c
huskies: merge 615_story_extract_timer_service
2026-04-24 17:43:53 +00:00
dave
62bfaf20f4
huskies: merge 611_story_extract_settings_service
2026-04-24 17:11:55 +00:00
dave
da6ae89667
huskies: merge 610_story_extract_wizard_service
2026-04-24 16:46:09 +00:00
dave
60a9c87794
huskies: merge 609_story_extract_oauth_service
2026-04-24 16:19:26 +00:00
dave
2dc2513fac
huskies: merge 620_refactor_enforce_test_fixture_discipline_in_service_modules
2026-04-24 16:07:00 +00:00
dave
65c896f07f
huskies: merge 608_story_extract_io_and_anthropic_services
2026-04-24 15:54:50 +00:00
dave
aba3120388
huskies: merge 607_story_extract_bot_command_service
2026-04-24 15:28:03 +00:00
dave
1910365321
huskies: merge 606_story_extract_project_service
2026-04-24 15:01:04 +00:00
dave
d9e883c21d
huskies: merge 612_story_extract_ws_service
2026-04-24 14:36:44 +00:00
dave
4a80600e22
huskies: merge 614_bug_gateway_web_ui_has_no_vertical_scrollbars
2026-04-24 14:25:09 +00:00
dave
23890a1d33
huskies: merge 605_story_extract_events_and_health_services
2026-04-24 14:08:39 +00:00
dave
2f07365745
huskies: merge 604_story_service_module_conventions_and_first_extraction
2026-04-24 13:45:22 +00:00
dave
3521649cbf
huskies: merge 599_story_cross_project_status_notifications_in_chat
2026-04-23 12:09:35 +00:00
dave
4b765bbc39
huskies: merge 601_story_project_local_agent_prompt_layer_for_huskies
2026-04-23 11:56:19 +00:00
dave
c9e8ed030e
huskies: merge 600_story_gateway_aggregated_pipeline_status_mcp_and_chat
2026-04-23 10:42:37 +00:00
dave
b3da321a3b
huskies: merge 598_story_expose_huskies_init_as_a_gateway_mcp_tool
2026-04-22 21:39:29 +00:00
dave
f2d9926c4c
huskies: merge 597_bug_rmtree_command_missing_from_web_ui_slash_dispatch
2026-04-21 12:29:51 +00:00
dave
135e9c4639
huskies: merge 596_bug_restore_missing_htop_command_in_bot_and_web_ui
2026-04-21 12:17:06 +00:00
dave
b77e139347
huskies: merge 593_bug_web_ui_work_item_detail_panel_returns_404_for_crdt_only_stories
2026-04-17 13:59:35 +00:00
dave
43ca0cbc59
huskies: merge 595_story_web_ui_settings_page_with_form_based_project_toml_editor
2026-04-17 13:38:09 +00:00
dave
982e65aec5
huskies: merge 594_story_scaffold_project_toml_includes_all_configurable_settings_with_comments
2026-04-17 12:45:09 +00:00
dave
4b710b02f2
huskies: merge 591_story_gateway_chat_commands_use_active_project_root_instead_of_gateway_config_dir
2026-04-16 16:14:05 +00:00
dave
e734e80da5
huskies: merge 590_story_gateway_native_mcp_tools_return_json_rpc_responses_missing_request_id
2026-04-16 11:41:52 +00:00
dave and Claude Opus 4.6
4ddf2a4367
fix: strip front matter from show command, display useful metadata inline
...
Strips the YAML front matter block and shows useful fields
(depends_on, agent, blocked, retries) as a summary line at the top.
Eliminates the duplicate title problem.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-16 09:01:54 +00:00
dave and Claude Opus 4.6
2b95388efd
fix: convert markdown headings to bold in show command for Matrix rendering
...
Element X doesn't style <h2> tags distinctly. Convert ## headings to
**bold** text with a blank line above for consistent rendering across
all Matrix clients.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-16 08:47:41 +00:00
dave
9f0274417d
huskies: merge 579_bug_matrix_bot_messages_render_markdown_headings_without_line_breaks_or_formatting
2026-04-16 08:22:34 +00:00
dave
df2f20a5e5
huskies: merge 589_story_wizard_auto_detects_project_components_and_configures_scripts_accordingly
2026-04-16 00:22:53 +00:00
dave
61502f51d9
huskies: merge 588_bug_wizard_generated_script_test_misses_frontend_tests_for_projects_with_a_frontend
2026-04-15 23:57:12 +00:00
dave
4553d7215a
huskies: merge 586_bug_wizard_skips_context_and_stack_generation_when_files_already_exist_from_scaffold
2026-04-15 23:52:25 +00:00
dave
4a1c6b4cfa
huskies: merge 585_bug_bot_not_aware_of_actual_running_port_defaults_to_3001
2026-04-15 23:47:37 +00:00
dave
2663c5f91f
huskies: merge 583_bug_add_test_that_builds_gateway_route_tree_to_catch_duplicate_route_panics
2026-04-15 19:57:12 +00:00
dave
79ee19ca5b
huskies: merge 587_bug_pipeline_db_not_in_default_gitignore_novice_users_will_commit_it
2026-04-15 19:49:46 +00:00
dave
871a18f821
huskies: merge 584_bug_bot_asks_user_to_run_huskies_init_instead_of_running_wizard_automatically
2026-04-15 19:28:58 +00:00
dave and Claude Opus 4.6
0969fb5d51
fix: remove duplicate / route in gateway that causes panic on startup
...
gateway_index_handler and embedded_index both registered at /. The
embedded React frontend should serve /. Remove the old gateway
index handler.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-15 18:57:35 +00:00
dave
744cc9dca4
huskies: merge 569_story_gateway_ui_cross_project_pipeline_status_view
2026-04-15 18:38:33 +00:00
dave
ce37281333
huskies: merge 571_story_expose_agent_remaining_turns_and_budget_via_mcp_tool
2026-04-15 18:30:32 +00:00
dave
149a383447
huskies: merge 568_story_gateway_ui_connected_agents_dashboard
2026-04-15 18:25:17 +00:00
dave
d68614e26a
huskies: merge 580_story_diff_bot_command_shows_git_diff_from_main_branch_to_worktree_branch
2026-04-15 18:16:26 +00:00
dave and Claude Opus 4.6
a4480fa067
chore: feed CONTEXT and STACK specs to all agents, update STACK with source map
...
Agents now read specs/00_CONTEXT.md (what the project does) and
specs/tech/STACK.md (tech stack + source map) in addition to the
README. STACK.md rewritten to reflect current state — removes stale
references to biome, tauri-specta, .story_kit.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-15 18:15:09 +00:00
dave
beb84ade9f
huskies: merge 567_story_gateway_ui_project_management_add_and_remove_projects
2026-04-15 18:06:43 +00:00
dave
d235fd41ac
huskies: merge 581_story_freeze_command_to_hold_a_story_at_its_current_stage_without_advancing
2026-04-15 18:02:14 +00:00
dave
2246278845
huskies: merge 582_story_bot_configuration_page
2026-04-15 17:37:52 +00:00
dave
d80fc143c2
huskies: merge 577_bug_show_command_reads_story_files_from_filesystem_instead_of_crdt
2026-04-15 17:28:05 +00:00
dave
1fe4ca2b7a
Revert "huskies: merge 566_story_gateway_ui_bot_configuration_page"
...
This reverts commit c28c86dbc6 .
2026-04-15 17:13:01 +00:00
dave
c28c86dbc6
huskies: merge 566_story_gateway_ui_bot_configuration_page
2026-04-15 14:12:23 +00:00
dave
70fecafd41
huskies: merge 576_bug_overview_command_reads_story_files_from_filesystem_instead_of_crdt
2026-04-15 14:06:31 +00:00
dave
c34b119526
huskies: merge 575_bug_unblock_command_reads_story_files_from_filesystem_instead_of_crdt
2026-04-15 13:53:21 +00:00
dave
0bf715d9bb
huskies: merge 574_bug_depends_bot_command_broken_after_removing_filesystem_story_files
2026-04-15 13:38:27 +00:00
dave
7fa31c03a3
huskies: merge 573_story_remove_criterion_mcp_tool_to_delete_an_acceptance_criterion
2026-04-15 13:23:18 +00:00
dave and Claude Opus 4.6
483489cc44
fix: rewrite coder agent prompts — run tests before commit, remove stale instructions
...
Key changes:
- Tests before commit, not after: "run run_tests, fix failures, then commit"
- Removed polling references (run_tests blocks now)
- Removed "never run script/test" (primes agents to think about it)
- Removed dead "user review" instruction
- Removed "commit and stop" which signalled skip-testing
- Cleaner workflow: implement → check criteria → test → fix → commit → exit
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-15 13:19:08 +00:00
dave
ec40b4771b
huskies: merge 572_story_edit_criterion_mcp_tool_to_update_acceptance_criteria_text
2026-04-15 13:03:55 +00:00
dave
52b21c22b1
huskies: merge 566_story_gateway_ui_bot_configuration_page
2026-04-14 18:57:32 +00:00
dave and Claude Opus 4.6
8936abd8cd
docs: add project architecture section to README for agent context
...
Agents need to know the gateway is a mode of the binary, not a
separate app, and that UI stories are frontend React work, not
Rust backend restructuring.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-14 16:23:18 +00:00
dave
8482df2f4e
huskies: merge 570_bug_merge_agent_work_should_check_if_story_is_already_done_before_attempting_merge
2026-04-14 16:15:29 +00:00
dave and Claude Opus 4.6
28adef9739
chore: switch mergemaster to opus and add cargo fmt guidance
...
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-14 12:35:57 +00:00
dave and Claude Opus 4.6
badfabcf5e
chore: switch mergemaster to opus and add cargo fmt guidance
...
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-14 12:27:58 +00:00
dave
d0d2b17484
huskies: merge 563_story_build_agent_join_mechanism_agents_register_with_the_gateway_via_token
2026-04-14 12:06:13 +00:00
dave
efe434ede3
huskies: merge 565_story_gateway_web_ui_shell_with_project_switcher
2026-04-14 11:28:55 +00:00
dave
df5ba8ebab
huskies: merge 560_story_make_merge_agent_work_return_results_like_run_tests_instead_of_polling
2026-04-14 10:26:44 +00:00
dave
ff1149750b
huskies: merge 561_bug_mcp_tools_matching_mcp_huskies_allowlist_still_trigger_permission_prompts
2026-04-14 10:19:51 +00:00
dave
d824dc4b73
huskies: merge 558_story_matrix_bot_can_run_on_the_gateway_to_manage_multiple_projects_from_one_chat
2026-04-14 10:01:04 +00:00
dave and Claude Opus 4.6
28777b0c77
fix: simplify boolean in validate_working_dir to satisfy clippy nonminimal_bool
...
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-14 09:52:51 +00:00
dave and Claude Opus 4.6
f412c7dee6
fix: cargo fmt the merge_workspace validation code
...
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-14 09:43:18 +00:00
dave and Claude Opus 4.6
44fe52195e
fix: allow MCP tools to access merge_workspace so mergemaster can fix conflicts
...
The permission lockdown restricted run_command/run_tests to
.huskies/worktrees/ only. The mergemaster could diagnose merge
conflict compile errors but couldn't edit files in .huskies/merge_workspace/
to fix them. Add merge_workspace as an allowed path.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-14 09:21:39 +00:00
dave
979cf39228
huskies: merge 557_refactor_remove_all_filesystem_fallback_paths_crdt_is_the_only_source_of_truth
2026-04-14 09:14:07 +00:00