mirror of
https://github.com/zoriya/v10.git
synced 2026-08-06 14:18:10 +00:00
fix(ci): reuse diagnosis comment per PR instead of per run (#740)
This commit is contained in:
@@ -13,7 +13,7 @@ permissions:
|
||||
id-token: write
|
||||
|
||||
concurrency:
|
||||
group: ci-diagnosis-${{ github.event.workflow_run.id }}
|
||||
group: ci-diagnosis-pr-${{ github.event.workflow_run.pull_requests[0].number || github.event.workflow_run.id }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
@@ -70,13 +70,13 @@ jobs:
|
||||
5. If the failure is only simple lint/style warnings, keep it brief and generic; do not enumerate every file.
|
||||
6. Avoid noise:
|
||||
- Do not post redundant comments.
|
||||
- Use one comment per CI run.
|
||||
- If a comment already exists with marker `<!-- ci-diagnosis:run-${{ github.event.workflow_run.id }} -->`, update it instead of creating a new one.
|
||||
- Use one comment per PR.
|
||||
- If a comment already exists with marker `<!-- ci-diagnosis:pr-${{ steps.context.outputs.pr_number }} -->`, update it instead of creating a new one.
|
||||
- Do not include stack traces or long command output in comments.
|
||||
|
||||
Post or update a single PR comment on #${{ steps.context.outputs.pr_number }} using this template exactly:
|
||||
|
||||
<!-- ci-diagnosis:run-${{ github.event.workflow_run.id }} -->
|
||||
<!-- ci-diagnosis:pr-${{ steps.context.outputs.pr_number }} -->
|
||||
### CI Failure Diagnosis
|
||||
- Run: ${{ github.event.workflow_run.html_url }}
|
||||
- Commit: `${{ github.event.workflow_run.head_sha }}`
|
||||
|
||||
Reference in New Issue
Block a user