-
Notifications
You must be signed in to change notification settings - Fork 232
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
extra can not hava keys like name #181
Comments
As you said,
and it is ok behavior.
https://docs.python.org/3/library/logging.html#logrecord-attributes So, just pick another name for your extra! |
emmm, I think it's inconvenient for users to use json formatter when there are so many reserve fields. As a formatter, it should format everything that user inputs. |
Per the stack trace you provided, this error is being generated by Despite the package name, The reserved names are enforced by the default |
above code throws a exception which tell us that name has already been existed in LogRecord
output
Reading the related source code of logging, the name key has been set as myname as the logger name.
so I am seriously curious about that if the way of using extra in my code is correct?
python json logger version
python-json-logger 2.0.7
l
The text was updated successfully, but these errors were encountered: