#NEWLINE# def require_exactly_one( **kwargs ) : #NEWLINE# #INDENT# non_None = sum ( ( ( non_None is not None ) for v in kwargs . values ( ) ) ) #NEWLINE# if ( non_None != 1 ) : #NEWLINE# #INDENT# raise ValueError ( ( 'Exactly one of %s must be specified' % ', ' . join ( kwargs ) ) )