From 52e8fd83ef24fcc1d0c3a3d96f89b0011d5593a0 Mon Sep 17 00:00:00 2001 From: pwei1018 Date: Wed, 14 Aug 2024 11:42:38 -0700 Subject: [PATCH] Fixing linting. --- auth-api/src/auth_api/__init__.py | 5 ++-- .../src/auth_api/services/authorization.py | 3 ++- auth-api/src/auth_api/version.py | 25 ------------------- 3 files changed, 5 insertions(+), 28 deletions(-) delete mode 100644 auth-api/src/auth_api/version.py diff --git a/auth-api/src/auth_api/__init__.py b/auth-api/src/auth_api/__init__.py index 2b2276b599..2c5b887fdf 100644 --- a/auth-api/src/auth_api/__init__.py +++ b/auth-api/src/auth_api/__init__.py @@ -107,10 +107,11 @@ def build_cache(app): cache.clear() if not app.config.get("TESTING", False): try: - from auth_api.services.permissions import ( # pylint: disable=import-outside-toplevel + # pylint: disable=import-outside-toplevel + from auth_api.services.permissions import ( Permissions as PermissionService, ) - from auth_api.services.products import ( # pylint: disable=import-outside-toplevel + from auth_api.services.products import ( Product as ProductService, ) diff --git a/auth-api/src/auth_api/services/authorization.py b/auth-api/src/auth_api/services/authorization.py index e4f8c13c42..75871e4fe0 100644 --- a/auth-api/src/auth_api/services/authorization.py +++ b/auth-api/src/auth_api/services/authorization.py @@ -196,7 +196,8 @@ def _is_product_based_auth(product_code): check_product_based_auth = False if product_code: - from auth_api.services.products import ( # pylint:disable=cyclic-import, import-outside-toplevel + # pylint:disable=cyclic-import, import-outside-toplevel + from auth_api.services.products import ( Product as ProductService, ) diff --git a/auth-api/src/auth_api/version.py b/auth-api/src/auth_api/version.py deleted file mode 100644 index fde0f6015d..0000000000 --- a/auth-api/src/auth_api/version.py +++ /dev/null @@ -1,25 +0,0 @@ -# Copyright © 2019 Province of British Columbia -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -"""Version of this service in PEP440. - -[N!]N(.N)*[{a|b|rc}N][.postN][.devN] -Epoch segment: N! -Release segment: N(.N)* -Pre-release segment: {a|b|rc}N -Post-release segment: .postN -Development release segment: .devN -""" - -__version__ = '2.10.4' # pylint: disable=invalid-name