libstempo icon indicating copy to clipboard operation
libstempo copied to clipboard

AttributeError: class Extension has no attribute '__mro__'

Open vivekvenkris opened this issue 7 years ago • 3 comments

Hey Michele,

I am trying to install libstempo but get different errors on different platforms. This is the OSX error that I get:

WARNING: The libstempo API has changed substantially (for the better) from versions 1.X to 2.X. If you need the older 1.X API, you can get an older libstempo from https://pypi.python.org/simple/libstempo, or checkout the libstempo1 branch on GitHub - https://github.com/vallis/libstempo/tree/libstempo1 Found tempo2 install in [u'/Users/vkrishnan/T2runtime/'], will use it. Traceback (most recent call last): File "setup.py", line 109, in extra_link_args = linkArgs)) File "/Users/vkrishnan/anaconda/lib/python2.7/site-packages/Cython/Build/Dependencies.py", line 818, in cythonize aliases=aliases) File "/Users/vkrishnan/anaconda/lib/python2.7/site-packages/Cython/Build/Dependencies.py", line 648, in create_extension_list elif isinstance(patterns, basestring) or not isinstance(patterns, collections.Iterable): File "/Users/vkrishnan/anaconda/lib/python2.7/abc.py", line 144, in instancecheck return cls.subclasscheck(subtype) File "/Users/vkrishnan/anaconda/lib/python2.7/abc.py", line 180, in subclasscheck if issubclass(subclass, scls): File "/Users/vkrishnan/anaconda/lib/python2.7/abc.py", line 180, in subclasscheck if issubclass(subclass, scls): File "/Users/vkrishnan/anaconda/lib/python2.7/abc.py", line 161, in subclasscheck ok = cls.subclasshook(subclass) File "/Users/vkrishnan/anaconda/lib/python2.7/site-packages/backports_abc.py", line 66, in subclasshook mro = C.mro AttributeError: class Extension has no attribute 'mro'

I tried pip install and setup.puy but both give the same error. Can you please tell me how to fix it?

My softwares: conda 4.3.25 Python 2.7.11 :: Anaconda custom (x86_64) OSX El Capitan 10.11.6 gcc (GCC) 4.9.2 20141029 g++ (GCC) 4.9.2 20141029 Tempo2 2017.03.1

Thanks, Vivek

vivekvenkris avatar Sep 22 '17 08:09 vivekvenkris

Some googling suggested it is a conflict with cython and setuptools which should have been resolved in the versions I am using but doesn't seem like it.

My versions: setuptools: 36.4.0-py27_1 cython: 0.26-py27_0

vivekvenkris avatar Sep 22 '17 08:09 vivekvenkris

Okay, Changing

backports_abc: 0.4-py27_0 --> 0.5-py27_0 tornado: 4.3-py27_0 --> 4.5.2-py27_0

seems to have done the trick. Sorry for posting the issue too soon! May be this will help others at some point. Please close this issue.

Vivek

vivekvenkris avatar Sep 22 '17 08:09 vivekvenkris

@vivekvenkris, I actually just had this problem as well and moving to Cython 0.25 from Cython 0.26 worked as well. Maybe this was done internally when you downgraded tornado?

Either, way @vallis and I should make take a look at this so it will fork for newer Cython versions.

jellis18 avatar Sep 25 '17 14:09 jellis18