This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author terry.reedy
Recipients Alex Quinn, BreamoreBoy, brian.curtin, paroga, steve.dower, terry.reedy, tim.golden, zach.ware
Date 2014-07-01.18:32:11
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1404239532.5.0.00907352540845.issue8631@psf.upfronthosting.co.za>
In-reply-to
Content
There are certainly some problems with subprocess on Windows.
Note .../python34> pip pyflakes  installs in a second or two.
...> pyflakes -h  # Windows Command Propmpt WCP
>>> import subprocess as s; s.check_output("pyflakes -h")
console interpreter CI or Idle, all produce help output

WCP> pyflakes c:\programs\python34\lib\turtle.py  # or / instead of \
c:\programs\python34\lib\turtle.py:572: local variable 'rgb' is assigned to but never used
... 50+ lines (all < 1/2 second)
c:\programs\python34\lib\turtle.py:4139: undefined name 'exitonclick'

CI>>> s.check_output("pyflakes c:\programs\python34\lib\turtle.py")
pause, so almost think is hanging, then

c:\programs\python34\lib\lib2to3\tests\data\bom.py:2:17: invalid syntax print "BOM BOOM!"
...100 more error for various files.
pyflakes ignores file name given and checks entire stdlib.

ID>>> s.check_output("pyflakes c:\programs\python34\lib\turtle.py")
hangs indefinitely, no output

CI or ID >>> s.check_output("pyflakes c:/programs/python34/lib/turtle.py")  # / instead of \ which was ok in WCP
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "F:\Python\dev\5\py35\lib\subprocess.py", line 627, in check_output
    raise CalledProcessError(retcode, process.args, output=output)
subprocess.CalledProcessError: Command 'pyflakes c:/programs/python34/lib/turtle
.py' returned non-zero exit status 1

Above is CI 3.5 and Idle 3.4. subprocess and pyflakes work fine on linux. We are trying to add a feature to Idle to do above on file in editor, and are stuck here. The actual provisional code is
+            proc = Popen(args, stdout=PIPE, stderr=PIPE)
+            proc.wait()
+            output, error = map(lambda b:b.decode('utf-8'), proc.communicate())
where args is  list, which shows the same hang forever behavior.
History
Date User Action Args
2014-07-01 18:32:12terry.reedysetrecipients: + terry.reedy, tim.golden, brian.curtin, Alex Quinn, BreamoreBoy, paroga, zach.ware, steve.dower
2014-07-01 18:32:12terry.reedysetmessageid: <1404239532.5.0.00907352540845.issue8631@psf.upfronthosting.co.za>
2014-07-01 18:32:12terry.reedylinkissue8631 messages
2014-07-01 18:32:11terry.reedycreate