Skip to content

Commit

Permalink
Update dependencies to fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
Zach Price committed Nov 26, 2024
1 parent 75272f4 commit 05d098e
Show file tree
Hide file tree
Showing 5 changed files with 114 additions and 356 deletions.
2 changes: 1 addition & 1 deletion esg_fastapi/api/versions/v1/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ class ESGSearchQuery(BaseModel):
"""Grid label of the dataset."""
grid_resolution: MultiValued[str] | None = None
"""Grid resolution of the dataset."""
height_units: Annotated[MultiValued[str], Query(alias="height-units")] | None = None
height_units: MultiValued[str] | None = Query(alias="height-units", default=None)
"""Height units of the dataset."""
index_node: MultiValued[str] | None = None
"""Index node of the dataset."""
Expand Down
4 changes: 1 addition & 3 deletions esg_fastapi/api/versions/v1/types.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
from collections.abc import Sequence
from typing import TYPE_CHECKING, Annotated, Any, Callable, ForwardRef, Mapping
from typing import TYPE_CHECKING, Annotated, Any, Callable, ForwardRef

from annotated_types import T
from fastapi import Query
from pydantic import AfterValidator, BeforeValidator, GetJsonSchemaHandler, PlainSerializer
from pydantic.fields import FieldInfo
from pydantic.json_schema import JsonSchemaValue
from pydantic_core import CoreSchema
from pydantic_core.core_schema import (
Expand Down Expand Up @@ -35,7 +34,6 @@
MultiValued = Annotated[list[T], BeforeValidator(ensure_list), Query()]
"""Solr MultiValued Field of the parameterized type."""


LowerCased = Annotated[T, PlainSerializer(lambda x: x.lower())]
"""Lower-case string representation of the parameterized type."""

Expand Down
Loading

0 comments on commit 05d098e

Please sign in to comment.