Author Topic: New fork resolution algorithm in bitshares_toolkit  (Read 1314 times)

0 Members and 1 Guest are viewing this topic.

Offline sparkles

  • Full Member
  • ***
  • Posts: 107
    • View Profile
I will look into merging your latest code.

Offline dannotestein

  • Hero Member
  • *****
  • Posts: 760
    • View Profile
    • BlockTrades International
  • BitShares: btsnow
Hi sparkles,

I've pushed a rewritten fork resolution algorithm to bitshares_toolkit repo (https://github.com/BitShares/bitshares/commit/96e00d39e8e41163a93310db369cd8c490e74589).

Originally I planned to make patches to the old algorithm, but I found it had serious flaws both in resolving to the longest fork in all cases and in terms of performance, so I went for a clean rewrite. I have performed various manual tests on the new algorithm which all passed fine. Unfortunately, a DPOS chain doesn't present a lot of easy tests for fork resolution code (not many forks get generated), but I still strongly recommend you try the new algorithm on the sparkles blockchain now. Please let me know if you find any problems with the new algorithm and I can assist in resolving them.
http://blocktrades.us Fast/Safe/High-Liquidity Crypto Coin Converter