✨ What You’ll Do
Right now, our logger is used in the codebase as:
pruna_logger.info("...")
pruna_logger.debug("...")
However, the logging level cannot be easily configured by the user. This makes it harder to control verbosity (for example, if they only want warnings/errors, or if they want more detailed debug output).
You’ll add functionality that lets users adjust the logging level globally, either programmatically or via an environment variable.
🛠️ Dependency
No new dependencies required — Python’s built-in logging module is sufficient.
🤖 Useful Resources
- The
pruna_logger instance is already defined and used throughout the codebase.
- A possible reference implementation can be found in the diffusers logger utility.
- You may add a utility function in a module like pruna/logging_utils.py.
➡ Desired Solution
Example usage could look like:
from pruna.logging import set_logging_level
# Option 1: set programmatically
set_logging_level("DEBUG")
# Option 2: set via environment variable
# export PRUNA_LOG_LEVEL=WARNING
✅ Acceptance Criteria
And don’t forget to give us a ⭐️!
❓ Questions?
Feel free to jump into the #contributing Discord channel if you hit any roadblocks. Can’t wait to see your contribution! 🚀
Share on X

✨ What You’ll Do
Right now, our logger is used in the codebase as:
However, the logging level cannot be easily configured by the user. This makes it harder to control verbosity (for example, if they only want warnings/errors, or if they want more detailed debug output).
You’ll add functionality that lets users adjust the logging level globally, either programmatically or via an environment variable.
🛠️ Dependency
No new dependencies required — Python’s built-in logging module is sufficient.
🤖 Useful Resources
pruna_loggerinstance is already defined and used throughout the codebase.➡ Desired Solution
Example usage could look like:
✅ Acceptance Criteria
set_logging_levelfunction exists and correctly adjusts the pruna_logger level.DEBUG,INFO,WARNING,ERROR,CRITICAL.PRUNA_LOG_LEVEL.And don’t forget to give us a ⭐️!
❓ Questions?
Feel free to jump into the #contributing Discord channel if you hit any roadblocks. Can’t wait to see your contribution! 🚀
Share on X