qwen-code/.github/workflows/stale.yml
Shaojin Wen 06cc41ee3f
Some checks failed
E2E Tests / E2E Test (Linux) - sandbox:docker - shard 1/3 (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:docker - shard 2/3 (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:docker - shard 3/3 (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:none - shard 1/3 (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:none - shard 2/3 (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:none - shard 3/3 (push) Waiting to run
E2E Tests / E2E Test - macOS - shard 1/2 (push) Waiting to run
E2E Tests / E2E Test - macOS - shard 2/2 (push) Waiting to run
E2E Tests / channel-plugin E2E (nightly) (push) Waiting to run
E2E Tests / cron-interactive E2E (nightly) (push) Waiting to run
E2E Tests / web-shell Browser Regression (push) Waiting to run
SDK Java / ubuntu-latest / Java 17 (push) Waiting to run
SDK Java / macos-latest / Java 21 (push) Waiting to run
SDK Java / ubuntu-latest / Java 21 (push) Waiting to run
SDK Java / windows-latest / Java 21 (push) Waiting to run
SDK Java / Real daemon E2E / Java 11 (push) Waiting to run
SDK Java / ubuntu-latest / Java 11 (push) Waiting to run
npm cache producer / Save npm cache (push) Has been cancelled
ci: route trusted-author fork PRs and no-checkout jobs to the ECS pool (#8502)
* ci: route trusted-author fork PRs and no-checkout jobs to the ECS pool

Fork PRs whose author has write access (OWNER/MEMBER/COLLABORATOR association) now run Linux CI on the self-hosted ECS pool instead of the saturated GitHub-hosted quota, and bot workflows that check out no code move to ECS unconditionally. Everything stays gated on the MAINTAINER_ECS_RUNNER_DISABLED kill-switch.

* ci: address review — real write-permission routing, watchdog independence, timeouts

Route the triage agent on the collaborator-permission API result computed by authorize instead of the coarse author_association, which admits org members and read-only collaborators; the two permission-gate jobs revert to the same-repo guard. Keep the fleet watchdog and the CI-failure reporter hosted so they stay independent of the pool they watch. Add missing timeouts, wipe serve-ab's reused workspace, and pin the routing logic with drift and negative-case tests.

---------

Co-authored-by: 易良 <1204183885@qq.com>
2026-08-04 03:48:24 +00:00

53 lines
2.6 KiB
YAML

name: 'Mark stale issues and pull requests'
# Run as a daily cron at 00:30 UTC (Beijing time 08:30).
# Avoid the top of the hour to dodge GitHub's high-contention window,
# and stay 30 minutes after release.yml (00:00 UTC) to reduce overlap.
on:
schedule:
- cron: '30 0 * * *'
workflow_dispatch:
jobs:
stale:
# Checks out nothing and runs no repository code (schedule/dispatch use
# base-repo YAML), so the persistent ECS pool is safe.
# Kill-switch: MAINTAINER_ECS_RUNNER_DISABLED.
runs-on: '${{ (github.repository == ''QwenLM/qwen-code'' && vars.MAINTAINER_ECS_RUNNER_DISABLED != ''true'') && fromJSON(''["self-hosted", "linux", "x64", "ecs-qwen"]'') || fromJSON(''["ubuntu-latest"]'') }}'
# A hung sweep must not pin a persistent pool machine for the 360-minute
# default; the sweep itself finishes in well under this.
timeout-minutes: 10
permissions:
issues: 'write'
pull-requests: 'write'
concurrency:
group: '${{ github.workflow }}-stale'
cancel-in-progress: true
steps:
- uses: 'actions/stale@eb5cf3af3ac0a1aa4c9c45633dd1ae542a27a899' # v10.3.0
with:
repo-token: '${{ secrets.GITHUB_TOKEN }}'
# Issues are intentionally disabled here; a separate policy will
# be introduced once issue triage labels are in place.
days-before-issue-stale: -1
days-before-issue-close: -1
# Pull requests: 60 days to stale + 30 days to close.
days-before-pr-stale: 60
days-before-pr-close: 30
stale-pr-label: 'status/stale'
stale-pr-message: >-
This pull request has had no activity for 60 days and is being marked as stale.
It will be closed in another 30 days if no further activity occurs.
To keep it open, push a new commit or leave a comment.
Maintainers may apply `pinned`, `status/blocked`, `status/on-hold`,
or `status/ready-for-merge` to exempt it from auto-close.
close-pr-message: >-
This pull request has been closed after 30 additional days of inactivity.
You are welcome to reopen it or submit a new pull request if the change is still relevant.
Thanks for contributing!
exempt-pr-labels: 'pinned,security,status/blocked,status/on-hold,status/ready-for-merge'
remove-stale-when-updated: true
ascending: true
# Cap per-run API operations to stay well under GitHub's hourly rate limit
# and give the current PR backlog (~150) enough headroom across a few runs.
operations-per-run: 100