[Twisted-Python] implementing scp using Conch

erick_bodine at comcast.net erick_bodine at comcast.net
Wed Nov 30 16:07:08 EST 2005


Using a suggestion from David Mertz's old article I am implementing scp using Conch.  I can scp from the server to the client, it does give an exception listed below.  Question #1 is why is the exception happening?  Question #2 is how to scp from the client to the server?  Can I use sendRequest() to open a file and then Channel.write('some data') to send the client file contents?


Traceback (most recent call last):
  File "client_mertz.py", line 80, in ?
    reactor.run()
  File "/usr/lib/python2.3/site-packages/twisted/internet/posixbase.py", line 206, in run
    self.mainLoop()
  File "/usr/lib/python2.3/site-packages/twisted/internet/posixbase.py", line 214, in mainLoop
    self.runUntilCurrent()
--- <exception caught here> ---
  File "/usr/lib/python2.3/site-packages/twisted/internet/base.py", line 541, in runUntilCurrent
    call.func(*call.args, **call.kw)
  File "/usr/lib/python2.3/site-packages/twisted/internet/base.py", line 397, in _continueSystemEvent
    for callList in sysEvtTriggers[1], sysEvtTriggers[2]:
exceptions.TypeError: unsubscriptable object


--
--ERick




More information about the Twisted-Python mailing list