Some packages don’t have a Project.toml file, like this one: GitHub - JuliaString/InternedStrings.jl: Fully transparent string interning functionality, with proper garbage collection
In this case, how can Julia find this package via $JULIA_LOAD_PATH? For example, the project can exist in /data/packages/InternedStrings, and if I set $JULIA_LOAD_PATH="/data/packages:", Julia can’t find this package.
This is for offline compilation so Julia can’t fetch unknown projects from the internet.
Well, from my point of view, a package without a Project.toml file is not a valid Julia package. So don’t use such code. Or create a fork and add a valid Project.toml file.
1 Like
This package (and a couple more) are historical artifacts. They predate Julia 1.0 and the current package manager and were never properly updated to Julia 1.0. They could still work with Julia 1.0 through some temporary compatibility measures to packages built for the previous package manager. Most of that was dismantled at some point, leaving these packages to only work with the Pkg.add mechanism for registered packages, but not with Pkg.develop and presumably JULIA_LOAD_PATH.
The best solution is to make a PR adding the missing Project.toml (UUID can be found in the General registry). Obviously this requires a receptive maintainer. Otherwise you can just patch your own copy.
2 Likes
I’m using Pickle as a dependency and Pickle depends on InternedStrings, so I have my hands tied.
Since I’m using packages dependent on this package, would it be sufficient to do manually create Project.toml for such legacy packages? e.g.
$ cat $JULIA_LOAD_PATH/InternedStrings/Project.toml
name = "InternedStrings"
uuid = "7d512f48-7fb1-5a58-b986-67e6dc259f01"
version = "0.7.0"
authors = ["Julia"]
That’s what I would try at least, but I’ve rarely used JULIA_LOAD_PATH.
1 Like
Once InternedString gets its Project.toml, Pickle would have to be updated to reflect this.
Pickle is compatible with any 0.7.x version of InternedStrings, so assuming the version isn’t bumped past that, no changes are needed to Pickle.