Browse Source

publish muk_utils - 12.0

pull/30/head
MuK IT GmbH 6 years ago
parent
commit
dcbb4594c7
  1. 4
      muk_utils/tests/common.py

4
muk_utils/tests/common.py

@ -112,9 +112,9 @@ def track_function(func):
threading.current_thread().query_count = 0 threading.current_thread().query_count = 0
threading.current_thread().perf_t0 = time.time() threading.current_thread().perf_t0 = time.time()
result = func(*args, **kwargs) result = func(*args, **kwargs)
message = "Track: %s" % func.__name__
message = "%s" % func.__name__
if args and hasattr(args[0], "uid"): if args and hasattr(args[0], "uid"):
message = "(UID: %s)" % args[0].uid
message = " (%s)" % args[0].uid
if hasattr(threading.current_thread(), "query_count"): if hasattr(threading.current_thread(), "query_count"):
query_count = threading.current_thread().query_count query_count = threading.current_thread().query_count
query_time = threading.current_thread().query_time query_time = threading.current_thread().query_time

Loading…
Cancel
Save