Code: Select all
>>> import socket
>>> s = socket.socket()
>>> s
<socket state=0 timeout=-1 incoming=0 off=0>
>>>
Code: Select all
>>> import socket
>>> s = socket.socket()
>>> s
<socket state=0 timeout=-1 incoming=0 off=0>
>>>
Short of parsing the output (via dupterm to stringio), there isn't a way.