[issue11820] idle3 shell os.system swallows shell command output

2019-09-19 Thread Terry J. Reedy
Change by Terry J. Reedy : -- versions: +Python 3.9 -Python 2.7, Python 3.4, Python 3.5 ___ Python tracker ___ ___ Python-bugs-list

[issue11820] idle3 shell os.system swallows shell command output

2017-07-07 Thread Terry J. Reedy
Terry J. Reedy added the comment: Closed #13220 as duplicate of this. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue11820] idle3 shell os.system swallows shell command output

2014-11-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: Currently, when Idle is started from a command line or console interpreter, "import os; os.system('dir')" produces the listing in the console window, as expected. Reading the patch, it *augments* one-channel socket communication, which properly* combines and

[issue11820] idle3 shell os.system swallows shell command output

2014-11-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What do you think about this patch Terry? -- ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue11820] idle3 shell os.system swallows shell command output

2014-10-19 Thread Ned Deily
Ned Deily added the comment: A quick smoke test of the patch (solely on OS X) looks like it works pretty well. Not surprisingly, it doesn't fix anything when using the deprecated -n ("no subprocess") option but that's not a problem. One more serious issue is that, depending on the length of

[issue11820] idle3 shell os.system swallows shell command output

2014-10-19 Thread Akira Li
Akira Li added the comment: It looks like the issue can be reduced to whether or not to show this output: >>> import os >>> os.write(1, b'should we see this in idle?\n') should we see this in idle? 28 assuming sys.__stdout__.fileno() == fileno(stdout) == 1. If "should we see this in id

[issue11820] idle3 shell os.system swallows shell command output

2014-10-19 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you Roger for your suggestion. Here is a patch which handless subprocess output (it is more complicated than Guido's demo because we need Unicode strings, not bytes). -- keywords: +patch nosy: +serhiy.storchaka stage: needs patch -> patch revie

[issue11820] idle3 shell os.system swallows shell command output

2014-10-18 Thread Terry J. Reedy
Terry J. Reedy added the comment: #22664 (closed as duplicate of this) has ppperry's multiprocessing test example. -- ___ Python tracker ___ _

[issue11820] idle3 shell os.system swallows shell command output

2014-10-18 Thread ppperry
ppperry added the comment: The same lack of output occurs from processes started via the multiprocessing module. -- nosy: +ppperry versions: +Python 2.7 ___ Python tracker ___ _

[issue11820] idle3 shell os.system swallows shell command output

2014-10-02 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- versions: +Python 3.4, Python 3.5 -Python 3.2, Python 3.3 ___ Python tracker ___ ___ Python-bugs-list m

[issue11820] idle3 shell os.system swallows shell command output

2012-05-27 Thread Roger Serwy
Roger Serwy added the comment: It might be possible to fix this problem by creating pipes to redirect stdout and stderr to the text widget in PyShell. The ShellWindow.py demo in Demo/tkinter/guido may be helpful. -- ___ Python tracker

[issue11820] idle3 shell os.system swallows shell command output

2012-05-27 Thread Ned Deily
Ned Deily added the comment: I didn't mean to imply anything about subprocess.check_output(). It works as expected, that is by explicitly intercepting anything written to the stdout of the forked subprocess and returning it as the call result. What doesn't work is if you try a default subpr

[issue11820] idle3 shell os.system swallows shell command output

2012-05-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: I thought I was un-confusing sys.std* Python objects (such as idlelib.rpc.RPCProxy) from std* integer file descriptors, whereas you seem to say they are the same: "copies of the file descriptors (in particular, sys.std*)". The rest of your message seems to im

[issue11820] idle3 shell os.system swallows shell command output

2012-05-27 Thread Ned Deily
Ned Deily added the comment: I disagree. I think you are confusing Python's sys.std* objects with the std* file descriptors of a process. The important points here are that IDLE is effectively substituting its rpcproxy for the std* file descriptors of the IDLE shell process that it creates *

[issue11820] idle3 shell os.system swallows shell command output

2012-05-27 Thread Terry J. Reedy
Terry J. Reedy added the comment: After thinking some more and re-reading the os.system doc, I am closing this. I think things are working exactly as documented, and in a way that will not be changed. The os.system doc initially says 1. "Execute the command (a string) in a subshell." It does

[issue11820] idle3 shell os.system swallows shell command output

2011-04-16 Thread kent
kent added the comment: The getoutput and getstatusoutput provide the expect output which can be captured >>> x=subprocess.getoutput('ls') >>> print(x) hs_err_pid28274.log LP4E-examples mydir.pth mydir.pth~ PP4E-Examples-1.2 ProgMan Python_dir Would it be a good thing to have the interpreter

[issue11820] idle3 shell os.system swallows shell command output

2011-04-16 Thread kent
kent added the comment: I had kind of figured it might be something like this. I ran the following code in the xterm interpreter: >>> x=subprocess.call('ls') bin Documents eclipse local Pictures tmp workspace Desktop Downloads hamlib Music Templates Videos >>> print(x) 0 It

[issue11820] idle3 shell os.system swallows shell command output

2011-04-15 Thread Ned Deily
Ned Deily added the comment: I agree that it is kind of odd behavior and, after a quick look back through open issues, I was a bit surprised to not find an open issue about it (although I may have overlooked one). "Thus it does not seem to be an os.system issue, but a failure of Idle to capt

[issue11820] idle3 shell os.system swallows shell command output

2011-04-15 Thread kent
kent added the comment: I tried using subprocess.Popen and subprocess.call, both of which did the same behavior. Under the interpreter I get the desired string output: >>> subprocess.call('ls') bin Documents eclipse local Pictures tmp workspace Desktop Downloads hamlib Music

[issue11820] idle3 shell os.system swallows shell command output

2011-04-15 Thread Terry J. Reedy
Terry J. Reedy added the comment: I am not sure if this should be called a bug or feature request, but that does not matter so much with IDLE. Os.system is documented as executing in a subshell and returning the exit code, which is does. The doc also says "If command generates any output, it

[issue11820] idle3 shell os.system swallows shell command output

2011-04-10 Thread kent
kent added the comment: When starting idle from a terminal the output from the command is sent to the terminal. When starting idle from the desktop, the output disappears except for the exit status. Same behavior with 2.65 -- ___ Python tracker

[issue11820] idle3 shell os.system swallows shell command output

2011-04-10 Thread kent
kent added the comment: running it as a file from idle gives the same result. import os print (os.system('pwd')) 0 -- ___ Python tracker ___ ___

[issue11820] idle3 shell os.system swallows shell command output

2011-04-10 Thread kent
New submission from kent : attempting to run an os.system command under the idle 3 shell swallows the out put. Idle 3 is running on a 32 bit kde mandriva linux. >>> import os >>> os.system('ls') 0 >>> os.system('pwd') 0 as you can see it returns a 0 indicating successful completion, but no ou