Calc decayed buckets to decide if we have valid historical points
authorMatt Corallo <git@bluematt.me>
Mon, 16 Jan 2023 23:18:39 +0000 (23:18 +0000)
committerMatt Corallo <git@bluematt.me>
Mon, 30 Jan 2023 22:32:06 +0000 (22:32 +0000)
commit30060c18b375a277fc11c4f601cbdeab07723c39
treedfa4249f32eefb1245f1349597d4a0cc56fdeb8a
parent869b71dccf1b6d22895067d461a408ac37012a26
Calc decayed buckets to decide if we have valid historical points

When we're calculating if, once we apply the unupdated decays, the
historical data tracker has enough data to assign a score, we
previously calculated the decayed points while walking the buckets
as we don't use the decayed buckets anyway (to avoid losing
precision). That is fine, except that as written it decayed
individual buckets additional times.

Instead, here we actually calculate the full set of decayed buckets
and use those to decide if we have valid points. This adds some
additional stack space and may in fact be slower, but will be
useful in the next commit and shouldn't be a huge change.
lightning/src/routing/scoring.rs