Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions .github/workflows/additional.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,35 @@ jobs:
- uses: actions/checkout@v5
- uses: prefix-dev/[email protected]
- run: pixi run docs-linkcheck

create-issue-on-failure:
name: Create issue on failure
runs-on: ubuntu-latest
needs: [min-version-policy, linkcheck]
if: failure() && github.event_name == 'schedule'
permissions:
issues: write
steps:
- name: Create issue
uses: actions/github-script@v7
with:
script: |
const workflowUrl = `${context.serverUrl}/${context.repo.owner}/${context.repo.repo}/actions/runs/${context.runId}`;
const title = `CI Additional workflow failed - ${new Date().toISOString().split('T')[0]}`;
const body = `The [CI Additional workflow](${workflowUrl}) failed on its scheduled run.

**Workflow Run:** ${context.runId}
**Trigger:** ${context.eventName}
**Branch:** ${context.ref}

Please investigate the failure and fix the issues.

_This issue was automatically created by the workflow._`;

await github.rest.issues.create({
owner: context.repo.owner,
repo: context.repo.repo,
title: title,
body: body,
labels: ['bug', 'automated']
});