'No extend metadata messages may be send and the connection
needs to close.'

def read_extend_metadata_close(self, conn):

    conn.s.settimeout(10.0)
    while True:
        response = conn.recv()
        if (len(response) == 0):
            break
        assert (not ((response[0] == EXTEND) and (response[1] == 3)))
