mirror of
https://github.com/joelwmale/webhook-action.git
synced 2026-06-12 10:45:58 -05:00
[GH-ISSUE #124] UnhandledPromiseRejectionWarning: Error: Request failed with status code: undefined #4043
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ramyaramdasan on GitHub (Jan 22, 2021).
Original GitHub issue: https://github.com/joelwmale/webhook-action/issues/124
Hi @joelwmale,
I tried to add the WebHook Action to my GitHub Workflow to send notifications to an MS Teams Channel using webhook. However, I am receiving the following error:
Run joelwmale/webhook-action@master
Sending webhook request to ***
Error: Received status code: 400
Error: Received status code: undefined
(node:2807) UnhandledPromiseRejectionWarning: Error: Request failed with status code: undefined
at error (/home/runner/work/_actions/joelwmale/webhook-action/master/dist/main.js:72:11)
at /home/runner/work/_actions/joelwmale/webhook-action/master/dist/main.js:64:17
at processTicksAndRejections (internal/process/task_queues.js:93:5)
(node:2807) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:2807) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Can you please provide some help in fixing it?
Thanks
Ramya
@joelwmale commented on GitHub (Feb 26, 2021):
Hey @ramyaramdasan,
I can look at fixing the error within the action - but your issue is that you are receiving a 400 status code when the action tries to send the webhook. It looks like you're giving it a bad url or the server is rejecting the action.
Thanks.