-
Notifications
You must be signed in to change notification settings - Fork 2
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
bug for Julia 1.6: reachable_registries
not defined
#71
Labels
bug
Something isn't working
Comments
So sth like joinpath(Base.DEPOT_PAT, "registries",
reachable_registries() = [RegistryInstance(joinpath(reg_dir, name)))] julia> DEPOT_PATH
3-element Vector{String}:
"C:\\Users\\tfiers\\.julia"
"C:\\Julia-1.8.1\\local\\share\\julia"
"C:\\Julia-1.8.1\\share\\julia"
julia> @edit Pkg.Registry.reachable_registries() gives srcfunction reachable_registries(; depots::Union{String, Vector{String}}=Base.DEPOT_PATH)
# collect registries
if depots isa String
depots = [depots]
end
registries = RegistryInstance[]
for d in depots
isdir(d) || continue
reg_dir = joinpath(d, "registries")
isdir(reg_dir) || continue
reg_paths = readdir(reg_dir; join=true)
candidate_registries = String[]
# All folders could be registries
append!(candidate_registries, filter(isdir, reg_paths))
if registry_read_from_tarball()
compressed_registries = filter(endswith(".toml"), reg_paths)
# if we are reading compressed registries, ignore compressed registries
# with the same name
compressed_registry_names = Set([splitext(basename(file))[1] for file in compressed_registries])
filter!(x -> !(basename(x) in compressed_registry_names), candidate_registries)
for compressed_registry in compressed_registries
if verify_compressed_registry_toml(compressed_registry)
push!(candidate_registries, compressed_registry)
end
end
end
for candidate in candidate_registries
# candidate can be either a folder or a TOML file
if isfile(joinpath(candidate, "Registry.toml")) || isfile(candidate)
push!(registries, RegistryInstance(candidate))
end
end
end
return registries
end |
eh if you see user_depot = first(DEPOT_PATHS)
RegistryInstance(joinpath(user_depot, "registries", "General.toml")) |
tfiers
added a commit
that referenced
this issue
Jan 11, 2023
(it also didn't have btw, I think you can analyse old pkg versions -- incl "julia 1.6 pkgs" -- while in a newer julia |
6 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
From
The text was updated successfully, but these errors were encountered: