Skip to content

Commit

Permalink
fixup: feedback 1
Browse files Browse the repository at this point in the history
  • Loading branch information
soofstad committed May 3, 2023
1 parent b9c035b commit 2d55ee2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions api/src/common/middleware.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ async def __call__(self, scope, receive, send):
path = scope["path"]
response = {}

async def innner_send(message):
async def inner_send(message):
nonlocal response
if message["type"] == "http.response.start":
response = message
Expand All @@ -74,7 +74,7 @@ async def innner_send(message):
with tracer.span("main") as span:
span.span_kind = SpanKind.SERVER

await self.app(scope, receive, innner_send)
await self.app(scope, receive, inner_send)

tracer.add_attribute_to_current_span(
attribute_key=COMMON_ATTRIBUTES["HTTP_STATUS_CODE"], attribute_value=response["status"]
Expand Down
2 changes: 1 addition & 1 deletion api/src/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ class Config(BaseSettings):

# Logging
LOGGER_LEVEL: str = Field("INFO", env="LOGGING_LEVEL", to_lower=True)
APPINSIGHTS_CONSTRING: str = Field(None, env="APPINSIGHTS_CONSTRING")
APPINSIGHTS_CONSTRING: str | None = Field(None, env="APPINSIGHTS_CONSTRING")

# Database
MONGODB_USERNAME: str = Field("dummy", env="MONGODB_USERNAME")
Expand Down

0 comments on commit 2d55ee2

Please sign in to comment.