Skip to content

Commit

Permalink
ci: add Stale Action for specifically labeled issues and PRs (#12488)
Browse files Browse the repository at this point in the history
  • Loading branch information
agilgur5 committed Jan 9, 2024
1 parent 6a0891e commit 3652241
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 1 deletion.
41 changes: 41 additions & 0 deletions .github/workflows/stale.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# https://github.com/actions/stale
name: Mark stale issues and pull requests

on:
schedule:
- cron: '0 2 * * *' # once a day at 2am

permissions:
contents: read

jobs:
stale:
permissions:
issues: write # for commenting on an issue and editing labels
pull-requests: write # for commenting on a PR and editing labels
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v9
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
# timing
days-before-stale: 14 # 2 weeks of inactivity
days-before-close: 14 # 2 more weeks of inactivity
# labels to watch for, add, and remove
only-labels: 'more information needed' # only mark issues/PRs as stale if they have this label
labels-to-remove-when-unstale: 'more information needed' # remove label when unstale -- should be manually added back if information is insufficient
stale-issue-label: 'stale'
stale-pr-label: 'stale'
# automated messages to issue/PR authors
stale-issue-message: >
This issue has been automatically marked as stale because it has not had recent activity and needs more information.
It will be closed if no further activity occurs.
stale-pr-message: >
This PR has been automatically marked as stale because it has not had recent activity and needs further changes.
It will be closed if no further activity occurs.
close-issue-message: >
This issue has been closed due to inactivity and lack of information.
If you still encounter this issue, please add the requested information and re-open.
close-pr-message:
This PR has been closed due to inactivity and lack of changes.
If you would like to still work on this PR, please address the review comments and re-open.
11 changes: 10 additions & 1 deletion docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,16 @@ Any bugs with 3-4 "👍" reactions should be labeled at least `P2`.
Bugs can be [sorted by "👍"](https://github.com/argoproj/argo-workflows/issues?q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc+label%3Abug).

If the issue is determined to be a user error and not a bug, remove the `bug` label (and the `regression` label, if applicable) and replace it with the `support` label.
If more information is needed from the author to diagnose the issue, then apply the `more-information-needed` label.
If more information is needed from the author to diagnose the issue, then apply the `more information needed` label.

##### Staleness

Only issues and PRs that have the [`more information needed` label](https://github.com/argoproj/argo-workflows/labels/more%20information%20needed) will be considered for staleness.

If the author does not respond timely to a request for more information, the issue or PR will be automatically marked with the `stale` label and a bot message.
Subsequently, if there is still no response, it will be automatically closed as "not planned".

See the [Stale Action configuration](https://github.com/argoproj/argo-workflows/blob/main/.github/workflows/stale.yaml) for more details.

## Sustainability Effort

Expand Down

0 comments on commit 3652241

Please sign in to comment.