Re: XML RPC Problem....

2008-09-13 Thread Usman Ajmal
Please explain the arguments of send_request. What exactly are the connection, handler and request_body? It will be really helpful if you give an example of how do i call send_request On Thu, Sep 11, 2008 at 7:18 AM, Fredrik Lundh [EMAIL PROTECTED]wrote: Usman Ajmal wrote: And i also fount

Re: XML RPC Problem....

2008-09-13 Thread Fredrik Lundh
Usman Ajmal wrote: Please explain the arguments of send_request. What exactly are the connection, handler and request_body? It will be really helpful if you give an example of how do i call send_request you don't call send_request. you should pass the SecureTransport instance as an

Re: XML RPC Problem....

2008-09-13 Thread Usman Ajmal
Where exactly should i call ServerProxy? Following is the code from my client.py t = SecureTransport() t.set_authorization(ustring, text_ucert) server = xmlrpclib.Server('http://localhost:8000/',transport=t) print server.s() Note: Full code for client is here at

Re: XML RPC Problem....

2008-09-13 Thread Fredrik Lundh
Usman Ajmal wrote: Where exactly should i call ServerProxy? Following is the code from my client.py ServerProxy is the preferred name. Server is an old alias for the same class. t = SecureTransport() t.set_authorization(ustring, text_ucert) server =

Re: XML RPC Problem....

2008-09-13 Thread Usman Ajmal
Problem is that when i start client (while the server is already running), i get an error i.e. Error 500 Internal Server Error On Sat, Sep 13, 2008 at 3:58 PM, Fredrik Lundh [EMAIL PROTECTED]wrote: Usman Ajmal wrote: Where exactly should i call ServerProxy? Following is the code from my

Re: XML RPC Problem....

2008-09-13 Thread Fredrik Lundh
Usman Ajmal wrote: Problem is that when i start client (while the server is already running), i get an error i.e. Error 500 Internal Server Error that's a server error, not a client error. check the server logs (e.g. error.log or similar). /F --

Re: XML RPC Problem....

2008-09-13 Thread Usman Ajmal
Yeah right but i don't see something wrong in my server's code. Following is my server's simple code import SimpleXMLRPCServer #server = ServerProxy(http://betty.userland.com;) class AuthenticationFunctions: def s(self): print something... server =

XML RPC Problem....

2008-09-11 Thread Usman Ajmal
Hi everyone, I am trying to call a function named system.auth at the server side running at localhost:8080 but at the same time i want to set the http header. I found that header can be set by h.putheader(AUTHORIZATION, Basic %s%encodestring(%s:%s % (ustring,text_ucert)))

Re: XML RPC Problem....

2008-09-11 Thread Fredrik Lundh
Usman Ajmal wrote: And i also fount that a typical system.auth call will look like: POST /xmlrpc/clarens_server.py HTTP/1.0 Host: localhost User-Agent: xmlrpclib.py/0.9.9 (by www.pythonware.com http://www.pythonware.com) Content-Type: text/xml Content-Length: 105 AUTHORIZATION: Basic

Re: XML RPC Problem....

2008-09-11 Thread Usman Ajmal
Thanks for ur help. But now i am getting an error xmlrpclib.ProtocolError: ProtocolError for localhost:8000/RPC2: 500 Internal Server Error Here is my code at http://privatepaste.com/d81Kut9AFj Any idea what wrong am i doing? On Thu, Sep 11, 2008 at 7:18 AM, Fredrik Lundh [EMAIL

py2exe + XML-RPC problem

2005-04-14 Thread codecraig
Hi, I tried to take the Monkey Shell script (http://www.sharp-ideas.net/archives/2005/03/monkey_shell_us.html) and make it into an executable. I am making an executable for the server piece (monkey_shelld.py). So my setup.py looks like this # setup.py from distutils.core import setup import

Re: py2exe + XML-RPC problem

2005-04-14 Thread codecraig
update to this. I generated an exe for the client and server. They both run fine, except, when i send a command from the client to server, the cleint spits out this.. xmlrpclib.ProtocolError: ProtocolError for 10.50.20.5:80/RPC2: -1 When I run the .py's by themselves I do not get this. This