enable registries by default#62
Conversation
|
@DilumAluthge can you review this please |
Specifically, it's because they use the non-extracted tarball, right? IIRC, the problem with slowness on Windows was due to the time it takes to extract all the files? |
DilumAluthge
left a comment
There was a problem hiding this comment.
Seems fine to me, and I think we can consider this a bug fix. Would be good to get review from someone more familiar than me with this action, though.
To elaborate what I meant: if we can consider this to be a bugfix, then we don't have to make a breaking release of this action. |
rikhuijzer
left a comment
There was a problem hiding this comment.
I‘ve tried this a while ago on Linux runners and it worked fine and saved some time if I remember correctly.
I’m on vacation and have no computer at hand. Would be good if someone could do some benchmarks for this PR on, for example, latest Julia with Linux, Mac, and Windows. Maybe it takes longer on average and we probably wouldn’t quickly notice after merge.
|
+1 on considering this a bug fix. I don't have the capacity to benchmark it either but feel free to merge and tag a release if you deem it ready :) |
|
I've been thinking and I'm not sure we should be caching the registries by default. Since 1.9, julia will only update the registry once per day, unless an explicit If we cache the registry, and now that scratchspaces are cached by default (where Pkg stores the date of the last registry update), Pkg will be able to know when the registry was last updated and avoid doing it unless That means that if a user wants to pick up a new version of a package that was just registered, simply re-running CI won't do that when the packages are They'd be forced instead to either clear out the cache, or add a Also not caching the registry won't hurt the goal of ensuring precompile cache hits. |
The other actions could force a |
|
However I maintain that enabling caching of the git registry on Windows can be a performance hit (but the git registry on Windows is a problem anyway). |
So the registry would be first downloaded from the cache, then an update downloaded. I think that defeats the point. And yeah, I doubt we'd want to do this for git caches. Perhaps we kick this ball further down the road.. The main gains to be had in duration are in getting precompile caches cached. Once that's stable we could see if this is worth it? |
Not really: if you have a git registry, pulling a few commits is much quicker than doing a full clone, and if the compressed registry is already up-to-date nothing is downloaded at all, no? |
|
So In the case where a manifest file is present then we require exact versions of packages so as long as the cached registry includes those required versions the instantiation should succeed. In a scenario where we're re-using a long lived cache and the manifest uses a version outside of the registry we end up falling back to updating the registries. A quick example of I think we're good to enable registry caching by default. |
|
Thanks. Based on that it does seem we can enable this by default. There are cases where jobs do things like this i.e. use non-stdlib packages without a Project/Manifest These cases will be affected by the registry update 24hrs cool-off, but in these cases the package are being used as tooling that is likely to be less critical to be up to date. If that's the case the job can call |
Closes #7
julia-buildpkgandjulia-runtestnow both use the pkgserver registry, so this should workjulia-actions/julia-buildpkg#31 - landed properly on https://github.com/julia-actions/julia-buildpkg/releases/tag/v1.4.2
julia-actions/julia-runtest#74 - landed properly on https://github.com/julia-actions/julia-runtest/releases/tag/v1.9.1