This is an automated email from the ASF dual-hosted git repository.

github-merge-queue[bot] pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow-rs.git


The following commit(s) were added to refs/heads/main by this push:
     new f971a78518 Open an issue when daily Miri checks fail (#11935)
f971a78518 is described below

commit f971a78518039c1108c8e8ffdc17e4bebc85dec5
Author: Kosta Tarasov <[email protected]>
AuthorDate: Wed Oct 28 12:39:39 2026 +0000

    Open an issue when daily Miri checks fail (#11935)
    
    # Which issue does this PR close?
    
    Closes #11548.
    
    # Rationale for this change
    
    From @Jefffrey's [review of
    
#11631](https://github.com/apache/arrow-rs/pull/11631#pullrequestreview-5598578977):
    
    > some follow up work would be a way to notify if this miri run fails
    (e.g. auto create an issue)
    
    # What changes are included in this PR?
    
    Failed scheduled Miri runs in `apache/arrow-rs` open a `Daily Miri
    checks failed` issue linking the failed run and commit. Further failures
    leave an existing alert alone; maintainers close it after Miri passes
    again. Manual runs and forks do not create alerts.
    
    # Are these changes tested?
    
    Validated with a temporary workflow on my fork using simulated Miri
    partitions and the same alert script, with the repository/event guard
    adapted for manual fork runs:
    
    - A failure created [alert issue
    #8](https://github.com/sdf-jkl/arrow-rs/issues/8).
    - A [repeat
    failure](https://github.com/sdf-jkl/arrow-rs/actions/runs/40513403680)
    created no duplicate issue or comment.
    - A [successful
    run](https://github.com/sdf-jkl/arrow-rs/actions/runs/40513291680)
    produced no alert.
    
    # Are there any significant user-facing changes?
    
    No.
    
    AI assisted with the workflow implementation, documentation, and
    validation.
---
 .github/workflows/README.md |  2 ++
 .github/workflows/miri.yaml | 33 +++++++++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)

diff --git a/.github/workflows/README.md b/.github/workflows/README.md
index 7b60aa3c96..67db463f0c 100644
--- a/.github/workflows/README.md
+++ b/.github/workflows/README.md
@@ -26,6 +26,8 @@ A single required status check combines the results and 
blocks merging on failur
 Miri runs separately every day at 03:17 UTC and on demand through the `miri`
 workflow's **Run workflow** button or
 `gh workflow run miri.yaml --repo apache/arrow-rs --ref <branch-or-tag>`.
+Failed scheduled runs in `apache/arrow-rs` open a `Daily Miri checks failed` 
issue
+unless one is already open. Close the issue after Miri passes again to allow 
new alerts.
 
 New jobs that are small and short should use `runs-on: ubuntu-slim`, as ASF 
Infra recommends.
 These runners have 1 vCPU, 5 GB of memory, no Docker engine and a 15-minute 
hard limit, but
diff --git a/.github/workflows/miri.yaml b/.github/workflows/miri.yaml
index f444faa862..16a16eee58 100644
--- a/.github/workflows/miri.yaml
+++ b/.github/workflows/miri.yaml
@@ -54,3 +54,36 @@ jobs:
           RUST_BACKTRACE: full
           RUST_LOG: "trace"
         run: bash .github/workflows/miri.sh ${{ matrix.partition }} 12
+
+  report-failure:
+    name: Report daily Miri failure
+    needs: miri-checks
+    if: failure() && github.event_name == 'schedule' && github.repository == 
'apache/arrow-rs'
+    runs-on: ubuntu-slim
+    permissions:
+      issues: write
+    steps:
+      - uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3  
# v9.0.0
+        with:
+          script: |
+            const title = 'Daily Miri checks failed';
+            const pages = 
github.paginate.iterator(github.rest.issues.listForRepo, {
+              ...context.repo, state: 'open', per_page: 100,
+            });
+            for await (const { data: issues } of pages) {
+              if (issues.some(issue => !issue.pull_request && issue.title === 
title)) {
+                return;
+              }
+            }
+            const repositoryUrl = 
`${context.serverUrl}/${context.repo.owner}/${context.repo.repo}`;
+            await github.rest.issues.create({
+              ...context.repo,
+              title,
+              labels: ['development-process'],
+              body: [
+                `The daily Miri run failed: 
${repositoryUrl}/actions/runs/${context.runId}`,
+                `Commit: ${context.sha}`,
+                `Check [subsequent 
runs](${repositoryUrl}/actions/workflows/miri.yaml) and close this issue once 
Miri passes again.`,
+                'Further failures will not create another alert while this 
issue is open.',
+              ].join('\n\n'),
+            });

Reply via email to