odoo / odoo

Odoo. Open Source Apps To Grow Your Business.

Home Page:https://www.odoo.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[17.0] delivery: neutralize should only disable production environment and not disable carriers

john-herholz-dt opened this issue · comments

Shipping providers have a test and production environment, to process API calls.
When neutralizing a database, it should switch to the test environment of the providers.

Impacted versions:
17.0

Steps to reproduce:
Neutralize a database

Current behavior:
After database neutralization, all shipping carriers are disabled.
For test environments, this means you need to manually enable all carriers and leave it in development environment.

Expected behavior:
Only production environment is disabled on neutralization

Video/Screenshot link (optional):

Support ticket number submitted via odoo.com/help (optional):
[FW][IMP] delivery: disable only delivery carriers from external providers #161182
Was already a move in the right direction, but the issue here is still present.

Hi @john-herholz-dt
Thanks for your feedback. Actually, I came up with a similar idea (see discussion in #160443) but @ticodoo thought it was safer to implement an intermediate version in stable.
I wonder if it couldn't be as you mention in master, with delivery only having

UPDATE delivery_carrier
   SET prod_environment = false;

and maybe a dedicated neutralize script for external providers that require further actions to ensure safe usage.