Skip to content

Update create_http_task.py #2187

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 1, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion tasks/create_http_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ def create_http_task(project,
# location = 'us-central1'
# url = 'https://example.com/task_handler'
# payload = 'hello'
in_seconds = 10

# Construct the fully qualified queue name.
parent = client.queue_path(project, location, queue)
Expand All @@ -56,7 +57,7 @@ def create_http_task(project,

# Add the payload to the request.
task['http_request']['body'] = converted_payload

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like this extra whitespace here is breaking lint.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

./create_http_task.py:60:1: W293 blank line contains whitespace

if in_seconds is not None:
# Convert "seconds from now" into an rfc3339 datetime string.
d = datetime.datetime.utcnow() + datetime.timedelta(seconds=in_seconds)
Expand Down