-
Notifications
You must be signed in to change notification settings - Fork 101
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
Add python-jl CLI #200
Add python-jl CLI #200
Conversation
Pull Request Test Coverage Report for Build 506
💛 - Coveralls |
In Windows, Launching https://ci.appveyor.com/project/Keno/pyjulia/build/1.0.203/job/kgic6eicchk4chx7#L776 Replacing Can we not support |
There is a bit of limitation in Interestingly, {
"argv": [
"/PATH/TO/bin/python-jl",
"-m",
"ipykernel_launcher",
"-f",
"{connection_file}"
],
"display_name": "Python.jl",
"language": "python"
} Note that all I needed to do was to replace Everything should work almost like normal IPython kernel. The only way to know that you are in Julia process is to do something like:
which should show |
@@ -650,6 +657,10 @@ def __init__(self, init_julia=True, jl_init_path=None, runtime=None, | |||
self.sprint = self.eval('sprint') | |||
self.showerror = self.eval('showerror') | |||
|
|||
if self.eval('VERSION >= v"0.7-"'): | |||
self.eval("@eval Main import Base.MainInclude: eval, include") | |||
# https://github.com/JuliaLang/julia/issues/28825 |
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.
It seems passing None is the way to pass NULL to dlopen. In master: https://github.com/python/cpython/blob/4ae8ece5cd4c5853b625381db13429f25512108d/Modules/_ctypes/callproc.c#L1322-L1336 In 2.7 branch: https://github.com/python/cpython/blob/69e96910153219b0b15a18323b917bd74336d229/Modules/_ctypes/callproc.c#L1431-L1434
This PR adds a CLI
python-jl
which acts likepython
CLI but executed as ajulia
process. This way, PyCall can use normal precompilation cache so that PyJulia can be used with Python installed in Debian/Ubuntu and conda #185.The users just have to use
python-jl script.py
instead ofpython script.py
.(previously: JuliaPy/PyCall.jl#562)