easybuild-framework icon indicating copy to clipboard operation
easybuild-framework copied to clipboard

make `LooseVersion('1.0') == LooseVersion('1')`

Open Flamefire opened this issue 1 year ago • 1 comments

Remove the pitfall where missing components were filled with empty strings that are less than any other value.

The common expectation is that trailing zeroes are equal to zeroes. I don't think there is any case where 1.0 > 1 is intended

If the trailing part is a string the current behavior is kept.

See the changed test case where "# Careful here: 1.0 > 1 !!!" can be removed now.

Flamefire avatar Oct 24 '24 11:10 Flamefire