pushyrpc / pushy

Easy-as RPC. Zero-server RPC for Python and Java.
http://github.com/pushyrpc/pushy
45 stars 18 forks source link

can't get pushy connection tunneling to work #51

Open bradharmon opened 10 years ago

bradharmon commented 10 years ago

I'm not sure if I'm doing this correctly or not, but the following does not work for me

import pushy
con = pushy.connect("ssh:remote_host", username='foo', password='bar')
remote_pushy = con.modules.pushy
remote_pushy.connect("ssh:another_host", username='foo', password='bar')
Traceback (most recent call last):
  File "<string>", line 383, in __init__
  File "<string>", line 236, in __init__
  File "<string>", line 478, in eval
  File "<string>", line 54, in eval
  File "<string>", line 315, in send_request
  File "<string>", line 420, in __waitForResponse
  File "<string>", line 601, in __recv
  File "<string>", line 104, in receive_message
  File "<string>", line 96, in unpack
  File "<string>", line 60, in read
IOError: End of file

[remote] Traceback (most recent call last):
[remote]   File "<string>", line 1, in ?
[remote]   File "<string>", line 28, in ?
[remote]   File "<string>", line 208, in pushy_server
[remote] ImportError: No module named pushy.server

Traceback (most recent call last):
  File "stuff.py", line 4, in <module>
    remote_pushy.connect("ssh:another_host", username='foo', password='bar')
  File "/home/bharmon/venvs/bdd/lib/python2.7/site-packages/pushy/protocol/proxy.py", line 255, in <lambda>
    (conn.operator(type_, self, args, kwargs))
  File "/home/bharmon/venvs/bdd/lib/python2.7/site-packages/pushy/protocol/connection.py", line 66, in operator
    return self.send_request(type_, (object, args, kwargs))
  File "/home/bharmon/venvs/bdd/lib/python2.7/site-packages/pushy/protocol/baseconnection.py", line 323, in send_request
    return self.__handle(m)
  File "/home/bharmon/venvs/bdd/lib/python2.7/site-packages/pushy/protocol/baseconnection.py", line 639, in __handle
    raise e
pushy.protocol.proxy.ExceptionProxy: End of file
axw commented 10 years ago

I think the problem here is that on the remote side, the PushyPackageLoader doesn't know how to obtain the source. It needs to know about the InMemoryImporter class.