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

Use python's logging module #88

Open
dafyddstephenson opened this issue Sep 17, 2024 · 0 comments
Open

Use python's logging module #88

dafyddstephenson opened this issue Sep 17, 2024 · 0 comments
Milestone

Comments

@dafyddstephenson
Copy link
Contributor

dafyddstephenson commented Sep 17, 2024

This issue is to track the implementation of python's logging. I was hoping to do this with PR #89 but the more I read about logging's capabilities, the more I'd rather implement it carefully.

Key things we'd like to achieve:

  • write subprocess output to log files and then hint to the user where they can find these files
  • Convert current print statements to logs at the info level
  • add debug information throughout the code using logging's debug level

Things to consider:

  • Logging has a global configuration that should be set once at the entry point (the best candidate currently would be environment.py)
  • "Loggers" can then be set up and re-used to track different things (we could imagine for example a roms_compile_logger
  • "Handlers" decide what to do with the logs (to file, to screen, etc.)

So where we set the global configuration, how many loggers we have and what their responsibilities are, and how to handle their output (new file each time with a date string in the filename is what I imagined) is to be decided before implementation.

@dafyddstephenson dafyddstephenson added this to the beta milestone Sep 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant