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

Discussion : Github workflow for marking the issue/pr stale which are inactive. #6005

Open
neeldoshii opened this issue Dec 6, 2024 · 7 comments
Labels

Comments

@neeldoshii
Copy link
Contributor

There seems a lot off PR which might be stale (inactive) which hasn't been touched for months. This could be maybe because the original author left. For example #5585 is lying around for around 9 month.

1. Identify Stale PRs

  • Define a stale PR as one that has had no activity for over 3 months.
  • Use a GitHub Workflow Action to scan for PRs that meet this criterion.

2. Add the "stale" Label

  • Automatically mark identified PRs with a "stale" label.
  • Notify the author or contributors with a comment like:

This PR has been marked as stale due to inactivity for over 3 months. If this PR is still relevant, please update it or leave a comment within 14 days to avoid automatic closure.

3. Allow a Grace Period (14 Days)

  • Provide a 14-day grace period for contributors to respond or update the PR.
  • If any activity occurs (e.g., a comment or code change):
    • Automatically remove the "stale" label and do not close the PR.

4. Close Inactive PRs

  • If no activity occurs within the grace period:
    • Automatically close the PR with a message like:

This PR has been closed due to inactivity. Feel free to reopen or create a new PR if this is still relevant.

5. Handle Exceptional PRs

  • Review PRs that are close to completion or otherwise exceptional. Criteria for this include:
    • The PR is nearly complete towards solving the issue.
  • For such PRs, add a "keep-open" label.
    • PRs with the "keep-open" label are excluded from the stale process and will not be closed automatically.

I believe this will be best for reviewers/maintainers to maintain the PR.
Now the question is do we really need it?

Github Stale Bot : https://github.com/marketplace/actions/close-stale-issues

Relevant Code/ Credits : https://github.com/ankidroid/Anki-Android/blob/main/.github/workflows/stale.yml

@neeldoshii
Copy link
Contributor Author

cc : @nicolas-raoul @misaochan wdyt?

@psh
Copy link
Collaborator

psh commented Dec 7, 2024

Labels are great to shine a light into the dark corners of the process, but the human factor remains ... and might be also relevant to why we (as a team) allow PRs to hang around.

I'll ask the tough question - are we willing to do what it takes with old PRs? If the process flags it, will we still leave them hanging around? We have old PRs right now that arent being addressed.

The agile manifesto says to value "people over process" - how are we doing at a people level with old contributions? Can we commit to cleaning house and moving things forward with the help of some software tools showing where things are aging badly?

@nicolas-raoul
Copy link
Member

A good PR is stale until someone is interested in the feature and decides to review it. 🙂

Adding a "stale" label might send the contributor a negative signal, when the only problem might be that reviewers are all busy.

I think we already have a way to know the next actions to perform:

  • CI failing or changes requested or draft: waiting for contributor
  • Other: waiting for reviewer

@nicolas-raoul
Copy link
Member

"marked as stale due to inactivity for over 3 months"

I personally hate such messages when they come about a PR (or bug report) I sent to another project I just wanted to help for 10 minutes. I am like "I contributed, now do your job!". Posting an empty comment every 2 months to keep it open feels silly and the opposite of efficiency.
Even though I know the developers are volunteers too, I have a very negative reaction to such messages.

@RitikaPahwa4444
Copy link
Collaborator

RitikaPahwa4444 commented Dec 7, 2024

"marked as stale due to inactivity for over 3 months"

I don't like this idea either. It simply closes the discussion thread, leaving no room for further fruitful discussion and restarting a completely new thread is the only option left in that case (we lose out on the context to some extent then).

Adding a "stale" label might send the contributor a negative signal, when the only problem might be that reviewers are all busy.

+1 to this. The Wikimedia community has always been friendly, let's not give a message to any contributor that their efforts went unnoticed :)

@misaochan
Copy link
Member

If we were to do this at all, I might support having the label added in situations where the most recent comment was from a reviewer, AND the PR author hasn't made any new commits or comments for the last 3 months (i.e. it was reviewed but the review was not responded to for 3 months). I'm not sure if filtering for this is possible, though, or even worthwhile.

@nicolas-raoul
Copy link
Member

By the way, I just crafted an URL to easily see what PRs are ready to review (not draft, not breaking CI, no changes requested):

https://github.com/commons-app/apps-android-commons/pulls?q=is%3Apr+is%3Aopen+-is%3Adraft+-status%3Afailure+-review%3Achanges_requested

I am not sure yet whether a "changes requested" PR that the contributor subsequently acts on (pushes commits or explains and marks comments as resolved) reappears in that search or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants