Logging does not work
See original GitHub issueHello,
I’m using sentry (7.6.2) and sentry-ldap-auth (1.0), with:
[root@charlotte1 ~]# /sentry/env/bin/pip list | grep django
django-auth-ldap (1.2.7)
django-bitfield (1.7.1)
django-crispy-forms (1.4.0)
django-jsonfield (0.9.13)
django-paging (0.2.5)
django-picklefield (0.3.1)
django-recaptcha (1.0.4)
django-social-auth (0.7.28)
django-statsd-mozilla (0.3.14)
django-sudo (1.1.3)
django-templatetag-sugar (1.0)
djangorestframework (2.3.14)
pytest-django (2.8.0)
Also, I’m using in /etc/sentry/sentry.conf.py:
import logging
logger = logging.getLogger('django_auth_ldap')
logger.addHandler(logging.StreamHandler())
logger.setLevel('DEBUG')
But there is any logging generetady by the supervisord about the login
[root@charlotte1 ~]# egrep '\[|log' /etc/supervisord.d/sentry.ini
[program:sentry-web]
stdout_logfile=/logs/sentry/sentry-web.log
stderr_logfile=/logs/sentry/sentry-web-err.log
[program:sentry-worker]
stdout_logfile=/logs/sentry/sentry-worker.log
stderr_logfile=/logs/sentry/sentry-worker-err.log
There is something missing?
Thanks!
Issue Analytics
- State:
- Created 8 years ago
- Comments:7 (2 by maintainers)
Top Results From Across the Web
logging - Python Logger not working - Stack Overflow
The problem is that the logger's level is still set to the default. So the logger discards the message before it even gets...
Read more >How to Get Started with Logging in Python - Better Stack
Logging is an invaluable tool in every developer's toolbox when developing software. It provides a reliable means of recording and tracking ...
Read more >Logging HOWTO — Python 3.11.1 documentation
Author, Vinay Sajip ,. Basic Logging Tutorial: Logging is a means of tracking events that happen when some software runs. The software's developer...
Read more >A Step-by-Step Guide to Python Logging - Pylenin
A comprehensive guide to understanding the advantages and usage of Python Logging module.
Read more >logging.info not showing up in console output #46 - GitHub
Not seeing logging.info() show up in the console output. In the example I don't see the "Tearing Down" or if I add logging.info...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Same here. Ironically, the logging setup in sentry is a bit obscure, but basically the problem is that LOGGING exists already, so I had success with the following lines in
sentry.conf.py
:… and then starting the web server with ‘–loglevel DEBUG’
references:
@tiago-cruz-movile Try to add the following snippet to
sentry.conf.py
: