mirror of
https://github.com/status-im/sourcecred.git
synced 2025-03-01 12:40:33 +00:00
This commit modifies `markovChain.findStationaryDistribution` so that in addition to returning the final distribution, it also reports the final convergence delta. This is motivated by the proposed API for the new PagerankGraph (see [#1020]). Also, I think it makes a nice addition to the test code. Note that this slightly changes the output from `findStationaryDistribution`, because we now return the first distribution that is sufficiently converged, rather than that distribution with one additional Markov action. Test plan: Unit tests are updated, and `yarn test` passes. [#1020]: https://github.com/sourcecred/sourcecred/issues/1020 Thanks to @BrianLitwin for semi-pair-programming it Thanks to @wchargin for extensive review feedback.