feat(logging): initialize tracing subscriber in CLI and desktop app - #111
Conversation
Muawiya-contact
left a comment
There was a problem hiding this comment.
The logging setup looks good, including sending logs to stderr so JSON output stays clean. Please also include the updated Cargo.lock in this PR. Both crates now depend on tracing-subscriber, but the lockfile still describes the old dependencies.
I checked the change in an isolated checkout:
cargo check --locked -p diskern-cli
# error: cannot update the lock file because --locked was passedPlease run cargo check -p diskern-cli to refresh the lockfile, commit the resulting Cargo.lock change, and rerun the command above. Keep any unrelated dependency upgrades out of this patch. That is the remaining change I need before approving.
Muawiya-contact
left a comment
There was a problem hiding this comment.
Hi @vhmns14, thank you again for the logging work, and welcome to Coding Moves.
This is close, but one required file is still missing: Cargo.lock needs to be updated after adding tracing-subscriber.workspace = true to the CLI and Tauri app crates. Right now the PR changes the Cargo manifests, but a fresh checkout still does not have the lockfile entry for tracing-subscriber, so dependency resolution is not fully captured in the PR.
Please run this from the repo root and commit the resulting Cargo.lock change:
cargo update -p tracing-subscriber
# or simply run cargo check/test and commit the Cargo.lock update it createsAfter that, I can review it again. Also, please keep exploring more projects from Coding Moves. We would be happy to see more contributions from you. If you can, please star the repo and follow the Coding Moves organization so more contributors can discover the work.
Muawiya-contact
left a comment
There was a problem hiding this comment.
Looks good now — thank you for the contribution! I added the missing Cargo.lock update so the new tracing-subscriber dependency is fully recorded, and the full CI run is green.
Welcome to Coding Moves. Please keep exploring more projects in Coding Moves, and if you like the work here, don’t forget to star the repo and follow the organization.
Fixes #85
Summary of Changes
tracing-subscriber.workspace = truetocrates/diskern-cli/Cargo.tomlandapp/src-tauri/Cargo.toml.tracing_subscriber::fmt()withEnvFilter(defaulting towarn, overridable viaRUST_LOG) writing tostderrat the entry point ofdiskern-cli(main()) anddiskern-app(run()).--json).Validation
cargo fmt --checkpassed cleanly.typoscheck passed with 0 warnings.