Questions tagged [pyenv]

pyenv lets you switch between multiple versions of Python. It's unobtrusive and follows the UNIX tradition of single-purpose tools that do one thing well.

pyenv lets you switch between multiple versions of Python. It's unobtrusive and follows the UNIX tradition of single-purpose tools that do one thing well.

https://github.com/yyuu/pyenv

857 questions
18
votes
2 answers

pydev debugger: CRITICAL WARNING: This version of python seems to be incorrectly compiled (internal generated filenames are not absolute)

By running: from sklearn.datasets import fetch_california_housing import pandas as pd pd.set_option("precision", 4) # massimo numero di cifre decimali pd.set_option("max_columns", 9) # massimo numero di colonne da…
Alessio Bolpagni
  • 181
  • 1
  • 1
  • 4
18
votes
6 answers

pyenv local/global not working on catalina

I have a new MacBook with fresh installs of everything which I upgraded to macOS Catalina. I installed homebrew and then pyenv, and installed Python 3.8.0 using pyenv. All these things seemed to work properly. However, neither pyenv local nor pyenv…
Stephen
  • 8,508
  • 12
  • 56
  • 96
17
votes
11 answers

Pyenv in Ubuntu 22.04: ERROR: The Python ssl extension was not compiled. Missing the OpenSSL lib?

Moving to Ubuntu 22 with a fresh install (I have Ubuntu 20 in another partition) and the last piece I need to use it for working it to have pyenv running fine. When trying to pyenv install x.xx.x it fails with this error: ERROR: The Python ssl…
Pere Picornell
  • 874
  • 1
  • 8
  • 15
17
votes
2 answers

Interpreters installed via pyenv are not added to $PATH

I can't figure out why pyenv (installed via homebrew) doesn't seem to work. It seems like my $PATH variable isn't updated correctly by pyenv and therefore none of the interpreters installed via pyenv can be found. For example, for python version…
cglacet
  • 8,873
  • 4
  • 45
  • 60
16
votes
4 answers

Unable to locate package python-openssl

I'm trying to install Pyenv, and I'm running on Ubuntu 22.04 LTS. but whenever I run this command sudo apt install -y make build-essential libssl-dev zlib1g-dev \ libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev \…
Jaygee
  • 173
  • 1
  • 8
16
votes
3 answers

How do I get into the environment VS Code is using for pylance?

I'm using pylance to check my Python code. It tells me Import "astor" could not be resolved When I switch to the terminal within VS Code: I'm pretty certain that the issue is that it uses another environment. I'm using pyenv by default and I…
Martin Thoma
  • 124,992
  • 159
  • 614
  • 958
15
votes
3 answers

Install python 3.6.* on Mac M1

I'm trying to run an old app that requires python < 3.7. I'm currently using python 3.9 and need to use multiple versions of python. I've installed pyenv-virtualenv and pyenv and successfully installed python 3.7.13. However, when I try to install…
tuemar29
  • 218
  • 1
  • 2
  • 9
15
votes
2 answers

Conda env vs venv / pyenv / virtualenv / etc

To add a question to the great question and discussion here on pyenv, venv, virtualenv, and virtualenvwrapper, could someone please explain how conda environments fit into this world? When are the preferred use cases for conda environments vs the…
BLimitless
  • 2,060
  • 5
  • 17
  • 32
15
votes
5 answers

zsh: /usr/local/bin/pipenv: bad interpreter: /usr/local/opt/python/bin/python3.7: no such file or directory

I recently switched from bash to zsh (MacOS). I haven't used pipenv since the switch. Now when I run any pipenv command I get the following error: $ pipenv install zsh: /usr/local/bin/pipenv: bad interpreter: /usr/local/opt/python/bin/python3.7: no…
Ryan Payne
  • 5,249
  • 4
  • 28
  • 69
15
votes
2 answers

Homebrew pyenv... can't install Python 3.8.3, despite I already have it installed

I have 3.8.2 installed via pyenv but I want to upgrade to 3.8.3 on my local machine, to match the version we're using in production. $  pyenv install 3.8.3 python-build: definition not found: 3.8.3 The following versions contain `3.8.3' in the…
Anentropic
  • 32,188
  • 12
  • 99
  • 147
13
votes
2 answers

How to install python 3.7.0 using pyenv?

I tried to install with the command "pyenv install 3.7.0" and getting the error as follows Downloading Python-3.7.0.tar.xz... -> https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tar.xz Installing Python-3.7.0... ERROR: The Python ssl…
krtk30
  • 143
  • 1
  • 2
  • 9
13
votes
1 answer

pyenv-virtualenv: `3.6.4' is not installed in pyenv

This just confuses me and I don't know what it means. I have 3.6.4 installed on my computer(MacOS) but it doesn't want to work. I can't think of any solution and don't know what to do.
Mathieu Monnot
  • 133
  • 1
  • 1
  • 7
12
votes
3 answers

How to set python interpreter in neovim for python language server depending on pyenv / virtualenv

I am using the pyright LSP in neovim (0.5). It works, but seems to only pick up on packages available in the standard python installation. It does not autocomplete for packages not in the base python, but in my pyenv environment. In VSCode this is…
Mike
  • 3,775
  • 8
  • 39
  • 79
12
votes
1 answer

pyenv BUILD FAILED while trying (pyenv install -v 3.9.0) on wsl2 ubuntu 20.04

SOLVED: the solution was I needed zlib1g-dev This is the error pyenv produces Traceback (most recent call last): File "", line 520, in _get_decompress_func ModuleNotFoundError: No module named 'zlib' During handling of the above…
INuke
  • 163
  • 1
  • 8
12
votes
2 answers

Linking pyenv python to homebrew in order to avoid homebrew python@3.8 installation

Some packages from brew require python@3.8 as a dependency. For example: $ brew deps vim gdbm gettext libyaml lua openssl@1.1 perl python@3.8 readline ruby sqlite xz However, I want to manage all my python installations with pyenv and I would not…
nela
  • 429
  • 5
  • 13