Commit cabbf993 authored by Markus Scheidgen's avatar Markus Scheidgen
Browse files

Fixed query for processes to stop in stop upload cli command. [skip ci]

parent 3aa42f38
Pipeline #53752 skipped
......@@ -294,6 +294,7 @@ def stop(ctx, uploads, calcs: bool, kill: bool, no_celery: bool):
process.on_process_complete(None)
process.save()
stop_all(proc.Calc.objects(query))
running_query = query & (Q(process_status=proc.PROCESS_RUNNING) | Q(tasks_status=proc.RUNNING))
stop_all(proc.Calc.objects(running_query))
if not calcs:
stop_all(proc.Upload.objects(query))
stop_all(proc.Upload.objects(running_query))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment