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

feat: add support for logging.NOTSET level #439

Merged
merged 2 commits into from
Dec 1, 2024
Merged

feat: add support for logging.NOTSET level #439

merged 2 commits into from
Dec 1, 2024

Conversation

monosans
Copy link
Contributor

From Python docs:

logging.NOTSET: When set on a logger, indicates that ancestor loggers are to be consulted to determine the effective level. If that still resolves to NOTSET, then all events are logged.

@@ -23,6 +24,7 @@ class LogLevels(str, Enum):
LogLevels.warn: logging.WARN,
LogLevels.info: logging.INFO,
LogLevels.debug: logging.DEBUG,
LogLevels.notset: logging.NOTSET,
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can remove log_levels_map at all and use the LogLevels enum above as a mapping. Let me know if you are interested.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather stick with the current approach, I prefer to have this explicit rather than implicit :)

@gi0baro gi0baro added this to the 1.7 milestone Nov 22, 2024
@gi0baro
Copy link
Member

gi0baro commented Nov 26, 2024

@monosans thank you for your contribution ❤️

Gonna merge this as soon as possible, with the 1.7 schedule.

@gi0baro gi0baro merged commit 915ba92 into emmett-framework:master Dec 1, 2024
19 checks passed
@monosans monosans deleted the patch-2 branch December 1, 2024 12:27
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

Successfully merging this pull request may close these issues.

2 participants