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

Error while install cymunk, No attribute filename #266

Open
kzulfazriawan opened this issue Jan 11, 2018 · 3 comments
Open

Error while install cymunk, No attribute filename #266

kzulfazriawan opened this issue Jan 11, 2018 · 3 comments

Comments

@kzulfazriawan
Copy link

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'

@Kovak
Copy link
Contributor

Kovak commented Jan 11, 2018

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+

@sergeLabo
Copy link

you must install cymunk first: from https://github.com/kivy/cymunk
with setup.py install
and after kivent_cymunk
I also install kivent_core

@vldanch
Copy link

vldanch commented Oct 15, 2018

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

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