Skip to content

Loosen the comparison for rdbd a little bit

Torsten Bögershausen requested to merge torsten/loosen-rbdb-for-rounding into master

test case 112 was sometimes failing, depending on the direction where we started. It turned out to be a rounding problem dealing with floating point variables, which can be reproduced in a python shell:

import math new_pos_half_way=85.0 act_pos2=84.96 math.fabs(act_pos2 - new_pos_half_way) 0.04000000000000625

And the value of rbdb was 0.04 Solution: loosen the comparison a little bit, allow 1% extra. Add a log at one place, and change a "<" into "<=" in 122

Merge request reports