instead of specifying `__metaclass__`, I think `BaseQuery` should just inherit from `ABCMeta`, i.e.: `class BaseQuery(abc.ABCMeta):`