chore: add more logging in /render to debug

This commit is contained in:
2026-05-31 15:28:16 -04:00
parent 5e989289bd
commit c03ccc9d39

View File

@@ -340,11 +340,22 @@ pub async fn handle(state: State, interaction: Interaction) {
let after_start = datetime - start;
let progress_by_time = after_start / duration;
let origin = (after_start.whole_seconds() as u32 * sample_rate)
+ (after_start.subsec_microseconds() as u32 * sample_rate / 1_000_000);
let origin = origin as usize;
tracing::debug!(origin, total_samples);
let progress_by_sample = (origin as f64) / (total_samples as f64);
tracing::debug!(
progress_by_time,
progress_by_sample,
?after_start,
?duration,
origin,
total_samples
);
for (i, sample) in samples.into_iter().enumerate() {
if let Some(composite_sample) = composite.get_mut(origin + i) {