[IMP] server_environment: module uninstallation#261
Open
gurneyalex wants to merge 1 commit into
Open
Conversation
1 task
5 tasks
0ecea77 to
398d5b1
Compare
|
Hello @gurneyalex. Thank you for your work! I did some tests on my side. I suggested a fixup, since I was not falling into the fallback logic because no processed field was required. I believe that is because we set all fields as not required in the |
ivantodorovich
approved these changes
Jun 4, 2026
simahawk
approved these changes
Jun 4, 2026
5d7e4ed to
f5d0e5c
Compare
twalter-c2c
approved these changes
Jun 26, 2026
twalter-c2c
left a comment
There was a problem hiding this comment.
Thank you @gurneyalex! Minor remark regarding the USAGE.md.
| from odoo.addons.server_environment import uninstall | ||
|
|
||
| def uninstall_hook(env): | ||
| uninstallrestore_env_managed_columns( |
There was a problem hiding this comment.
Suggested change
| uninstallrestore_env_managed_columns( | |
| restore_env_managed_columns( |
We can either handle that in imports or dot is missing.
f5d0e5c to
8f16e59
Compare
Add a helper to manage the restoring of the database columns when a module using `server_environment` is uninstalled or the dependency on `server_environment` is dropped. Document how to use the helper in an uninstall script or in an upgrade script (if a new version of the addon drops the dependency).
8f16e59 to
5fa1624
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 helper to manage the restoring of the database columns when a module using
server_environmentis uninstalled or the dependency onserver_environmentis dropped.Document how to use the helper in an uninstall script or in an upgrade script (if a new version of the addon drops the dependency).