mirror of
https://github.com/status-im/spiff-arena.git
synced 2025-02-06 07:04:18 +00:00
backend/git_service: accept webhook test requests
https://docs.github.com/en/webhooks-and-events/webhooks/testing-webhooks Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
parent
e47c0752db
commit
fb024a49f7
@ -206,6 +206,10 @@ class GitService:
|
|||||||
% (config_clone_url, valid_clone_urls)
|
% (config_clone_url, valid_clone_urls)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Test webhook requests have a zen koan and hook info.
|
||||||
|
if "zen" in webhook or "hook_id" in webhook:
|
||||||
|
return False
|
||||||
|
|
||||||
if "ref" not in webhook:
|
if "ref" not in webhook:
|
||||||
raise InvalidGitWebhookBodyError(
|
raise InvalidGitWebhookBodyError(
|
||||||
f"Could not find the 'ref' arg in the webhook boy: {webhook}"
|
f"Could not find the 'ref' arg in the webhook boy: {webhook}"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user