-
Notifications
You must be signed in to change notification settings - Fork 15
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
Implement NoDataStrategy to deal with optional setup_functions #229
Conversation
Stable tests are failing, because I believe that they do no yet use the latest version of hydromt (v0.9.3). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the good work! LGTM. I'd only request that setup_reservoirs
is structured the same in this regard as the other methods.
hydromt_wflow/wflow.py
Outdated
else: | ||
self.logger.info("Skipping method, as no data has been found") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd say, for consistency's sake, make this the same as the other methods, i.e.:
if ... is None:
logger.warning(< warning message >)
return
I'm excited about a new release. It would be great to have water level management and inflow/outflow calculations for lakes/reservoirs (if possible). It would also be nice if the created toml file at model build stage includes, e.g. lake = "wflow_lakelocs" and reservoir = "wflow_reservoirlocs" to reduce a manual model build step. The reservoir model build has been an exciting new addition to the model. Thanks for all the updates! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Issue addressed
Fixes #208, but needs Deltares/hydromt#731 to be fixed in order to work.
Explanation
Implemented a NoDataStrategy that ignores errors for the optional setup function (lakes, reservoirs, glacier and gauges). Now a warning is returned (in stead of an error), similar to the old behavior of hydromt_wflow. However, as the NoDataStrategy is currently incomplete in HydroMT-core, we need Deltares/hydromt#731 to be fixed before this fix works.
Checklist
main