#750: Using more descriptive status; new route {{{POST /command}}} to launch command/script in a callback thread that returns all data to a server route.

oglive^2
Ramón M. Gómez 2018-06-30 17:13:45 +02:00
parent dc8c12bf6e
commit d1b88b05ee
1 changed files with 3 additions and 0 deletions

View File

@ -83,6 +83,7 @@ def check_locked_partition(sync=False):
""" """
Decorator to check if a partition is locked Decorator to check if a partition is locked
""" """
def outer(fnc): def outer(fnc):
def wrapper(*args, **kwargs): def wrapper(*args, **kwargs):
part_id = 'None' part_id = 'None'
@ -101,7 +102,9 @@ def check_locked_partition(sync=False):
if sync is True: if sync is True:
this.locked[part_id] = False this.locked[part_id] = False
logger.debug('Lock status: {} {}'.format(fnc, this.locked)) logger.debug('Lock status: {} {}'.format(fnc, this.locked))
return wrapper return wrapper
return outer return outer