From afdc8766a03ce79167050050af326a8a85bd34d5 Mon Sep 17 00:00:00 2001 From: Mathieu Cloutier Date: Mon, 26 Aug 2024 09:49:31 -0600 Subject: [PATCH] Updated _retrieve_parameter_from_context_variables typing --- .../apigateway/next_gen/execute_api/parameters_mapping.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/localstack-core/localstack/services/apigateway/next_gen/execute_api/parameters_mapping.py b/localstack-core/localstack/services/apigateway/next_gen/execute_api/parameters_mapping.py index c324438eee948..875af08a482c6 100644 --- a/localstack-core/localstack/services/apigateway/next_gen/execute_api/parameters_mapping.py +++ b/localstack-core/localstack/services/apigateway/next_gen/execute_api/parameters_mapping.py @@ -8,7 +8,7 @@ # https://docs.aws.amazon.com/apigateway/latest/developerguide/request-response-data-mappings.html import json import logging -from typing import TypedDict +from typing import Any, TypedDict from localstack.utils.json import extract_jsonpath from localstack.utils.strings import to_str @@ -253,7 +253,7 @@ def _retrieve_parameter_from_invocation_request( ) def _retrieve_parameter_from_context_variables( - self, expr: str, context_variables: ContextVariables + self, expr: str, context_variables: dict[str, Any] ) -> str | None: # we're using JSON path here because we could access nested properties like `context.identity.sourceIp` return self._get_json_path_from_dict(context_variables, expr)