I installed the telnet client but still the same error.
Traceback (most recent call last):
File "C:\Users\Rayon\Documents\projects1\super_hia\main.py", line 6, in
<module>
child = winspawn('telnet 192.168.0.55:210')
File
"C:\Python26\lib\site-packages\winpexpect-1.5-py2.6.egg\winpexpect.py", line
346, in __init__
logfile=logfile, cwd=cwd, env=env)
File "C:\Python26\lib\site-packages\winpexpect-1.5-py2.6.egg\pexpect.py",
line 429, in __init__
self._spawn (command, args)
File
"C:\Python26\lib\site-packages\winpexpect-1.5-py2.6.egg\winpexpect.py", line
369, in _spawn
raise ExceptionPexpect, 'Command not found: %s' % self.command
ExceptionPexpect: Command not found: telnet
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Steven
D'Aprano
Sent: 17 November 2011 19:52
To: [email protected]
Subject: Re: [Tutor] python telnet
Rayon wrote:
> I am trying to use winpexpect to connect a telnet session.
> I keep getting this error.
>
>
>
> raise ExceptionPexpect, 'Command not found: %s' % self.command
> ExceptionPexpect: Command not found: telnet
Please copy and paste the entire traceback, not just the last couple of
lines. But judging by just the small bit you show, it looks like "telnet" is
not a command that winpexpect understands, so it raises an error "command
not found".
Perhaps it is a bug in winpexpect. Are you using the latest version?
Do you actually have telnet available on your system? If not, then you can't
expect winpexpect to use something which isn't there.
--
Steven
_______________________________________________
Tutor maillist - [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
_______________________________________________
Tutor maillist - [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor