msm1089 / ipynbname

Simple utility that retrieves current Jupyter notebook filename or path, when run from Jupyter notebook.
MIT License
57 stars 8 forks source link

File Not Found with Xeus kernel #10

Closed JulianSMoore closed 1 year ago

JulianSMoore commented 3 years ago

It works fine with the ipykernel but does not work with Xeus. Completely reproducible for me.

Setup: Python 3.9.5, Jupyter lab 3.1.4. (Win 10, 64-bit, 21H1).

NB this environment config was created before ipykernel supported debugging... I don't need Xeus now, but it's curious that it does not work there!

Error details:

---------------------------------------------------------------------------
FileNotFoundError                         Traceback (most recent call last)
File C:\Users\Julian\anaconda3\envs\TF250_PY395_xeus\lib\site-packages\IPython\core\interactiveshell.py, in run_code:
Line 3441:  exec(code_obj, self.user_global_ns, self.user_ns)

In  [2]:
Line 1:     thisNbName = ipynbname.name()

File C:\Users\Julian\anaconda3\envs\TF250_PY395_xeus\lib\site-packages\ipynbname\__init__.py, in name:
Line 82:    raise FileNotFoundError(FILE_ERROR.format('name'))

FileNotFoundError: Can't identify the notebook name.