Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SAME VERSION] Workflow to mark inactive issues/PRs as stale and eventually close them #363

Merged
merged 6 commits into from
Aug 26, 2021

Conversation

romoh
Copy link
Contributor

@romoh romoh commented Aug 23, 2021

What this PR does / why we need it:
Help keeping akri repo current by marking issues and PRs with no recent activity as stale and eventually closing them.

Special notes for your reviewer:

If applicable:

  • this PR has an associated PR with documentation in akri-docs
  • this PR contains unit tests
  • added code adheres to standard Rust formatting (cargo fmt)
  • code builds properly (cargo build)
  • code is free of common mistakes (cargo clippy)
  • all Akri tests succeed (cargo test)
  • inline documentation builds (cargo doc)
  • version has been updated appropriately (./version.sh)

.github/workflows/stale-tasks.yml Show resolved Hide resolved
.github/workflows/stale-tasks.yml Show resolved Hide resolved
.github/workflows/stale-tasks.yml Outdated Show resolved Hide resolved
stale-pr-message: >
PR has been automatically marked as stale due to inactivity for 45 days. Update the PR to remove label, otherwise it will be automatically closed."
exempt-issue-labels: keep-alive
token: ${{ secrets.GITHUB_TOKEN }}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just to double check ... does {secrets.GHTOKEN} have any issue with PRs from forks?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't be a problem. The token should have enough permissions to add labels, add comments and close PR.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my curiousity was more around whether a forked pr would have access to secrets. i think it is ok, but wanted to make sure we tried it.

@kate-goldenring
Copy link
Contributor

Curious: Does day 1 on the stale check start when this is merged or will issues that have already been inactive for 45 days be marked stale? Also, does triaging actions count as "activity" and would remove stale? Or just comments? The latter is probably preferred IMO.

@bfjelds
Copy link
Collaborator

bfjelds commented Aug 24, 2021

Curious: Does day 1 on the stale check start when this is merged or will issues that have already been inactive for 45 days be marked stale? Also, does triaging actions count as "activity" and would remove stale? Or just comments? The latter is probably preferred IMO.

i think the time is dictated by the issue's updated_at state (which reflects the last time the issue was updated) against now. we will probably see a lot of issues that are summarily marked stale instantly. triaging should be activity, as updated_at is changed by just about everything.

@romoh
Copy link
Contributor Author

romoh commented Aug 24, 2021

Curious: Does day 1 on the stale check start when this is merged or will issues that have already been inactive for 45 days be marked stale? Also, does triaging actions count as "activity" and would remove stale? Or just comments? The latter is probably preferred IMO.

i think the time is dictated by the issue's updated_at state (which reflects the last time the issue was updated) against now. we will probably see a lot of issues that are summarily marked stale instantly. triaging should be activity, as updated_at is changed by just about everything.

Brian is correct (see my earlier reply to Jirka)
The action is based off the issue's updated_at field and uses that for calculations. Any updates to the issue resets the counter.

Brian, for your concern I was planning on adding keep-alive for good first issues before merging. That way those issues are not marked as stale. Also since @kate-goldenring did recent cleanup most issues have been recently updated so we shouldn't see a flood of stales after merge.

@jiria
Copy link
Contributor

jiria commented Aug 24, 2021

Brian, for your concern I was planning on adding keep-alive for good first issues before merging.

Great idea. Should we expand it to issues that were not triaged yet? Or more generically, have a label to denote issues that await feedback from Akri team?

@romoh
Copy link
Contributor Author

romoh commented Aug 24, 2021

Brian, for your concern I was planning on adding keep-alive for good first issues before merging.

Great idea. Should we expand it to issues that were not triaged yet? Or more generically, have a label to denote issues that await feedback from Akri team?

Good point, We can also exclude untriaged issues, but right now we don't have any labels for those.
Looks like a potential improvement: Label any newly created issue as untriaged so that we can exclude it from stale issue rules. Having said that, we triage monthly so 45 days should be more than enough to cover new issues.

@romoh romoh assigned romoh and unassigned romoh Aug 25, 2021
@romoh romoh merged commit cf7895b into project-akri:main Aug 26, 2021
vincepnguyen pushed a commit that referenced this pull request Nov 23, 2021
[SAME VERSION] Workflow to mark inactive issues/PRs as stale and eventually close them
Signed-off-by: vincepnguyen <70007233+vincepnguyen@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants