You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -30915,6 +30957,10 @@ use code_core::protocol::OrderMeta;
30915
30957
note.contains("Background auto-review completed and reported 1 issue(s)"),
30916
30958
"idle auto-review findings should be sent to core immediately"
30917
30959
);
30960
+
assert!(
30961
+
note.contains("Auto Review: 1 issue(s) found. needs work Merge /tmp/wt to apply fixes."),
30962
+
"developer follow-up should include the same concise notice shown in the UI"
30963
+
);
30918
30964
}
30919
30965
30920
30966
#[test]
@@ -36667,13 +36713,12 @@ impl ChatWidget<'_> {
36667
36713
})
36668
36714
}
36669
36715
36670
-
fn insert_auto_review_notice(
36671
-
&mut self,
36716
+
fn auto_review_notice_line(
36672
36717
branch: &str,
36673
36718
worktree_path: &std::path::Path,
36674
36719
summary: Option<&str>,
36675
36720
findings: usize,
36676
-
) {
36721
+
) -> String {
36677
36722
let path_text = format!("{}", worktree_path.display());
36678
36723
let has_path = !path_text.is_empty();
36679
36724
@@ -36694,6 +36739,17 @@ impl ChatWidget<'_> {
36694
36739
line.push_str(&format!("Merge {path_text} to apply fixes."));
36695
36740
}
36696
36741
line.push_str(" [Ctrl+A] Show");
36742
+
line
36743
+
}
36744
+
36745
+
fn insert_auto_review_notice(
36746
+
&mut self,
36747
+
branch: &str,
36748
+
worktree_path: &std::path::Path,
36749
+
summary: Option<&str>,
36750
+
findings: usize,
36751
+
) {
36752
+
let line = Self::auto_review_notice_line(branch, worktree_path, summary, findings);
36697
36753
36698
36754
let message_lines = vec![MessageLine {
36699
36755
kind: MessageLineKind::Paragraph,
@@ -36857,6 +36913,14 @@ impl ChatWidget<'_> {
36857
36913
resolved_worktree_path.display().to_string()
36858
36914
};
36859
36915
let errored = error.is_some();
36916
+
let notice_line = has_findings.then(|| {
36917
+
Self::auto_review_notice_line(
36918
+
&worktree_label,
36919
+
&resolved_worktree_path,
36920
+
summary.as_deref(),
36921
+
effective_findings,
36922
+
)
36923
+
});
36860
36924
let (indicator_status, developer_note) = if let Some(err) = error {
36861
36925
let summarized_error = Self::summarize_auto_review_error(&err);
36862
36926
let classification = Self::classify_auto_review_error(&err);
@@ -36873,7 +36937,8 @@ impl ChatWidget<'_> {
36873
36937
)
36874
36938
} else if has_findings {
36875
36939
let mut note = format!(
36876
-
"[developer] Background auto-review completed and reported {effective_findings} issue(s).\n\nA separate LLM ran /review (and may have run auto-resolve) in an isolated git worktree. Any proposed fixes live only in that worktree until you merge them.\n\nNext: Decide if the findings are genuine. If yes, Merge the worktree '{worktree_label}' to apply the changes (or cherry-pick selectively). If not, do not merge.\n\nWorktree path: {worktree_path_label}\n{snapshot_note}\n{agent_note}",
36940
+
"[developer] {}\n\nBackground auto-review completed and reported {effective_findings} issue(s).\n\nA separate LLM ran /review (and may have run auto-resolve) in an isolated git worktree. Any proposed fixes live only in that worktree until you merge them.\n\nNext: Decide if the findings are genuine. If yes, Merge the worktree '{worktree_label}' to apply the changes (or cherry-pick selectively). If not, do not merge.\n\nWorktree path: {worktree_path_label}\n{snapshot_note}\n{agent_note}",
36941
+
notice_line.as_deref().unwrap_or("Background auto-review found issues."),
0 commit comments