You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
logging module LogRecord can accept non-str msg but it's not documented #102873
But just below that it explains that in getMessage:
Returns the message for this LogRecord instance after merging any user-supplied arguments with the message. If the user-supplied message argument to the logging call is not a string, str() is called on it to convert it to a string. This allows use of user-defined classes as messages, whose str method can return the actual format string to be used.
changed the title [-]logging module LogRecord can accept non-str msg but it's not reflected[/-][+]logging module LogRecord can accept non-str msg but it's not documented[/+]on Mar 21, 2023
Activity
pythongh-102873: Update logging LogRecord argument types
aminalaee commentedon Mar 21, 2023
cc @AlexWaygood
[-]logging module LogRecord can accept non-str msg but it's not reflected[/-][+]logging module LogRecord can accept non-str msg but it's not documented[/+]arhadthedev commentedon Mar 22, 2023
@vsajip (as a logging expert)
gh-102873: logging.LogRecord docs: improve description of `msg` param…
pythongh-102873: logging.LogRecord docs: improve description of `msg`…
pythongh-102873: logging.LogRecord docs: improve description of `msg`…
gh-102873: logging.LogRecord docs: improve description of `msg` param…
gh-102873: logging.LogRecord docs: improve description of `msg` param…
AlexWaygood commentedon Mar 24, 2023
Thanks @aminalaee!
pythongh-102873: logging.LogRecord docs: improve description of `msg`…
pythongh-102873: logging.LogRecord docs: improve description of `msg`…