Conditions | 1 |
Total Lines | 13 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | import time |
||
9 | def entry(): |
||
10 | @wraps(entry) |
||
11 | def dec(func): |
||
12 | def my_fn(*args, **kwargs): |
||
13 | t0 = time.monotonic() |
||
14 | results = func(*args, **kwargs) |
||
15 | delta = UnitTools.delta_time_to_str(time.monotonic() - t0) |
||
16 | logger.debug(f"Command took {delta}") |
||
17 | return results |
||
18 | |||
19 | return wraps(func)(my_fn) |
||
20 | |||
21 | return dec |
||
22 | |||
25 |