Skip to content

Conversation

@fw-bot
Copy link
Contributor

@fw-bot fw-bot commented Dec 4, 2025

In some case, a database can be in a state where some auto install module are not installed

  • when the user uninstall a module
  • when module was added in stable and a database was created before the addition.

It can lead to issues where an upgrade fails or some business logic does not work as expected because of the missing modules.

This is not easy to reproduce and to test, even if uninstalling such module should in theory work and be tested.

This pr proposes to add a flag "--skip-auto-install" to the config to be able to disable all auto install of modules.

It is open to discussion to change this to a config option, with or without a module list

Initial solution (alternative to avoid a config)
--dev skipautoinstall

Current solutions
(command line param)
--skip-auto-install

Maybe in the future but unlikely
(more flexible)
--skip-auto-install=all
--skip-auto-install=web_enterprise,iap

(krma suggestions)
--skip-auto-install=*
--skip-auto-install=web_*,iap

Those two last one could be more flexible but the use case are limited and can be done another way with an explicit -i, maybe no worth the additional complexity (mainly since we need to filter in two different places)

Note that this pr uses get on the config just in case the config is monkey patched somewhere to make it more robust.

Forward-Port-Of: #234710

@robodoo
Copy link
Contributor

robodoo commented Dec 4, 2025

Pull request status dashboard

@fw-bot
Copy link
Contributor Author

fw-bot commented Dec 4, 2025

This PR targets 18.0 and is part of the forward-port chain. Further PRs will be created up to master.

More info at https://github.com/odoo/odoo/wiki/Mergebot#forward-port

@robodoo robodoo added the forwardport This PR was created by @fw-bot label Dec 4, 2025
@fw-bot
Copy link
Contributor Author

fw-bot commented Dec 4, 2025

@Xavier-Do ci/runbot failed on this forward-port PR

In some case, a database can be in a state where some auto install
module are not installed
- when the user uninstall a module
- when module was added in stable and a database was created before the
addition.

It can lead to issues where an upgrade fails or some business logic does
not work as expected because of the missing modules.

This is not easy to reproduce and to test, even if uninstalling such
module should in theory work and be tested.

This pr proposes to add a flag "--skip-auto-install" to the config to be
able to disable some autoinstall of modules.

X-original-commit: 1a6947b
@Xavier-Do Xavier-Do force-pushed the 18.0-17.0-allow-to-disable-autoinstall-xdo-475512-fw branch from e5e4232 to fa9816b Compare December 8, 2025 08:28
@fw-bot
Copy link
Contributor Author

fw-bot commented Dec 8, 2025

@Xavier-Do this PR has become a normal PR because head updated from e5e4232 to fa9816b. It must be merged be forward-ported further.

@C3POdoo C3POdoo requested review from a team, kmagusiak and rco-odoo and removed request for a team December 8, 2025 08:31
@Xavier-Do
Copy link
Contributor

config related tests should be fixed

robodoo r+

robodoo pushed a commit that referenced this pull request Dec 8, 2025
In some case, a database can be in a state where some auto install
module are not installed
- when the user uninstall a module
- when module was added in stable and a database was created before the
addition.

It can lead to issues where an upgrade fails or some business logic does
not work as expected because of the missing modules.

This is not easy to reproduce and to test, even if uninstalling such
module should in theory work and be tested.

This pr proposes to add a flag "--skip-auto-install" to the config to be
able to disable some autoinstall of modules.

closes #238685

X-original-commit: 1a6947b
Related: odoo/documentation#15570
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
robodoo pushed a commit to odoo/documentation that referenced this pull request Dec 8, 2025
Document new cli option.

closes #15570

X-original-commit: bb3c14e
Related: odoo/odoo#238685
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
@robodoo robodoo closed this Dec 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

forwardport This PR was created by @fw-bot

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants