From b8716ed849952dd3d230a4a396fc925dc64b451d Mon Sep 17 00:00:00 2001 From: DanConwayDev Date: Fri, 13 Feb 2026 17:51:52 +0000 Subject: fix: preserve progress bars on relay errors during clone fetching_with_report_for_helper unconditionally cleared the progress reporter, wiping error bars that showed relay timeouts. Only clear when all relays succeeded (or in verbose mode where bars were always visible), matching the pattern in fetching_with_report. --- src/bin/git_remote_nostr/main.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/bin/git_remote_nostr/main.rs b/src/bin/git_remote_nostr/main.rs index 3663d5b..41164fe 100644 --- a/src/bin/git_remote_nostr/main.rs +++ b/src/bin/git_remote_nostr/main.rs @@ -167,6 +167,7 @@ async fn fetching_with_report_for_helper( &HashSet::new(), ) .await?; + let has_errors = relay_reports.iter().any(std::result::Result::is_err); let report = consolidate_fetch_reports(relay_reports); if report.to_string().is_empty() { if verbose { @@ -175,6 +176,8 @@ async fn fetching_with_report_for_helper( } else { term.write_line(&format!("nostr updates: {report}"))?; } - let _ = progress_reporter.clear(); + if !has_errors || verbose { + let _ = progress_reporter.clear(); + } Ok(()) } -- cgit v1.2.3