Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'h_forecast' bug when creating env without forecast for l2rpn_idf_2023 #593

Closed
marota opened this issue Mar 13, 2024 · 4 comments
Closed
Labels
bug Something isn't working

Comments

@marota
Copy link
Contributor

marota commented Mar 13, 2024

Environment

  • Grid2op version: 1.9.8
  • System: ubuntu20.04, ...

Bug description

When loading the environemnt l2rpn_idf_2023 without forecast, this error is returned:

TypeError: init() got an unexpected keyword argument 'h_forecast'

How to reproduce

Code snippet

import grid2op
from grid2op.Chronics import GridStateFromFile

env = grid2op.make("l2rpn_idf_2023",
                   data_feeding_kwargs={"gridvalueClass": GridStateFromFile})

Current output

TypeError: __init__() got an unexpected keyword argument 'h_forecast'

Expected output

No error should be returned, and the h_forecast parameter should be disregarded in this case when not considering forecasts.
@marota marota added the bug Something isn't working label Mar 13, 2024
@BDonnot
Copy link
Collaborator

BDonnot commented Mar 13, 2024

To deactivate the forecast you can also do :
youhttps://grid2op.readthedocs.io/en/latest/environment.html#grid2op.Environment.BaseEnv.deactivate_forecast

(and I'll fix this ASAP)

@marota
Copy link
Contributor Author

marota commented Mar 14, 2024

That's indeed a workaround I was thinking about, I can confirm it to IRT now, thanks!

@BDonnot
Copy link
Collaborator

BDonnot commented Mar 14, 2024

Ideally both should be done for maximum performance. I'll work on the fix asap

@BDonnot
Copy link
Collaborator

BDonnot commented Mar 18, 2024

Fixed in 1.10.1 :-)

@BDonnot BDonnot closed this as completed Mar 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants