actions / stale

Marks issues and pull requests that have not had recent interaction
MIT License
1.34k stars 353 forks source link

Error delete _state: [403] Resource not accessible by integration #1133

Open autoantwort opened 7 months ago

autoantwort commented 7 months ago

Description: If a job has multiple actions/stale steps the creation of the cache fails.

Action version: 9

Platform:

Runner type:

Repro steps:
https://github.com/microsoft/vcpkg/blob/master/.github/workflows/stale.yml

Expected behavior: No errors.

Actual behavior: Errors. See https://github.com/microsoft/vcpkg/actions/runs/7750221792

HarithaVattikuti commented 7 months ago

Hello @autoantwort Thank you for creating this issue. We will investigate it and get back to you as soon as we have some feedback.

ericLemanissier commented 7 months ago

Hello, the same error happens in here : https://github.com/conan-io/conan-center-index/actions/runs/7810903828/job/21305055330#step:2:1032

sophies927 commented 6 months ago

Hello, I am encountering the same error here: https://github.com/microsoft/onnxruntime/actions/runs/7917906948/job/21615103971#step:2:3615.

Pil0tXia commented 4 months ago

Hi everyone, I'm encountering the same issue at https://github.com/apache/eventmesh/actions/runs/8675497930/job/23788986036 and I hope this log would be helpful to you.

Maybe I would revert back to v8 and see if this problem still exists.

shmishra99 commented 4 months ago

Granting actions:write to the stale workflow will allow it to manage issues cache as intended.

jeremystretch commented 3 months ago

This appears to be the same issue described in #1131.

autoantwort commented 3 months ago

Adding actions: write also fixes parts of the problem. The same cache entry is then still used across different cache steps

ericLemanissier commented 3 months ago

Giving actions: write means the workflow has all these permissions and this is way too much, and not acceptable for a lot of projects. https://github.com/actions/cache does not require these permissions, and still manages to save a cache across builds. Could the stale action be refactored to use the same trick as the cache action ? Or could it use the cache action under the hood ?