From 4a763a030444e90be8a0a97271ee26ed15dc2685 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miquel=20Ra=C3=AFch?= Date: Thu, 12 Dec 2024 11:20:50 +0100 Subject: [PATCH 1/4] [FIX] upgrade_analysis: new modules cannot be merged/renamed in same version Issue: v14 has OCA's 10n_eu_oss (https://github.com/OCA/account-fiscal-rule/tree/14.0/l10n_eu_oss), which is renamed in v15 to l10n_eu_oss_oca (https://github.com/OCA/account-fiscal-rule/tree/15.0/l10n_eu_oss_oca) due to new module Odoo's 10n_eu_oss (https://github.com/odoo/odoo/tree/15.0/addons/l10n_eu_oss). Thus, it doesn't makes sense to have in the coverage file the row `|[new] 10n_eu_oss | |Renamed to l10n_eu_oss_oca|`. --- upgrade_analysis/models/upgrade_analysis.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/upgrade_analysis/models/upgrade_analysis.py b/upgrade_analysis/models/upgrade_analysis.py index 8d0e53aa5d9..8a96fc664db 100644 --- a/upgrade_analysis/models/upgrade_analysis.py +++ b/upgrade_analysis/models/upgrade_analysis.py @@ -552,16 +552,19 @@ def generate_module_coverage_file(self, no_changes_modules): module_descriptions = {} for module in all_modules: status = "" + is_new = False if module in all_local_modules and module in all_remote_modules: module_description = " %s" % module elif module in all_local_modules: module_description = " |new| %s" % module + is_new = True else: module_description = " |del| %s" % module - if module in compare.apriori.merged_modules: + # new modules cannot be merged/renamed in same version + if not is_new and module in compare.apriori.merged_modules: status = "Merged into %s. " % compare.apriori.merged_modules[module] - elif module in compare.apriori.renamed_modules: + elif not is_new and module in compare.apriori.renamed_modules: status = "Renamed to %s. " % compare.apriori.renamed_modules[module] elif module in compare.apriori.renamed_modules.values(): status = ( From 554aeba27513682cfa86e5025639f85d41a2a260 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miquel=20Ra=C3=AFch?= Date: Thu, 12 Dec 2024 11:24:45 +0100 Subject: [PATCH 2/4] [FIX] upgrade_analysis: exclude OU modules from coverage file --- upgrade_analysis/models/upgrade_analysis.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/upgrade_analysis/models/upgrade_analysis.py b/upgrade_analysis/models/upgrade_analysis.py index 8a96fc664db..370a3774b93 100644 --- a/upgrade_analysis/models/upgrade_analysis.py +++ b/upgrade_analysis/models/upgrade_analysis.py @@ -532,7 +532,16 @@ def generate_module_coverage_file(self, no_changes_modules): module_domain = [ ("state", "=", "installed"), - ("name", "not in", ["upgrade_analysis", "openupgrade_records"]), + ( + "name", + "not in", + [ + "upgrade_analysis", + "openupgrade_records", + "openupgrade_scripts", + "openupgrade_framework", + ], + ), ] connection = self.config_id.get_connection() From 5e43fced3d8856acb2058ff1f856c1eb08c3b502 Mon Sep 17 00:00:00 2001 From: Jean-Charles Drubay Date: Tue, 10 May 2022 22:16:31 +0700 Subject: [PATCH 3/4] [FIX] smart button to open the list of analysis from a config --- upgrade_analysis/README.rst | 15 +++++++++++---- .../models/upgrade_comparison_config.py | 8 +++++++- upgrade_analysis/readme/DESCRIPTION.rst | 11 +++++++++-- 3 files changed, 27 insertions(+), 7 deletions(-) diff --git a/upgrade_analysis/README.rst b/upgrade_analysis/README.rst index 6dc740b49c2..33c4c460ec2 100644 --- a/upgrade_analysis/README.rst +++ b/upgrade_analysis/README.rst @@ -2,7 +2,7 @@ Upgrade Analysis ================ -.. +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! @@ -28,9 +28,16 @@ Upgrade Analysis |badge1| |badge2| |badge3| |badge4| |badge5| -This module provides the tool to generate the database analysis files that indicate how the Odoo data model and module data have changed between two versions of Odoo. Database analysis files for the core modules are included in the OpenUpgrade distribution so as a migration script developer you will not usually need to use this tool yourself. If you do need to run your analysis of a custom set of modules, please refer to the documentation here: https://doc.therp.nl/openupgrade/analysis.html +This module provides the tool to generate the database analysis files that indicate +how the Odoo data model and module data have changed between two versions of Odoo. +Database analysis files for the core modules are included in the OpenUpgrade +distribution so as a migration script developer you will not usually need to use +this tool yourself. If you do need to run your analysis of a custom set of modules, +please refer to the documentation here: https://doc.therp.nl/openupgrade/analysis.html -This module is just a tool, a continuation of the old openupgrade_records in OpenUpgrade in previous versions. It's not recommended to have this module in a production database. +This module is just a tool, a continuation of the old openupgrade_records in +OpenUpgrade in previous versions. It's not recommended to have this module in a +production database. **Table of contents** @@ -102,7 +109,7 @@ promote its widespread use. Current `maintainers `__: -|maintainer-StefanRijnhart| |maintainer-legalsylvain| +|maintainer-StefanRijnhart| |maintainer-legalsylvain| This module is part of the `OCA/server-tools `_ project on GitHub. diff --git a/upgrade_analysis/models/upgrade_comparison_config.py b/upgrade_analysis/models/upgrade_comparison_config.py index 649866379af..9ba4e2b3ac8 100644 --- a/upgrade_analysis/models/upgrade_comparison_config.py +++ b/upgrade_analysis/models/upgrade_comparison_config.py @@ -93,4 +93,10 @@ def new_analysis(self): def action_show_analysis(self): self.ensure_one() - return {} + return { + "type": "ir.actions.act_window", + "name": "Analyses", + "res_model": "upgrade.analysis", + "view_mode": "tree,form", + "domain": [("id", "in", self.analysis_ids.ids)], + } diff --git a/upgrade_analysis/readme/DESCRIPTION.rst b/upgrade_analysis/readme/DESCRIPTION.rst index 1b12e675fe0..d6539b4f1a1 100644 --- a/upgrade_analysis/readme/DESCRIPTION.rst +++ b/upgrade_analysis/readme/DESCRIPTION.rst @@ -1,3 +1,10 @@ -This module provides the tool to generate the database analysis files that indicate how the Odoo data model and module data have changed between two versions of Odoo. Database analysis files for the core modules are included in the OpenUpgrade distribution so as a migration script developer you will not usually need to use this tool yourself. If you do need to run your analysis of a custom set of modules, please refer to the documentation here: https://doc.therp.nl/openupgrade/analysis.html +This module provides the tool to generate the database analysis files that indicate +how the Odoo data model and module data have changed between two versions of Odoo. +Database analysis files for the core modules are included in the OpenUpgrade +distribution so as a migration script developer you will not usually need to use +this tool yourself. If you do need to run your analysis of a custom set of modules, +please refer to the documentation here: https://doc.therp.nl/openupgrade/analysis.html -This module is just a tool, a continuation of the old openupgrade_records in OpenUpgrade in previous versions. It's not recommended to have this module in a production database. +This module is just a tool, a continuation of the old openupgrade_records in +OpenUpgrade in previous versions. It's not recommended to have this module in a +production database. From 85ccb7474da3bd4057808a8001d414f2d375cd31 Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Thu, 2 Jan 2025 12:59:18 +0000 Subject: [PATCH 4/4] [BOT] post-merge updates --- README.md | 2 +- upgrade_analysis/README.rst | 6 +++--- upgrade_analysis/__manifest__.py | 2 +- upgrade_analysis/static/description/index.html | 13 ++++++++++--- 4 files changed, 15 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 7ba78365980..2302bdeb5dd 100644 --- a/README.md +++ b/README.md @@ -74,7 +74,7 @@ addon | version | maintainers | summary [server_action_logging](server_action_logging/) | 16.0.1.0.0 | | Module that provides a logging mechanism for server actions [session_db](session_db/) | 16.0.1.0.6 | [![sbidoul](https://github.com/sbidoul.png?size=30px)](https://github.com/sbidoul) | Store sessions in DB [tracking_manager](tracking_manager/) | 16.0.1.1.7 | [![Kev-Roche](https://github.com/Kev-Roche.png?size=30px)](https://github.com/Kev-Roche) [![sebastienbeau](https://github.com/sebastienbeau.png?size=30px)](https://github.com/sebastienbeau) | This module tracks all fields of a model, including one2many and many2many ones. -[upgrade_analysis](upgrade_analysis/) | 16.0.1.1.0 | [![StefanRijnhart](https://github.com/StefanRijnhart.png?size=30px)](https://github.com/StefanRijnhart) [![legalsylvain](https://github.com/legalsylvain.png?size=30px)](https://github.com/legalsylvain) | Performs a difference analysis between modules installed on two different Odoo instances +[upgrade_analysis](upgrade_analysis/) | 16.0.1.2.0 | [![StefanRijnhart](https://github.com/StefanRijnhart.png?size=30px)](https://github.com/StefanRijnhart) [![legalsylvain](https://github.com/legalsylvain.png?size=30px)](https://github.com/legalsylvain) | Performs a difference analysis between modules installed on two different Odoo instances [url_attachment_search_fuzzy](url_attachment_search_fuzzy/) | 16.0.1.0.0 | [![mariadforgelow](https://github.com/mariadforgelow.png?size=30px)](https://github.com/mariadforgelow) | Fuzzy Search of URL in Attachments [//]: # (end addons) diff --git a/upgrade_analysis/README.rst b/upgrade_analysis/README.rst index 33c4c460ec2..8a96d42d242 100644 --- a/upgrade_analysis/README.rst +++ b/upgrade_analysis/README.rst @@ -2,12 +2,12 @@ Upgrade Analysis ================ -.. +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - !! source digest: sha256:d3fed94216a53b58bca8455d3a2758193f7641ca45adee8e03cf50464674a61d + !! source digest: sha256:530141731a853793cda478da96e88f4ecbc21374090758a88258a61a3e75f78d !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png @@ -109,7 +109,7 @@ promote its widespread use. Current `maintainers `__: -|maintainer-StefanRijnhart| |maintainer-legalsylvain| +|maintainer-StefanRijnhart| |maintainer-legalsylvain| This module is part of the `OCA/server-tools `_ project on GitHub. diff --git a/upgrade_analysis/__manifest__.py b/upgrade_analysis/__manifest__.py index 6ffce92269f..087bc5970d8 100644 --- a/upgrade_analysis/__manifest__.py +++ b/upgrade_analysis/__manifest__.py @@ -5,7 +5,7 @@ "name": "Upgrade Analysis", "summary": "Performs a difference analysis between modules" " installed on two different Odoo instances", - "version": "16.0.1.1.0", + "version": "16.0.1.2.0", "category": "Migration", "author": "Therp BV, Opener B.V., GRAP, Odoo Community Association (OCA)", "maintainers": ["StefanRijnhart", "legalsylvain"], diff --git a/upgrade_analysis/static/description/index.html b/upgrade_analysis/static/description/index.html index b535245c5b8..5f533df81e5 100644 --- a/upgrade_analysis/static/description/index.html +++ b/upgrade_analysis/static/description/index.html @@ -367,11 +367,18 @@

Upgrade Analysis

!! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -!! source digest: sha256:d3fed94216a53b58bca8455d3a2758193f7641ca45adee8e03cf50464674a61d +!! source digest: sha256:530141731a853793cda478da96e88f4ecbc21374090758a88258a61a3e75f78d !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->

Beta License: AGPL-3 OCA/server-tools Translate me on Weblate Try me on Runboat

-

This module provides the tool to generate the database analysis files that indicate how the Odoo data model and module data have changed between two versions of Odoo. Database analysis files for the core modules are included in the OpenUpgrade distribution so as a migration script developer you will not usually need to use this tool yourself. If you do need to run your analysis of a custom set of modules, please refer to the documentation here: https://doc.therp.nl/openupgrade/analysis.html

-

This module is just a tool, a continuation of the old openupgrade_records in OpenUpgrade in previous versions. It’s not recommended to have this module in a production database.

+

This module provides the tool to generate the database analysis files that indicate +how the Odoo data model and module data have changed between two versions of Odoo. +Database analysis files for the core modules are included in the OpenUpgrade +distribution so as a migration script developer you will not usually need to use +this tool yourself. If you do need to run your analysis of a custom set of modules, +please refer to the documentation here: https://doc.therp.nl/openupgrade/analysis.html

+

This module is just a tool, a continuation of the old openupgrade_records in +OpenUpgrade in previous versions. It’s not recommended to have this module in a +production database.

Table of contents