-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
import gdal clobbering PATH environment variable on Ubuntu #1231
Comments
Workaround:
|
@Thingus I can't find anything that sets PATH in the codebase, either via This is under master (via the Trusty/Linux vagrant dev environment):
This is under 2.3.x on another Ubuntu host:
That would suggest it's something anaconda-related? |
Neither the GDAL library nor the Python bindings of upstream GDAL touch the PATH. Must be something anaconda-related indeed. Should be reported to their bug tracker. |
Are there different versions of GDAL out there? The GDAL 2.3.2 Python bindings (using Python 3.6 under Anaconda3) has an "osgeo/__init__.py" that starts as follows and does indeed modify PATH:
Notice that it simply appends "\Library\bin;" to the PATH entry matching sys.prefix, without checking to see if the host system is Windows. |
This is not the content of the official file provided by GDAL: https://github.com/OSGeo/gdal/blob/master/gdal/swig/python/osgeo/__init__.py |
Thank you, I see that now, and I have reported it to the Anaconda team. Looks like distribute patched versions of libraries. |
Problem description
On import, gdal prepends "[env]\Library\bin;" to PATH, breaking any subprocesses that depend on that path.
Steps to reproduce the problem.
Operating system
Ubuntu 18.04 64 bit
GDAL version and provenance
GDAL 2.3.3 version from from conda ( py36hbb2a789_0)
Python 3.6.8
The text was updated successfully, but these errors were encountered: