Skip to content

Commit d841b4f

Browse files
committed
docs: fix highlight lefovers
1 parent ebf4f3b commit d841b4f

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

docs/core/event_handler/api_gateway.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -379,7 +379,7 @@ This will enable full tracebacks errors in the response, print request and respo
379379

380380
You can instruct API Gateway handler to use a custom serializer to best suit your needs, for example take into account Enums when serializing.
381381

382-
```python hl_lines="36 41" title="Using a custom JSON serializer for responses"
382+
```python hl_lines="35 40" title="Using a custom JSON serializer for responses"
383383
--8<-- "examples/event_handler_rest/src/custom_serializer.py"
384384
```
385385

@@ -427,7 +427,7 @@ When necessary, you can set a prefix when including a router object. This means
427427

428428
This is a sample project layout for a monolithic function with routes split in different files (`/todos`, `/health`).
429429

430-
```shell hl_lines="1 8 10 12-15" title="Sample project layout"
430+
```shell hl_lines="4 7 10 12-13" title="Sample project layout"
431431
.
432432
├── pyproject.toml # project app & dev dependencies; poetry, pipenv, etc.
433433
├── poetry.lock

examples/event_handler_rest/src/not_found_routes.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
import requests
2-
from requests import Response
32

43
from aws_lambda_powertools import Logger, Tracer
5-
from aws_lambda_powertools.event_handler import APIGatewayRestResolver, content_types
4+
from aws_lambda_powertools.event_handler import APIGatewayRestResolver, Response, content_types
65
from aws_lambda_powertools.event_handler.exceptions import NotFoundError
76
from aws_lambda_powertools.logging import correlation_paths
87
from aws_lambda_powertools.utilities.typing import LambdaContext
@@ -22,7 +21,7 @@ def handle_not_found_errors(exc: NotFoundError) -> Response:
2221
@app.get("/todos")
2322
@tracer.capture_method
2423
def get_todos():
25-
todos: Response = requests.get("https://jsonplaceholder.typicode.com/todos")
24+
todos: requests.Response = requests.get("https://jsonplaceholder.typicode.com/todos")
2625
todos.raise_for_status()
2726

2827
# for brevity, we'll limit to the first 10 only

0 commit comments

Comments
 (0)