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

Cache in Github Actions doesn't work #402

Closed
BinderDavid opened this issue Apr 17, 2023 · 1 comment · Fixed by #403
Closed

Cache in Github Actions doesn't work #402

BinderDavid opened this issue Apr 17, 2023 · 1 comment · Fixed by #403
Labels
bug Something isn't working

Comments

@BinderDavid
Copy link
Collaborator

The cache in the github actions for both the deploy actions and the actions which are run on every PR doesn't work correctly. As a consequence, hakyll is rebuilt from scratch every time which can take half an hour.

I think I know what the problem is: The key for the cache consists of the cabal file. I.e. we have the following line:

key: cabal-cache-0-${{ hashFiles('message-index/message-index.cabal') }}

This means that the last time the cache was updated was the last time we changed the cabal file.
Since we invoke cabal update directly afterwards, we invalidate the cached content and build from scratch.

Proposed solution: Use a cabal.freeze file.

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.

1 participant