Odoo Help


What are your best practices to debug code or find a variable usage

on 12/4/15, 3:34 AM 712 views


i'm facing a new problem. I'm new to Odoo and as a python developper I'm able to debug app when it crashes but unfortunately it's a little hard to find some variable usage. In example, I'd like to understand what's the aim of the variable group_partner_manager

Do you have clues to help me how to find this informations ? Do you always go to the code to find the usage or is there an hidden documentation ? I need some help from advanced users.

Thanks a lot.


Axel Mendoza

--Axel Mendoza--
| 7 8 8
Camaguey, Cuba
--Axel Mendoza--

DevOps - Full stack - Software Architect - Developer - Technology Integrator

I could help you to develop anything and solve complex problems based on technologies, integrations and tricky stuffs mostly in Python with OpenERP/Odoo, Zato, Django and many others frameworks programming languages and technologies.

I offers consulting services to anyone with an unanswered questions or needs for customizations. Think about it, maybe it's better to have an expert to solve your issues and projects than having a full-time employee trying to understand what to do and how

Reach me at aekroft@gmail.com

Axel Mendoza
On 12/5/15, 3:24 AM

Hi @smorele

Good to know that you are asking for how to know more about Odoo internals.

You need to find what is what you are looking for, in your case it's not a variable, it's a group name declared in an xml file as:

        <record model="res.groups" id="group_partner_manager">
<field name="name">Contact Creation</field>

Defined on addons/base/res/res_security.xml file, so basically you will find the usage in the source code files and have often to search for .xml, .py, and .js files to get the usage of a variable or a behavior, .js files will be the last resource but there are stuffs that you will only found there. There are other files extensions on Odoo but normally will not give you results of variable usage like: .po for translations, .rml old report format, .css styles, and I could figure out any other relevant.

After you get more familiar with Odoo you will learn how to find where you will get more chances to get a good search result. but always try to filter the results to only one file extension because if not you will get to much usage and will be a mess to follow the thread. Normally you apply a search on the addons/ folder but that will exclude Odoo core files like models and fields and it will be ok to search for modules fields and methods examples or code usage

Hope this help you a little

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

2 follower(s)


Asked: 12/4/15, 3:34 AM
Seen: 712 times
Last updated: 12/5/15, 3:24 AM