Something is wrong with the display of units when a composed unit is used. For example, if we do display(length_unit), displaying a speed unit will get a little confused and change the display unit but not the display value.
Steps:
>>> knot
knot # speed, 0.5144444444444445 m / s
>>> knot(1)
0.5144444444444445 m / s # speed
>>> display(mile)
Observed results:
>>> knot
knot # speed, 0.5144444444444445 mi / s
>>> knot(1)
0.5144444444444445 mi / s # speed
See how mi is somehow taken, but not the inherent value modifier.
Expected results (obtained with @ mile/second):
>>> knot
0.0003196609577843174 mi / s # speed
This could do with a unit test.
Obviously #1 needs fixing such that mile / hour is the canonical imperial display speed, but this numerical inaccuracy is a serious bug that must be fixed.
In-development bug.
Something is wrong with the display of units when a composed unit is used. For example, if we do
display(length_unit)
, displaying a speed unit will get a little confused and change the display unit but not the display value.Steps:
Observed results:
See how
mi
is somehow taken, but not the inherent value modifier.Expected results (obtained with
@ mile/second
):This could do with a unit test.
Obviously #1 needs fixing such that
mile / hour
is the canonical imperial display speed, but this numerical inaccuracy is a serious bug that must be fixed.