python-mapnik icon indicating copy to clipboard operation
python-mapnik copied to clipboard

Can't install bindings on Windows, getting "no module named _mapnik" on `import mapnik`

Open mradamcox opened this issue 8 years ago • 4 comments

I am on Windows 10, 64-bit. I have installed mapnik both through npm and through a binary. I have set the environment paths so that I can run mapnik-config.bat from any directory. I think this means I have mapnik installed correctly.

However, I need to install python bindings into 64-bit python, though I do see that most documentation says only 32-bit python is supported at this time. Either way (I've been trying with two separate 2.7.13 virtual environments, one is 32-bit and one is 64-bit). pip install mapnik seems to run successfully, but then I get

ImportError: No module named _mapnik

as reported here. I have tried restarting the OS, but it doesn't help. Any thoughts?

I have also tried making the bindings from python-mapnik, but have been unsuccessful, with a different set of errors...

mradamcox avatar Mar 19 '17 18:03 mradamcox

same problem.... anybody found the solution...?

claudiofinizio avatar Dec 16 '17 10:12 claudiofinizio

not me, I gave up a long time ago because I was able to focus on using non-Windows systems. would certainly be interested to hear of progress though.

mradamcox avatar Feb 22 '18 21:02 mradamcox

This will happen on Windows if there are DLLs that mapnik needs but which are not on the search path. Python will not give any indication of any missing dll (or which one)

So on a console try set PATH=c:\path\to\dlls;%PATH% and then start python

roelandschoukens avatar Aug 01 '19 13:08 roelandschoukens

This will happen on Windows if there are DLLs that mapnik needs but which are not on the search path. Python will not give any indication of any missing dll (or which one)

So on a console try set PATH=c:\path\to\dlls;%PATH% and then start python

I did this but the error persists. Any new idea?

parsley3 avatar Jan 13 '20 17:01 parsley3