From 75533225e45a5c51a329d2f60df69724c3922488 Mon Sep 17 00:00:00 2001 From: dave Date: Mon, 27 Apr 2026 11:17:31 +0000 Subject: [PATCH] fix: commit minor fmt residue blocking mergemaster cherry-picks MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Master had 8 uncommitted single-line whitespace changes (blank-line trimming in test mod headers, etc.) left over from a previous mergemaster cargo-fmt run that didn't get committed. Each subsequent merge attempt hit: cherry-pick failed: 'Your local changes to the following files would be overwritten by merge. Please commit your changes or stash them.' So merges had been silently un-mergeable for the last several rounds — mergemaster correctly reported the issue but had no way to fix master's own state from inside the merge_workspace. Files affected (all whitespace-only): - chat/transport/matrix/bot/messages/{handle_message,on_room_message}.rs - chat/transport/slack/commands/{llm,mod}.rs - http/mcp/agent_tools/worktree.rs - http/workflow/story_ops/{create,criterion,update}.rs cargo clippy --all-targets -- -D warnings: clean cargo fmt --all --check: clean 2636 tests pass. --- .../chat/transport/matrix/bot/messages/handle_message.rs | 1 - .../chat/transport/matrix/bot/messages/on_room_message.rs | 7 ++----- server/src/chat/transport/slack/commands/llm.rs | 1 - server/src/chat/transport/slack/commands/mod.rs | 1 - server/src/http/mcp/agent_tools/worktree.rs | 2 +- server/src/http/workflow/story_ops/create.rs | 6 ++++-- server/src/http/workflow/story_ops/criterion.rs | 8 +++++--- server/src/http/workflow/story_ops/update.rs | 6 ++++-- 8 files changed, 16 insertions(+), 16 deletions(-) diff --git a/server/src/chat/transport/matrix/bot/messages/handle_message.rs b/server/src/chat/transport/matrix/bot/messages/handle_message.rs index cdb8996d..aa75b994 100644 --- a/server/src/chat/transport/matrix/bot/messages/handle_message.rs +++ b/server/src/chat/transport/matrix/bot/messages/handle_message.rs @@ -265,4 +265,3 @@ pub(in crate::chat::transport::matrix::bot) async fn handle_message( // --------------------------------------------------------------------------- // Tests // --------------------------------------------------------------------------- - diff --git a/server/src/chat/transport/matrix/bot/messages/on_room_message.rs b/server/src/chat/transport/matrix/bot/messages/on_room_message.rs index 40b43cb8..d9410eba 100644 --- a/server/src/chat/transport/matrix/bot/messages/on_room_message.rs +++ b/server/src/chat/transport/matrix/bot/messages/on_room_message.rs @@ -8,15 +8,13 @@ use matrix_sdk::{ Client, event_handler::Ctx, room::Room, - ruma::{ - events::room::message::{MessageType, OriginalSyncRoomMessageEvent}, - }, + ruma::events::room::message::{MessageType, OriginalSyncRoomMessageEvent}, }; use std::sync::Arc; use super::super::context::BotContext; -use super::super::mentions::{is_addressed_to_other, is_reply_to_bot, mentions_bot}; use super::super::format::markdown_to_html; +use super::super::mentions::{is_addressed_to_other, is_reply_to_bot, mentions_bot}; use super::super::verification::check_sender_verified; use super::handle_message; @@ -598,4 +596,3 @@ pub(in crate::chat::transport::matrix::bot) async fn on_room_message( handle_message(room_id_str, incoming_room_id, ctx, sender, user_message).await; }); } - diff --git a/server/src/chat/transport/slack/commands/llm.rs b/server/src/chat/transport/slack/commands/llm.rs index 8d167104..32c2a5c8 100644 --- a/server/src/chat/transport/slack/commands/llm.rs +++ b/server/src/chat/transport/slack/commands/llm.rs @@ -193,4 +193,3 @@ pub(super) async fn handle_llm_message( } // ── Tests ─────────────────────────────────────────────────────────────── - diff --git a/server/src/chat/transport/slack/commands/mod.rs b/server/src/chat/transport/slack/commands/mod.rs index 83050313..4889c729 100644 --- a/server/src/chat/transport/slack/commands/mod.rs +++ b/server/src/chat/transport/slack/commands/mod.rs @@ -353,7 +353,6 @@ mod tests { use super::*; use std::collections::HashMap; - #[test] fn parse_slash_command_payload() { let body = "command=%2Fhuskies-status&text=&user_id=U123&channel_id=C456"; diff --git a/server/src/http/mcp/agent_tools/worktree.rs b/server/src/http/mcp/agent_tools/worktree.rs index efabc774..74b5f3c6 100644 --- a/server/src/http/mcp/agent_tools/worktree.rs +++ b/server/src/http/mcp/agent_tools/worktree.rs @@ -2,9 +2,9 @@ use serde_json::{Value, json}; +use crate::config::ProjectConfig; use crate::http::context::AppContext; use crate::service::settings::get_editor_command; -use crate::config::ProjectConfig; use crate::worktree; pub(crate) async fn tool_create_worktree(args: &Value, ctx: &AppContext) -> Result { diff --git a/server/src/http/workflow/story_ops/create.rs b/server/src/http/workflow/story_ops/create.rs index e5b99d20..a5fc492a 100644 --- a/server/src/http/workflow/story_ops/create.rs +++ b/server/src/http/workflow/story_ops/create.rs @@ -1,8 +1,10 @@ //! create_story_file: write new story to CRDT/content store. - #[allow(unused_imports)] -use super::super::{create_section_content, next_item_number, read_story_content, replace_section_content, slugify_name, story_stage, write_story_content}; +use super::super::{ + create_section_content, next_item_number, read_story_content, replace_section_content, + slugify_name, story_stage, write_story_content, +}; pub fn create_story_file( root: &std::path::Path, diff --git a/server/src/http/workflow/story_ops/criterion.rs b/server/src/http/workflow/story_ops/criterion.rs index 8e2adf12..1345b328 100644 --- a/server/src/http/workflow/story_ops/criterion.rs +++ b/server/src/http/workflow/story_ops/criterion.rs @@ -3,8 +3,10 @@ use std::path::Path; #[allow(unused_imports)] -use super::super::{create_section_content, next_item_number, read_story_content, replace_section_content, slugify_name, story_stage, write_story_content}; - +use super::super::{ + create_section_content, next_item_number, read_story_content, replace_section_content, + slugify_name, story_stage, write_story_content, +}; pub fn check_criterion_in_file( project_root: &Path, @@ -229,10 +231,10 @@ pub fn add_criterion_to_file( /// - String → quoted unless it looks like a bool, integer, or inline sequence #[cfg(test)] mod tests { + use super::super::update_story_in_file; use super::*; use serde_json::Value; use std::collections::HashMap; - use super::super::update_story_in_file; use std::fs; #[allow(dead_code)] diff --git a/server/src/http/workflow/story_ops/update.rs b/server/src/http/workflow/story_ops/update.rs index 889cb779..65cc5ed7 100644 --- a/server/src/http/workflow/story_ops/update.rs +++ b/server/src/http/workflow/story_ops/update.rs @@ -5,11 +5,13 @@ use std::collections::HashMap; use std::path::Path; #[allow(unused_imports)] -use super::super::{create_section_content, next_item_number, read_story_content, replace_section_content, slugify_name, story_stage, write_story_content}; +use super::super::{ + create_section_content, next_item_number, read_story_content, replace_section_content, + slugify_name, story_stage, write_story_content, +}; use crate::io::story_metadata::set_front_matter_field; - fn json_value_to_yaml_scalar(value: &Value) -> String { match value { Value::Bool(b) => b.to_string(),