Skip to content

Commit

Permalink
Changed error message to be more descriptive in try_to_get_dfs.
Browse files Browse the repository at this point in the history
  • Loading branch information
BrianWeiHaoMa committed Dec 24, 2024
1 parent e9c6038 commit c7a141f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions MISOReports/test_MISOReports.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def try_to_get_dfs(
report_name: str,
datetime_increment_limit: int,
number_of_dfs_to_stop_at: int,
) -> Generator[tuple[pd.DataFrame, datetime.datetime], None, None]:
) -> Generator[tuple[pd.DataFrame, datetime.datetime | None], None, None]:
"""Tries to get the df for report_name and returns
it with its respective target datetime. If a request
fails, it will increment the datetime and try again
Expand Down Expand Up @@ -88,7 +88,7 @@ def try_to_get_dfs(
increment_cnt += 1
except Exception as e:
raise Exception(
f"Unexpected exception for {report_name} at "
f"Unexpected exception for {report_name} at datetime="
+ f"{curr_target_datetime}: {e}"
)

Expand Down

0 comments on commit c7a141f

Please sign in to comment.