chore: log more stuff around rendering to debug

This commit is contained in:
2026-05-28 02:45:16 -04:00
parent 4463ff7b3a
commit c351358947
3 changed files with 14 additions and 16 deletions

View File

@@ -2,19 +2,12 @@ use std::{convert::Infallible, fmt::Display};
use opendal::Operator;
use opus2::Application;
use songbird::driver::SampleRate;
use time::{
UtcDateTime,
format_description::{self, StaticFormatDescription},
macros::format_description,
};
use time::{UtcDateTime, format_description::StaticFormatDescription, macros::format_description};
use twilight_model::id::{
Id,
marker::{ChannelMarker, GuildMarker},
};
use crate::{AudioChannels, AudioSampleRate};
#[derive(Debug, Clone)]
pub struct RenderManager {
operator: Operator,
@@ -78,11 +71,15 @@ impl RenderManager {
let mut encoder =
opus2::Encoder::new(sample_rate, channels, Application::Audio).expect("TODO");
encoder.encode(&samples, &mut bytes).expect("TODO");
let encode_result = encoder.encode(&samples, &mut bytes);
tracing::info!(?encode_result);
encode_result.expect("TODO");
let path = render.to_string();
self.operator.write(&path, bytes).await.expect("TODO");
let write_result = self.operator.write(&path, bytes).await;
tracing::info!(?write_result);
write_result.expect("TODO");
Ok(())
}