Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[14.0][BACKPORT] [16.0] stock_picking_volume: Speedup install and avoid useless recompute #2148

Merged
merged 5 commits into from
Sep 30, 2024

Conversation

sebalix
Copy link
Contributor

@sebalix sebalix commented Aug 28, 2024

Port of #1680 from 16.0 to 14.0.

SQL request in pre_init_hook has been adapted to 14.0 (see https://github.com/OCA/OpenUpgrade/blob/16.0/openupgrade_scripts/scripts/stock/16.0.1.1/pre-migration.py#L17-L18 )

Makes computed fields readonly in state 'done' or 'cancel' to avoid triggering recompute when these values are useless
@OCA-git-bot
Copy link
Contributor

Hi @lmignon,
some modules you are maintaining are being modified, check this out!

Init computed fields from plain sql queries to speedup install on large database
@sebalix sebalix force-pushed the oca-port-from-16.0-to-14.0-pr-1680 branch 2 times, most recently from 4947b9a to 3e1537a Compare August 28, 2024 13:15
ferran-S73 and others added 3 commits August 28, 2024 15:32
…c' to 'double precision'

As no digits parameters are provided on `<stock.move>.volume' and
'<stock.picking>.volume' fields, the 'double precision' type is used
instead of 'numeric'.

This avoids time consuming SQL requests 'ALTER TABLE...' at module
install.
Copy link
Contributor

@lmignon lmignon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (Code review only)

@sebalix sebalix changed the title [14.0][FW] [16.0] stock_picking_volume: Speedup install and avoid useless recompute [14.0][BACKPORT] [16.0] stock_picking_volume: Speedup install and avoid useless recompute Sep 2, 2024
@OCA-git-bot
Copy link
Contributor

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

@sebalix
Copy link
Contributor Author

sebalix commented Sep 30, 2024

/ocabot merge patch

@OCA-git-bot
Copy link
Contributor

This PR looks fantastic, let's merge it!
Prepared branch 14.0-ocabot-merge-pr-2148-by-sebalix-bump-patch, awaiting test results.

OCA-git-bot added a commit that referenced this pull request Sep 30, 2024
Signed-off-by sebalix
@OCA-git-bot
Copy link
Contributor

It looks like something changed on 14.0 in the meantime.
Let me try again (no action is required from you).
Prepared branch 14.0-ocabot-merge-pr-2148-by-sebalix-bump-patch, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit 1375897 into OCA:14.0 Sep 30, 2024
7 checks passed
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at 93c5fe2. Thanks a lot for contributing to OCA. ❤️

@sebalix sebalix deleted the oca-port-from-16.0-to-14.0-pr-1680 branch September 30, 2024 14:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants