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

Set up standard logging module #2232

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft

Conversation

lasers
Copy link
Contributor

@lasers lasers commented Jan 21, 2024

Starting an attempt to close #2063 with #2064.

rlerm and others added 2 commits February 5, 2024 17:04
This has the advantage of overall less custom code; as well as support
for per-module configuration. This would enable a potential solution for
ultrabug#1479, since in the future
it can allow per-module configuration of log levels.

I expect this to mainly help module creators, allowing them to enable
logging for only their module, while disabling all other messages. It
also is easier to use, since the `logging` module's interface is
generally simpler than `self.py3`.

Here, I've made the decision to keep the message format as close as
possible to the existing log messages.
@ultrabug
Copy link
Owner

Looks like a simple yet effective start mate, would you want to keep on that?

@lasers
Copy link
Contributor Author

lasers commented Mar 26, 2024

This is a clean rebase attempt on the master.

I have much more on my side, but I have stopped working on it for a while mainly because I'm on KDE so I'm not using py3status now. If and when I get back to this, I will try again.

I didn't like a separate file to deal with logs because I think we would forget about that... so I'm trying to put the logger configs inside py3status {} config section.... Easier to comment out/debug/et cetera.

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.

Make logging from modules easier
3 participants