Odoo Help


ProgrammingError: can't adapt type 'dict'

on 9/17/13, 9:04 AM 2,176 views

How I can resolve this problem ?

Can you please more specify ? At where or code you have done ?

Pinakin Nayi (pna)
on 9/17/13, 11:05 AM

Tarek Mohamed Ibrahim

--Tarek Mohamed Ibrahim--
| 5 3 7
Gîza, Egypt
--Tarek Mohamed Ibrahim--

I am an old VFP developer on ERP

I have moved to 2p since Nov-2014 and started developing with Python on Odoo.



Tarek Mohamed Ibrahim
On 4/27/15, 3:22 AM

I got the same error when using the method trg_validate with the customized button 'signal_draft_depheadapr' :

wf_service.trg_validate(uid, 'purchase.order', id, 'signal_draft_depheadapr', cr)

After trace I discovered that the 'id' parameter is an object one and not an integer id, I replace the above line with the following line and it worked:

wf_service.trg_validate(uid, 'purchase.order', po_obj.id, 'signal_draft_depheadapr', cr) 

The exact line that caused this problem was the cr.execute method

So check your code, the reason of this was a wrong parameter type you passed.

About This Community

This platform 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.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

0 follower(s)


Asked: 9/17/13, 9:04 AM
Seen: 2176 times
Last updated: 4/27/15, 3:22 AM