Skip to content

Load server wide modules in environment#56

Open
paradoxxxzero wants to merge 1 commit intoacsone:masterfrom
akretion:server-wide-modules-support
Open

Load server wide modules in environment#56
paradoxxxzero wants to merge 1 commit intoacsone:masterfrom
akretion:server-wide-modules-support

Conversation

@paradoxxxzero
Copy link
Copy Markdown

Odoo loads server wide modules before doing anything else (see https://github.com/odoo/odoo/blob/16.0/odoo/service/server.py#L1356), not doing it here can break modules that expect server wide modules to be loaded.

@sbidoul
Copy link
Copy Markdown
Member

sbidoul commented Jul 5, 2024

Could we make this optional, disabled by default? I worry about backward compatibility issues.

@sbidoul
Copy link
Copy Markdown
Member

sbidoul commented Jul 5, 2024

Related: #35 by @lmignon

@AnizR
Copy link
Copy Markdown

AnizR commented Feb 17, 2026

I have a case where this PR can be useful:
I try to avoid installation of a module that is set as auto-install (account_loans) with https://github.com/OCA/server-tools/tree/19.0/module_change_auto_install .

Is it possible to re-base this pr?

@paradoxxxzero paradoxxxzero force-pushed the server-wide-modules-support branch from 45dc4b3 to 71bcf45 Compare February 20, 2026 14:46
@paradoxxxzero
Copy link
Copy Markdown
Author

Rebased

@sbidoul
Copy link
Copy Markdown
Member

sbidoul commented Feb 23, 2026

Another use case is the logging_json server_wide_module which would nice to have enabled in click-odoo-initdb and click-odoo-update.

@sbidoul
Copy link
Copy Markdown
Member

sbidoul commented Feb 23, 2026

I still worry about backward compatibility if this is enabled unconditionally, though.

@lmignon
Copy link
Copy Markdown
Member

lmignon commented Feb 23, 2026

It should not be enabled by default. For example, we don't want to load queue_job on click-odoo-update.... (it could be without effect but it's a module that raises a red flag for me in terms of the potentially unpredictable behaviors of this change)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants