Skip to content

Commit

Permalink
Format.
Browse files Browse the repository at this point in the history
Signed-off-by: Bart Pleiter <[email protected]>
  • Loading branch information
bartpleiter committed Dec 11, 2023
1 parent 2f681c0 commit 531c7d3
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion openstef/tasks/create_forecast.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def create_forecast_task(pj: PredictionJobDataClass, context: TaskContext) -> No
return
elif isinstance(e, InputDataOngoingZeroFlatlinerError):
raise InputDataOngoingZeroFlatlinerError(
"All recent load measurements are zero. Check the load profile of this pid as well as related/neighbouring prediction jobs. Afterwards, consider adding this pid to the "known_zero_flatliners" app_setting and possibly removing other pids from the same app_setting."
'All recent load measurements are zero. Check the load profile of this pid as well as related/neighbouring prediction jobs. Afterwards, consider adding this pid to the "known_zero_flatliners" app_setting and possibly removing other pids from the same app_setting.'
) from e
elif isinstance(e, LookupError):
raise LookupError(
Expand Down
2 changes: 1 addition & 1 deletion openstef/tasks/train_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ def train_model_task(
return
else:
raise InputDataOngoingZeroFlatlinerError(
"All recent load measurements are zero. Check the load profile of this pid as well as related/neighbouring prediction jobs. Afterwards, consider adding this pid to the "known_zero_flatliners" app_setting and possibly removing other pids from the same app_setting."
'All recent load measurements are zero. Check the load profile of this pid as well as related/neighbouring prediction jobs. Afterwards, consider adding this pid to the "known_zero_flatliners" app_setting and possibly removing other pids from the same app_setting.'
)


Expand Down
2 changes: 1 addition & 1 deletion test/unit/tasks/test_create_forecast.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ def test_create_forecast_unexpected_zero_flatliner(self):

assert (
e.value.args[0]
== "All recent load measurements are zero. Check the load profile of this pid as well as related/neighbouring prediction jobs. Afterwards, consider adding this pid to the "known_zero_flatliners" app_setting and possibly removing other pids from the same app_setting."```
== 'All recent load measurements are zero. Check the load profile of this pid as well as related/neighbouring prediction jobs. Afterwards, consider adding this pid to the "known_zero_flatliners" app_setting and possibly removing other pids from the same app_setting.'
)

@patch(
Expand Down
2 changes: 1 addition & 1 deletion test/unit/tasks/test_train_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ def test_train_model_unexpected_zero_flatliner(self):
train_model_task(self.pj, context)
self.assertEqual(
e.value.args[0],
"All recent load measurements are zero. Check the load profile of this pid as well as related/neighbouring prediction jobs. Afterwards, consider adding this pid to the "known_zero_flatliners" app_setting and possibly removing other pids from the same app_setting.",
'All recent load measurements are zero. Check the load profile of this pid as well as related/neighbouring prediction jobs. Afterwards, consider adding this pid to the "known_zero_flatliners" app_setting and possibly removing other pids from the same app_setting.',
)

@patch("openstef.model.serializer.MLflowSerializer.save_model")
Expand Down

0 comments on commit 531c7d3

Please sign in to comment.