I am creating two virtual environments named as "venv35" and "venv36" for Python 3.5 and 3.6, respectively. The sub-directory "include" is missing in "venv36", thus "Python.h" cannot found at this environment (Python 3.6). Any ideas about it?
$ virtualenv -p python3.5 venv35
$ virtualenv -p python3.6 venv36
$ ls -la venv35 venv36
venv35:
total 28
.
..
bin
include
lib
pip-selfcheck.json
share
venv36:
total 24
.
..
bin
lib
pip-selfcheck.json
share
Just put a file with a . pth extension (any basename works) in your virtualenv's site-packages folder, e.g. lib\python2. 7\site-packages , with the absolute path to the directory containing your package as its only contents.
Virtualenv is only installed on DreamHost servers for Python 2. If you're working with Python 3, you must install virtualenv using pip3. pip3 is not installed on the server by default. You must first install a custom version of Python 3.
If a virtual environment is created with "venv", we get:
$ /usr/bin/python3.6 -m venv py36
$ ls -la py36/
total 32
.
..
bin
include
lib
lib64 -> lib
pip-selfcheck.json
pyvenv.cfg
share
The "include" folder is still empty so the solution seems to be the creation of a symbolic link to the original "include" folder location.
ln -s /usr/include/python3.6/ py36/include/python3.6
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With