-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
pass profile-dir instead of profile name to Kernel #4098
Conversation
allows specifying exact path to profile directory, rather than just the name.
store a copy so it can't be manipulated
avoids relative path issues for local profiles when the notebook server starts in a different directory from the kernels.
# Kernel should inherit default config file from frontend | ||
self.kernel_argv.append("--IPKernelApp.parent_appname='%s'" % self.name) | ||
# Kernel should get *absolute* path to profile directory | ||
self.kernel_argv.extend(["--profile-dir", self.profile_dir.location]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would you like to use --ProfileDir.location
explicitely ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The advantage of --profile-dir
the alias over --ProfileDir.location
is that the Class.trait approach must be merged into a single string, whereas --profile-dir
and path
can be separate items in the list. So there's a smaller chance of escape issues.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fine with me then.
+1 should I test on euroscipy profile ? Trust you ? |
Go ahead and test it there - I think I have, but who knows what is unique about my environment. |
👍 Have you done all the testing that you want on this? |
Let me play with it a little more after I get in to the office today, but I think this is fine. |
Did you get time to play with it some more? |
Yes, I tested it in the use case that it is meant to fix:
Which should result in both the notebook server and the kernel finding the profile directory in the notebook server's cwd, which is not the kernel's cwd. |
OK, merging and backporting. |
avoids relative path issues for local profiles when the notebook server starts in a different directory from the kernels. moves the `profile-dir` alias from the parallel apps up to the base IPython app Candidate for backport to 1.1
pass profile-dir instead of profile name to Kernel
pass profile-dir instead of profile name to Kernel
avoids relative path issues for local profiles when the notebook server starts in a different directory from the kernels.
moves the
profile-dir
alias from the parallel apps up to the base IPython appCandidate for backport to 1.1