From e1e63a23f98a974ec64478a2e4cdde997d656a62 Mon Sep 17 00:00:00 2001 From: Christoph Zwerschke Date: Wed, 20 Mar 2024 16:11:12 +0000 Subject: [PATCH] Update docs and reformat --- README.md | 2 +- config_schema.json | 1 + example_config.yaml | 1 + scripts/script_utils/deps.py | 11 ++++++----- scripts/script_utils/lock_deps.py | 1 + tests/conftest.py | 1 + 6 files changed, 11 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 8fdd84c..3f0546d 100644 --- a/README.md +++ b/README.md @@ -239,7 +239,7 @@ The service requires the following configuration parameters: - **Items** *(string)* -- **`auth_check_claims`** *(object)*: A dict of all GHGA internal claims that shall be verified. Default: `{"name": null, "email": null, "iat": null, "exp": null}`. +- **`auth_check_claims`** *(object)*: A dict of all GHGA internal claims that shall be verified. Default: `{"id": null, "name": null, "email": null, "iat": null, "exp": null}`. - **`auth_map_claims`** *(object)*: A mapping of claims to attributes in the GHGA auth context. Can contain additional properties. Default: `{}`. diff --git a/config_schema.json b/config_schema.json index 8619a8a..1755a8f 100644 --- a/config_schema.json +++ b/config_schema.json @@ -199,6 +199,7 @@ }, "auth_check_claims": { "default": { + "id": null, "name": null, "email": null, "iat": null, diff --git a/example_config.yaml b/example_config.yaml index fd8a1af..ef43a7b 100644 --- a/example_config.yaml +++ b/example_config.yaml @@ -5,6 +5,7 @@ auth_check_claims: email: null exp: null iat: null + id: null name: null auth_key: '{}' auth_map_claims: {} diff --git a/scripts/script_utils/deps.py b/scripts/script_utils/deps.py index 5d65cf7..cd84c93 100644 --- a/scripts/script_utils/deps.py +++ b/scripts/script_utils/deps.py @@ -14,6 +14,7 @@ # limitations under the License. # """Contains utils for working with dependencies, lock files, etc.""" + from copy import deepcopy from pathlib import Path from typing import Any @@ -55,11 +56,11 @@ def remove_self_dependencies(pyproject: dict) -> dict: if "optional-dependencies" in project_metadata: for group in project_metadata["optional-dependencies"]: - project_metadata["optional-dependencies"][ - group - ] = exclude_from_dependency_list( - package_name=package_name, - dependencies=project_metadata["optional-dependencies"][group], + project_metadata["optional-dependencies"][group] = ( + exclude_from_dependency_list( + package_name=package_name, + dependencies=project_metadata["optional-dependencies"][group], + ) ) return modified_pyproject diff --git a/scripts/script_utils/lock_deps.py b/scripts/script_utils/lock_deps.py index 60d857e..6dca822 100644 --- a/scripts/script_utils/lock_deps.py +++ b/scripts/script_utils/lock_deps.py @@ -14,6 +14,7 @@ # limitations under the License. # """Provides a function to get all dependencies from the lock file""" + import re from pathlib import Path from typing import Optional diff --git a/tests/conftest.py b/tests/conftest.py index 36a8147..61c3f72 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -15,6 +15,7 @@ # """Shared fixtures""" + import asyncio from time import sleep