-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
include() relative paths are different on worker processes #27429
Labels
parallelism
Parallel or distributed computation
Comments
I am surprised that this did not receive more attention. This is literally the first thing I ran into when trying |
Also, the proposed fix will work when using several processes on the same machine but it will break when using multiple machines. |
JeffBezanson
added a commit
that referenced
this issue
Jul 21, 2020
JeffBezanson
added a commit
that referenced
this issue
Jul 23, 2020
simeonschaub
pushed a commit
to simeonschaub/julia
that referenced
this issue
Aug 11, 2020
Keno
pushed a commit
that referenced
this issue
Jun 5, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The behavior of
@everywhere include
seems inconsistent/broken. (I'm using Julia 0.6.3 on OSX)Suppose you have a repository structure:
with “MyMod.jl” containing:
and “script.jl” containing:
From within
repo/src/
you can runjulia -p 4 script.jl
successfully, but fromrepo/
you cannot run Julia with multiple processes (i.e. calljulia -p 4 src/script.jl
), since the worker processes attempt to loadrepo/MyMod.jl
which doesn’t exist.This seems to be because
include
interprets relative paths differently when run on the main process than it does when run on worker processes. On main "relative" is relative to the script/file, whereas on workers it is relative to the current working directory.(Note the behavior of
include
allows you to run "script.jl" on a single process from anywhere.)As a workaround I've been using:
But this feels like it ought to be the default behavior of
@everywhere include
.The text was updated successfully, but these errors were encountered: