Alan Kennedy wrote:

> Sorry, my mistake.

No problem.


> So, a question I would ask is: Is "connect" the right name for that function?
> ...
> Perhaps a better name might be "create_connected_client_socket", or
> something equally descriptive?

Guido proposed "connect_with_timeout". I don't like your proposal,
neither Guido's.

But, I recognize that maybe it's not the best name. What about
"create_connection"?


> Another question I would ask is: "How do I ensure that my newly
> created connected client socket is in blocking mode, *without* making
> any assumptions about the value of socket.getdefaulttimeout()?"

Call like this:

  newsock = socket.connect((..., ...))
  newsock.setblocking(1)

Remember that this function is to replace the same code in N other
places, and in any of other places I saw this usage.

Regards,

-- 
.   Facundo
.
Blog: http://www.taniquetil.com.ar/plog/
PyAr: http://www.python.org/ar/


_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to