I've been using nodeenv to install node into a conda env for the last year or so. I use pip for the installation:
(AppServerEnv) clnorris@nottelling:/mnt/c/Users/clnorris/source/repos/nodeenv$ pip install nodeenv
Collecting nodeenv
Using cached nodeenv-1.4.0-py2.py3-none-any.whl (21 kB)
Installing collected packages: nodeenv
Successfully installed nodeenv-1.4.0
Installation of a prebuilt node used to work great, but now it is failing as follows:
(AppServerEnv) clnorris@nottelling:/mnt/c/Users/clnorris/source/repos/nodeenv$ nodeenv --node=8.9.4 -p
* Install prebuilt node (8.9.4) .
Traceback (most recent call last):
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/urllib/request.py", line 1350, in do_open
h.request(req.get_method(), req.selector, req.data, headers,
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/http/client.py", line 1240, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/http/client.py", line 1286, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/http/client.py", line 1235, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/http/client.py", line 1006, in _send_output
self.send(msg)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/http/client.py", line 946, in send
self.connect()
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/http/client.py", line 1409, in connect
self.sock = self._context.wrap_socket(self.sock,
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/ssl.py", line 500, in wrap_socket
return self.sslsocket_class._create(
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/ssl.py", line 1040, in _create
self.do_handshake()
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/ssl.py", line 1309, in do_handshake
self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1108)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/miniconda3/envs/siAppServerEnv/bin/nodeenv", line 8, in <module>
sys.exit(main())
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/site-packages/nodeenv.py", line 1046, in main
create_environment(env_dir, opt)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/site-packages/nodeenv.py", line 935, in create_environment
install_node(env_dir, src_dir, opt)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/site-packages/nodeenv.py", line 700, in install_node
install_node_wrapped(env_dir, src_dir, opt)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/site-packages/nodeenv.py", line 722, in install_node_wrapped
download_node_src(node_url, src_dir, opt)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/site-packages/nodeenv.py", line 553, in download_node_src
dl_contents = io.BytesIO(urlopen(node_url).read())
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/site-packages/nodeenv.py", line 585, in urlopen
return urllib2.urlopen(req)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/urllib/request.py", line 222, in urlopen
return opener.open(url, data, timeout)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/urllib/request.py", line 525, in open
response = self._open(req, data)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/urllib/request.py", line 542, in _open
result = self._call_chain(self.handle_open, protocol, protocol +
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/urllib/request.py", line 502, in _call_chain
result = func(*args)
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/urllib/request.py", line 1393, in https_open
return self.do_open(http.client.HTTPSConnection, req,
File "/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/urllib/request.py", line 1353, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1108)>
As a workaround, I am installing nodeenv from source. Then I can use the --ignore_ssl_certs option to get a successful installation of a prebuilt node.
(AppServerEnv) clnorris@nottelling:/mnt/c/Users/clnorris/source/repos/nodeenv$ pip uninstall nodeenv
Found existing installation: nodeenv 1.4.0
Uninstalling nodeenv-1.4.0:
Would remove:
/opt/miniconda3/envs/siAppServerEnv/bin/nodeenv
/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/site-packages/nodeenv-1.4.0.dist-info/*
/opt/miniconda3/envs/siAppServerEnv/lib/python3.8/site-packages/nodeenv.py
Proceed (y/n)? y
Successfully uninstalled nodeenv-1.4.0
(siAppServerEnv) clnorris@nottelling:/mnt/c/Users/clnorris/source/repos/nodeenv$ pip install .
Processing /mnt/c/Users/clnorris/source/repos/nodeenv
Building wheels for collected packages: nodeenv
Building wheel for nodeenv (setup.py) ... done
Created wheel for nodeenv: filename=nodeenv-1.4.0-py2.py3-none-any.whl size=21312 sha256=6b37d28b576bfcd2492582de0381833c1743c3c97b27fffed52414fd9a61c0c7
Stored in directory: /tmp/pip-ephem-wheel-cache-0jcvakpg/wheels/5f/c0/bd/e3777bc31d626f903854e88a09f1b7158787c1592546310539
Successfully built nodeenv
Installing collected packages: nodeenv
Successfully installed nodeenv-1.4.0
(AppServerEnv) clnorris@nottelling:/mnt/c/Users/clnorris/source/repos/nodeenv$ nodeenv --node=8.9.4 -p --ignore_ssl_certs
* Install prebuilt node (8.9.4) ..... done.
Is anyone else using nodeenv from conda, and are you experiencing the issue? Any suggestions on a fix? Don't really like the unsafe workaround.
(AppServerEnv) clnorris@nottelling:/mnt/c/Users/clnorris/source/repos/nodeenv$ conda list
# packages in environment at /opt/miniconda3/envs/siAppServerEnv:
#
# Name Version Build Channel
_libgcc_mutex 0.1 main
blas 1.0 mkl
ca-certificates 2020.6.24 0
certifi 2020.6.20 py38_0
cycler 0.10.0 py38_0
dbus 1.13.16 hb2f20db_0
expat 2.2.9 he6710b0_2
fontconfig 2.13.0 h9420a91_0
freetype 2.10.2 h5ab3b9f_0
glib 2.65.0 h3eb4bd4_0
gst-plugins-base 1.14.0 hbbd80ab_1
gstreamer 1.14.0 hb31296c_0
icu 58.2 he6710b0_3
intel-openmp 2020.1 217
intelpython 2020.2 0 intel
ipp 2020.2 intel_254 intel
jpeg 9b h024ee3a_2
kiwisolver 1.2.0 py38hfd86e86_0
ld_impl_linux-64 2.33.1 h53a641e_7
libedit 3.1.20191231 h14c3975_1
libffi 3.3 he6710b0_2
libgcc-ng 9.1.0 hdf63c60_0
libgfortran-ng 7.3.0 hdf63c60_0
libpng 1.6.37 hbc83047_0
libstdcxx-ng 9.1.0 hdf63c60_0
libuuid 1.0.3 h1bed415_2
libxcb 1.14 h7b6447c_0
libxml2 2.9.10 he19cac6_1
matplotlib 3.2.2 0
matplotlib-base 3.2.2 py38hef1b27d_0
mkl 2020.1 217
mkl-service 2.3.0 py38he904b0f_0
mkl_fft 1.1.0 py38h23d657b_0
mkl_random 1.1.1 py38h0573a6f_0
ncurses 6.2 he6710b0_1
nodeenv 1.4.0 pypi_0 pypi
numpy 1.18.5 py38ha1c710e_0
numpy-base 1.18.5 py38hde5b4d6_0
openssl 1.1.1g h7b6447c_0
pandas 1.0.5 py38h0573a6f_0
pcre 8.44 he6710b0_0
pip 20.1.1 py38_1
pyparsing 2.4.7 py_0
pyqt 5.9.2 py38h05f1152_4
python 3.8.3 hcff3b4d_2
python-dateutil 2.8.1 py_0
pytz 2020.1 py_0
qt 5.9.7 h5867ecd_1
readline 8.0 h7b6447c_0
scipy 1.5.0 py38h0b6359f_0
seaborn 0.10.1 py_0
setuptools 49.2.0 py38_0
sip 4.19.13 py38he6710b0_0
six 1.15.0 py_0
sqlite 3.32.3 h62c20be_0
tk 8.6.10 hbc83047_0
tornado 6.0.4 py38h7b6447c_1
wheel 0.34.2 py38_0
xz 5.2.5 h7b6447c_0
zlib 1.2.11 h7b6447c_3
Hello,
I've been using nodeenv to install node into a conda env for the last year or so. I use pip for the installation:
Installation of a prebuilt node used to work great, but now it is failing as follows:
As a workaround, I am installing nodeenv from source. Then I can use the --ignore_ssl_certs option to get a successful installation of a prebuilt node.
Is anyone else using nodeenv from conda, and are you experiencing the issue? Any suggestions on a fix? Don't really like the unsafe workaround.
For reference, here are my currently installed conda packages: