Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Commit

Permalink
docs(sample): update protobuf in create_http_task.py (#283)
Browse files Browse the repository at this point in the history
  • Loading branch information
averikitsch committed Aug 9, 2022
1 parent 94cafc3 commit b685da5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion samples/snippets/create_http_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ def create_http_task(
if deadline is not None:
# Add dispatch deadline for requests sent to the worker.
duration = duration_pb2.Duration()
task["dispatch_deadline"] = duration.FromSeconds(deadline)
duration.FromSeconds(deadline)
task["dispatch_deadline"] = duration

# Use the client to build and send the task.
response = client.create_task(request={"parent": parent, "task": task})
Expand Down

0 comments on commit b685da5

Please sign in to comment.