[issue23043] doctest ignores from __future__ import print_function

2015-02-12 Thread Demian Brecht
Changes by Demian Brecht demianbre...@gmail.com: -- nosy: -demian.brecht ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23043 ___ ___

[issue23043] doctest ignores from __future__ import print_function

2014-12-23 Thread Julien Palard
Julien Palard added the comment: Works for me in 2.7.8: $ python --version Python 2.7.8 # cat /tmp/test.py #!/usr/bin/env python from __future__ import print_function def toto(): print (42, 43) 42 43 return 42 $ python -m doctest -v /tmp/test.py Trying: print (42,

[issue23043] doctest ignores from __future__ import print_function

2014-12-23 Thread Demian Brecht
Demian Brecht added the comment: @Julien.Palard: There's a subtle difference between your test and the issue as written. Your test lives within a module and therefore executes testmodule (see https://hg.python.org/cpython/file/9f60d024e586/Lib/doctest.py#l1819) whereas the issue reported uses

[issue23043] doctest ignores from __future__ import print_function

2014-12-23 Thread Demian Brecht
Demian Brecht added the comment: it's been resolved in 3.5 Sorry, that statement can be a little misleading, possibly indicating that something may have changed in the doctest globals handling. It was resolved in 3.5 because print is no longer a statement so this ambiguous behaviour resolved

[issue23043] doctest ignores from __future__ import print_function

2014-12-12 Thread Vjacheslav
New submission from Vjacheslav: from __future__ import print_function print (1,2) 1 2 in interactive session, but, with this 3 lines in tmp.txt: python -m doctest tmp.txt fails (prints tuple) -- components: Library (Lib) messages: 232577 nosy: fva priority: normal severity: normal

[issue23043] doctest ignores from __future__ import print_function

2014-12-12 Thread Demian Brecht
Changes by Demian Brecht demianbre...@gmail.com: -- nosy: +demian.brecht ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23043 ___ ___