Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
provide more context to errors (#92)
* reverse the order of checks in the DimensionalityError constructor * simplify the str method * add a custom exception for invalid units * use the new exception to present all invalid units at once * replace the custom class by a formatter * use the new formatter to collect and present unit errors * fix a leftover reference to the custom error class * synchronize DataArray quantify with Dataset quantify * more removing of the custom error classes * fix a bug in reindex and rely on convert_units to raise an error * fix most other methods * update whats-new.rst * fix a link [skip-ci] * explicitly parse the units * limit the errors caught in quantify to ValueError and UndefinedUnitError * remove the custom error class * actually call loc when expecting errors * also check whether the error for a invalid attribute is properly formatted * rewrite the tests for to
- Loading branch information