TKinter on Win98 and os.popen
David Fisher
python at rose164.wuh.wustl.edu
Thu Feb 3 08:50:19 EST 2000
>>>>>>>>>>>>>>>>>> Original Message <<<<<<<<<<<<<<<<<<
On 2/3/00, 6:59:02 AM, "Damian Dobroczyñski" <dd at ar-kari.put.poznan.pl>
wrote regarding TKinter on Win98 and os.popen :
> Problem description:
> script:
> import os
> f = os.popen('python -c "print 1"','r')
> on Win98 Python in IDLE shell ends up with exception:
> "Traceback (innermost last):
> File "<pyshell#1>", line 1, in ?
> f = os.popen('python -c "print 1"','r')
> OSError: (0, 'Error')"
> Other 'popens' with other commands also fails. Is it normal behaviour
when
> using Tkinter mod?
This one's in the faq. It's a bug on win9x with the popen command.
On win9x, popen expects a console to redirect i/o to. In idle and
Tkinter, there is no console open. I spent about two days beating my
head against this on, before i realized it wasn't my fault <0.1wink>.
The faq sugests some fixes, but i just started using os.system and
redirecting to/from a file. Which is ugly, but that's win32 for you.
The microsoft site also has some info about this.
David Fisher
More information about the Python-list
mailing list