-
Notifications
You must be signed in to change notification settings - Fork 12
support for "no unit" values #125
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
Conversation
Creating a pint.Unit instance directly will create it from the default registry, so the first and second TODO comments actually referred to the same issue. We also decided to have specific packages (i.e. cf-xarray) provide the unit registry.
|
fine with me. Seems like we shouldn't put this in |
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 @keewis - the only other thing I would add is some kind of example or note in the documentation to show this feature, beyond just the note in the quantify docstring.
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.
Looks good to me!
great, let's merge. I'll try to create a few more PRs with small fixes, merge #110 and then issue a minor release. |
This exposes the internal use of
None
as a "no unit" value and adds the new values requested in #118 (I skipped the integer1
for now but it should be a single line change to add it).cc @dcherian, @jbusecke
pre-commit run --all-files
whats-new.rst
New functions/methods are listed inapi.rst