Update Cargo.lock dependencies to latest versions to ensure compatibility and improve functionality.

This commit is contained in:
Till Wegmueller 2025-07-27 11:02:37 +02:00
parent 8760bf0c4d
commit bf5d60c77c
No known key found for this signature in database
4 changed files with 745 additions and 343 deletions

1068
Cargo.lock generated

File diff suppressed because it is too large Load diff

View file

@ -16,7 +16,7 @@ clap = { version = "4", features = ["derive"] }
miette = { version = "7", features = ["fancy"] }
thiserror = "2"
tracing = "0.1"
tracing-subscriber = "0.3"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
libips = { path = "../libips" }
serde = { version = "1", features = ["derive"] }
serde_json = "1"

View file

@ -48,6 +48,13 @@ pub enum Pkg6RepoError {
)]
ActionError(#[from] ActionError),
#[error("logging environment setup error: {0}")]
#[diagnostic(
code(pkg6repo::logging_env_error),
help("Check your logging environment configuration and try again")
)]
LoggingEnvError(String),
#[error("other error: {0}")]
#[diagnostic(
code(pkg6repo::other_error),

View file

@ -8,8 +8,8 @@ use serde::Serialize;
use std::convert::TryFrom;
use std::path::PathBuf;
use tracing::{debug, info};
use tracing_subscriber::fmt;
use tracing_subscriber::{fmt, EnvFilter};
use tracing_subscriber::filter::LevelFilter;
use libips::repository::{FileBackend, ReadableRepository, RepositoryVersion, WritableRepository};
#[cfg(test)]
@ -322,8 +322,15 @@ enum Commands {
fn main() -> Result<()> {
// Initialize the tracing subscriber with the default log level as debug and no decorations
// Parse the environment filter first, handling any errors with our custom error type
let env_filter = EnvFilter::builder()
.with_default_directive(LevelFilter::WARN.into())
.from_env()
.map_err(|e| Pkg6RepoError::LoggingEnvError(format!("Failed to parse environment filter: {}", e)))?;
fmt::Subscriber::builder()
.with_max_level(tracing::Level::DEBUG)
.with_env_filter(env_filter)
.without_time()
.with_target(false)
.with_ansi(false)