Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Unreleased
- Support `gpt_5_1_2025_11_13`, `gpt_5_4_2026_03_05`, `gemini_2_5_pro`, and `gemini_3_1_pro_preview` model versions
- Fix downloaded packages placing extension-less documents at the package root instead of in the `documents/` folder
- Fix `re package download` progress bar showing more progress than the total when the dataset's comment count is approximate

# v0.39.0
- Allow `re get comments --reviewed-only` to be combined with dataset filters
Expand Down
4 changes: 2 additions & 2 deletions cli/src/commands/package/download.rs
Original file line number Diff line number Diff line change
Expand Up @@ -598,7 +598,7 @@ fn get_ixp_progress_bar(total_comments: u64, statistics: &Arc<Statistics>) -> Pr
let num_annotations = statistics.num_annotations();
let num_docs_written = statistics.num_document_writes();
(
((num_comments + num_docs_downloaded + num_docs_written) / 3) as u64,
(num_comments + num_docs_downloaded + num_docs_written) as u64,
format!(
"{} {} {} {} {} {} {} {}",
num_comments.to_string().bold(),
Expand All @@ -613,7 +613,7 @@ fn get_ixp_progress_bar(total_comments: u64, statistics: &Arc<Statistics>) -> Pr
)
},
statistics,
Some(total_comments),
Some(total_comments * 3),
crate::progress::Options { bytes_units: false },
)
}
12 changes: 10 additions & 2 deletions cli/src/progress.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,14 +107,22 @@ where
let progress_fn = progress_fn;
let statistics = Arc::clone(&statistics);
let sleep_duration = Duration::from_millis(100);
let mut current_max = max_progress_value;

while report_progress.load(Ordering::SeqCst) {
thread::sleep(sleep_duration);
let (progress_value, message) = progress_fn(&statistics);
progress_bar.set_position(progress_value);
progress_bar.set_prefix(message);
match max_progress_value {
Some(value) => progress_bar.set_message(format!("{progress_value} / {value}")),
match current_max {
Some(value) => {
let display_total = progress_value.max(value);
if display_total > value {
progress_bar.set_length(display_total);
current_max = Some(display_total);
}
progress_bar.set_message(format!("{progress_value} / {display_total}"));
}
None => progress_bar.set_message(format!("{progress_value}")),
};
}
Expand Down
Loading