def __init__(self, errors):
addrs = sorted(errors.keys())<EOL>body = "<STR_LIT:U+002CU+0020>".join([x[<NUM_LIT:0>] for x in addrs[:-<NUM_LIT:1>]])<EOL>tail = addrs[-<NUM_LIT:1>][<NUM_LIT:0>]<EOL>if body:<EOL><INDENT>msg = "<STR_LIT>"<EOL><DEDENT>else:<EOL><INDENT>msg = "<STR_LIT>"<EOL><DEDENT>super(NoValidConnectionsError, self).__init__(<EOL>None, msg.format(addrs[<NUM_LIT:0>][<NUM_LIT:1>], body, tail)  <EOL>)<EOL>self.errors = errors<EOL>
:param dict errors:
    The errors dict to store, as described by class docstring.