class Foo(object):

    def foo(self):
        print('FOO!')


class Bar(Foo):

    def foo(self):
        raise AttributeError("'Bar' object has no attribute 'foo'")
b = Bar()
Python inheritance - how to disable a function