Not able to get the debug logs or python stacktrace on errors even after LOG_LEVEL is set to 'DEBUG'
See original GitHub issueMake sure these boxes are checked before submitting your issue - thank you!
- [can’t find the stacktrace ] I have checked the superset logs for python stacktraces and included it here as text if any
- [check ] I have reproduced the issue with at least the latest released version of superset
- [ check] I have checked the issue tracker for the same issue and I haven’t found one similar
I’m using the following 2 parameters to define the log level of superset
LOG_FORMAT = ‘%(asctime)s:%(levelname)s:%(name)s:%(message)s’ LOG_LEVEL = ‘DEBUG’
But when I start superset using superset runserver
, I cannot see the debug logs (or python stacktrace on errors) on the console. I’m trying to login to superset using LDAP, but not able to do so, and hence need the debug logs/python stacktrace. Can someone please help me out.
Superset version
0.24.0 superset.txt
Expected results
Debug logs on the console
Actual results
Info logs on the console
Steps to reproduce
The config file is attached. When I try to login, the login fails and I get the following message
Invalid login. Please try again.
and there is no debug log on the console.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:17 (3 by maintainers)
Top Results From Across the Web
How do I log a Python error with debug information?
Save this answer. Show activity on this post. If "debugging information" means the values present when exception was raised, then logging. exception(...)
Read more >Logging HOWTO — Python 3.11.1 documentation
In this case, because we set the threshold to DEBUG , all of the messages were printed. If you want to set the...
Read more >Exceptional Logging of Exceptions in Python - Loggly
Just notice that the first line is the message you passed to logger. exception() , and the subsequent lines are the full stack...
Read more >The Ultimate Guide to Logging in Python - Rollbar
This logger can be used to write formatted messages using a log level (DEBUG, INFO, ERROR etc). Here's an example:
Read more >How to Get Started with Logging in Python - Better Stack
Generally, these are the meanings behind each log level: DEBUG : used to give a detailed report about an event, especially when diagnosing ......
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
@deepak-goel could you share with your
pip freeze
results? I have the same problem and adding public role doesnt solve my issue. I am still not able to check if my LDAP configuration works. So, to better understand… after such configuration - should I register a new user (where username == uid from LDAP)?EDIT: I checked BaseSecurityManager line by line and in my case that solved the issue:
AUTH_LDAP_USERNAME_FORMAT = "uid=%s,ou=YOUR,o=ORG"
I got this working. I added the following 3 parameters
AUTH_USER_REGISTRATION = True
AUTH_ROLE_PUBLIC = 'Public'
AUTH_USER_REGISTRATION_ROLE = 'Public'
Superset config specifically needs the user registration as True for any user that logs in the first time. Closing this issue now.