Odoo Experience 2017 -And the Winner is...
And the Winner is Us. See below.
I shunted between some technical developer streams for some time.
Recording and playing tests in session one. Using pylint in session two.
The pylint for Odoo is something I have been using, but not enough, and I think it is something we should (and can) be pushing in to our regular development workflow for everyone. Besides the standard pylint process checks, it looks for Odoo specific coding mistakes, including:
Dangerous sql insertions;
Bad xml_id references;
Button references to undefined methods;
Not just py, but rst and xml validation; and
I really enjoyed the session about best practices for ORM performance optimisations. Some of the things I took out:
Identify a performance bottleneck, launch with single worker, use pyflame to capture the python stack every millisecond or so, render and analyse using flamegraph;
Odoo 11 has a line profiling tool which lets us know how long a line takes, and how many database calls were made when it ran;
If postgres is remote from the database, then reducing queries can be beneficial;
Generally, with timing, watch scalability closely, especially with queries – if scaling has a squared or cubed effect on timing, then this could be disastrous when scaling;
Reading / writing / unlinking 1 or reading 10 is about the same amount of time, almost constant scalability which is perfect, while creating is linear;
X2many fields adds extra operations, per line;
Prefetching uses heuristics to determine what needs to be cached, and it’s good, but sometimes it is too much, and sometimes not enough – these can be fiddled if needed (self.env[‘batch’]._prefetch to use more, and records.with_context(prefetch_fields=False) to use none);
The magic of stored computed fields is not free, so if you need to, you can use “norecompute” and trigger a recompute at the end with self.recompute(), especially if recompute is optimised for batch updating; and
If you don’t need it in a batch update, you can turn off the mail stuff like value tracking.
After lunch, I did a couple of functional sessions. Multi-company intercompany transactions (nothing new), and the all new MRP workcentres (plenty of new stuff – look out for workcentre steps).
The final session for me was the inventory and MRP refactoring – Brace yourselves, and I am yet to contextualise what all these things mean:
New model – stock.move.line;
Quants don’t move, but are “container counters”;
Quants don’t have a cost (??!!??!!??);
Stock moves have a better link to accounting; and
Many2many links to dest_move_id.
Overall, I think many things about this are good, and simplify concepts, but I have my reservations, and wonder about valuations, particularly past, and any form of real costed items. I have trepidation about this more than anything else I’ve seen at this roadshow.
In the evening, Jon and I were called to stage to accept the award as best partner for APAC, 2017. Yay to us.
Following this, we danced and partied to the Odoo band (rocking heavy, including ACDC), followed by Abba Gold.
And Paulius and Ignas say hi.
Join our Mailing List today
Join our mailing list today and receive free ERP insights straight into your inbox.