Closed IanButterworth closed 9 months ago
Can we add a test for this? E.g. do StatStruct
in Julia (like in your example above) and check the mtime?
Added mtime test which fails on master https://github.com/julia-actions/setup-julia/pull/200
Can we remove the tests from here, and keep the tests in #200, and merge #200 separately?
Reason: I am hoping that this PR will be a short-term solution; I'm hoping that the long-term solution will be for me to get a patch into upstream tc.cacheDir
to add the ability to preserve mtimes. If we are able to get that feature accepted into upstream, then we can revert this PR. But if/when we revert this PR, I wouldn't want to revert the tests. If we keep the tests separate in #200, then later we can revert this PR without reverting #200.
I'm hoping that the long-term solution will be for me to get a patch into upstream
tc.cacheDir
to add the ability to preserve mtimes.
If we're changing tool-cache
you may want to introduce a tc.cache
function which provides a callback so we just do the install inside the callback. I foresee that this new function could be used by tc.cacheFile
and tc.cacheDir
.
Ok, #200 is updated. Probably best to merge that as failing first then rebase this
This is great!
Is this the last change needed to make /compiled
reusable in GitHub Actions CI when using Julia 1.10?
Yeah, should be.
I made a test release for 1.9.5 using bin/build-test-release.sh
and tested it here https://github.com/IanButterworth/PowerMonitor.jl/pull/2
with
uses: julia-actions/setup-julia@test/ib/1_9_5/releases/v1.9.5
And all platforms avoid re-precompilation once cached
Can we remove the tests from here, and keep the tests in #200, and merge #200 separately?
Reason: I am hoping that this PR will be a short-term solution; I'm hoping that the long-term solution will be for me to get a patch into upstream
tc.cacheDir
to add the ability to preserve mtimes. If we are able to get that feature accepted into upstream, then we can revert this PR. But if/when we revert this PR, I wouldn't want to revert the tests. If we keep the tests separate in #200, then later we can revert this PR without reverting #200.
Upstream tc.cacheDir
PR to preserve mtimes: https://github.com/actions/toolkit/pull/1617
A bit of a hack to get julia installed with original mtimes to help https://github.com/JuliaLang/julia/issues/50667
The comments explain the reasoning.
Also should be a bit faster as it avoids the
cp
action.You can see here that 1.10.0 has the release mtimes
The added mtime test fails on master to illustrate the issue. https://github.com/julia-actions/setup-julia/pull/200
Closes https://github.com/julia-actions/setup-julia/pull/100 Closes https://github.com/julia-actions/setup-julia/pull/165