Fix dispatcher logging (#33299)
This commit is contained in:
1 parent
6cafc45d2b
commit
73c52e668e
2 files changed
+11
-3
No files matched your search
@@ -47,7 +47,10 @@ def async_dispatcher_connect(
|
||||
wrapped_target = catch_log_exception(
|
||||
target,
|
||||
lambda *args: "Exception in {} when dispatching '{}': {}".format(
|
||||
target.__name__, signal, args
|
||||
# Functions wrapped in partial do not have a __name__
|
||||
getattr(target, "__name__", None) or str(target),
|
||||
signal,
|
||||
args,
|
||||
),
|
||||
)
|
||||
|
||||
|
||||
Reference in new issue
Block a user