Skip to content

Commit

Permalink
Merge pull request #277 from dora-rs/fix-tracing-error
Browse files Browse the repository at this point in the history
Fix: Don't try to create two global tracing subscribers when using bundled runtime
  • Loading branch information
phil-opp authored May 3, 2023
2 parents 4735033 + 9217d84 commit f54b25c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions binaries/daemon/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,6 @@ async fn main() -> eyre::Result<()> {
}

async fn run() -> eyre::Result<()> {
#[cfg(feature = "tracing")]
set_up_tracing("dora-daemon").wrap_err("failed to set up tracing subscriber")?;

let Args {
run_dataflow,
machine_id,
Expand All @@ -50,6 +47,9 @@ async fn run() -> eyre::Result<()> {
return tokio::task::block_in_place(dora_daemon::run_dora_runtime);
}

#[cfg(feature = "tracing")]
set_up_tracing("dora-daemon").wrap_err("failed to set up tracing subscriber")?;

let ctrl_c_events = {
let (ctrl_c_tx, ctrl_c_rx) = mpsc::channel(1);
let mut ctrlc_sent = false;
Expand Down

0 comments on commit f54b25c

Please sign in to comment.