Skip to content
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

Deal with compressed registry in Julia v1.7 #67

Closed
giordano opened this issue Feb 2, 2022 · 8 comments · Fixed by #68
Closed

Deal with compressed registry in Julia v1.7 #67

giordano opened this issue Feb 2, 2022 · 8 comments · Fixed by #68
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@giordano
Copy link
Member

giordano commented Feb 2, 2022

At the moment we assume the registry is uncompressed on disk. For users in Julia v1.7+ this may not be the case. Pkg.jl in Julia v1.7 comes with an API to deal with the registry in all cases (both compressed and uncompressed) which is probably the best option, that'd mean to drop support for Julia v1.6, but I believe that's reasonable.

@giordano giordano added enhancement New feature or request help wanted Extra attention is needed labels Feb 2, 2022
@ufechner7
Copy link

Is there a workaround? I always get the following error message:

julia> analyze("DataFrames")
ERROR: ArgumentError: collection must be non-empty
Stacktrace:
 [1] first
   @ ./abstractarray.jl:419 [inlined]
 [2] general_registry
   @ ~/.julia/packages/PackageAnalyzer/8nIpt/src/PackageAnalyzer.jl:165 [inlined]
 [3] analyze(name_or_dir_or_url::String)
   @ PackageAnalyzer ~/.julia/packages/PackageAnalyzer/8nIpt/src/PackageAnalyzer.jl:453
 [4] top-level scope
   @ REPL[8]:1

@giordano
Copy link
Member Author

giordano commented Jun 12, 2022

As I said above already, the uncompressed registry (e.g. as a git repository) still works. The alternative is for someone to write the code to use the API in Julia v1.7+ to deal with both formats, but I'm not very motivated to do that since locally I still use the uncompressed registry.

@ufechner7
Copy link

But how can I get an uncompressed registry?
I did:

cd .julia/registries
tar xzf General.tar.gz

But this did not help.

@ufechner7
Copy link

And why not merging JuliaEcosystem/PkgDeps.jl#39 which should fix this issue?

@giordano
Copy link
Member Author

[email protected]

You'd have to opt-out the PkgServer by setting the environment variable JULIA_PKG_SERVER=""

And why not merging JuliaEcosystem/PkgDeps.jl#39 which should fix this issue?

Because the two packages aren't related in any way?

@giordano
Copy link
Member Author

What version of PackageAnalyzer.jl are you using? There may actually be a simple workaround without messing with Julia's registry

@ufechner7
Copy link

(Analyze) pkg> st
      Status `~/repos/Analyze/Project.toml`
  [b19fd437] KiteControllers v0.1.3
  [e713c705] PackageAnalyzer v0.1.0

@ufechner7
Copy link

I tried: JULIA_PKG_SERVER="" before launching Julia.

But I still get the same error: ERROR: ArgumentError: collection must be non-empty

@ericphanson ericphanson linked a pull request Oct 1, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants