How to Trigger and Debug the `deploy` Function after Deploying a Broken Source Code using the CLI?

I was thinking I’d add debug statements to get the URL it’s calling

Hmm looking at the code, maybe you need to manually create the webhook

and try running it locally

Oh wait nvm

I know the posts are triggering the webhook I set up manually, they’re posting to a test endpoint I set up. So it’s not that discourse isn’t firing on post.

Got it

the logs are showing /undefined at the end of the webhook URL it’s trying to delete

so I don’t think the webhooks are being created properly

(plus they don’t show up in the list of webhooks in Discourse)

But I wasn’t 100% sure they would.

Yeah the undefined makes it seem like the webhook wasn’t created properly

exactly

not sure why that would affect the REST call in deploy though

I’m creating a webhook and watching the calls in web inspector… maybe that changed.

That would explain

well, part of it

not the REST issue

Maybe the URL is incorrect?

You said running an action works?

but then it wouldn’t work with cli