This is confusing, and a question I've harvested from a duplicate, so let me start with my setup.
- OS: Windows 7 x64
- GIS Client 1: ArcGIS Desktop 10.5
- GIS Client 2: ArcGIS Pro 1.4
- GIS Client 3: Boundless Desktop 1.0 (QGIS 2.14)
Many of the scripts I write, I try to keep open-source for those without a fancy ArcGIS license. However, I can't set PyQGIS as my default system interpreter in my environment variables because it will break many of the tools in ArcMap. So I have taken the approach of making ArcGIS's Python instance the system Python, and installing open-source libraries there (and using .pth files to pull in qgis.core functionality if I need it). I am using Gohlke's precompiled GDAL wheel (32-bit) in this case. I am operating under the assumption that this breaks the fewest amount of things.
I have multiple installs of GDAL, and the system seems to keep defaulting to one of them, ignoring any environment variables I set.
C:\Program Files\GDAL contains version 2.1.0 (64-bit).
C:\Python27\ArcGIS10.5\Lib\site-packages\osgeo contains version 2.1.3 (32-bit).
C:\Program Files\GDAL appears nowhere in my user environment variables.
Instead, I have the variables:
GDAL_DATA pointing to
and a variable called
GDAL_DRIVER_PATH pointing to
C:\Python27\ArcGIS10.5\Lib\site-packages\osgeo is in my
Yet, when I open a command prompt and type
ogrinfo --version it does not give me 2.1.3 (the version in
PATH) but rather 2.1.0 (the 64-bit version in
\Program Files\GDAL, which is nowhere in
Answers that do not answer my question