Skip to content

Convert a lone UCUM annotation to unity - #86

Merged
dalito merged 2 commits into
mainfrom
fix-lone-annotation
Nov 6, 2026
Merged

dalito merged 2 commits into
mainfrom
fix-lone-annotation

Conversation

@dalito

@dalito dalito commented Nov 6, 2026

Copy link
Copy Markdown
Owner

A UCUM code that is only an annotation, e.g. {rbc}, now gives a dimensionless 1 from from_ucum and ucum_preprocessor, as UCUM defines.

Also adds Python 3.15 to the CI test matrix and the classifiers.

Closes #85

An annotation without a unit, e.g. {rbc}, reached main_term as the bare
ANNOTATION token: UcumToPintTransformer returned the token and
UcumToPintStrTransformer returned "({rbc})", which pint cannot parse.
@dalito dalito added the bug Something isn't working label Nov 6, 2026
@dalito
dalito merged commit a9244b0 into main Nov 6, 2026
6 checks passed
@dalito
dalito deleted the fix-lone-annotation branch November 6, 2026 00:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Lone annotation like {rbc} is not converted to unity

1 participant