Skip to content

Commit

Permalink
make CreateWorkflow.tasks optional
Browse files Browse the repository at this point in the history
  • Loading branch information
andrii-i committed Sep 12, 2024
1 parent 4aa3046 commit c276385
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions jupyter_scheduler/workflows.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
class WorkflowsHandler(ExtensionHandlerMixin, JobHandlersMixin, APIHandler):
@authenticated
async def post(self):
payload = self.get_json_body()
payload = self.get_json_body() or {}
try:
workflow_id = await ensure_async(
self.scheduler.create_workflow(CreateWorkflow(**payload))
Expand Down Expand Up @@ -160,7 +160,7 @@ async def post(self, workflow_id: str):


class CreateWorkflow(BaseModel):
tasks: List[str]
tasks: List[str] = []


class DescribeWorkflow(BaseModel):
Expand Down

0 comments on commit c276385

Please sign in to comment.