|
@ -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 |
|
|