pyenv-jupyter-kernel icon indicating copy to clipboard operation
pyenv-jupyter-kernel copied to clipboard

Creating new virtualenv fails

Open flicht opened this issue 4 years ago • 5 comments

After installing this plugin I cannot create a new virtualenv. I get the following error:

>>> pyenv virtualenv test
Looking in links: /var/folders/pg/4g0whhsj4jvgx6mn7q482nt00000gp/T/tmpy0ymny0s
Requirement already satisfied: setuptools in ~/.pyenv/versions/3.8.2/envs/test/lib/python3.8/site-packages (41.2.0)
Requirement already satisfied: pip in ~/.pyenv/versions/3.8.2/envs/test/lib/python3.8/site-packages (19.2.3)
pyenv: jupyter: command not found

The `jupyter' command exists in these Python versions:
  3.8.1/envs/py3
  py3

Note: See 'pyenv help global' for tips on allowing both
      python2 and python3 to be found.

I get the same error when I try to install a new version of python using pyenv

pyenv install 2.7.15

When I uninstall the plugin, I no longer get any errors.

Any ideas why this might be?

flicht avatar Jun 12 '20 16:06 flicht

I also get the same error.

bhanukaManesha avatar Aug 03 '20 07:08 bhanukaManesha

A workaround is to install jupyter in the environment defined in $(pyenv root)/version.

papr avatar Oct 23 '20 11:10 papr

Sorry for the delayed response, for some reason I never got a notification about this.

I personally have jupyter installed globally using pipx, but you could install it using brew, a linux package manager or some other means. I suppose the extension could check if jupyter is already in the path and pip install it if not

aiguofer avatar Oct 12 '22 20:10 aiguofer

Sorry for the delayed response, for some reason I never got a notification about this.

I personally have jupyter installed globally using pipx, but you could install it using brew, a linux package manager or some other means. I suppose the extension could check if jupyter is already in the path and pip install it if not

No that would be awful, because you couldn't create any clean environments more, without jupyter dependencies, so especially if you have a project with conflicting versions of dependencies with jupyter's. I actually was looking for how to switch it off or remove for specific environments.

sebnapi avatar Aug 25 '23 20:08 sebnapi

Is it possible to create a switch in etc/pyenv.d/install/register-jupyter-kernel.bash to decide if it should register a kernel?

sebnapi avatar Aug 25 '23 20:08 sebnapi