-
Notifications
You must be signed in to change notification settings - Fork 387
sort order to get issues/pullrequests should be updated
not created
#1231
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
Comments
Hi @nakamasato ,Thank you for creating this issue. We will investigate it and provide feedback as soon as we have some updates. |
Thanks! |
Hi @nakamasato , Similar kind of discussion has happened in issue #792 where optimization about actions/stale has been discussed. You can refer to following comment thread in the same issue where effects of sorting issues by date updated has been discussed. As you can see in the issue #792 , PR #1033 was raised for performance optimization with help of actions/cache where it and was successfully merged and new version was released . Please refer to the following release notes (v 9.0.0). |
@suyashgaonkar Thank you for the information and I checked the links and one of our executions. I found the following failure.
I think it's same as #1090. I'm testing with the mentioned permission permissions:
actions: write And it's successfully stored.
Also as discussed in the issue #1090, it'd be nice to mention the permission in the readme. |
Though I confirmed the state was successfully saved to the cache on a PR but after running on the default branch, it failed to save and find the state.
Is it possible to specify a cache key? |
@nakamasato perhaps you are running into #1136? There is an open PR #1169 to configure the cache key. |
Hi @nakamasato , Following issue needs a permanent fix in actions/cache, which is working under the hood for actions/stale to handle statefulness in stale. You can also refer to issue #1361 which is created in actions/cache addressing the same issue, where you can keep a track for checking the progress on the same. We feel it won’t be ideal to add this work around in the README as above mentioned issue is already addressed and needs a permanent fix. |
@rcomer I'm not pretty sure if it's because of having many caches but thank you for the information. would be nice if we can set a prefix for cache key. |
@suyashgaonkar Thank you for the information. I understand but at the same time, we can't use the written feature if we just follow the readme right now. so back to my original issue, the issue would be resolved (at least partly) only if we change the order to I reread the comment (#792 (comment)) but I think the following statement is not always true.
The oldest stale pr would get labeled for the first time and it indeed becomes most recently updated one, so it won't be checked until all the older prs are updated in some way (manually or by the actions/stale). If we have too many stale prs, it'd take long to start closing until all the stale prs need to get labeled until the first labeled pr gets closed. However in this case, we can increase the frequency of the action execution as long as the API limit allows and sooner or later the stale action will catch up with all the old stale prs eventually. On the other hand, with the current order with |
Description:
Strictly speaking, it's not a bug but the current behavior makes the stale feature less efficient.
As the default value of
sort
iscreated
, when having many old issues, the retrieved issues are almost same until they're gradually closed especially when settingoperations-per-run
is set. https://docs.github.com/en/rest/issues/issues?apiVersion=2022-11-28#list-repository-issuesAction version:
Specify the action version
Platform:
Runner type:
Repro steps:
A description with steps to reproduce the issue. If your have a public example or repo to share, please provide the link.
Expected behavior:
A description of what you expected to happen.
Sort by
updated
Actual behavior:
A description of what is actually happening.
Sort by
created
https://github.com/nakamasato/stale/blob/ee7ef89499a3de6e4fe1fc1acb994e67c64e0a2a/src/classes/issues-processor.ts#L565-L576
The text was updated successfully, but these errors were encountered: