Install a Python 3.6 virtualenv with no site packages on a mac

I needed to upgrade from python 3.4 to 3.6 to be able to use the SIP library required by PyQt5. Using brew virtualenv-3.x failed and pyenv has been deprecated as of python 3.6.

brew install python3
brew link --overwrite python3
deactivate
python3.6 -m venv ./pyenv
source ./pyenv/bin/activate

The defaults of the venv command, pip installed, and no system packages, are exactly what I required. For more information refer to pythons venv command.

See also Migrating PyPI packages to a newer python minor version for a quick method to populate your new environment with the packages from a previous environment.

Advertenties

Een gedachte over “Install a Python 3.6 virtualenv with no site packages on a mac

  1. Pingback: Migrating PyPI packages to a newer python minor version | w01f359

Geef een reactie

Vul je gegevens in of klik op een icoon om in te loggen.

WordPress.com logo

Je reageert onder je WordPress.com account. Log uit /  Bijwerken )

Google+ photo

Je reageert onder je Google+ account. Log uit /  Bijwerken )

Twitter-afbeelding

Je reageert onder je Twitter account. Log uit /  Bijwerken )

Facebook foto

Je reageert onder je Facebook account. Log uit /  Bijwerken )

Verbinden met %s