Skip to content

Commit 6d0f347

Browse files
committed
pylint
1 parent d30f4dd commit 6d0f347

3 files changed

Lines changed: 3 additions & 5 deletions

File tree

decoimpact/business/entities/rules/time_aggregation_rule.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ def execute(self, value_array: _xr.DataArray, logger: ILogger) -> _xr.DataArray:
105105
value_array = value_array.sel({time_dim_name: slice_obj})
106106
grouped_values = value_array.groupby(f"{time_dim_name}.month")
107107
result = self._perform_grouping_operation(
108-
grouped_values, settings.operation_type, time_dim_name
108+
grouped_values, settings.operation_type
109109
)
110110
# create a new aggregated time dimension based on original time dimension
111111
result_time_dim_name = f"{time_dim_name}_monthly"
@@ -136,7 +136,6 @@ def _perform_grouping_operation(
136136
self,
137137
grouped_values,
138138
operation_type: TimeOperationType,
139-
time_dim_name: str,
140139
) -> _xr.DataArray:
141140
"""Returns the values based on the grouping operation type
142141

decoimpact/data/api/i_time_aggregation_rule_data.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,7 @@
1414

1515

1616
from abc import ABC, abstractmethod
17-
18-
from pyparsing import Optional
17+
from typing import Optional
1918

2019
from decoimpact.data.api.i_rule_data import IRuleData
2120
from decoimpact.data.api.time_operation_type import TimeOperationType

tests/business/entities/rules/test_time_aggregation_rule.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -464,7 +464,7 @@ def test_multi_year_monthly_average():
464464

465465

466466
def test_multi_yearly_month_average_with_year_range():
467-
"""Aggregate input_variable_names of a TimeAggregationRule (average, months) with year range"""
467+
"""Aggregate multi-year monthly average of a TimeAggregationRule with year range"""
468468

469469
# create test set
470470
logger = Mock(ILogger)

0 commit comments

Comments
 (0)