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

existing cache not found from pull_request workflow on same branch #1435

Open
alvaromartmart opened this issue Aug 22, 2023 · 3 comments
Open

Comments

@alvaromartmart
Copy link

I have two separate workflows (I simplified the details as much as possible for brevity):

  • ci runs on push: trigger and creates a cache key key-${{github.sha}}
  • pr-checks runs on pull_request: trigger (with synchronize included) and tries to read key key-

My understanding is that, pr-checks should be able to read from the cache, even if in case of synchronize event it would get the cache corresponding to the previous commit sha that was cached.

However the pr-checks always fails with cache not found for key ..., even though if check on Github's UI, valid cache keys for that branch exists.

Is this expected? Does it have something to do with the scope of the cache? (I wouldn't expect it, since the cache was created in the scope of let's say feature-branch-1, and the PR ref is also feature-branch-1)

@nekkon
Copy link

nekkon commented Jul 3, 2024

Having a similar issue. I have two on pull_request workflows. One that runs when the pull request is created and one after it is merged. Even though they are for the same branch, the cache created when the pull request is created is not found in the workflow when the pull request is merged.

@gracezheng9
Copy link

Did you find a solution to this? I am also having the same issue.

@gabrielbryk
Copy link

Running into same issue

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

No branches or pull requests

4 participants