[ADD] modules: check module force install#368
Open
jjmaksoud wants to merge 1 commit intoodoo:masterfrom
Open
Conversation
Contributor
Contributor
Author
|
upgradeci retry with always only base |
0a2163e to
ec6be07
Compare
diagnoza
reviewed
Jan 5, 2026
ec6be07 to
512a20c
Compare
Pirols
approved these changes
Jan 27, 2026
aj-fuentes
approved these changes
Jan 28, 2026
KangOl
reviewed
Jan 28, 2026
512a20c to
2e585bf
Compare
KangOl
requested changes
Feb 3, 2026
Comment on lines
+679
to
681
| ENVIRON["__force_installed_modules"].update(toinstall) | ||
|
|
||
| if module in toinstall: |
Contributor
There was a problem hiding this comment.
Shouldn't we track the module only if it has actually been marked as "to install"?
Suggested change
| ENVIRON["__force_installed_modules"].update(toinstall) | |
| if module in toinstall: | |
| if module in toinstall: | |
| ENVIRON["__force_installed_modules"].update(toinstall) | |
Contributor
Author
There was a problem hiding this comment.
the toinstall list is a result of the previous query which set the state of the module and its dependencies. doesnt this mean they are actually marked as to install?
src/util/modules.py
Outdated
| :param str module: name of the module to check | ||
| :rtype: bool | ||
| """ | ||
| return module in ENVIRON["__force_installed_modules"] |
Contributor
There was a problem hiding this comment.
Maybe check if the module is still marked "to install".
Suggested change
| return module in ENVIRON["__force_installed_modules"] | |
| return module in ENVIRON["__force_installed_modules"] and module_installed(cr, module) |
Contributor
Author
There was a problem hiding this comment.
👍 would be useful in case a specific fix script reverted the installation of some modules
Add a utility function to check if a given module was force installed during the upgrade. This can be useful when a module is force installed and another module upgrade scripts need to fill in some data for it.
2e585bf to
a81a7ef
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Add a utility function to check if a given module was force installed during the upgrade.
This can be useful when a module is force installed and another module upgrade scripts need to fill in some data for it.