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

if isinstance(res2[record['id']], str): res2[record['id']] = eval(res2[record['id']]) #TOCHECK : why got string instend of dict in python2.6 KeyError

By
rihab
on 5/7/16, 4:42 PM 176 views

I am new to python and OpenERP and I apologise if my question is inconvenient. But I am trying to add a control that check if a field is empty, but I am getting this error on OpenERP

if isinstance(res2[record['id']], str): res2[record['id']] = eval(res2[record['id']]) #TOCHECK : why got string instend of dict in python2.6
KeyError

Please could you help me? What the problem could be?  Thanks 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

1 follower(s)

Stats

Asked: 5/7/16, 4:42 PM
Seen: 176 times
Last updated: 5/8/16, 12:56 AM