-
-
Notifications
You must be signed in to change notification settings - Fork 53
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
Dispatch on code-review comments? #88
Comments
@asford Thank you. I'm glad you are finding this action useful. It might be feasible, but I'll need to investigate a bit and think about how the action could support both regular comments and pull request review comments. Perhaps pull_request_review_comment is the event which is triggered for all review comments, including the final "top level" review comment. One possible problem is that the command workflow which runs as a result of the dispatch would not be able to set reactions on the comment when it completes with create-or-update-comment action. That action only works for issue and pull request comments. That means a new action would likely be required to handle review comments. Further, if you wanted the slash command to work in both comment types (issue and review) then the command workflow would need to be written to support that. (This assumes you care about having feedback to the comment containing the slash command) |
That's an excellent point I hadn't thought about. We're currently just posting-pack to the PR that issues the slash command in a separate, rather than targeting the exact comment that launched the command. You're right that things are going to get ...hairy... when you start writing a workflow that tries to interaction with both issue comments and PR review comments separately. It looks like the content of the review (entered as the top-level review summary on an approve/changes/comment action) is included as the "review.body" property of the It sounds like, if anything, we'd be getting into here-be-dragons territory in terms of the |
After looking into this a bit more I think it's feasible to modify the action to support this, however, I think it would end up complicating the use of this action and any command workflows that would need to support both regular issue comments and review comments. Unless there is a really compelling reason to add this I'm leaning towards not supporting this for now. Do you have a good reason for needing this feature? Or is it just a "nice to have?" |
This is an incredible repo, amazing code and even better docs. 👏👏👏
One minor nitpick, would it be possible to teach the dispatch to operate on PR review comments. Right now github doesn't dispatch an
issue_comment
event for a "top level" review comment, even though it shows up like a comment in the PR thread. I believe it dispatches a pull_request_review event, and from a quick peak atmain.js
I don't thinkslash-command-dispatch
will be able to process these events?slash-command-dispatch/src/main.ts
Lines 16 to 31 in 2ce216d
@peter-evans Do you think this would be feasible?
The text was updated successfully, but these errors were encountered: