Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > xmlrpclib/timeoutsocket not happy together in 2.3

Reply
Thread Tools

xmlrpclib/timeoutsocket not happy together in 2.3

 
 
Larry
Guest
Posts: n/a
 
      09-16-2003
I've had a production system running for a long time that uses
xmlrpclib with timeoutsocket, and with my recent upgrade to 2.3 it's
no longer able to use xmlrpclib with the xmlrpc servers I communicate
with. I can call remote procedures still, but as soon as I import
timeoutsocket and the old socket switcharoo is done it's over.

To add to the fun I can use xmlrpc w/timeoutsocket if calling
functions at the ubiquitous betty.userland.com example, but not the
servers I've been talking to for the last two years. Example:

Python 2.3 (#46, Jul 29 2003, 18:54:32) [MSC v.1200 32 bit (Intel)] on
win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import xmlrpclib
>>> s=xmlrpclib.Server('http://myrpcserver/server')
>>> s.version()

22
>>> s.localTime()

'9/16/2003 12:16:38 PM'
>>> import timeoutsocket
>>> s.version()

Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "C:\Python23\lib\xmlrpclib.py", line 1029, in __call__
return self.__send(self.__name, args)
File "C:\Python23\lib\xmlrpclib.py", line 1316, in __request
verbose=self.__verbose
File "C:\Python23\lib\xmlrpclib.py", line 1080, in request
return self._parse_response(h.getfile(), sock)
File "C:\Python23\lib\xmlrpclib.py", line 1217, in _parse_response
p.close()
File "C:\Python23\lib\xmlrpclib.py", line 531, in close
self._parser.Parse("", 1) # end of data
xml.parsers.expat.ExpatError: no element found: line 1, column 0
>>> s.localTime()

Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "C:\Python23\lib\xmlrpclib.py", line 1029, in __call__
return self.__send(self.__name, args)
File "C:\Python23\lib\xmlrpclib.py", line 1316, in __request
verbose=self.__verbose
File "C:\Python23\lib\xmlrpclib.py", line 1080, in request
return self._parse_response(h.getfile(), sock)
File "C:\Python23\lib\xmlrpclib.py", line 1217, in _parse_response
p.close()
File "C:\Python23\lib\xmlrpclib.py", line 531, in close
self._parser.Parse("", 1) # end of data
xml.parsers.expat.ExpatError: no element found: line 1, column 0
>>> s=xmlrpclib.Server('http://betty.userland.com')
>>> s.examples.getStateName(41)

'South Dakota'

Obviously the bad element here is the remote servers I communicate
with since userland works, but this just started with 2.3 and I'm
curious if anyone else has had a similar problem before I start
digging into this.

Thanks.

- Larry
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nikon RAW codec, Vista x64 now happy together Barb Bowman Windows 64bit 3 08-05-2008 09:09 AM
OT: Happy Happy Joy Joy! Mike T. MCSE 79 11-19-2006 08:22 PM
HEXUS.opinions :: Have a happy happy gaming holiday Silverstrand Front Page News 0 12-23-2005 04:12 PM
Happy Happy Joy Joy, I recovered my photos Tama Mativa Digital Photography 9 05-24-2004 04:58 PM
happy happy christmas showgun MCSE 26 12-17-2003 07:11 PM



Advertisments