Skip to content
Merged
Show file tree
Hide file tree
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
10 changes: 6 additions & 4 deletions .github/workflows/agentic-auto-upgrade.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This file was automatically generated by pkg/workflow/auto_update_workflow.go (v0.88.4). DO NOT EDIT. To debug this workflow, load the skill at https://github.com/github/gh-aw/blob/main/debug.md
# This file was automatically generated by pkg/workflow/auto_update_workflow.go (v0.93.2). DO NOT EDIT. To debug this workflow, load the skill at https://github.com/github/gh-aw/blob/main/debug.md
#
# ___ _ _
# / _ \ | | (_)
Expand Down Expand Up @@ -47,14 +47,16 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false

- name: Install gh-aw
uses: github/gh-aw-actions/setup-cli@v0.88.4
uses: github/gh-aw-actions/setup-cli@v0.93.2
with:
version: v0.88.4
version: v0.93.2

- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand Down
87 changes: 60 additions & 27 deletions .github/workflows/agentics-maintenance.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This file was automatically generated by pkg/workflow/maintenance_workflow.go (v0.88.4). DO NOT EDIT. To debug this workflow, load the skill at https://github.com/github/gh-aw/blob/main/debug.md
# This file was automatically generated by pkg/workflow/maintenance_workflow.go (v0.93.2). DO NOT EDIT. To debug this workflow, load the skill at https://github.com/github/gh-aw/blob/main/debug.md
#
# ___ _ _
# / _ \ | | (_)
Expand All @@ -24,8 +24,10 @@
# This file defines the generated agentic maintenance workflow for this repository.
# It runs scheduled cleanup for expiring safe outputs and supports manual maintenance operations.
#
# This workflow is generated automatically when workflows use expiring safe outputs
# or when repository maintenance features are enabled in .github/workflows/aw.json.
# This workflow is generated automatically when workflows use expiring safe outputs,
# when workflows enable steering (safe-outputs.steer), declare compaction-enabled
# ledgers (tools.ledger) or work queues, or when repository maintenance features are
# enabled in .github/workflows/aw.json.
#
# To disable maintenance workflow generation, set in .github/workflows/aw.json:
# {"maintenance": false}
Expand Down Expand Up @@ -79,22 +81,30 @@ on:
outputs:
operation_completed:
description: 'The maintenance operation that was completed (empty when none ran or a scheduled job ran)'
value: ${{ jobs.run_operation.outputs.operation || inputs.operation }}
value: ${{ jobs.run_operation.outputs.operation || (inputs.operation == 'safe_outputs' || inputs.operation == 'create_labels' || inputs.operation == 'activity_report' || inputs.operation == 'close_agentic_workflows_issues' || inputs.operation == 'update_pull_request_branches' || inputs.operation == 'validate' || inputs.operation == 'forecast' || inputs.operation == 'clean_cache_memories') && inputs.operation || '' }}
applied_run_url:
description: 'The run URL that safe outputs were applied from'
value: ${{ jobs.apply_safe_outputs.outputs.run_url }}

# Jobs request only the permissions needed for their individual maintenance operations.
permissions: {}

# Serialize maintenance runs to avoid overlapping writes to repository resources.
concurrency:
group: ${{ github.workflow }}-${{ github.repository }}
cancel-in-progress: false

jobs:
close-expired-discussions:
name: Close expired discussions
if: ${{ (!(github.event.repository.fork)) && github.event_name != 'push' && (github.event_name != 'workflow_dispatch' && github.event_name != 'workflow_call' || inputs.operation == '' || inputs.operation == 'none') }}
runs-on: ubuntu-slim
# Closing expired resources requires write access to this resource type only.
permissions:
discussions: write
steps:
- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -109,13 +119,15 @@ jobs:
const { main } = require(path.join(actionsDir, 'close_expired_discussions.cjs'));
await main();
close-expired-issues:
name: Close expired issues
if: ${{ (!(github.event.repository.fork)) && github.event_name != 'push' && (github.event_name != 'workflow_dispatch' && github.event_name != 'workflow_call' || inputs.operation == '' || inputs.operation == 'none') }}
runs-on: ubuntu-slim
# Closing expired resources requires write access to this resource type only.
permissions:
issues: write
steps:
- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -130,13 +142,15 @@ jobs:
const { main } = require(path.join(actionsDir, 'close_expired_issues.cjs'));
await main();
close-expired-pull-requests:
name: Close expired pull requests
if: ${{ (!(github.event.repository.fork)) && github.event_name != 'push' && (github.event_name != 'workflow_dispatch' && github.event_name != 'workflow_call' || inputs.operation == '' || inputs.operation == 'none') }}
runs-on: ubuntu-slim
# Closing expired resources requires write access to this resource type only.
permissions:
pull-requests: write
steps:
- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -152,13 +166,15 @@ jobs:
await main();

cleanup-cache-memory:
name: Cleanup cache memory
if: ${{ (!(github.event.repository.fork)) && github.event_name != 'push' && (github.event_name != 'workflow_dispatch' && github.event_name != 'workflow_call' || inputs.operation == '' || inputs.operation == 'none' || inputs.operation == 'clean_cache_memories') }}
runs-on: ubuntu-slim
# Removing obsolete Actions caches requires actions: write.
permissions:
actions: write
steps:
- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -174,8 +190,10 @@ jobs:
await main();

run_operation:
name: Run maintenance operation
if: ${{ (github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call') && inputs.operation != '' && inputs.operation != 'none' && inputs.operation != 'safe_outputs' && inputs.operation != 'create_labels' && inputs.operation != 'activity_report' && inputs.operation != 'close_agentic_workflows_issues' && inputs.operation != 'clean_cache_memories' && inputs.operation != 'update_pull_request_branches' && inputs.operation != 'validate' && inputs.operation != 'forecast' && (!(github.event.repository.fork)) }}
runs-on: ubuntu-slim
# Updates, upgrades, and workflow enable/disable operations need repository write access.
permissions:
actions: write
contents: write
Expand All @@ -189,7 +207,7 @@ jobs:
persist-credentials: false

- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -206,9 +224,9 @@ jobs:
await main();

- name: Install gh-aw
uses: github/gh-aw-actions/setup-cli@v0.88.4
uses: github/gh-aw-actions/setup-cli@v0.93.2
with:
version: v0.88.4
version: v0.93.2

- name: Run operation
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
Expand All @@ -233,14 +251,16 @@ jobs:
run: echo "operation=$GH_AW_OPERATION" >> "$GITHUB_OUTPUT"

update_pull_request_branches:
name: Update pull request branches
if: ${{ (github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call') && inputs.operation == 'update_pull_request_branches' && (!(github.event.repository.fork)) }}
runs-on: ubuntu-slim
# Branch updates may write commits and update pull requests.
permissions:
contents: write
pull-requests: write
steps:
- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand Down Expand Up @@ -271,8 +291,10 @@ jobs:
await main();

apply_safe_outputs:
name: Apply safe outputs
if: ${{ (github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call') && inputs.operation == 'safe_outputs' && (!(github.event.repository.fork)) }}
runs-on: ubuntu-slim
# Replay can create or update any supported safe-output resource.
permissions:
actions: read
contents: write
Expand All @@ -291,7 +313,7 @@ jobs:
persist-credentials: false

- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -310,6 +332,8 @@ jobs:
- name: Apply Safe Outputs
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_JOB_CHECK_RUN_ID: ${{ job.check_run_id }}
GH_AW_WORKFLOW_ID: "agentics-maintenance"
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_AW_RUN_URL: ${{ inputs.run_url }}
with:
Expand All @@ -329,8 +353,10 @@ jobs:
run: echo "run_url=$GH_AW_RUN_URL" >> "$GITHUB_OUTPUT"

create_labels:
name: Create labels
if: ${{ (github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call') && inputs.operation == 'create_labels' && (!(github.event.repository.fork)) }}
runs-on: ubuntu-slim
# Creating repository labels uses the issues API.
permissions:
contents: read
issues: write
Expand All @@ -341,7 +367,7 @@ jobs:
persist-credentials: false

- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -358,9 +384,9 @@ jobs:
await main();

- name: Install gh-aw
uses: github/gh-aw-actions/setup-cli@v0.88.4
uses: github/gh-aw-actions/setup-cli@v0.93.2
with:
version: v0.88.4
version: v0.93.2

- name: Create missing labels
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
Expand All @@ -377,9 +403,11 @@ jobs:
await main();

activity_report:
name: activity report
if: ${{ (github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call') && inputs.operation == 'activity_report' && (!(github.event.repository.fork)) }}
runs-on: ubuntu-slim
timeout-minutes: 120
# Read workflow logs and create the resulting report issue.
permissions:
actions: read
contents: read
Expand All @@ -391,7 +419,7 @@ jobs:
persist-credentials: false

- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -408,9 +436,9 @@ jobs:
await main();

- name: Install gh-aw
uses: github/gh-aw-actions/setup-cli@v0.88.4
uses: github/gh-aw-actions/setup-cli@v0.93.2
with:
version: v0.88.4
version: v0.93.2

- name: Restore activity report logs cache
id: activity_report_logs_cache
Expand Down Expand Up @@ -484,9 +512,11 @@ jobs:
core.info('Created issue #' + createdIssue.data.number + ': ' + createdIssue.data.html_url);

forecast_report:
name: forecast report
if: ${{ (github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call') && inputs.operation == 'forecast' && (!(github.event.repository.fork)) }}
runs-on: ubuntu-slim
timeout-minutes: 60
# Read workflow logs and create the resulting report issue.
permissions:
actions: read
contents: read
Expand All @@ -498,7 +528,7 @@ jobs:
persist-credentials: false

- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -515,9 +545,9 @@ jobs:
await main();

- name: Install gh-aw
uses: github/gh-aw-actions/setup-cli@v0.88.4
uses: github/gh-aw-actions/setup-cli@v0.93.2
with:
version: v0.88.4
version: v0.93.2

- name: Restore forecast report logs cache
id: forecast_report_logs_cache
Expand All @@ -535,7 +565,6 @@ jobs:
shell: bash
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DEBUG: "*"
GH_AW_CMD_PREFIX: gh aw
run: |
mkdir -p ./.cache/gh-aw/forecast
Expand Down Expand Up @@ -588,13 +617,15 @@ jobs:
await main();

close_agentic_workflows_issues:
name: Close agentic workflows issues
if: ${{ (github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call') && inputs.operation == 'close_agentic_workflows_issues' && (!(github.event.repository.fork)) }}
runs-on: ubuntu-slim
# Closing no-repro issues requires issues: write.
permissions:
issues: write
steps:
- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand Down Expand Up @@ -623,8 +654,10 @@ jobs:
await main();

validate_workflows:
name: Validate workflows
if: ${{ (github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call') && inputs.operation == 'validate' && (!(github.event.repository.fork)) }}
runs-on: ubuntu-latest
# Read workflow sources and file issues for validation findings.
permissions:
contents: read
issues: write
Expand All @@ -635,7 +668,7 @@ jobs:
persist-credentials: false

- name: Setup Scripts
uses: github/gh-aw-actions/setup@v0.88.4
uses: github/gh-aw-actions/setup@v0.93.2
with:
destination: ${{ runner.temp }}/gh-aw/actions

Expand All @@ -652,9 +685,9 @@ jobs:
await main();

- name: Install gh-aw
uses: github/gh-aw-actions/setup-cli@v0.88.4
uses: github/gh-aw-actions/setup-cli@v0.93.2
with:
version: v0.88.4
version: v0.93.2

- name: Validate workflows and file issue on findings
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
Expand Down
Loading