use with_metaclass instead of add_metaclass