Fantom Technical Update 12
By Michael Kong
Go-Lachesis
New consensus implementation based on modified version of early Lachesis, including fast gossip implementation for more efficient transfer of events between nodes: https://github.com/Fantom-foundation/go-lachesis/commit/232ea6b15af9e0cae46411ae6fe152900dfc3e1e
Identified a number of quality issues with recently added code into go-lachesis, fixed some and reported the rest as issues;
https://github.com/Fantom-foundation/go-lachesis/issues/210
https://github.com/Fantom-foundation/go-lachesis/issues/211
https://github.com/Fantom-foundation/go-lachesis/issues/212
https://github.com/Fantom-foundation/go-lachesis/issues/230
https://github.com/Fantom-foundation/go-lachesis/issues/231
https://github.com/Fantom-foundation/go-lachesis/issues/232
Restored `testnet` test in Travis;
https://github.com/Fantom-foundation/go-lachesis/commit/24b5e93102e086217c0bf8c5ceb5575b232330dc
Developed a schema of possible Byzantine attack on go-lachesis and reported it as an issue;
https://github.com/Fantom-foundation/go-lachesis/issues/253
Rust
- Defined `libconsensus` and `libtransport`, for abstract consensus — Raft (for benchmarking against), Fantom-consensus, and various transport protocol (TCP, SCTP), RPCs, and UDP.
https://github.com/Fantom-foundation/libtransport
https://github.com/Fantom-foundation/libtransport-rpc
https://github.com/Fantom-foundation/libtransport-http
https://github.com/Fantom-foundation/libconsensus - Made number of fixes into tests to allow Travis effectively control quality of PRs;
https://github.com/Fantom-foundation/go-lachesis/commit/ff2533cec50f0cd6cb3ae936468dee87d2393239
https://github.com/Fantom-foundation/go-lachesis/commit/4c18395d4d13a9f81ba774b11ad74c191d81871a - [WIP] Research into feasibility of DAG-based asynchronous consensus architecture that able to track node failure.
- Raft-rs integration for benchmarking and testing against:
https://github.com/Fantom-foundation/libconsensus-raft-rs - Finished representation in memory of modifiers for solidity.
https://github.com/Fantom-foundation/libvm-rs
https://github.com/Fantom-foundation/solidity-rs - Refactored code to remove unnecessary complexity by using default null values instead of complicated Result<Option<Value>, Error> types when code/type generating.
- Working on expressions to try to figure out how to add side effects.
Research
- Learned TLA+
- Researched TLA+ consensus specs online.
- Started a Coq development of the theory of Concurrent Common Knowledge (CCK) intended as a dependency for proofs about our DAG consensus. Using CertiChain and ToyChain as a reference.
- Started designing how modifiers will be _called_ in memory and how to use placeholder statement.
https://github.com/Fantom-foundation/solidity-rs/commit/97d47bae892a160ace3a9e584374d97b5d2f05ac - Similar work with functions to make them work with modifiers.
https://github.com/Fantom-foundation/solidity-rs/commit/8fc90863c66dd4ae20c6dc1f6715d57c6187b2f7
https://github.com/Fantom-foundation/solidity-rs/commit/4d0d17315c60b8341069de1669f9cc75c9950036 - Formalising the CCK paper, proved some lemmas needed for the type class hierarchy of Ssreflect to function
https://www.cs.mcgill.ca/~prakash/Pubs/cck.pdf