-
Notifications
You must be signed in to change notification settings - Fork 207
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
feat(workflow): add check_run and check_suite #8
feat(workflow): add check_run and check_suite #8
Conversation
Sorry for not getting back earlier: Is it ready from your perspective? |
async function handleCheckUpdate(context, eventName, event) { | ||
const { action } = event; | ||
const payload = eventName === 'check_suite' ? event.check_suite : event.check_run; | ||
if (action === 'completed') { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't tested this code, but shouldn't this be action !== 'completed'
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This would be great to have in. Happy to update the PR.
How can I pull this branch locally or publish a canary build to check it with the update?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unfortunately, didn't work for me (this PR with the (action !== 'completed')
tweak). i got these messages:
INFO No update necessary
INFO PR is probably ready: mergeable_state: unknown
INFO Failed to merge PR: Required status check "continuous-integration/jenkins/branch" is expected.
this is after the workflow yml with these on event types:
on:
pull_request:
types:
- labeled
- unlabeled
- synchronize
- opened
- edited
- ready_for_review
- reopened
- unlocked
pull_request_review:
types:
- submitted
check_suite:
types:
- completed
check_run:
types:
- completed
status: {}
It seems like the action is still triggered too early, and then not again once jenkins has finished.
@pascalgn @peter-mouland I don't have the bandwidth at the moment to see this through, but I am still very much interested in this feature. If y'all want access to our fork I can add you as collaborators. |
@brad-decker no worries, I've forked the project and tried it on our servers with no luck... It looks like a great place to get started with this goal (rather than trying my own home-grown solution from scratch). When I get more time I'll give it another go. cheers |
If it helps this is our current configuration @peter-mouland .. workflows/check_suite.yml:
workflows/pull_request_review.yml
workflows/pull_request
it currently works with this setup like <=50% of the time... 😬 |
I made retries + retry sleep configurable now (see also #30), so maybe that could help here? |
i forked this one again in #60 - I guess github had changed it behavior quite a bit until now. Had to change it drastically enough that I didn't want to directly change this PR. |
I've merged #60 now, so I'm closing this PR. If you have any objections, just let me know and/or reopen it again! Thanks! 👍 |
Testing this on our application first, but hopefully adds support for check_run and check_suite