Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-15 Thread Joaquim Manuel Freire Luís
, 2021 1:38 PM To: Pedro Venâncio ; gdal-dev@lists.osgeo.org Subject: Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed Le 15/10/2021 à 14:05, Pedro Venâncio a écrit : Hi Even, I've been trying to tackle this issue and these are my last findings: https://gi

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-15 Thread Even Rouault
1 2:39 PM *To:* Pedro Venâncio mailto:pedrongvenan...@gmail.com>> *Cc:* gdal-dev@lists.osgeo.org <mailto:gdal-dev@lists.osgeo.org> *Subject:* Re: [gdal-dev] Running GDAL through Pytho

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-15 Thread Pedro Venâncio
gt;> >>>> >>>> From my experience on this there is really nothing one can do other >>>> than rebuild the dll or replace the dependency that is missing the required >>>> symbol. Nothing we can do from a conda installation. >>>> >>>> >>>

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Alexandre Neto
t; >>> >>> But ofc my analysis may be all wrong. >>> >>> >>> >>> Joaquim >>> >>> >>> >>> *From:* gdal-dev *On Behalf Of *Pedro >>> Venâncio >>> *Sent:* Wednesday, October 13, 2021 4:04 PM >

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Pedro Venâncio
ofc my analysis may be all wrong. >> >> >> >> Joaquim >> >> >> >> *From:* gdal-dev *On Behalf Of *Pedro >> Venâncio >> *Sent:* Wednesday, October 13, 2021 4:04 PM >> *To:* gdal-dev@lists.osgeo.org >> *Subject:* Re: [gdal-d

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Pedro Venâncio
m a conda installation. > > > > But ofc my analysis may be all wrong. > > > > Joaquim > > > > *From:* gdal-dev *On Behalf Of *Pedro > Venâncio > *Sent:* Wednesday, October 13, 2021 4:04 PM > *To:* gdal-dev@lists.osgeo.org > *Subject:* Re: [gdal-dev

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Joaquim Manuel Freire Luís
sts.osgeo.org<mailto:gdal-dev@lists.osgeo.org> Subject: Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed ok, so now you have to inspect the PATH and fix it so that the gdal DLL and its dependencies are in it. But all of this sounds like there's something weird

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Pedro Venâncio
importing _gdal: The specified procedure could not be found.” > > > > Hopefully the screen capture is small enough to get through. > > > > Joaquim > > > > *From:* gdal-dev *On Behalf Of *Even > Rouault > *Sent:* Wednesday, October 13, 2021 2:39 PM > *To:*

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Joaquim Manuel Freire Luís
day, October 13, 2021 2:39 PM To: Pedro Venâncio Cc: gdal-dev@lists.osgeo.org Subject: Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed ok, so now you have to inspect the PATH and fix it so that the gdal DLL and its dependencies are in it. But all of this sound

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Even Rouault
ok, so now you have to inspect the PATH and fix it so that the gdal DLL and its dependencies are in it. But all of this sounds like there's something weird in your environment. Perhaps a mix of GDAL versions? Le 13/10/2021 à 15:36, Pedro Venâncio a écrit : Can you change in __init__.py

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Pedro Venâncio
> Can you change in __init__.py > > try: > os.add_dll_directory(p) > except FileNotFoundError: > continue > > > to > > try: > os.add_dll_directory(p) > except (FileNotFoundErr

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Even Rouault
Can you change in __init__.py     try:     os.add_dll_directory(p)     except FileNotFoundError:     continue to     try:     os.add_dll_directory(p)     except (FileNotFoundError, OSError):    

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Pedro Venâncio
> But I don't understand why you still get the "On Windows, with Python >= > 3.8, DLLs are no longer imported from the PATH." error message. > > It shouldn't be emitted because USE_PATH_FOR_GDAL_PYTHON is set: > https://github.com/OSGeo/gdal/blob/f3a83a2c2628219bdc60001580da677758015a60/gdal/swig/p

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Even Rouault
Le 13/10/2021 à 14:05, Pedro Venâncio a écrit : Hi Even, Thanks for your help! Yes, I've tried "set USE_PATH_FOR_GDAL_PYTHON=YES" but the behaviour does not change. I believe OSGeo4W shell sets the environment variables through .bat files, and does not use system path. Am I right, Jurgen?

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Pedro Venâncio
Hi Even, Thanks for your help! Yes, I've tried "set USE_PATH_FOR_GDAL_PYTHON=YES" but the behaviour does not change. I believe OSGeo4W shell sets the environment variables through .bat files, and does not use system path. Am I right, Jurgen? (sorry for calling in CC) Meanwhile I've found those

Re: [gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Even Rouault
Pedro, Did you try to "set USE_PATH_FOR_GDAL_PYTHON=YES" environment variable a suggested ? Can you check if it set in OSGeo4W shell ?  ("echo %USE_PATH_FOR_GDAL_PYTHON%") Wondering if we shouldn't enable that behavior automatically... although that we would go against upstream Python poli

[gdal-dev] Running GDAL through Python >= 3.8 on Anaconda - DLL load failed

2021-10-13 Thread Pedro Venâncio
Hi all, I'm trying to create an Anaconda environment to run arosics, a software that performs automatic subpixel co-registration of two satellite image datasets. The environment seems correctly created, with GDAL working as expected on the CLI: (arosics) PS C:\Users\PedroVenancio> gdalinfo --ver