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

Configurable Path for compiled #30202

Open
JaredCrean2 opened this issue Nov 30, 2018 · 4 comments
Open

Configurable Path for compiled #30202

JaredCrean2 opened this issue Nov 30, 2018 · 4 comments
Labels
compiler:precompilation Precompilation of modules

Comments

@JaredCrean2
Copy link
Contributor

Ref #30174 where it was noted that having source code and compiled code on the same filesystem may be problematic with the new atomic compilecache. Having an environment variable (separate from JULIA_DEPOT_PATH) to configure this would be good.

@JeffBezanson JeffBezanson added the compiler:precompilation Precompilation of modules label Nov 30, 2018
@vtjnash
Copy link
Sponsor Member

vtjnash commented Nov 30, 2018

The JULIA_DEPOT_PATH already does this, so I'm not certain of the need for a duplicate mechanism. The first entry in the list gives the location for newly compiled code to be saved to. The list also gives an ordered search path for finding source files, and typically is approximately ordered from most-volatile first (perhaps temp files) to most-static (perhaps system files).

@JaredCrean2
Copy link
Contributor Author

JaredCrean2 commented Nov 30, 2018

From the package manager docs for Depot Path:

The first entry is the “user depot” and should be writable by and owned by the current user. The user depot is where: registries are cloned, new package versions are installed, named environments are created and updated, package repos are cloned, newly compiled package image files are saved, log files are written, development packages are checked out by default, and global configuration data is saved.

It looks like any newly installed package will be installed to the first entry of the path, so making the first entry in JULIA_DEPOT_PATH point to a location on a non-persistent file system will results in source code getting install there too, which is not good.

@KristofferC
Copy link
Sponsor Member

Aren't the packages already installed? If not, could you just not push the depot path after they are installed but before they are loaded?

@JaredCrean2
Copy link
Contributor Author

Having a static configuration is better than a dynamic one because it reduces the possibility of errors. For example, installing a few packages, running a simulation, installing one additional package and then having the one additional package magically disappear because it got installed to the non-persistent file system. It also jives better with the module system frequently used on clusters, where the person who creates the julia module can configure the depot and compiled paths for each user. This avoids the possibility of one user forgetting to set the compiled path and causing filesystem problems for everyone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compiler:precompilation Precompilation of modules
Projects
None yet
Development

No branches or pull requests

4 participants