Specify check suite when creating a checkrun #24616
-
When creating a check run through the API, a check suite is newly created unless a check suite for the requesting application has already been made, in which case that check suite seems to be reused. This leads to issues however: due to Github Actions workflows, and each Workflow Run (workflow/event) having its own check suite, multiple check suites may exist for a given commit SHA. As a result, annotations generated in a Github action during a step executed in the “pull request” event, end up in the “workflow” for the "push’ event. Through hoops, it is possible to find the check run ID during a Github Action: one can look up the Workflow Run by the run_id and then extract the Check Suite ID from the checkSuiteUrl. However, there is no way to specify the Check Suite ID when creating a new check run (its ignored in the request) and neither there seems to be any dedicated endpoint for creating check runs for a particular check suite. It would be great if it were possible to more easily find the corresponding Check Suite for a Workflow Run, and if it were possible to create Check Runs for this particular Check Suite rather than have one picked “randomly” for you. See also the issue thread jwgmeligmeyling/pmd-github-action#4 and proof of concept code in jwgmeligmeyling/pmd-github-action#3 |
Beta Was this translation helpful? Give feedback.
Replies: 36 comments 40 replies
-
jwgmeligmeyling:
@jwgmeligmeyling - Welcome back to the Support Community and thanks for this feedback! 🙇♂️ After reviewing your particular case, I’d like to confirm here that it is not currently possible to create a check run associated with a particular check suite with the We’re always working to improve GitHub and the GitHub Support Community, and we consider every suggestion we receive. Would you mind submitting this through our official product feedback form so that our product team can track your request? That’s the best place to share requests like these in consideration for future iterations of GitHub features, including Actions. |
Beta Was this translation helpful? Give feedback.
-
Thanks for your response! I’ve submitted the product feedback form. |
Beta Was this translation helpful? Give feedback.
-
Is this product feedback submitted by @jwgmeligmeyling publicly visible? What is the best way to track progress of this issue? |
Beta Was this translation helpful? Give feedback.
-
No I don’t think its publicly available. I didn’t receive any response as well. I’ve filed another support ticket, maybe that gets things going. |
Beta Was this translation helpful? Give feedback.
-
@EnricoMi - Great question! Because product feedback submitted through this form isn’t publicly visible, it’s not possible to track its progress. However, it may be worth sharing that our team announced the GitHub public roadmap to give everyone more transparency into what each of our teams are planning and to help everyone understand our product vision. It’s publicly viewable if you’re interested in following what our team is working on next, though it doesn’t currently show any feedback submitted from that form. I hope this helps! |
Beta Was this translation helpful? Give feedback.
-
It might be worth trying out to use the token of a separate GitHub App when creating the check run. Here is an action that retrieves a temporary token from a GitHub App created just for this purpose: https://github.com/peter-murray/workflow-application-token-action |
Beta Was this translation helpful? Give feedback.
-
Yes I have the same problem. I have also submitted a suggestion on the feedback form. |
Beta Was this translation helpful? Give feedback.
-
@francisfuzz is there any update on this issue? I wasn’t able to find it on the roadmap you’ve mentioned. |
Beta Was this translation helpful? Give feedback.
-
I was expecting to use several runners to perform distinct, unrelated checks, but the results appear in a randomly picked workflow tab. Is there any known workaround for now? Thanks. (note: it sounds weird to have this thread flagged as “solved” :-)) |
Beta Was this translation helpful? Give feedback.
-
@dobegor - I don’t have any updates to share on my part nor am I able to provide any in the future. The public roadmap is still the best place to keep up with upcoming features. |
Beta Was this translation helpful? Give feedback.
-
Hello @francisfuzz, this seems to be a “minor” bug from the roadmap PoV, and is unlikely to ever be listed there. Hence this response from you is not really useful at all, as we don’t even know whether the issue is still being tracked by Github internally or it just “fell through the cracks”. It’s a shame especially because at least on the surface this seems like it should be an easy fix to actually use the Check Suite ID. For my use case it’s causing this: Report check item appears under the wrong workflow name · Issue #39 · ScaCap/action-surefire-report · GitHub and again, it’s a shame, because that action allows reasonable and very simple test result reporting via workflow annotations, which is clear and easy to find/read even by outside contributors. There are very few options with regards to test result reporting that don’t require outside resources! I have submitted another feedback form for this, hopefully it can get some more attention. Thank you. |
Beta Was this translation helpful? Give feedback.
-
This issue makes it difficult to locate checks for specific workflows and is serious enough for us to consider moving away from GH actions 😦 |
Beta Was this translation helpful? Give feedback.
-
This is a BREAKING issue for GitHub Actions, and it’s honestly mindblowing that it’s come down to “submit feedback and get no answer”. We have zero acknowledgment that our feedback was even seen by anyone working on GitHub Actions. It’s especially sad since we all know this would be a very easy fix. You can literally put an intern on it they’ll get it done in less than a day. |
Beta Was this translation helpful? Give feedback.
-
Sad to see this was still not communicated to the appropriate folks. It is a trivial fix. A dozen people have requested this feature. And annotations are practically useless as it is. Someone made a stinky API decision and successfully managed to sweep it under the carpet. Of course we want to be able to specify to which check run annotations should be added, rather than have one picked randomly for us! It’s just common sense. |
Beta Was this translation helpful? Give feedback.
-
This is seriously needed by my team. We moved to github actions and we are even paying for the service. We cannot have test results, annotations spread all over the place randomly. When will we get an update on the API? |
Beta Was this translation helpful? Give feedback.
-
You can see how confusing this is for our users. The "flake8" check is a python linting check: |
Beta Was this translation helpful? Give feedback.
-
@francisfuzz is it possible for Github to re-evaluate the priority of this issue? |
Beta Was this translation helpful? Give feedback.
-
This is the proper way to add feedback in actions, equivalent with the check runs in GitHub Apps: https://github.blog/2022-05-09-supercharging-github-actions-with-job-summaries/ |
Beta Was this translation helpful? Give feedback.
-
Same problem on my side. Definitely a problem, or "missing feature", if you prefer. |
Beta Was this translation helpful? Give feedback.
-
Is GH going to fix this or should we give up on the checks? |
Beta Was this translation helpful? Give feedback.
-
Well this seems to explain why my check runs keep keep ending up associate with my push action and not the action driven by the PR. I can't believe this is an issue. If you cannot control what the check run is actually associated with it's next to useless. |
Beta Was this translation helpful? Give feedback.
-
@francisfuzz , @maxprit , Can we raise the severity of this? It's not just a desired feature, it's a total misimplementation of how it should work. As you can see, quite a few other developers feel this way and are affected by it. What do we need to do in order to get the attention of the Github developers/managers? Is there a issue tracker where this can be reported? How do escalations work? |
Beta Was this translation helpful? Give feedback.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
-
There is a workaround. It's possible to publish the check-run in a dedicated, separate check-suite by using a token for a GitHub app, instead of the regular GITHUB_TOKEN.
update: your workflow should create a comment like the default one using the github-actions user, as otherwise the action will create one comment per workflow run, instead of updating the first:
result It comes at the cost of not having the published message as part of the GH Actions run - this would otherwise be randomly assigned. |
Beta Was this translation helpful? Give feedback.
-
Github support's response is:
The API is meant to be called from a Github app, but not from Githubs very own Github app called Github Actions. The proper use in Github Actions is to create your own Github app, install that app in your repos, get an installation token and use that with the Checks API (see https://github.com/orgs/community/discussions/24616#discussioncomment-5607870 above). Very user-friendly. |
Beta Was this translation helpful? Give feedback.
-
Just to clear something out: if you have a single workflow that is triggered by serveral different webhook events, you can't have it resulting in a single status on a commit? An example:
So the action can't create a commit status in first case, which would be updated in the second? |
Beta Was this translation helpful? Give feedback.
-
It is now May 2024 and this trivially fixable problem still plagues the whole GitHub Actions ecosystem. I'm definitely baffled. |
Beta Was this translation helpful? Give feedback.
-
Encountered this issue recently. Sad to see this thread was open in 2022 and the problem still exists. |
Beta Was this translation helpful? Give feedback.
-
Just encountered this myself and spent a solid ten minutes staring at the code, the workflow run, and the GitHub support form, before finding this discussion... this seems bizarre! Adding a voice to ask for this to be fixed please. |
Beta Was this translation helpful? Give feedback.
@jwgmeligmeyling - Welcome back to the Support Community and thanks for this feedback! 🙇♂️
After reviewing your particular case, I’d like to confirm here that it is not currently possible to create a check run associated with a particular check suite with the
GitHub Actions
-providedGITHUB_TOKEN
. I acknowledge that it is something that would be valuable given your use case.We’re always working to improve GitHub and the GitHub Support Co…