Skip to content

Commit

Permalink
fix mypy typings using sequence instead of list
Browse files Browse the repository at this point in the history
  • Loading branch information
fmigneault committed May 2, 2024
1 parent 2eb6392 commit e1af1ef
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions stac_model/input.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from typing import Annotated, Any, List, Literal, Optional, TypeAlias, Union
from typing import Annotated, Any, List, Literal, Optional, Sequence, TypeAlias, Union
from typing_extensions import Self

from pydantic import Field, model_validator
Expand Down Expand Up @@ -88,7 +88,7 @@ def validate_expression(self) -> Self:
class ModelInput(MLMBaseModel):
name: str
# order is critical here (same index as dim shape), allow duplicate if the model needs it somehow
bands: List[Union[str, ModelBand]] = Field(
bands: Sequence[Union[str, ModelBand]] = Field(
description=(
"List of bands that compose the input. "
"If a string is used, it is implied to correspond to a named-band. "
Expand Down

0 comments on commit e1af1ef

Please sign in to comment.