Summary
This patch release address an issue in Event Handler REST API to support dynamic routes with an equal sign (=
).
Big thanks to @baraksalomon for the bug report!
Previously, a dynamic route containing =
would result in a not found response (HTTP 404).
Example
from aws_lambda_powertools.event_handler import APIGatewayRestResolver
from aws_lambda_powertools.utilities.typing import LambdaContext
app = APIGatewayRestResolver()
# NOTE: `/token/bXl0b2tlbg==` should be matched and not return 404 now
@app.get("/token/<token>")
def get_token(token: str):
return {"received": f"{token}"}
def lambda_handler(event: dict, context: LambdaContext) -> dict:
return app.resolve(event, context)
Changes
🐛 Bug and hot fixes
- fix(apigateway): support dynamic routes with equal sign (RFC3986) (#1737) by @heitorlessa
🔧 Maintenance
- chore(deps-dev): bump mypy-boto3-xray from 1.26.9 to 1.26.11.post1 (#1734) by @dependabot
This release was made possible by the following contributors:
@dependabot, @dependabot[bot], @heitorlessa and Release bot