def _combine(self, x, y):
    """Combines two constraints, raising an error if they are not compatible."""
    if x is None or y is None:
      return x or y
    if x != y:
      raise ValueError('Incompatible set of constraints provided.')
    return x
def _combine ( self , x , y ) : if x is None or y is None : return x or y if x != y : raise ValueError ( 'Incompatible set of constraints provided.' ) return x
Combines two constraints, raising an error if they are not compatible.