xeus-python
xeus-python copied to clipboard
Import ipynb file with xeus-python as jupyterlab kernel
Hi,
I am using xeus-python as the kernel in python3.6 in jupyterlab 3.0.
When I key in the following command, "from ipynb.fs.full.performance_measurement import performance_analysis as pa", I get the below error.
Any idea on how to solve it?
KeyError Traceback (most recent call last) File C:\Users\User\anaconda3\envs\env_testing\lib\site-packages\IPython\core\interactiveshell.py, in run_code: Line 3437: exec(code_obj, self.user_global_ns, self.user_ns)
In [3]: Line 1: from ipynb.fs.full.performance_measurement import performance_analysis as pa
File C:\Users\User\anaconda3\envs\env_testing\lib\site-packages\ipynb\fs_init_.py, in
KeyError: 'package'
Did you try the latest xeus-python? It makes use of IPython and user_ns should be better populated.

These are the package versions that i have installed. Are they the latest?
No, xeus-python 0.12.3 is the latest.
i updated the package to the following version and still face the same issue. I am using Python v3.8. Any idea on how to fix this issue will be greatly appreciated.
-
Package Version

-
Error Message File C:\Users\Name\anaconda3\envs\env_name\lib\site-packages\ipynb\fs_init_.py, in
: Line 27: if ip.user_ns['package'] is None: KeyError: 'package'
I tried with python 3.9 with xeus-python and same error, shown below, appears.
I think xeus-python doesn't work with commands that import other jupyter files via "from ipynb......" command
File C:\Users\Name\anaconda3\envs\env_name\lib\site-packages\ipynb\fs_init_.py, in : Line 27: if ip.user_ns['package'] is None: KeyError: 'package'