diff options
| author | =?UTF-8?q?St=C3=A9phane=20Bidoul=20=28ACSONE=29?= <stephane.bidoul@acsone.eu> | 2016-09-27 12:00:44 +0200 |
|---|---|---|
| committer | Simon Lejeune <sle@openerp.com> | 2016-09-30 12:05:49 +0200 |
| commit | 389c2ba97ba83dea01949d2a3cad295bd710d9ef (patch) | |
| tree | 9505bb68bce48a29df770936a25fe49744dbcca9 /odoo/addons/__init__.py | |
| parent | ffd3c513ed3178fc87a79b9244ef5967d5ebcdef (diff) | |
[REF] packaging: make odoo a namespaced package
by auto-extending addons path with odoo.addons.__path__.
This patch also introduce
* an explicit declaration of odoo.addons as a namespace package
This is necessary because the standard way of declaring namespace
packages in setup.py does not work as long as odoo/__init__.py
contains code.
* a more reliable way to find odoo root path.
Diffstat (limited to 'odoo/addons/__init__.py')
| -rw-r--r-- | odoo/addons/__init__.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/odoo/addons/__init__.py b/odoo/addons/__init__.py index 8f2c331e5c0..d3a3e7e9ba2 100644 --- a/odoo/addons/__init__.py +++ b/odoo/addons/__init__.py @@ -14,3 +14,4 @@ This module also conveniently reexports some symbols from odoo.modules. Importing them from here is deprecated. """ +__import__('pkg_resources').declare_namespace(__name__) |
