From f7dbbcffe7747bc79c90084968b44b36108538fa Mon Sep 17 00:00:00 2001 From: Carsopre Date: Wed, 25 Oct 2023 18:26:03 +0000 Subject: [PATCH] chore: autoformat with isort & black --- koswat/cost_report/summary/koswat_summary.py | 12 +++++++++--- .../summary/koswat_summary_location_matrix.py | 2 ++ .../koswat_summary_location_matrix_builder.py | 1 + koswat/strategies/order_strategy/order_stategy.py | 2 +- koswat/strategies/strategy_input.py | 3 ++- koswat/strategies/strategy_location_matrix.py | 1 + .../profile/test_volume_cost_parameters_builder.py | 1 + 7 files changed, 17 insertions(+), 5 deletions(-) diff --git a/koswat/cost_report/summary/koswat_summary.py b/koswat/cost_report/summary/koswat_summary.py index b428fff6..fa81b792 100644 --- a/koswat/cost_report/summary/koswat_summary.py +++ b/koswat/cost_report/summary/koswat_summary.py @@ -1,12 +1,18 @@ from __future__ import annotations -from dataclasses import field, dataclass + +from dataclasses import dataclass, field from koswat.cost_report.multi_location_profile import MultiLocationProfileCostReport from koswat.dike.surroundings.point.point_surroundings import PointSurroundings from koswat.strategies.strategy_location_matrix import StrategyLocationReinforcements + @dataclass class KoswatSummary: - locations_profile_report_list: list[MultiLocationProfileCostReport] = field(default_factory=lambda: []) + locations_profile_report_list: list[MultiLocationProfileCostReport] = field( + default_factory=lambda: [] + ) available_locations: list[PointSurroundings] = field(default_factory=lambda: []) - reinforcement_per_locations: list[StrategyLocationReinforcements] = field(default_factory=lambda: []) \ No newline at end of file + reinforcement_per_locations: list[StrategyLocationReinforcements] = field( + default_factory=lambda: [] + ) diff --git a/koswat/cost_report/summary/koswat_summary_location_matrix.py b/koswat/cost_report/summary/koswat_summary_location_matrix.py index 2a1b5cb4..4a767731 100644 --- a/koswat/cost_report/summary/koswat_summary_location_matrix.py +++ b/koswat/cost_report/summary/koswat_summary_location_matrix.py @@ -1,5 +1,7 @@ from __future__ import annotations + from typing import Type + from koswat.dike.surroundings.point.point_surroundings import PointSurroundings from koswat.dike_reinforcements.reinforcement_profile.reinforcement_profile import ( ReinforcementProfile, diff --git a/koswat/cost_report/summary/koswat_summary_location_matrix_builder.py b/koswat/cost_report/summary/koswat_summary_location_matrix_builder.py index db45225e..5adc842a 100644 --- a/koswat/cost_report/summary/koswat_summary_location_matrix_builder.py +++ b/koswat/cost_report/summary/koswat_summary_location_matrix_builder.py @@ -1,4 +1,5 @@ import logging + from koswat.core.protocols.builder_protocol import BuilderProtocol from koswat.cost_report.multi_location_profile.multi_location_profile_cost_report import ( MultiLocationProfileCostReport, diff --git a/koswat/strategies/order_strategy/order_stategy.py b/koswat/strategies/order_strategy/order_stategy.py index 85978020..fb07591e 100644 --- a/koswat/strategies/order_strategy/order_stategy.py +++ b/koswat/strategies/order_strategy/order_stategy.py @@ -1,9 +1,9 @@ from collections import defaultdict from typing import Type + from koswat.cost_report.summary.koswat_summary_location_matrix import ( KoswatSummaryLocationMatrix, ) - from koswat.dike.surroundings.point.point_surroundings import PointSurroundings from koswat.dike_reinforcements.reinforcement_profile.outside_slope.cofferdam_reinforcement_profile import ( CofferdamReinforcementProfile, diff --git a/koswat/strategies/strategy_input.py b/koswat/strategies/strategy_input.py index e5046db5..b137e434 100644 --- a/koswat/strategies/strategy_input.py +++ b/koswat/strategies/strategy_input.py @@ -2,8 +2,9 @@ from koswat.cost_report.summary import koswat_summary_location_matrix_builder + @dataclass class StrategyInput: locations_matrix: koswat_summary_location_matrix_builder structure_buffer: float - min_space_between_structures: float \ No newline at end of file + min_space_between_structures: float diff --git a/koswat/strategies/strategy_location_matrix.py b/koswat/strategies/strategy_location_matrix.py index 9d172b1a..567ac7a3 100644 --- a/koswat/strategies/strategy_location_matrix.py +++ b/koswat/strategies/strategy_location_matrix.py @@ -1,5 +1,6 @@ from dataclasses import dataclass from typing import Type + from koswat.dike.surroundings.point.point_surroundings import PointSurroundings from koswat.dike_reinforcements.reinforcement_profile.reinforcement_profile_protocol import ( ReinforcementProfileProtocol, diff --git a/tests/cost_report/profile/test_volume_cost_parameters_builder.py b/tests/cost_report/profile/test_volume_cost_parameters_builder.py index 842a3cd1..606c0a33 100644 --- a/tests/cost_report/profile/test_volume_cost_parameters_builder.py +++ b/tests/cost_report/profile/test_volume_cost_parameters_builder.py @@ -92,6 +92,7 @@ def __init__(self) -> None: def _get_mocked_reinforcement(self) -> ReinforcementProfileProtocol: class MockedReinforcement(StandardReinforcementProfile): output_name: str = "Mocked reinforcement" + @property def new_ground_level_surface(self) -> float: return 42.0