Skip to content
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

Spyder 5.2.0 (installed with Conda) complains about missing dependency: Rtree >= 0.9.7 : None (NOK) #196

Open
bghadam opened this issue Dec 6, 2021 · 4 comments

Comments

@bghadam
Copy link

bghadam commented Dec 6, 2021

Using conda 4.10.3 on Windows 10 64-bit.

Installed Spyder 5.2.0 from conda-forge, and rtree 0.9.7 was downloaded and deployed automatically. So far so good. However, shortly after starting Spyder the missing dependency error pops up.

Copying the missing spatialindex_c-64.dll to ...miniconda3\envs\<env name>\Lib\site-packages\rtree is a suitable workaround, which suggests that the problem is with how rtree looks for the dll.

It seems to me that the root of the issue is in finder.py. Line 58 is currently :

rt = ctypes.cdll.LoadLibrary(os.path.join(path, lib_name))

but I think it should rather read

rt = ctypes.cdll.LoadLibrary(lib_name)

In my case at least this solves the problem.

@ChenXiaoTemp
Copy link

+1

@denis-bz
Copy link

@bghadam, folks,
Line 58 is for os.name == 'nt', os.name == 'posix' is farther down.
On Macos 10.14 with Miniconda3-py37_4.10.3-MacOSX-x86_64.pkg I had to

cd /opt/miniconda3/lib/python3.7/site-packages/rtree
ln -s /opt/miniconda3/lib/libspatialindex_c.6.1.1.dylib libspatialindex_c.dylib

(Imho, it would be nice if rtree wheels just worked, i.e. had the .dylib inside.
Maybe this used to work, see the comments in rtree setup.py;
the finder approach is almost impossible to test thoroughly, so breaks easily, and does break.)

@bghadam
Copy link
Author

bghadam commented Dec 15, 2021

@denis-bz

@bghadam, folks, Line 58 is for os.name == 'nt', os.name == 'posix' is farther down.

I am using Windows, so this is the bit that applies to my situation.

@simaoafonso-pwt
Copy link

simaoafonso-pwt commented Feb 3, 2023

Got hit with the same issue on Windows. I can confirm my problem is that I'm using 32-bits Python 3.10, and there's no wheels published for this combination. Just like #245, I think in this case setup should just die, not pretend it has the library.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants