Describe your issue
The stale label isn't being removed from PRs when there's new activity even though remove-stale-when-updated isn't set.
Your stale action configuration
on:
push:
paths:
- .github/workflows/triage-issues.yml
schedule:
# Once every day at midnight UTC
- cron: "0 0 * * *"
issue_comment:
jobs:
stale:
if: >
startsWith(github.repository, 'Homebrew/') && (
github.event_name != 'issue_comment' || (
contains(github.event.issue.labels.*.name, 'stale') ||
contains(github.event.pull_request.labels.*.name, 'stale')
)
)
runs-on: ubuntu-latest
steps:
- name: Mark/Close Stale Issues and Pull Requests
uses: actions/stale@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
days-before-stale: 21
days-before-close: 7
stale-issue-message: >
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs.
stale-pr-message: >
This pull request has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs.
exempt-issue-labels: "gsoc-outreachy,help wanted,in progress"
exempt-pr-labels: "gsoc-outreachy,help wanted,in progress"
Further context
I made a comment on Homebrew/brew#11140 (comment) that should have caused the action to remove the stale label. The action did run successfully (the logs are available here). Here are the relevant lines from the logs:
[#11140] Found this pull request last updated 2021-05-08T15:44:35Z
[#11140] The option "onlyLabels" was not specified. Continuing the process for this pull request
[#11140] Days before pull request stale: 21
[#11140] The pull request is not closed nor locked. Trying to remove the close label...
[#11140] There is no close label on this pull request. Skip
[#11140] This pull request has a stale label
[#11140] This pull request has no assignee
[#11140] Skip the assignees checks
[#11140] Found a stale pull request
[#11140] Checking for label on pull request
[#11140] Pull request marked stale on: 2021-05-08T15:44:35Z
[#11140] Checking for comments on pull request since 2021-05-08T15:44:35Z
[#11140] Comments not made by actor or another bot: 0
[#11140] Pull request has been commented on: false
[#11140] Days before pull request close: 7
[#11140] Pull request has been updated: true
[#11140] Stale pull request is not old enough to close yet (hasComments? false, hasUpdate? true)
The line that says Pull request marked stale on: 2021-05-08T15:44:35Z seems to be incorrect, as the stale label was added 16 hours ago before that time. I wonder if the action is using the time of the latest comment as the time that the stale label was added.
Describe your issue
The
stalelabel isn't being removed from PRs when there's new activity even thoughremove-stale-when-updatedisn't set.Your stale action configuration
Further context
I made a comment on Homebrew/brew#11140 (comment) that should have caused the action to remove the
stalelabel. The action did run successfully (the logs are available here). Here are the relevant lines from the logs:The line that says
Pull request marked stale on: 2021-05-08T15:44:35Zseems to be incorrect, as the stale label was added 16 hours ago before that time. I wonder if the action is using the time of the latest comment as the time that the stale label was added.