#prefix

finality-grandpa

PBFT-based finality gadget for blockchains

13 releases (6 breaking)

✓ Uses Rust 2018 edition

new 0.7.2 Apr 15, 2019
0.6.0 Jan 25, 2019
0.5.1 Dec 5, 2018
0.4.0 Nov 23, 2018
Download history 166/week @ 2018-12-31 304/week @ 2019-01-07 230/week @ 2019-01-14 207/week @ 2019-01-21 301/week @ 2019-01-28 219/week @ 2019-02-04 151/week @ 2019-02-11 192/week @ 2019-02-18 202/week @ 2019-02-25 201/week @ 2019-03-04 143/week @ 2019-03-11 398/week @ 2019-03-18 353/week @ 2019-03-25 251/week @ 2019-04-01 239/week @ 2019-04-08

1,020 downloads per month

GPL-3.0 license

162KB
3.5K SLoC

GRANDPA

GHOST-based Recursive ANcestor Deriving Prefix Agreement

A finality gadget for blockchains, implemented in Rust.

See https://github.com/w3f/consensus/blob/master/pdf/grandpa.pdf for a formal specification.


lib.rs:

Finality gadget for blockchains.

https://github.com/w3f/consensus/blob/master/pdf/grandpa.pdf

Consensus proceeds in rounds. Each round, voters will cast a prevote and precommit message.

Votes on blocks are then applied to the blockchain, being recursively applied to blocks before them. A DAG is superimposed over the blockchain with the vote_graph logic.

Equivocation detection and vote-set management is done in the round module. The work for actually casting votes is done in the voter module.

Dependencies

~2.5MB
~35K SLoC