Community mailing list archives

Re: Should Odoo keep the old API for v10?

Camptocamp France SAS, Alexandre Fayolle - Camptocamp
- 05/03/2016 06:09:01
On 03/05/2016 10:47, Fabien Pinckaers wrote:
> Hello,
> In Odoo 10, all official modules should be ported to the new API.
> So, we face the choice to remove the old API to clean the code and speed
> up the software, or keep it to help the community port old modules to v10.
> If we keep the old API:
>   * it's easier to port community modules to v10, if they are not ported
>     to the new API yet
> If we remove the old API:
>   * Odoo will run about 10% faster
>   * Tracebacks are cleaner for developers (ORM code is lighter too)

Additionnally, removing the old API means:

* lighter and cleaner code base -> less bugs, easier for newcomers to
get on board
* no more funky @api.v7 decorator and related unexpected behaviors
* no more funky @api.returns decorator and related unexpected behaviors
* no more painful stepping in the wrapper layers in pdb
* no more pain when overloading a computed field from an addon using the
v7 api
* no more pain when extending an onchange method defined using the v7 api
* get back the ability to use profiling tools to analyze performance

My choice is clear :-)

Alexandre Fayolle
Chef de Projet
Tel : +33 4 58 48 20 30

Camptocamp France SAS
Savoie Technolac, BP 352
73377 Le Bourget du Lac Cedex