mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Add back code logic that pyupgrade
removed.
We still need this for salt-ssh Signed-off-by: Pedro Algarvio <palgarvio@vmware.com>
This commit is contained in:
parent
e8a392577d
commit
a6cb942a3b
1 changed files with 23 additions and 10 deletions
|
@ -275,16 +275,29 @@ class SaltLoggingClass(LOGGING_LOGGER_CLASS, metaclass=LoggingMixinMeta):
|
|||
else:
|
||||
extra["exc_info_on_loglevel"] = exc_info_on_loglevel
|
||||
|
||||
LOGGING_LOGGER_CLASS._log(
|
||||
self,
|
||||
level,
|
||||
msg,
|
||||
args,
|
||||
exc_info=exc_info,
|
||||
extra=extra,
|
||||
stack_info=stack_info,
|
||||
stacklevel=stacklevel,
|
||||
)
|
||||
try:
|
||||
LOGGING_LOGGER_CLASS._log(
|
||||
self,
|
||||
level,
|
||||
msg,
|
||||
args,
|
||||
exc_info=exc_info,
|
||||
extra=extra,
|
||||
stack_info=stack_info,
|
||||
stacklevel=stacklevel,
|
||||
)
|
||||
except TypeError:
|
||||
# Python < 3.8 - We still need this for salt-ssh since it will use
|
||||
# the system python, and not out onedir.
|
||||
LOGGING_LOGGER_CLASS._log(
|
||||
self,
|
||||
level,
|
||||
msg,
|
||||
args,
|
||||
exc_info=exc_info,
|
||||
extra=extra,
|
||||
stack_info=stack_info,
|
||||
)
|
||||
|
||||
def makeRecord(
|
||||
self,
|
||||
|
|
Loading…
Add table
Reference in a new issue