def _error_msg_network(option, expected):
    '''
    Build an appropriate error message from a given option and
    a list of expected values.
    '''
    msg = 'Invalid network setting -- Setting: {0}, Expected: [{1}]'
    return msg.format(option, '|'.join(str(e) for e in expected))
def _error_msg_network ( option , expected ) : msg = 'Invalid network setting -- Setting: {0}, Expected: [{1}]' return msg . format ( option , '|' . join ( str ( e ) for e in expected ) )
Build an appropriate error message from a given option and
    a list of expected values.