Odoo Addons path Setup

Import Issue if module is in other directory - K

Probuse Admin

import sys
sys.path.insert(0, '/home/mustufa/Odoo/custom-addons')
import Balalala
If we don't use above steps then we have to use in our file as below that is not looks good as technical.
Above will fix the issue. Please make sure you have to exit terminal one time and then restart Terminal again and then Odoo server should be restart too.
export PYTHONPATH="$PYTHONPATH:/home/mustufa/Odoo/custom-addons"
To fix that we can do that in Ubuntu linux server by opening .bashrc file from /home folder and add line below:
Normally if we have two addons path of custom modules and if we try to import module from other addons path it gives error called Import error "No module name Balalala".