kowainik / stan

🕵️ Haskell STatic ANalyser
https://kowainik.github.io/projects/stan
Mozilla Public License 2.0
562 stars 48 forks source link

Fixing Github actions caching #529

Closed 0rphee closed 8 months ago

0rphee commented 8 months ago

Hi! I saw your posts on Discourse and figured that maybe I could help a little with the caching issues.

Checking the last two CI runs, I found that for the windows ghc 9.6.3 case, the cache keys were the same, yet there was no cache hit! Weirdly enough, if the cache keys were the same for the windows runs, they weren't for the 9.6.3 linux and macos runs that I checked! (Here are the windows runs with the same keys, but with no cache hit: https://github.com/kowainik/stan/actions/runs/6537397845/job/17751158155, https://github.com/kowainik/stan/actions/runs/6537515014/job/17751527928)

Anyways. I checked other repos looking for differences in caching strategies and the only difference I found is that the stan CI doesn't run cabal update before freezing and looking for the cache.

I created a fork, made the changes and after a cursory look in the logs, it seems to have worked. Here are two consecutive runs: https://github.com/0rphee/stan/actions/runs/6550149679/job/17788640195 & https://github.com/0rphee/stan/actions/runs/6550668746/job/17790256402

Also, I've changed the haskell setup action, as it has been deprecated in favor of this action.

I was about to create a PR, but I saw in your post that I should create an issue before so here I am!

0rphee commented 8 months ago

Oh, and tell me if I need to reword the commits according to CONTRIBUTING.md

tomjaguarpaw commented 8 months ago

Resolved by https://github.com/kowainik/stan/pull/530