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

More descriptive errors for precipitable_water #1926

Merged
merged 2 commits into from Jun 22, 2021

Conversation

23ccozad
Copy link
Contributor

@23ccozad 23ccozad commented Jun 21, 2021

In issue #1549, precipitable_water() raises an error because the pressure passed to top is outside the bounds of the pressure and dewpoint profiles, only because missing values have been removed. This PR provides more descriptive error messages, which could save some time for users who run into the same issue in the future.

Checklist

@dopplershift dopplershift added Area: Calc Pertains to calculations Type: Enhancement Enhancement to existing functionality labels Jun 21, 2021
@dopplershift dopplershift added this to the 1.1.0 milestone Jun 21, 2021
@23ccozad 23ccozad marked this pull request as ready for review June 22, 2021 15:25
Copy link
Member

@dopplershift dopplershift left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think chaining the comparisons makes this easier to parse, how about you?

src/metpy/calc/indices.py Outdated Show resolved Hide resolved
src/metpy/calc/indices.py Outdated Show resolved Hide resolved
@dopplershift dopplershift merged commit 9076dc8 into Unidata:main Jun 22, 2021
@23ccozad 23ccozad deleted the pwat_bounds branch June 28, 2021 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Calc Pertains to calculations Type: Enhancement Enhancement to existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bounds issue with precipitable water
2 participants