I downloaded cymunk to use it on kivent_cymunk and as i tried to import it got following error:
>>> import cymunk
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.7/dist-packages/cymunk/__init__.py", line 1, in <module>
from .cymunk import *
File "/usr/local/lib/python2.7/dist-packages/cymunk/cymunk/__init__.py", line 1, in <module>
from .cymunk import *
ImportError: No module named cymunk
So python finds cymunk in my main.py but it doesn't find cymunk in cymunk.init().
Im am working on ubuntu 14.04 and i installed cymunk like this:
daniel@daniel-K54C:/usr/local/lib/python2.7/dist-packages/cymunk$ sudo python setup.py build
running build
running build_py
running build_ext
skipping 'cymunk/cymunk.c' Cython extension (up-to-date)
daniel@daniel-K54C:/usr/local/lib/python2.7/dist-packages/cymunk$ sudo python setup.py check
running check
warning: check: missing required meta-data: version, url
daniel@daniel-K54C:/usr/local/lib/python2.7/dist-packages/cymunk$ sudo python setup.py install
running install
running build
running build_py
running build_ext
skipping 'cymunk/cymunk.c' Cython extension (up-to-date)
running install_lib
running install_egg_info
Removing /usr/local/lib/python2.7/dist-packages/cymunk-0.0.0.egg-info
Writing /usr/local/lib/python2.7/dist-packages/cymunk-0.0.0.egg-info
As you probably recognized the required meat data is missing. I don't know what that is and if this is causing my problem.
What am i doing wrong? And what can i do to get cymunk to work? I appreciate any help, thank you!!
Based on your build output, you incorrectly extracted the "cymunk" source into /usr/local/lib/python2.7/dist-packages/cymunk .
You should not extract sources into /usr/local/lib/python2.7/dist-packages/..., in this case, the source directory "name" is colliding with the library name that is installed with site-packages.
Fix:
rm -rf /usr/local/lib/python2.7/dist-packages/cymunk
extract and rebuild from your home dir
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With