huskies: merge 927

This commit is contained in:
dave
2026-05-12 17:49:44 +00:00
parent b8945654bf
commit 03a99b3cf1
33 changed files with 119 additions and 25 deletions
+1
View File
@@ -225,6 +225,7 @@ async fn proxy_and_respond(state: &GatewayState, bytes: &[u8], id: Option<Value>
///
/// On sled disconnect mid-stream a JSON-RPC error event is emitted so the
/// client does not hang forever.
#[allow(clippy::string_slice)] // pos from buf.find('\n'); '\n' is ASCII so pos and pos+1 are valid boundaries
async fn proxy_and_respond_sse(state: &GatewayState, bytes: &[u8], id: Option<Value>) -> Response {
let url = match state.active_url().await {
Ok(u) => u,
+1
View File
@@ -90,6 +90,7 @@ pub(super) fn is_bug_item(stem: &str) -> bool {
}
/// Extract bug name from content (heading or front matter).
#[allow(clippy::string_slice)] // colon_pos from find(": "); +2 skips ASCII ": " → valid boundary
pub(super) fn extract_bug_name_from_content(content: &str) -> Option<String> {
// Try front matter first.
if let Ok(meta) = parse_front_matter(content)
@@ -9,6 +9,7 @@ use super::super::{
};
/// Toggle an acceptance criterion checkbox (`- [ ]` → `- [x]`) by its 0-based index among unchecked items.
#[allow(clippy::string_slice)] // indent_len = line.len() - trimmed.len(); trim() returns a sub-slice → valid boundary
pub fn check_criterion_in_file(
project_root: &Path,
story_id: &str,
@@ -107,6 +108,7 @@ pub fn remove_criterion_from_file(
///
/// Finds the criterion at `criterion_index` (0-based, counting all criteria regardless
/// of checked state) and replaces its text with `new_text`.
#[allow(clippy::string_slice)] // indent_len = line.len() - trimmed.len(); trim() returns a sub-slice → valid boundary
pub fn edit_criterion_in_file(
project_root: &Path,
story_id: &str,
+1
View File
@@ -124,6 +124,7 @@ fn format_test_line(t: &TestCaseResult) -> String {
}
/// Parse `StoryTestResults` from the JSON embedded in the `## Test Results` section.
#[allow(clippy::string_slice)] // json_end from rfind("-->") → always a char boundary
fn parse_test_results_from_contents(contents: &str) -> Option<StoryTestResults> {
for line in contents.lines() {
let trimmed = line.trim();