def remove_instance ( self , item ) : self . instances . remove ( item ) self . remove_item ( item )
how to remove object from list python
Remove instance from model
def remove_instance(self, item):
        """Remove `instance` from model"""
        self.instances.remove(item)
        self.remove_item(item)