def remove ( self, value ):
        trait = getattr(self, 'trait', None)
        if trait is None:
            list.remove(self, value)
            return
        if trait.minlen < len( self ):
            try:
                index   = self.index( value )
                removed = [ self[ index ] ]
            except:
                pass

            list.remove( self, value )

            if self.name_items is not None:
                self._send_trait_items_event( self.name_items,
                    TraitListEvent( index, removed ) )
        elif len(self) == 0:
            # Let whatever system error (ValueError) should be raised be raised.
            list.remove(self, value)
        else:
            self.len_error( len( self ) - 1 )
dataset/ETHPy150Open enthought/traits/traits/trait_handlers.py/TraitListObject.remove/original