Commit graph

30 commits

Author SHA1 Message Date
Luke Parker
5e52817dcd
Modularize to get_proposal 2022-10-22 00:47:38 -04:00
Luke Parker
bf5bdb89c2
Implement block proposal logic 2022-10-21 23:36:24 -04:00
Luke Parker
422f7e3e2f
Replace panicking todos with stubs and // TODO
Enables progress.
2022-10-21 21:14:05 -04:00
Luke Parker
0218db0084
Update SelectChain documentation 2022-10-21 05:53:15 -04:00
Luke Parker
123b8ad11b
Tendermint SelectChain
This is incompatible with Substrate's expectations, yet should be valid 
for ours
2022-10-21 05:28:26 -04:00
Luke Parker
976948e9d9
Update Cargo.tomls for substrate packages 2022-10-21 03:17:02 -04:00
Luke Parker
c0432e122c
Update consensus/lib.rs from PoW to Tendermint
Not possible to be used as the previous consensus could. It will not
produce blocks nor does it currenly even instantiate a machine. This is
just he next step.
2022-10-21 02:38:06 -04:00
Luke Parker
3b08633445
BlockImport, JustificationImport, Verifier, and import_queue function 2022-10-21 02:18:51 -04:00
Luke Parker
bdd0b42419
Move logic into TendermintImport itself
Multiple traits exist to verify/handle blocks. I'm unsure exactly when 
each will be called in the pipeline, so the easiest solution is to have 
every step run every check.

That would be extremely computationally expensive if we ran EVERY check, 
yet we rely on Substrate for execution (and according checks), which are 
limited to just the actual import function.

Since we're calling this code from many places, it makes sense for it to 
be consolidated under TendermintImport.
2022-10-21 02:17:40 -04:00
Luke Parker
56afb13ed5
Move documentation to the top of the file 2022-10-21 02:14:48 -04:00
Luke Parker
2cf1573c52
Dummy Weights 2022-10-21 02:13:44 -04:00
Luke Parker
5c46edbe98
Implement tendermint_machine::Block for Substrate Blocks
Unfortunately, this immediately makes Tendermint machine capable of 
deployment as  crate since it uses a git reference. In the future, a 
Cargo.toml patch section for serai/substrate should be investigated. 
This is being done regardless as it's the quickest way forward and this 
is for Serai.
2022-10-21 02:06:48 -04:00
Luke Parker
280683142a
Rename import to import_queue 2022-10-20 04:28:26 -04:00
Luke Parker
49a26e5841
Properly use check_block 2022-10-20 04:27:53 -04:00
Luke Parker
eb59dd5a55
Initial work on an import queue 2022-10-20 03:50:06 -04:00
Luke Parker
975c9d7456
Map TM SignatureScheme to Substrate's sr25519 2022-10-20 03:46:09 -04:00
Luke Parker
cc8284ad40
Merge branch 'develop' into tendermint 2022-10-20 01:34:59 -04:00
Luke Parker
ccd4ef193c
Move substrate/consensus/tendermint to substrate/tendermint 2022-10-16 01:32:54 -04:00
Luke Parker
19488cf446
Fill out Cargo.tomls
Updated missing fields/sections, even if some won't be used, to 
standardize.

Also made FROST tests feature-gated.
2022-10-15 23:46:22 -04:00
Luke Parker
d081934725
Time code 2022-10-12 21:36:40 -04:00
Luke Parker
b56c88468e
Machine without timeouts 2022-10-02 23:23:58 -04:00
Luke Parker
482a8ec209
Update to the latest Serai Substrate (#125)
* Update to the latest Serai Substrate

* Add Protobuf to build dependencies

Docker shouldn't need updating as this should've been added to the image 
in 
2dbace5b01.

* Get substrate to build

* Correct protoc build step

* Remove the benchmarking code

There's some macro resolution error that isn't apparent. I worked on it 
for about half an hour but...

* Remove unnecessary clone

* Correct runtime-benchmarks flag usage
2022-09-29 13:33:09 -05:00
Luke Parker
546b772be3
Clarify licensing per https://github.com/serai-dex/serai/issues/13
Implements bullets 2-4 of 
https://github.com/serai-dex/serai/issues/13#issuecomment-1212689876.
2022-08-25 04:02:13 -04:00
Luke Parker
755dc84859
Replace rand with rand_core where possible
Turns out rand_core offers OsRng.
2022-07-27 05:45:08 -04:00
Luke Parker
3711e13009
Remove old duplicates of the AGPL-3.0 2022-07-24 09:33:08 -04:00
Luke Parker
76a7160ea5
Correct clippy warnings
Currently intended to be done with:
cargo clippy --features "recommended merlin batch serialize experimental 
ed25519 ristretto p256 secp256k1 multisig" -- -A clippy::type_complexity 
-A dead_code
2022-07-22 02:35:17 -04:00
Luke Parker
9cb2d8aa4a
Integrate ink! 2022-07-16 21:06:54 -04:00
Luke Parker
314c9cd8f7
Clean Substrate Cargo.tomls 2022-07-16 20:53:28 -04:00
Luke Parker
e67033a207 Apply an initial set of rustfmt rules 2022-07-16 15:16:30 -05:00
Luke Parker
0b879a53fa
Add an initial Substrate instantiation
Consensus has been nuked for an AcceptAny currently routed throough PoW 
(when it doesn't have to be, doing so just took care of a few pieces of 
leg work).

Updates AGPL handling.
2022-07-15 00:05:00 -04:00