-
Notifications
You must be signed in to change notification settings - Fork 19
Missing pull_request_target.* types #86
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
Comments
Ideally the loaded webhook types would be an extendable interface, so that https://github.com/probot/adapter-github-actions could add types for GitHub Actions-specific events. But @octokit is currently not maintained, see octokit/octokit.js#620 (comment), so it might take a while.
|
This setting seems to trigger a warning: ```text "pull_request_target.opened" is not a known webhook name (https://developer.github.com/v3/activity/events/types/) "pull_request_target.reopened" is not a known webhook name (https://developer.github.com/v3/activity/events/types/) "pull_request_target.synchronize" is not a known webhook name (https://developer.github.com/v3/activity/events/types/) "pull_request_target.edited" is not a known webhook name (https://developer.github.com/v3/activity/events/types/) ``` See <https://github.com/probot/probot/issues/1635>.
Any update here? Still unmaintained? |
Octokit is no longer unmaintained. This is a not a simple task to do. If you would like to contribute, feel free to open a PR |
As octokit seems to be actively maintained and with recent releases https://github.com/octokit/octokit.js/releases what is still preventing us from getting a fix on this?
|
The problem is that that is an event for GitHub actions and not Webhooks. It requires some changes and possibly new packages Feel free to work on this yourself instead of posting an unproductive comment |
According to the pull_request_target docs, its payload is identical with the corresponding Considering this is purely action-specific behaviour and does not exist with webhooks. I think we can deal with this in If we go this route (just replace What do you think? |
Agree with that.
I don't know... Mixing webhooks with actions events sounds like getting into trouble, they should ideally stay seperate, as they might have seperate types, and have seperate events. I think a good solution to this problem would be octokit/webhooks.js#474 Maybe I'm not seeing what you're suggesting though, I'm okay with what you think is good |
You're right, there are some differences for some events. In the case of However, the actions adapter right now does not seem to care about the differences between events and webhooks. As such, just rewriting the event type internally sounds like a "good enough" solution given the current circumstances. Users would then just do I'll try to create a PR on the weekend with my proposed implementation, and we can have a look at a better long-term solution as part of octokit/webhooks.js#474. |
This is old, but still the right path forward I think. But given the little investment @octokit gets these days I wouldn't hold my breath. I think it would be fair to say this is out of scope for Probot, move the issue over to the |
Bug Report
Current Behavior
app.on
complains aboutpull_request_target
events due to use ofoctokit/webhook
for verification.pull_request_target.opened
pull_request_target.reopened
pull_request_target.synchronize
pull_request_target.edited
console.warn
"pull_request_target.synchronize" is not a known webhook name (developer.github.com/v3/activity/events/types)
octokit/webhooks.js#666
https://github.com/release-drafter/release-drafter/blob/e3aebd9e73094fee1a9f046928a3dea5389893b9/index.js#L25-L35
Expected behavior/code
Since Probot has intention of supporting GitHub actions via https://github.com/probot/adapter-github-actions than these should not show up as warnings?
Environment
Possible Solution
Additional context/Screenshots
Add any other context about the problem here. If applicable, add screenshots to help explain.
The text was updated successfully, but these errors were encountered: