Description
I'm seeing unexpected cache misses when pushing commits to a feature branch. I have the cache action set up like this:
- name: Fetch cache
uses: actions/cache@v4
with:
key: md-deps-cache-${{ hashFiles('mix.lock', '.tool-versions') }}
path: |
_build
deps
When I trigger the workflow by pushing a commit to my feature branch, I see that a cache entry is created with the key md-deps-cache-9e2b2c8317020aef62614eb08fbfe828891380c4accb7ce17f872ae7c8716009
When pushing a subsequent commit, the workflow reports a cache miss, but the cache key is the same as the one created in the previous step: Cache not found for input keys: md-deps-cache-9e2b2c8317020aef62614eb08fbfe828891380c4accb7ce17f872ae7c8716009
This should be a cache hit, but it's not. Oddly, in the Actions -> Management -> Caches
, I see "Last Used: 1m ago", which lines up with my second commit push. So it's as if the caches tab thinks the cache has been used, but my workflow reports a cache miss.