Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add logs mechanism #18

Closed
mrtryhard opened this issue Jan 30, 2024 · 2 comments · Fixed by #77
Closed

Add logs mechanism #18

mrtryhard opened this issue Jan 30, 2024 · 2 comments · Fixed by #77
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@mrtryhard
Copy link
Owner

mrtryhard commented Jan 30, 2024

  • Use a stable library for logging (e.g. version >=1.0.0)
  • Add some useful logs in the code.
    • trace level to explain decision tree
    • debug level to explain operations

Implementation

  • Use RUST_LOG=level where level is either trace, debug, info, warn, info
  • Use LOG_DIR=path to directory to set the output directory.
  • The file will be output as qt_ts_tools.log.

Example:

RUST_LOG=debug LOG_DIR=. ./qt-ts-tools
@mrtryhard mrtryhard added the enhancement New feature or request label Jan 30, 2024
@mrtryhard
Copy link
Owner Author

tracing seems to be becoming the industry standard. However this is a sub 1.y.z version.

However there doesn't seem to be any lib that satisfies, so it's ok.

@mrtryhard mrtryhard added this to the 0.5.0 milestone May 12, 2024
@mrtryhard mrtryhard self-assigned this May 27, 2024
mrtryhard added a commit that referenced this issue May 27, 2024
* Use `RUST_LOG=level` where `level` is either `trace`, `debug`, `info`, `warn`, `info`
* Use `LOG_DIR=path to directory` to set the output directory.
* The file will be output as `qt_ts_tools.log`.
@mrtryhard mrtryhard linked a pull request May 27, 2024 that will close this issue
3 tasks
@mrtryhard
Copy link
Owner Author

Fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant