@classmethod
def deregister(cls, component):
    """Remove a component from the registry."""
    try:
        cls._components.remove(component)
    except ValueError:
        pass
    for class_ in component.__mro__:
        for interface in class_.__dict__.get('_implements', ()):
            implementers = cls._registry.get(interface)
            try:
                implementers.remove(component)
            except ValueError:
                pass
