Please sign in to comment.
[IMP] base_address_partner: don't re-set street when we just set it
If write()ing both the country and street, the override would then go and re-write the street based on what had *just* been split into sub-street fields, which could waste a lot of time during the import post-process as address fields get moved back and forth between parents and children leading to *lots* of writing both country and address together, we're talking: ncalls tottime percall cumtime percall filename:lineno(function) 10002/2 0.111 0.000 344.390 172.195 res_partner.py:181(write) [...] 2 0.455 0.228 165.264 82.632 base_address_extended.py:41(_set_street) My initial instinct was to just add the country_id to _set_street and remove the write override but it would break 88ff6be: if the country alone is updated on a partner, we do want to re-format the "unified" address based on individual fields and the new country's format. Might be that the logic *should* be for `street` to be the computed fields and the other 3 to be the actual source fields, that seems to be the more intentional logic.
- Loading branch information...
Showing with 1 addition and 1 deletion.