We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
When using a logging.Filter, it seems to be not working when inside the logging_redirect_tqdm context manager. Here is an example:
logging.Filter
import logging from tqdm.contrib.logging import logging_redirect_tqdm class Filter(logging.Filter): def filter(self, record): record.msg = f"{record.msg} -- filter" return True filter = Filter() handler = logging.StreamHandler() handler.addFilter(filter) logging.basicConfig(handlers=[handler]) logger = logging.getLogger("main") logger.error("outside redirect") with logging_redirect_tqdm(): logger.error("inside redirect")
Expected output
ERROR:main:outside redirect -- filter ERROR:main:inside redirect -- filter
Actual output
ERROR:main:outside redirect -- filter ERROR:main:inside redirect
It looks like they just ought to be copied over from the original handler. If you like I can prepare a pull request.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
read the known issues
environment, where applicable:
When using a
logging.Filter
, it seems to be not working when inside the logging_redirect_tqdm context manager. Here is an example:Expected output
Actual output
It looks like they just ought to be copied over from the original handler. If you like I can prepare a pull request.
The text was updated successfully, but these errors were encountered: