Is abc.ABC available in python 2.7.16?

81 Views Asked by At

Based on https://docs.python.org/2/library/abc.html, it seems abstract classes are available starting in version 2.6 (the top says "New in version 2.6.")

However, I cannot from abc import ABC, abstractmethod using python 2.7.16 as it produces the error:ImportError: cannot import name ABC but I can with python3+. So is abc not available for python 2.X?

0

There are 0 best solutions below