Message138998
Consider the following code:
import code
class Console(code.InteractiveConsole):
def write(self, data):
print("DATA: {0}".format(data))
c = Console()
c.interact()
Then enter "1" at the prompt. The output will be 1 (and not DATA: 1).
If you create an error (such as 1/0), then the error lines will be prefixed by DATA. |
|
Date |
User |
Action |
Args |
2011-06-24 22:45:07 | tebeka | set | recipients:
+ tebeka |
2011-06-24 22:45:07 | tebeka | set | messageid: <1308955507.7.0.876307843842.issue12402@psf.upfronthosting.co.za> |
2011-06-24 22:45:07 | tebeka | link | issue12402 messages |
2011-06-24 22:45:07 | tebeka | create | |
|