Skip to content
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

handle GET requests in webhook hra #378

Merged
merged 1 commit into from
Mar 8, 2021
Merged

Conversation

robwhitby
Copy link
Contributor

Hi,

The logs of the webhook controller show an error every 30secs, I guess due to a health check request which fails to be parsed as a GitHub event.

2021-03-08T14:41:55.562Z	ERROR	controllers.Runner	error validating request body	{"error": "Webhook request has unsupported Content-Type \"\""}
2021-03-08T14:42:25.556Z	ERROR	controllers.Runner	error validating request body	{"error": "Webhook request has unsupported Content-Type \"\""}
2021-03-08T14:42:55.558Z	ERROR	controllers.Runner	error validating request body	{"error": "Webhook request has unsupported Content-Type \"\""}

Currently the handler assumes all requests are POSTs from GitHub, this PR changes it to return early with 200 OK for any GET request.

Copy link
Collaborator

@mumoshu mumoshu left a comment

Choose a reason for hiding this comment

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

Awesome! Thanks a lot for your contribution @robwhitby ☺️

@mumoshu mumoshu merged commit 1753fa3 into actions:master Mar 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants