Closed CameronBieganek closed 2 months ago
There are three possible formats that the registry can take. Unfortunately, RegistryCI currently only supports two of them.
Git or Pkg server | Tarball has been extracted | Supported by RegistryCI | JULIA_PKG_SERVER |
JULIA_PKG_UNPACK_REGISTRY |
---|---|---|---|---|
Git | Yes | ENV["JULIA_PKG_SERVER"] = "" |
delete!(ENV, "JULIA_PKG_UNPACK_REGISTRY") |
|
Pkg server | Yes | Yes | delete!(ENV, "JULIA_PKG_SERVER") |
ENV["JULIA_PKG_UNPACK_REGISTRY"] = "true" |
Pkg server | No | No | delete!(ENV, "JULIA_PKG_SERVER") |
delete!(ENV, "JULIA_PKG_UNPACK_REGISTRY") |
To switch your registry format:
import Pkg
Pkg.Registry.rm("General")
Pkg.Registry.add("General")
For example, to switch to the Pkg server extracted registry:
import Pkg
Pkg.Registry.rm("General")
delete!(ENV, "JULIA_PKG_SERVER")
ENV["JULIA_PKG_UNPACK_REGISTRY"] = "true"
Pkg.Registry.add("General")
@CameronBieganek Can you confirm that switching to one of the two supported registry formats fixes the problem for you? If so, then we can change this issue to be a feature request for RegistryCI to support the non-extracted Pkg server registry. But let's first make sure you can get things working.
Are there any performance advantages to sticking with the unextracted tarball? If so, I'd rather stick with that. Although I suppose I could probably just delete the registry and reinstall it if I want to go back to an unextracted tarball. This isn't an important issue for me---I just wanted to check out the string distance for a package name.
On most systems, it is more performant to use the unextracted tarball.
You could just clone the General registry to a temp directory, and pass that directory as the first positional argument to get_all_non_jll_package_names
.
Cool, thanks! I'll try that when I get a chance.
I think the way to do this without needing an unpacked registry would be for someone to help setup https://github.com/GunnarFarneback/RegistryInstances.jl as a stable face in front of Pkg's registry-handling internals on Julia 1.7+, and then use it here.
That package is stuck because I haven't needed it badly enough myself yet. The major missing part is to extract the relevant tests from Pkg and if necessary add some new ones.
Just adding that I hit this today and would be interested in this feature. Thanks for your work on the CI infrastructure!
Here are the contents of my
~/.julia/registries
directory: