ipython / ipython/ipykernel

ipykernel installs invalid kernel.json

Đang mở
#332 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Python
Star
734
Fork
412
Merge trung bình
1 ngày 5 giờ
Pull request đã merge (30 ngày)
8

Mô tả

In #223 the setup.py learned to generate kernel.json, using `write_kernel_spec(overrides={'argv': make_ipkernel_cmd(executable='python')})`

This is completely invalid, as the default is to use sys.executable and hardcoding "python" when installing via:

- `python2 setup.py install` creates a kernel.json that refers to python3 on at least Arch Linux, where python is a symlink to python3
- `python3 setup.py install` creates a kernel.json that refers to python2 on on other operating systems/distributions where python is a symlink to python2

If it is very important to strip out the absolute leading path for sys.executable, then a better way to do that would be, in fact, to strip out the leading path using `os.path.split(sys.executable)[1]`

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.