smtplib, capturing output from set_debuglevel ??

Josiah Carlson jcarlson at uci.edu
Thu Oct 7 23:46:18 EDT 2004


> If you want to use file primitives to read the value back, just create 
> another one:
> 
> inpt = StringIO.StringIO(firstStringIO.getvalue())
> 
> then you can read the printed output from inpt just like a file.

Or even:

 firstStringIO.seek(0)

 - Josiah




More information about the Python-list mailing list