OCA / odoorpc

Python module to pilot your Odoo servers through JSON-RPC.
http://pythonhosted.org/OdooRPC/
GNU Lesser General Public License v3.0
231 stars 123 forks source link

Does not work in odoo13 #54

Closed grey27 closed 4 years ago

grey27 commented 4 years ago

code:

import odoorpc

odoo = odoorpc.ODOO()
odoo.login('test_db')

logs:

Traceback (most recent call last):
  File "D:\PyCharm 2019.3.3\plugins\python\helpers\pydev\pydevd.py", line 1434, in _exec
    pydev_imports.execfile(file, globals, locals)  # execute the script
  File "D:\PyCharm 2019.3.3\plugins\python\helpers\pydev\_pydev_imps\_pydev_execfile.py", line 18, in execfile
    exec(compile(contents+"\n", file, 'exec'), glob, loc)
  File "E:/odoo13/my_addons/test_model/models/odoorpc_t.py", line 5, in <module>
    cli = odoo.login('test_db')
  File "C:\Users\grey27\AppData\Local\Programs\Python\Python37\lib\site-packages\odoorpc\odoo.py", line 355, in login
    {'db': db, 'login': login, 'password': password})
  File "C:\Users\grey27\AppData\Local\Programs\Python\Python37\lib\site-packages\odoorpc\odoo.py", line 285, in json
    data['error'])
odoorpc.error.RPCError: request not bound to a database
altanmur commented 4 years ago

Hello, Grey27

It is Working on me

Screen Shot 2020-07-31 at 12 01 50
pedrobaeza commented 4 years ago

The login command of the issuer seems not correct. Anyway, as said, it's working in a general way, so closing unless there's an specific case presented here to be fixed.

grey27 commented 4 years ago

image One database can and one database can't

pedrobaeza commented 4 years ago

Credentials may be not correct.