"""A convenience function for connect.
This function will connect to the given host, perform a select
"""A convenience function for connect.
This function will connect to the given host, perform a select
any of these steps fail, an exception is raised. If successful,
the file descriptor for the server connection is returned.
"""
any of these steps fail, an exception is raised. If successful,
the file descriptor for the server connection is returned.
"""
-def cnl(host = None, port = -1, useauthless = True, **kw):
+def cnl(host = None, useauthless = True, revision = latest, **kw):
"""A convenience function for connect and loginasync.
This function will connect to the given server, or the server in
"""A convenience function for connect and loginasync.
This function will connect to the given server, or the server in
err, reason = login(useauthless, **kw)
if err != "success":
raise RuntimeError, (err, reason)
err, reason = login(useauthless, **kw)
if err != "success":
raise RuntimeError, (err, reason)
if resp.getcode() >= 500 and resp.getcode() < 600:
raise ValueError, tuple(resp.extract()[0])
return resp
if resp.getcode() >= 500 and resp.getcode() < 600:
raise ValueError, tuple(resp.extract()[0])
return resp