[issue1927] raw_input behavior incorrect if readline not enabled

2016-02-05 Thread Martin Panter
Changes by Martin Panter : -- Removed message: http://bugs.python.org/msg259637 ___ Python tracker ___

[issue1927] raw_input behavior incorrect if readline not enabled

2016-02-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think we first should fix 3.6 in correct way, and then see what we can backport to other branches without breaking too much. Or left them as is. For example the output of --version was changed from strerr to stdout (issue18338, issue18920) in default

[issue1927] raw_input behavior incorrect if readline not enabled

2016-02-04 Thread Martin Panter
Martin Panter added the comment: Okay, I see. To clarify, it is Python that sets up Gnu Readline for stdout: . The problem is whichever way we go, we will have to change some part of the behaviour to make it internally

[issue1927] raw_input behavior incorrect if readline not enabled

2016-02-04 Thread Martin Panter
Martin Panter added the comment: Okay, I see. To clarify, it is Python that sets up Gnu Readline for stdout: . The problem is whichever way we go, we will have to change some part of the behaviour to make it internally

[issue1927] raw_input behavior incorrect if readline not enabled

2016-02-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This is rather an objection. If Gnu Readline is configured for stdout, why bash outputs to stderr? We should investigate what exactly do bash and other popular programs with readline, and implement this in Python. Changing the documentation usually is a

[issue1927] raw_input behavior incorrect if readline not enabled

2016-02-04 Thread Martin Panter
Martin Panter added the comment: Serhiy, was your comment an objection to changing away from stderr, or was that just an observation that Python’s design is inconsistent with the rest of the world? -- ___ Python tracker

[issue1927] raw_input behavior incorrect if readline not enabled

2016-01-19 Thread Martin Panter
Martin Panter added the comment: The way I see it, input() is mainly geared for prompting to stdout, and it is just one aspect that strangely uses stderr: * Documentation says stdout * Stdout is checked if it is a terminal and not redirected * Gnu Readline is configured for stdout * The

[issue1927] raw_input behavior incorrect if readline not enabled

2016-01-19 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Unix shell builtin command "read" outputs prompt to stderr. In bash that uses readline and in dash that doesn't use readline. Looks as this is standard behavior. -- nosy: +serhiy.storchaka ___ Python tracker

[issue1927] raw_input behavior incorrect if readline not enabled

2016-01-18 Thread Martin Panter
Martin Panter added the comment: Tal: thanks for testing. This v3 patch changes the interactive interpreter to pass stderr as the sys_stdout parameter. This means we should maintain compatibility with the interpreter prompt going to stderr, but still fix input(). -- versions:

[issue1927] raw_input behavior incorrect if readline not enabled

2015-12-05 Thread Tal Einat
Tal Einat added the comment: The entire test suite passes with the v2 patch on my OSX 10.10. -- ___ Python tracker ___

[issue1927] raw_input behavior incorrect if readline not enabled

2015-12-05 Thread Martin Panter
Martin Panter added the comment: Here is an updated patch for Python 3. I did not remove the “lost sys.stderr” check I mentioned earlier, because the implementation still needs it to call flush(). Changes compared to Michael’s patch: * Added a test for input() using a pseudoterminal and

[issue1927] raw_input behavior incorrect if readline not enabled

2015-12-02 Thread Jason R. Coombs
Changes by Jason R. Coombs : -- versions: +Python 3.5, Python 3.6 ___ Python tracker ___

[issue1927] raw_input behavior incorrect if readline not enabled

2015-12-02 Thread Jason R. Coombs
Changes by Jason R. Coombs : -- nosy: +jason.coombs ___ Python tracker ___ ___

[issue1927] raw_input behavior incorrect if readline not enabled

2015-12-02 Thread Jason R. Coombs
Jason R. Coombs added the comment: +1 to applying this patch. After reviewing this and Issue 12869, I don't see any substantial objections or concerns. The status is "test needed". Is a test really needed? My instinct that simply aligning the implementation with the docs is sufficient.

[issue1927] raw_input behavior incorrect if readline not enabled

2015-12-02 Thread Martin Panter
Martin Panter added the comment: “Test needed” is meant to mean someone needs help producing the problem, but people also seem use it to request a refined test case for the test suite. A test case is always nice, although in this case it is a bit tricky. I can try to knock one up use the

[issue1927] raw_input behavior incorrect if readline not enabled

2015-11-21 Thread Martin Panter
Martin Panter added the comment: The input() implementation is a bit like this: def input(prompt): if stdin and stdout are the original file descriptors, and are terminals: return PyOS_Readline(sys.stdin, sys.stdout, prompt) else: sys.stdout.write(prompt) # Writes to

[issue1927] raw_input behavior incorrect if readline not enabled

2015-07-07 Thread Tal Einat
Tal Einat added the comment: See also issue #24402: input() uses sys.__stdout__ instead of sys.stdout for prompt -- nosy: +taleinat ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1927 ___

[issue1927] raw_input behavior incorrect if readline not enabled

2015-04-20 Thread Bhuvan Arumugam
Bhuvan Arumugam added the comment: For the record, this bug is still open. The proposed patch is not merged in any of branches. The prompt for raw_input in all versions, go to stderr. -- nosy: +bhuvan ___ Python tracker rep...@bugs.python.org

[issue1927] raw_input behavior incorrect if readline not enabled

2014-07-19 Thread Martin Panter
Martin Panter added the comment: I experimented with various redirections to /dev/null, files, and other terminal windows on Linux. Current behaviour I am seeing seems to be something like this: * Prefers prompting to stderr if both stdout and stderr are terminals * Prefers prompting to

[issue1927] raw_input behavior incorrect if readline not enabled

2014-02-03 Thread Mark Lawrence
Changes by Mark Lawrence breamore...@yahoo.co.uk: -- nosy: -BreamoreBoy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1927 ___ ___

[issue1927] raw_input behavior incorrect if readline not enabled

2012-12-23 Thread Daniel Gonzalez
Daniel Gonzalez added the comment: Please see this stackoverflow thread where more information is given about this issue: http://stackoverflow.com/questions/14009714/strange-redirection-effect-with-raw-input -- nosy: +Daniel.Gonzalez ___ Python

[issue1927] raw_input behavior incorrect if readline not enabled

2012-09-23 Thread Michael Domingues
Michael Domingues added the comment: The code that dictates this behavior is in /Parser/myreadline.c and has not been rectified yet in either Python 2.7 (http://hg.python.org/cpython/file/bfdf366a779a/Parser/myreadline.c#l107) or the default branch

[issue1927] raw_input behavior incorrect if readline not enabled

2012-09-23 Thread Michael Domingues
Michael Domingues added the comment: Also uploading a patch for the Python3.2 branch. -- Added file: http://bugs.python.org/file27270/promptOutputFix3.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1927

[issue1927] raw_input behavior incorrect if readline not enabled

2012-02-22 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: From reading the code for raw_input in 2.7 or input in 3.3 (Python/bltinmodule.c:1573), it looks to me that stdout is used, which would mean this issue is fixed. However I browsed the file history and could not find the commit that changed

[issue1927] raw_input behavior incorrect if readline not enabled

2010-09-20 Thread Mark Lawrence
Mark Lawrence breamore...@yahoo.co.uk added the comment: Any *NIX gurus who can sort this one? -- nosy: +BreamoreBoy versions: +Python 2.7 -Python 2.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1927

[issue1927] raw_input behavior incorrect if readline not enabled

2010-05-20 Thread Skip Montanaro
Changes by Skip Montanaro s...@pobox.com: -- nosy: -skip.montanaro ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1927 ___ ___ Python-bugs-list

[issue1927] raw_input behavior incorrect if readline not enabled

2010-01-28 Thread Brian Curtin
Changes by Brian Curtin cur...@acm.org: -- stage: - test needed versions: -Python 2.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1927 ___ ___

[issue1927] raw_input behavior incorrect if readline not enabled

2008-01-24 Thread Skip Montanaro
New submission from Skip Montanaro: From a thread on python-dev... http://mail.python.org/pipermail/python-dev/2008-January/076446.html Mike Kent mike.kent at sage.com Thu Jan 24 16:33:47 CET 2008 Recently I was trying to debug an old python program who's maintenance I inherited. I was using

[issue1927] raw_input behavior incorrect if readline not enabled

2008-01-24 Thread Skip Montanaro
Changes by Skip Montanaro: -- type: - behavior __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1927 __ ___ Python-bugs-list mailing list Unsubscribe:

[issue1927] raw_input behavior incorrect if readline not enabled

2008-01-24 Thread Christian Heimes
Changes by Christian Heimes: -- priority: - normal __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1927 __ ___ Python-bugs-list mailing list Unsubscribe:

[issue1927] raw_input behavior incorrect if readline not enabled

2008-01-24 Thread Gabriel Genellina
Gabriel Genellina added the comment: GNU readline is configured as to prompt the user using standard output, and read input from standard input; if this is the desired behavior it would be easy to provide a simple patch so input/raw_input behave that way even when readline is not used.