diff --git a/.github/workflows/python-lint.yml b/.github/workflows/python-lint.yml index 8d7f541..987d7f1 100644 --- a/.github/workflows/python-lint.yml +++ b/.github/workflows/python-lint.yml @@ -22,4 +22,4 @@ jobs: pip install -r requirements.txt - name: lint with ruff - run: ruff check --output-format=github . + run: ruff check --output-format=github -v . diff --git a/src/nextroute/schema/input.py b/src/nextroute/schema/input.py index bd363fc..9d4bfc6 100644 --- a/src/nextroute/schema/input.py +++ b/src/nextroute/schema/input.py @@ -30,8 +30,10 @@ class DurationGroup(BaseModel): group: List[str] """Stop IDs contained in the group.""" + class MatrixTimeFrame(BaseModel): """Represents a time-dependent duration matrix or scaling factor.""" + start_time: datetime """Start time of the time frame.""" end_time: datetime @@ -41,8 +43,10 @@ class MatrixTimeFrame(BaseModel): scaling_factor: Optional[float] = None """Scaling factor for the time frame.""" + class TimeDependentMatrix(BaseModel): """Represents time-dependent duration matrices.""" + vehicle_ids: Optional[List[str]] = None """Vehicle IDs for which the duration matrix is defined.""" default_matrix: List[List[float]] @@ -67,9 +71,15 @@ class Input(BaseModel): """Default values for vehicles and stops.""" distance_matrix: Optional[List[List[float]]] = None """Matrix of travel distances in meters between stops.""" - duratrion_groups: Optional[List[DurationGroup]] = None + duration_groups: Optional[List[DurationGroup]] = None """Duration in seconds added when approaching the group.""" - duration_matrix: Optional[Union[List[List[float]], TimeDependentMatrix, List[TimeDependentMatrix]]] = None + duration_matrix: Optional[ + Union[ + List[List[float]], + TimeDependentMatrix, + List[TimeDependentMatrix], + ] + ] = None """Matrix of travel durations in seconds between stops as a single matrix or duration matrices.""" options: Optional[Any] = None """Arbitrary options."""