Skip to content

Commit

Permalink
fix some error after previous commits
Browse files Browse the repository at this point in the history
Signed-off-by: DONNOT Benjamin <[email protected]>
  • Loading branch information
BDonnot committed Nov 7, 2024
1 parent c30ac8a commit edc1565
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions grid2op/Chronics/_obs_fake_chronics_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def _kwargs(self):
def real_data(self):
raise EnvError("There are no time series in the observation from `obs.simulate`, so no `real_data`")

# functions overriden from the ChronicsHandler class
# # functions overriden from the ChronicsHandler class
def forecasts(self):
return []

Expand Down Expand Up @@ -130,7 +130,16 @@ def _prev_cache_id(self):
raise EnvError("There are no time series in the observation from `obs.simulate`, so no `_prev_cache_id`")

def done(self):
return True
"""
.. warning::
This function is part of the public API of ChronicsHandler,
by being accessible through the __getattr__ call that is
forwarded to the GridValue class
Agent can in theory simulate as many times as they want,
the "obs.simulate" call is never "done".
"""
return False

def check_validity(self, backend):
return True
Expand Down Expand Up @@ -251,6 +260,6 @@ def regenerate_with_new_seed(self):
"""
pass

def max_timestep(self):
raise EnvError("There are no time series in the observation from `obs.simulate`, so no `max_timestep`")
# def max_timestep(self):
# raise EnvError("There are no time series in the observation from `obs.simulate`, so no `max_timestep`")

0 comments on commit edc1565

Please sign in to comment.