Skip to content

Commit 428890d

Browse files
authored
Merge branch 'main' into main
2 parents ce21248 + da4579d commit 428890d

Some content is hidden

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

74 files changed

+17180
-1631
lines changed

.github/workflows/build-and-test.yml

Lines changed: 77 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ jobs:
3131
wget https://github.com/casey/just/releases/download/1.14.0/just-1.14.0-x86_64-unknown-linux-musl.tar.gz
3232
tar -vxf just-1.14.0-x86_64-unknown-linux-musl.tar.gz just
3333
sudo cp just /usr/bin/just
34+
- name: Install rustfmt for nightly
35+
run: rustup component add --toolchain nightly rustfmt
36+
- name: Install Foundry
37+
uses: foundry-rs/foundry-toolchain@v1
3438
- name: Install protobuf compiler
3539
run: |
3640
sudo apt-get update
@@ -60,6 +64,10 @@ jobs:
6064
wget https://github.com/casey/just/releases/download/1.14.0/just-1.14.0-x86_64-unknown-linux-musl.tar.gz
6165
tar -vxf just-1.14.0-x86_64-unknown-linux-musl.tar.gz just
6266
sudo cp just /usr/bin/just
67+
- name: Install rustfmt for nightly
68+
run: rustup component add --toolchain nightly rustfmt
69+
- name: Install Foundry
70+
uses: foundry-rs/foundry-toolchain@v1
6371
- name: Run tests
6472
run: just test_ci
6573

@@ -81,12 +89,14 @@ jobs:
8189
sudo cp just /usr/bin/just
8290
- name: Install rustfmt for nightly
8391
run: rustup component add --toolchain nightly rustfmt
92+
- name: Install Foundry
93+
uses: foundry-rs/foundry-toolchain@v1
8494
- name: Check packages individually
8595
run: just check-individually
8696
- name: Run lint
8797
run: just lint
98+
8899
build-docker:
89-
needs: build
90100
runs-on: ubuntu-latest
91101
steps:
92102
- uses: actions/checkout@v5
@@ -101,6 +111,7 @@ jobs:
101111
sudo cp just /usr/bin/just
102112
- name: Build Docker
103113
run: just build_docker
114+
104115
integration:
105116
runs-on: ubuntu-latest
106117
timeout-minutes: 25
@@ -118,9 +129,74 @@ jobs:
118129
wget https://github.com/casey/just/releases/download/1.14.0/just-1.14.0-x86_64-unknown-linux-musl.tar.gz
119130
tar -vxf just-1.14.0-x86_64-unknown-linux-musl.tar.gz just
120131
sudo cp just /usr/bin/just
132+
- name: Install rustfmt for nightly
133+
run: rustup component add --toolchain nightly rustfmt
134+
- name: Install Foundry
135+
uses: foundry-rs/foundry-toolchain@v1
121136
- name: Run tests
122137
run: just run_demo -s /tmp/stamp --ignore-stamp --yapper -k test-configs/local-5.json
123138
- name: Run tests with late-start node
124139
run: just run_demo -l -s /tmp/stamp --ignore-stamp --yapper -k test-configs/local-5.json
125140
- name: Run sailfish demo
126141
run: just run_sailfish_demo
142+
143+
contracts:
144+
runs-on: ubuntu-latest
145+
steps:
146+
- uses: actions/checkout@v4
147+
with:
148+
submodules: recursive
149+
fetch-depth: 0
150+
- name: Install Just
151+
run: |
152+
wget https://github.com/casey/just/releases/download/1.14.0/just-1.14.0-x86_64-unknown-linux-musl.tar.gz
153+
tar -vxf just-1.14.0-x86_64-unknown-linux-musl.tar.gz just
154+
sudo cp just /usr/bin/just
155+
- name: Install rustfmt for nightly
156+
run: rustup component add --toolchain nightly rustfmt
157+
- name: Install Foundry
158+
uses: foundry-rs/foundry-toolchain@v1
159+
- name: Run contract tests
160+
run: forge test -vvv
161+
162+
nitro-timeboost-integration:
163+
runs-on: ubuntu-latest
164+
timeout-minutes: 60
165+
steps:
166+
- uses: actions/checkout@v4
167+
with:
168+
submodules: recursive
169+
fetch-depth: 0
170+
- name: Install protobuf compiler
171+
run: |
172+
sudo apt-get update
173+
sudo apt-get install -y protobuf-compiler
174+
- name: Install Just
175+
run: |
176+
wget https://github.com/casey/just/releases/download/1.14.0/just-1.14.0-x86_64-unknown-linux-musl.tar.gz
177+
tar -vxf just-1.14.0-x86_64-unknown-linux-musl.tar.gz just
178+
sudo cp just /usr/bin/just
179+
- name: Install rustfmt for nightly
180+
run: rustup component add --toolchain nightly rustfmt
181+
- name: Install Foundry
182+
uses: foundry-rs/foundry-toolchain@v1
183+
- name: Clone Espresso Testnode Repository
184+
run: |
185+
git clone --recursive https://github.com/EspressoSystems/decentralized-timeboost-nitro-testnode.git
186+
- name: Run Test Node with Timeboost
187+
run: |
188+
cd decentralized-timeboost-nitro-testnode
189+
chmod +x test-node.bash
190+
./test-node.bash \
191+
--build-dev-nitro \
192+
--batchposters 0 \
193+
--redundantsequencers 1 \
194+
--decentralized-timeboost \
195+
--init &
196+
cd ..
197+
- name: Run test timeboost with nitro sequencer
198+
run: just run_demo -s /tmp/stamp --ignore-stamp -k test-configs/local-2.json --rounds 10000 --yapper --nitro
199+
- name: Verify sequencer blocks
200+
run: |
201+
RUST_LOG=info just verify_blocks
202+

.gitignore

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,6 @@
33
debug/
44
target/
55

6-
# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
7-
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
8-
Cargo.lock
9-
106
# Exclude sources generated by protoc.
117
timeboost-proto/src/*.rs
128

@@ -35,4 +31,7 @@ timeboost-proto/src/*.rs
3531
bacon.toml
3632

3733
__pycache__/
34+
*.DS_Store
3835

36+
# Rust bindings for smart contracts
37+
timeboost-contract/src/bindings

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
[submodule "timeboost-proto/protos"]
22
path = timeboost-proto/protos
33
url = https://github.com/EspressoSystems/timeboost-proto.git
4+
[submodule "contracts/lib/openzeppelin-contracts-upgradeable"]
5+
path = contracts/lib/openzeppelin-contracts-upgradeable
6+
url = https://github.com/OpenZeppelin/openzeppelin-contracts-upgradeable

0 commit comments

Comments
 (0)