summaryrefslogtreecommitdiff
path: root/doc/source/user
diff options
context:
space:
mode:
authorSebastian Berg <sebastian@sipsolutions.net>2020-05-19 17:24:14 -0500
committerSebastian Berg <sebastian@sipsolutions.net>2020-05-20 17:25:22 -0500
commit1d57e850d5895be4bc928459059c241818f84c2c (patch)
treee713584f897eb09f5eb3122ed7fdd147b61bed00 /doc/source/user
parent84809accddc771d525319c227d78c0152b1f7874 (diff)
downloadnumpy-1d57e850d5895be4bc928459059c241818f84c2c.tar.gz
DOC: Fix troubleshooting code snippet when env vars are empty
The previous snippet worked fine, but not when the environment variables were completly empty.
Diffstat (limited to 'doc/source/user')
-rw-r--r--doc/source/user/troubleshooting-importerror.rst6
1 files changed, 2 insertions, 4 deletions
diff --git a/doc/source/user/troubleshooting-importerror.rst b/doc/source/user/troubleshooting-importerror.rst
index acbcd3ed8..7d4846f77 100644
--- a/doc/source/user/troubleshooting-importerror.rst
+++ b/doc/source/user/troubleshooting-importerror.rst
@@ -133,10 +133,8 @@ your system. If you can open a correct python shell, you can also run the
following in python::
import os
- PYTHONPATH = os.environ['PYTHONPATH'].split(os.pathsep)
- print("The PYTHONPATH is:", PYTHONPATH)
- PATH = os.environ['PATH'].split(os.pathsep)
- print("The PATH is:", PATH)
+ print("PYTHONPATH:", os.environ.get('PYTHONPATH'))
+ print("PATH:", os.environ.get('PATH'))
This may mainly help you if you are not running the python and/or NumPy
version you are expecting to run.