kivent
kivent copied to clipboard
Error while install cymunk, No attribute filename
so I was installing new Kivent with Python 3.6 on virtualenv, I followed the instruction for execute the install python setup.py build_ext install
Using distutils
Traceback (most recent call last):
File "setup.py", line 108, in <module>
cymunk_dirname = loader.path if hasattr(loader, 'path') else loader.filename
AttributeError: 'NoneType' object has no attribute 'filename'
Looks like this area has changed in 3.4 and above https://github.com/kivy/kivent/blob/master/modules/cymunk/setup.py#L107
it looks like we need to be using https://docs.python.org/3.6/library/importlib.html#importlib.util.find_spec in 3.4+
you must install cymunk first: from https://github.com/kivy/cymunk with setup.py install and after kivent_cymunk I also install kivent_core
So in the end how to solve this problem?
root@k1:~/Desktop/kivent/modules/cymunk# python3 -V
Python 3.6.7
root@k1:~/Desktop/kivent/modules/cymunk# python3 setup.py build_ext install
Using distutils
Traceback (most recent call last):
File "setup.py", line 108, in <module>
cymunk_dirname = loader.path if hasattr(loader, 'path') else loader.filename
AttributeError: 'NoneType' object has no attribute 'filename'
root@k1:~/Desktop/kivent/modules/cymunk# python3 setup.py build_ext install
Using distutils
Traceback (most recent call last):
File "setup.py", line 107, in <module>
loader = pkgutil.find_spec("cymunk")
AttributeError: module 'pkgutil' has no attribute 'find_spec'
Here I tried to change your setup file:
root@k1:~/Desktop/kivent/modules/cymunk# python3 setup.py build_ext install
Using distutils
Traceback (most recent call last):
File "setup.py", line 107, in <module>
loader = util.find_spec("cymunk")
NameError: name 'util' is not defined
root@k1:~/Desktop/kivent/modules/cymunk# python3 setup.py build_ext install
Using distutils
Traceback (most recent call last):
File "setup.py", line 107, in <module>
loader = importlib.util.find_spec("cymunk")
NameError: name 'importlib' is not defined