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: update logger for more precise log level and format control #306

Merged
merged 4 commits into from
Jul 14, 2023

Conversation

BustDot
Copy link
Contributor

@BustDot BustDot commented Jul 13, 2023

Use python logging dict_config to achieve more precise log level and format control

@casbin-bot
Copy link
Member

@Nekotoxin please review

@casbin-bot casbin-bot requested a review from Nekotoxin July 13, 2023 10:04
@hsluoyz
Copy link
Member

hsluoyz commented Jul 13, 2023

@BustDot what issue does this resolve?

Fix CI:

image

@BustDot
Copy link
Contributor Author

BustDot commented Jul 13, 2023

@BustDot what issue does this resolve?

Fix CI:

image

I add a default logger config for pycasbin and change different modules' logger name following Django style. In this way, user can control the log level and module easier.
I will update the doc after merge.
You can find more information in the following links:
Python docs
Django logging docs

@hsluoyz
Copy link
Member

hsluoyz commented Jul 13, 2023

@jessecooper @favipcj @leeqvip plz review

@leeqvip leeqvip merged commit 5c688d7 into casbin:master Jul 14, 2023
github-actions bot pushed a commit that referenced this pull request Jul 14, 2023
# [1.22.0](v1.21.0...v1.22.0) (2023-07-14)

### Features

* update logger for more precise log level and format control ([#306](#306)) ([5c688d7](5c688d7))
@github-actions
Copy link

🎉 This PR is included in version 1.22.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@BustDot BustDot deleted the feat/logger branch July 16, 2023 09:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants