[New-bugs-announce] [issue8029] bug in 2to3 dealing with "print FOO, " followed by "sys.stdout.write('')"
Trent Mick
report at bugs.python.org
Sun Feb 28 00:08:43 CET 2010
New submission from Trent Mick <trentm at gmail.com>:
According to http://docs.python.org/reference/simple_stmts.html#the-print-statement the following with result in the print statement NOT printing a trailing space:
import sys
print u"ASD",; sys.stdout.write(u"")
However, 2to3 currently translates this to:
import sys
print("ASD", end=' '); sys.stdout.write("")
It *should* translate to:
import sys
print("ASD", end='')
You can also see the discussion of this on this lib3to2 bug report:
http://bitbucket.org/amentajo/lib3to2/issue/13/print-3-end-isnt-translated-properly
and translation of this between 2to3 and 3to2 here:
http://pythontranslationparty.appspot.com/6004/
----------
components: 2to3 (2.x to 3.0 conversion tool)
messages: 100194
nosy: trentm
severity: normal
status: open
title: bug in 2to3 dealing with "print FOO," followed by "sys.stdout.write('')"
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue8029>
_______________________________________
More information about the New-bugs-announce
mailing list