Skip to content

Commit c77a8a2

Browse files
committed
fix: protocol units structuring.
1 parent 6049ac1 commit c77a8a2

File tree

1,513 files changed

+5692
-1
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,513 files changed

+5692
-1
lines changed

protocol-units/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
`protocol-units` are used to collect runnable and composable units for interacting with the `ffs` protocol. We store contracts within protocol units, for example.
33

44
## Contents
5-
- **[`contracts`](./contracts/)**: contract-based implementations of the `ffs` protocol.
5+
- **[`mcr`](./mcr/)**: the `MCR` implementation of `ffs` provided prior to the specification of the `fast-confirmations` and `post-confirmations` protocols.
File renamed without changes.
File renamed without changes.

protocol-units/mcr/README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# MCR - Multi-Commit Rollup
2+
3+
**MCR** implements a staking-based settlement where validators commit L2-blocks on Layer 1 (L1).
4+
5+
Validators stake tokens to participate in block validation. They commit to L2-blocks on L1, and the contract on L1 tracks block commitments, epochs, and stake. The contracts also manage validators and custodian staking and unstaking. The contract validates if commitments have reached two-thirds supermajority stake, and rewards or slashes validators based on their actions.
6+
7+
For further details see the [RFC for MCR](https://github.com/movementlabsxyz/rfcs/pull/29) and the [MIP-34](https://github.com/movementlabsxyz/MIP/blob/main/MIP/mip-34).
8+
9+
## Architecture
10+
11+
- [Contracts](./contracts/README.md): Includes settlement contracts for block commitments, staking contracts for validator management, token contracts for custody.
12+
- **Manager**: Manages block commitments by batching and submitting them, interacts with clients, and processes commitment events (acceptance or rejection) for the settlement system.
13+
- **Setup**: Prepares local environments or deploys contracts, manages configuration for local and deployment setups, and ensures contract deployment when needed.
14+
- **Runner**: Orchestrates the setup and execution of configuration tasks, applies setup steps, and logs processes for debugging.
15+
- **Client**: Handles interaction with the MCR system by posting block commitments, streaming commitment data, and managing Ethereum blockchain interactions.
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
[package]
2+
name = "mcr-settlement-client"
3+
version = { workspace = true }
4+
edition = { workspace = true }
5+
license = { workspace = true }
6+
authors = { workspace = true }
7+
homepage = { workspace = true }
8+
publish = { workspace = true }
9+
rust-version = { workspace = true }
10+
11+
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
12+
# [[bin]]
13+
# name = "test-mcr-settlement-client"
14+
# path = "src/bin/e2e/test_client_settlement.rs"
15+
16+
17+
[dependencies]
18+
mcr-settlement-config = { workspace = true }
19+
movement-signer-loader = { workspace = true }
20+
movement-signer = { workspace = true }
21+
movement-signing-eth = { workspace = true }
22+
23+
alloy = { workspace = true, features = [
24+
"node-bindings",
25+
"rpc-types-trace",
26+
"json-rpc",
27+
"rpc-client",
28+
"signers",
29+
"signer-yubihsm",
30+
"pubsub",
31+
"providers",
32+
] }
33+
alloy-contract = { workspace = true }
34+
alloy-network = { workspace = true }
35+
alloy-primitives = { workspace = true }
36+
alloy-provider = { workspace = true, features = [] }
37+
alloy-signer = { workspace = true }
38+
alloy-sol-types = { workspace = true }
39+
alloy-transport = { workspace = true }
40+
alloy-transport-ws = { workspace = true }
41+
42+
anyhow = { workspace = true }
43+
async-stream = { workspace = true }
44+
async-trait = { workspace = true }
45+
serde_json = { workspace = true }
46+
movement-types = { workspace = true }
47+
thiserror = { workspace = true }
48+
tokio = { workspace = true }
49+
tokio-stream = { workspace = true }
50+
tracing = { workspace = true }
51+
serde = { workspace = true }
52+
53+
godfig = { workspace = true }
54+
55+
dot-movement = { workspace = true }
56+
alloy-rpc-types = { workspace = true }
57+
futures = { workspace = true }
58+
tracing-subscriber = { workspace = true }
59+
60+
[features]
61+
default = ["eth"]
62+
e2e = ["eth"]
63+
eth = []
64+
mock = []
65+
66+
[lints]
67+
workspace = true

protocol-units/mcr/client/abis/MCR.json

Lines changed: 1 addition & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)