Skip to content

Commit 4b836d1

Browse files
type error
1 parent a650a6a commit 4b836d1

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

core/pioreactor/web/unit_api.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -315,8 +315,7 @@ def stop_jobs() -> DelayedResponseReturnValue:
315315
job_name = json.get("job_name")
316316
experiment = json.get("experiment")
317317
job_source = json.get("job_source")
318-
job_id = json.get("job_id") # note job_id is typically an int, so you might convert it.
319-
318+
job_id = json.get("job_id")
320319
if not any([job_name, experiment, job_source, job_id]):
321320
return abort(400, "No job filter specified")
322321

@@ -328,7 +327,7 @@ def stop_jobs() -> DelayedResponseReturnValue:
328327
if job_source:
329328
kill_args.extend(["--job-source", job_source])
330329
if job_id:
331-
kill_args.extend(["--job-id", job_id])
330+
kill_args.extend(["--job-id", str(job_id)]) # note job_id is typically an int, convert to str
332331

333332
task = tasks.pio_kill(*kill_args)
334333
return create_task_response(task)

0 commit comments

Comments
 (0)