Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Why XML-RPC requests fail on windows? :'(

By
justeUnPseudo
on 6/19/13, 7:10 AM 726 views

Hi, I've got some problems with XML-RPC request on windows.

      sock_common = xmlrpclib.ServerProxy (path +"/xmlrpc/common")
       uid = sock_common.login(dbname, pseudo, pwd)
       sock = xmlrpclib.ServerProxy(path +'/xmlrpc/object')

       search = sock.execute(dbname, uid, pwd, request, 'search', [])
       read = sock.execute(dbname, uid, pwd, request, 'read', search,fields)

This code work perfectly on Linux but fail on windows with this error:

    read = sock.execute(dbname, uid, pwd, request, 'read', search,fields)
  File "C:\Python27\lib\xmlrpclib.py", line 1224, in __call__
    return self.__send(self.__name, args)
  File "C:\Python27\lib\xmlrpclib.py", line 1578, in __request
    verbose=self.__verbose
  File "C:\Python27\lib\xmlrpclib.py", line 1264, in request
    return self.single_request(host, handler, request_body, verbose)
  File "C:\Python27\lib\xmlrpclib.py", line 1297, in single_request
    return self.parse_response(response)
  File "C:\Python27\lib\xmlrpclib.py", line 1467, in parse_response
    p.feed(data)
  File "C:\Python27\lib\xmlrpclib.py", line 557, in feed
    self._parser.Parse(data, 0)
xml.parsers.expat.ExpatError: not well-formed (invalid token): line 697, column 17

with OpenERP v6, windows 7 32 bits, python 2.7

Have you any idea why it's fail? thank in advance.

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)

Stats

Asked: 6/19/13, 7:10 AM
Seen: 726 times
Last updated: 3/16/15, 8:10 AM