nbopen: nbopen does not work, it simply flashes Python interpreter command prompt

I ran the nbopen installation and activation commands on Windows 10 . I am using a new installation of Anaconda Python distribution (new as of last week 1/10/2020).

python -m pip install nbopen python -m nbopen.install_win

Then I double-click on a Jupyter notebook file, the interpreter Command Prompt flashes, but the Jupyter NB file never opens up. I saw this behavior about 11 months ago the first time I tried it. What is the fix for this?

About this issue

  • Original URL
  • State: open
  • Created 4 years ago
  • Comments: 17 (3 by maintainers)

Most upvoted comments

I just managed to fix mine by following some steps when you get the DLL load failed error, many thanks for the screenshot! Make sure you have the following in your PATH variable:

c:\users\USERNAME\anaconda3 c:\users\USERNAME\anaconda3\scripts c:\users\USERNAME\anaconda3\library\bin c:\users\USERNAME\anaconda3\library\usr\bin where c:\users\USERNAME\anaconda3 is the anaconda install location.

I was missing the 2 bin directory paths above.

A slightly neater alternative to what @matt-sharp suggests is to get conda to run* nbopen for you, so that you don’t need to modify the PATH at all

The easiest way is to go to the registry with Regedit and change the key at Computer\HKEY_CURRENT_USER\SOFTWARE\Classes\Jupyter.nbopen\shell\open\command to

C:\Users\{USERNAME}\anaconda3\python.exe -m conda run -n base pythonw -m nbopen "%1"

… ofc swap C:\Users\{USERNAME}\anaconda3\python.exe … for whichever python executable is currently referenced (i.e. change USERNAME)


Note:

  1. run -n base will run nbopen in the environment named base, but you may have installed it in a different environment so you can change that here.
  2. If, like me, your anaconda base installation is your default python version then you can replace the C:\Users\{USERNAME}\anaconda3\python.exe with py which should do the same thing using the windows python launcher (installed by default).
  3. A terminal window may flash but it’s fine to close it if it stays open, I asked about a fix over on SO here.

*NB: conda run is a beta feature at time of writing so this approach may break if the api changes, but it seems to work fine for now

Hi all, I had the same issue and I’ve fixed it by :

  1. Uninstalling Anaconda
  2. Reinstalling Anaconda clicking “Add Anaconda to the PATH” when proposed
  3. Reinstalling nbopen : in the Anaconda Powershell Prompt :
  • pip install nbopen
  • python -m nbopen.install_win

I can now open .ipynb files by doucle-clicking on it That feel so great ! 😃

I confess I was afraid of changing these deep configurations, since I am not an expert in this subject. But it works now. I just saw a python window and a node.js one, but that’s not relevant for me at all. It is working now. Thank you so much for the instructions @Greedquest, you helped me a lot!!!

@nick-025 I understand. The registry can be used to configure some quite important things in the Operating System (and break them). However in this case it’s being used more like a text file/dictionary just to store the command string on the computer somewhere so it can be accessed later.

PS. If the method worked then maybe thumbs up the original post so other people can see it works and use it themselves?

Same problem here, with the latest Anaconda distribution on W10.