Read and respond to this message at: 
https://sourceforge.net/forum/message.php?msg_id=6301204
By: armdeveloper

I'm trying to build a small Python app in Eclipse under Fedora 10.

I have the following code:

import os
import sys
import pexpect

child = pexpect.spawn('/bin/bash')
child.interact()

When I run it in Eclipse, I get:

Traceback (most recent call last):
  File "/home/xxx/workspace/FixPermissions/src/default/main.py", line
56, in <module>
    child.interact()
  File "/usr/lib/python2.5/site-packages/pexpect.py", line 1489, in
interact
    mode = tty.tcgetattr(self.STDIN_FILENO)
termios.error: (22, 'Invalid argument')


Yet if I run it in a bash shell, it works:

$ python
Python 2.5.2 (r252:60911, Sep 30 2008, 15:41:38)
[GCC 4.3.2 20080917 (Red Hat 4.3.2-4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import os
>>> import sys
>>> import pexpect
>>> child = pexpect.spawn('/bin/bash')
>>> child.interact()
[...@localhost ~]$ ls
                <outputs file list here...>
[...@localhost ~]$ exit
>>>
>>>

Why doesn't it run under Eclipse and how do I fix it so it does ?

Thanks

BTW: pydev rocks !

______________________________________________________________________
You are receiving this email because you elected to monitor this forum.
To stop monitoring this forum, login to SourceForge.net and visit: 
https://sourceforge.net/forum/unmonitor.php?forum_id=293649

------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
Pydev-users mailing list
Pydev-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pydev-users

Reply via email to