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

Not handling a repo with many PRs and many stale PRs in a useful manner #975

Closed
2 of 5 tasks
msorens opened this issue Mar 29, 2023 · 8 comments · Fixed by #1033
Closed
2 of 5 tasks

Not handling a repo with many PRs and many stale PRs in a useful manner #975

msorens opened this issue Mar 29, 2023 · 8 comments · Fixed by #1033
Assignees
Labels
bug Something isn't working

Comments

@msorens
Copy link

msorens commented Mar 29, 2023

Description:
The handling of a repo with many PRs (on the order of a hundred PRs or so) and many stale PRs seems poor. Upon hooking up the stale action, expecting to get a lot of PRs tagged as stale, it tagged a dozen or so PRs as stale. So far, so good. Figured it stopped due to the operations-per-run limit and throttling issues discussed in the docs. But upon running it again—expecting it to tag an additional set of PRs—it did apparently nothing.

From the docs, "If you choose not to increase the limit, you might end up with unprocessed issues or pull requests after a stale action run." But what that statement does not say is that that will be true forever. Meaning, the stale action does not take history into account at all. It always just starts from the newest PR, and runs until it hits the operations-per-run limit. I am not sure if that means it stops when it has reviewed a certain number of PRs or when it has tagged a certain number of PRs as stale, but either way that makes its not very useful for a large repo with a large number of PRs.

The potential workaround, of course, is to increase the operations-per-run, but given the warnings in the docs that does not bode well.

Action version:
v8

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Repro steps:
Set up a repo with a hundred PRs

Expected behavior:
Prior runs should be taken into account so that, if running the stale action multiple times, it will eventually review all PRs.

Actual behavior:
No history is accounted for; new scans always review the same set of PRs until the limit is reached.

@msorens msorens added bug Something isn't working needs triage labels Mar 29, 2023
@dsame
Copy link
Contributor

dsame commented Mar 30, 2023

Hello @msorens, thanks for your input, we are starting to investigate the issue

@dsame
Copy link
Contributor

dsame commented Mar 30, 2023

this issue relates to #792

@dsame dsame self-assigned this Apr 6, 2023
@dsame
Copy link
Contributor

dsame commented Jul 13, 2023

Hello @msorens, the issue expected to be resolved with #1033

Now the next job resumes its processing from the last issue processed in the previous build.

@dsame dsame linked a pull request Jul 13, 2023 that will close this issue
2 tasks
@dsame
Copy link
Contributor

dsame commented Jul 13, 2023

Hello @msorens , can you please try to run the action on the main branch to make sure it solves the problem?

- uses: actions/stale@main

@msorens
Copy link
Author

msorens commented Jul 13, 2023

I would, but I no longer have access to the repositories I was using at the time. 😞

@dsame
Copy link
Contributor

dsame commented Jul 14, 2023

Ok, then i close the issue, because the repated PR is merged, but please feel free to reopen it or create new one in case if the problem still exists

@dsame dsame closed this as completed Jul 14, 2023
@vintagepc
Copy link

vintagepc commented Aug 25, 2023

We are seeing that the resume doesn't seem to be working - it keeps just reprocessing the same 30 issues (our ops-per-run) over and over with an action that runs on Mondays and Thursdays.

https://github.com/prusa3d/Prusa-Firmware/blob/MK3/.github/workflows/stale.yml

Edit: I see now there hasn't been a release since this fix was merged. When can we expect one?

@julesvirallinen
Copy link

+1 for release, we are struggling with this too @dsame

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants