difftreelog
feat reenable indicatif, since the eaten line was fixed
in: trunk
3 files changed
cmds/fleet/Cargo.tomldiffbeforeafterboth49fleet-base = { version = "0.1.0", path = "../../crates/fleet-base" }49fleet-base = { version = "0.1.0", path = "../../crates/fleet-base" }505051[features]51[features]52default = ["indicatif"]52# Not quite stable53# Not quite stable53indicatif = [54indicatif = [54 "dep:tracing-indicatif",55 "dep:tracing-indicatif",cmds/fleet/src/main.rsdiffbeforeafterboth185#[tokio::main]185#[tokio::main]186async fn async_main(opts: RootOpts) -> ExitCode {186async fn async_main(opts: RootOpts) -> ExitCode {187 if let Err(e) = main_real(opts).await {187 if let Err(e) = main_real(opts).await {188 // If I remove this line, the next error!() line gets eaten.189 // This is a bug in indicatif, it needs to be fixed190 #[cfg(feature = "indicatif")]191 info!("fixme: this line gets eaten by tracing-indicatif on levels info+");192 error!("{e:#}");188 error!("{e:#}");193 return ExitCode::FAILURE;189 return ExitCode::FAILURE;194 }190 }crates/fleet-base/src/opts.rsdiffbeforeafterboth6 sync::{Arc, Mutex},6 sync::{Arc, Mutex},7};7};889use anyhow::Result;9use anyhow::{Context, Result};10use clap::Parser;10use clap::Parser;11use nix_eval::{nix_go, util::assert_warn, NixSessionPool, Value};11use nix_eval::{nix_go, util::assert_warn, NixSessionPool, Value};12use nom::{12use nom::{197 let mut fleet_data_path = directory.clone();197 let mut fleet_data_path = directory.clone();198 fleet_data_path.push("fleet.nix");198 fleet_data_path.push("fleet.nix");199 let bytes = std::fs::read_to_string(fleet_data_path)?;199 let bytes =200 std::fs::read_to_string(fleet_data_path).context("reading fleet state (fleet.nix)")?;200 let data: Mutex<FleetData> = nixlike::parse_str(&bytes)?;201 let data: Mutex<FleetData> = nixlike::parse_str(&bytes)?;201202202 let fleet_root = Value::binding(nix_session.clone(), "fleetConfigurations").await?;203 let fleet_root = Value::binding(nix_session.clone(), "fleetConfigurations").await?;