-
Notifications
You must be signed in to change notification settings - Fork 35
Description
A recent fqm-execution issue (#352)[https://github.com/projecttacoma/fqm-execution/issues/352]. Uncovered an issue with comparison of unconvertible units in a GreaterOrEqual comparison of Quantity for [IU]/mL. ex logic:
Dalteparin.dosage ( ) >= 10000 '[IU]/mL'
The result of Datleparin.dosage ( ) is a Quantity 10000 '[IU]/mL'. It seems like this logic should result in true for the comparison, but it results in null. On deeper inspection this is occurring because the comparison logic for Quantity in the engine is converting the units even though they are the "same". The UCUM library we use refuses to convert [IU]/mL to [IU]/mL with the response "Attempt to convert arbitrary unit international unit per milliliter". This appears to be considered arbitrary because [IU] is different depending on the chemical.
This raises two questions?
- Is this actually correct that it should throw a fit here and return
nullfor this Quantity comparison of[IU]/mLto[IU]/mL? - Should Quantity comparisons of the same exact
unitactually skip past the conversion stop?