You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<!--Please ensure the PR fulfills the following requirements! -->
<!-- If this is your first PR, make sure to add your details to the
AUTHORS.rst! -->
### Pull Request Checklist:
- [x] This PR addresses an already opened issue (for bug fixes /
features)
- This PR fixes#1456
- [x] Tests for the changes have been added (for bug fixes / features)
- [x] (If applicable) Documentation has been added / updated (for bug
fixes / features)
- [x] CHANGES.rst has been updated (with summary of main changes)
- [x] Link to issue (:issue:`number`) and pull request (:pull:`number`)
has been added
### What kind of change does this PR introduce?
* Fixes the `raise_flags` argument of `xclim.core.dataflags.data_flags`
so that an Exception is only raised when some checkups fail.
### Does this PR introduce a breaking change?
- No
### Other information:
Setup Information
Description
When using
xclim.core.dataflags.data_flags
, an exception will always be raised whenraise_flags=True
.Steps To Reproduce
Gives:
Additional context
I'm pretty sure that the culprit is
xclim/xclim/core/dataflags.py
Line 695 in 7451885
It currently gives:
Which I'm guessing gets interpreted as a
True
. Something likenp.any([dsflags[v].values for v in dsflags.data_vars])
would give the correctFalse
.Contribution
Code of Conduct
The text was updated successfully, but these errors were encountered: