From 1d1e2ee40a1db483681adae1f9086d8d4788c7e3 Mon Sep 17 00:00:00 2001 From: Lucas Moura Date: Thu, 28 Sep 2023 14:43:09 -0300 Subject: [PATCH] api: rename fix/common folder to fix/_common Rename the module to indicate that the content in this folder is for internal use only --- uaclient/api/tests/test_api_u_pro_security_fix_execute.py | 2 +- .../api/u/pro/security/fix/{common => _common}/__init__.py | 0 .../pro/security/fix/{common => _common}/execute/__init__.py | 0 .../api/u/pro/security/fix/{common => _common}/execute/v1.py | 2 +- uaclient/api/u/pro/security/fix/cve/execute/v1.py | 4 ++-- uaclient/api/u/pro/security/fix/cve/plan/v1.py | 2 +- uaclient/api/u/pro/security/fix/usn/execute/v1.py | 4 ++-- uaclient/api/u/pro/security/fix/usn/plan/v1.py | 2 +- uaclient/cli/fix.py | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) rename uaclient/api/u/pro/security/fix/{common => _common}/__init__.py (100%) rename uaclient/api/u/pro/security/fix/{common => _common}/execute/__init__.py (100%) rename uaclient/api/u/pro/security/fix/{common => _common}/execute/v1.py (99%) diff --git a/uaclient/api/tests/test_api_u_pro_security_fix_execute.py b/uaclient/api/tests/test_api_u_pro_security_fix_execute.py index 8c65c171fc..0b7837f14b 100644 --- a/uaclient/api/tests/test_api_u_pro_security_fix_execute.py +++ b/uaclient/api/tests/test_api_u_pro_security_fix_execute.py @@ -22,7 +22,7 @@ PackageCannotBeInstalledData, SecurityIssueNotFixedData, ) -from uaclient.api.u.pro.security.fix.common.execute.v1 import ( +from uaclient.api.u.pro.security.fix._common.execute.v1 import ( FailedUpgrade, FixExecuteError, FixExecuteResult, diff --git a/uaclient/api/u/pro/security/fix/common/__init__.py b/uaclient/api/u/pro/security/fix/_common/__init__.py similarity index 100% rename from uaclient/api/u/pro/security/fix/common/__init__.py rename to uaclient/api/u/pro/security/fix/_common/__init__.py diff --git a/uaclient/api/u/pro/security/fix/common/execute/__init__.py b/uaclient/api/u/pro/security/fix/_common/execute/__init__.py similarity index 100% rename from uaclient/api/u/pro/security/fix/common/execute/__init__.py rename to uaclient/api/u/pro/security/fix/_common/execute/__init__.py diff --git a/uaclient/api/u/pro/security/fix/common/execute/v1.py b/uaclient/api/u/pro/security/fix/_common/execute/v1.py similarity index 99% rename from uaclient/api/u/pro/security/fix/common/execute/v1.py rename to uaclient/api/u/pro/security/fix/_common/execute/v1.py index 5a96178c5a..c2035b3da1 100644 --- a/uaclient/api/u/pro/security/fix/common/execute/v1.py +++ b/uaclient/api/u/pro/security/fix/_common/execute/v1.py @@ -11,7 +11,7 @@ FixPlanWarningPackageCannotBeInstalled, FixPlanWarningSecurityIssueNotFixed, ) -from uaclient.api.u.pro.security.fix.common import status_message +from uaclient.api.u.pro.security.fix._common import status_message from uaclient.data_types import DataObject, Field, StringDataValue, data_list from uaclient.security import FixStatus diff --git a/uaclient/api/u/pro/security/fix/cve/execute/v1.py b/uaclient/api/u/pro/security/fix/cve/execute/v1.py index 33f016053a..f12b92b24e 100644 --- a/uaclient/api/u/pro/security/fix/cve/execute/v1.py +++ b/uaclient/api/u/pro/security/fix/cve/execute/v1.py @@ -2,8 +2,8 @@ from uaclient.api.api import APIEndpoint from uaclient.api.data_types import AdditionalInfo -from uaclient.api.u.pro.security.fix.common import get_expected_overall_status -from uaclient.api.u.pro.security.fix.common.execute.v1 import ( +from uaclient.api.u.pro.security.fix._common import get_expected_overall_status +from uaclient.api.u.pro.security.fix._common.execute.v1 import ( FixExecuteResult, _execute_fix, ) diff --git a/uaclient/api/u/pro/security/fix/cve/plan/v1.py b/uaclient/api/u/pro/security/fix/cve/plan/v1.py index b28001ec92..126b9cf9db 100644 --- a/uaclient/api/u/pro/security/fix/cve/plan/v1.py +++ b/uaclient/api/u/pro/security/fix/cve/plan/v1.py @@ -3,7 +3,7 @@ from uaclient.api.api import APIEndpoint from uaclient.api.data_types import AdditionalInfo from uaclient.api.u.pro.security.fix import FixPlanResult, fix_plan_cve -from uaclient.api.u.pro.security.fix.common import get_expected_overall_status +from uaclient.api.u.pro.security.fix._common import get_expected_overall_status from uaclient.config import UAConfig from uaclient.data_types import DataObject, Field, StringDataValue, data_list diff --git a/uaclient/api/u/pro/security/fix/usn/execute/v1.py b/uaclient/api/u/pro/security/fix/usn/execute/v1.py index ab543e102e..47f647987d 100644 --- a/uaclient/api/u/pro/security/fix/usn/execute/v1.py +++ b/uaclient/api/u/pro/security/fix/usn/execute/v1.py @@ -2,8 +2,8 @@ from uaclient.api.api import APIEndpoint from uaclient.api.data_types import AdditionalInfo -from uaclient.api.u.pro.security.fix.common import get_expected_overall_status -from uaclient.api.u.pro.security.fix.common.execute.v1 import ( +from uaclient.api.u.pro.security.fix._common import get_expected_overall_status +from uaclient.api.u.pro.security.fix._common.execute.v1 import ( FixExecuteResult, _execute_fix, ) diff --git a/uaclient/api/u/pro/security/fix/usn/plan/v1.py b/uaclient/api/u/pro/security/fix/usn/plan/v1.py index ed664fb658..b2e27fe743 100644 --- a/uaclient/api/u/pro/security/fix/usn/plan/v1.py +++ b/uaclient/api/u/pro/security/fix/usn/plan/v1.py @@ -3,7 +3,7 @@ from uaclient.api.api import APIEndpoint from uaclient.api.data_types import AdditionalInfo from uaclient.api.u.pro.security.fix import FixPlanUSNResult, fix_plan_usn -from uaclient.api.u.pro.security.fix.common import get_expected_overall_status +from uaclient.api.u.pro.security.fix._common import get_expected_overall_status from uaclient.config import UAConfig from uaclient.data_types import DataObject, Field, StringDataValue, data_list diff --git a/uaclient/cli/fix.py b/uaclient/cli/fix.py index 2231af47d8..d8d7d232fd 100644 --- a/uaclient/cli/fix.py +++ b/uaclient/cli/fix.py @@ -42,7 +42,7 @@ NoOpLivepatchFixData, USNAdditionalData, ) -from uaclient.api.u.pro.security.fix.common import status_message +from uaclient.api.u.pro.security.fix._common import status_message from uaclient.api.u.pro.security.fix.cve.plan.v1 import CVEFixPlanOptions from uaclient.api.u.pro.security.fix.cve.plan.v1 import _plan as cve_plan from uaclient.api.u.pro.security.fix.usn.plan.v1 import USNFixPlanOptions