Where do all the packages come from?

Today I was testing one of my packages with the nightly Julia. I noticed that the list of packages during “update” was several dozen entries long. I don’t know how it got so long: I’m pretty sure that most of these packages are not used directly in mine. How do I find out the chain of dependencies that pulls in all of these packages? Is it possible to simply name a package to get a list of packages which depend on it in the current environment?

2 Likes

Easiest way: the dependencies tab (here’s Plots.jl, for example) on JuliaHub. Of course, that only works for registered packages.

2 Likes

Thank you Matt. That is a way, but not one to look forward to. I’d have to repeat this dozens of times, form intersections, …

I wonder if this functionality could be somehow provided in Pkg? @kristoffer.carlsson?

I guess what you really want it the other direction? Given every package in your Manifest, figure out which package(s) in the Project demanded its installation?

1 Like

It is really a proactive approach to the resolution of possible failure of a package. Let’s say one of the packages does not install. Am I stuck, or can I prune the packages so that the failing package is no longer required, and I can get my own package up and running? The place to start is to figure out the chain of dependencies.

5 Likes

Here’s a related issue for surfacing this data through a JuliaHub API:

https://github.com/JuliaComputing/JuliaHub/issues/4

implement why, showing why a package is in the manifest by KristofferC · Pull Request #1810 · JuliaLang/Pkg.jl · GitHub does something like that.

3 Likes

Fantastic! Thanks.

1 Like