Skip to content

Commit 166934f

Browse files
authored
refactor (#40)
* refactor
1 parent 566ee6e commit 166934f

Some content is hidden

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

52 files changed

+6090
-1564
lines changed

.github/actions/setup-rust/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@ name: Setup Rust (cache & toolchain)
22
runs:
33
using: composite
44
steps:
5-
- name: Install toolchain 1.75.0
5+
- name: Install toolchain 1.78.0
66
uses: actions-rs/toolchain@v1
77
with:
88
profile: minimal
9-
toolchain: 1.75.0
9+
toolchain: 1.78.0
1010
components: rustfmt, clippy
1111

1212
- uses: Swatinem/rust-cache@v2

.github/workflows/cc.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
swap-storage: true
3030

3131
- name: Checkout sources
32-
uses: actions/checkout@v3
32+
uses: actions/checkout@v5
3333
with:
3434
submodules: recursive
3535

@@ -45,10 +45,13 @@ jobs:
4545
RUSTDOCFLAGS: '-Zprofile -Ccodegen-units=1 -Copt-level=0 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests'
4646

4747
- id: coverage
48-
uses: actions-rs/grcov@v0.1
48+
uses: SierraSoftworks/setup-grcov@v1
49+
with:
50+
github-token: ${{ secrets.GITHUB_TOKEN }}
51+
version: 0.9.1
4952

5053
- name: Upload coverage to Codecov
51-
uses: codecov/codecov-action@v3
54+
uses: codecov/codecov-action@v4
5255
with:
5356
file: ${{ steps.coverage.outputs.report }}
5457
# Disable to avoid CI failure as following:

.github/workflows/rust.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
runs-on: ubuntu-latest
2222
steps:
2323
- name: Checkout sources
24-
uses: actions/checkout@v3
24+
uses: actions/checkout@v5
2525
with:
2626
submodules: recursive
2727
- name: Setup Rust (cache & toolchain)
@@ -37,7 +37,7 @@ jobs:
3737
runs-on: ubuntu-latest
3838
steps:
3939
- name: Checkout sources
40-
uses: actions/checkout@v3
40+
uses: actions/checkout@v5
4141
with:
4242
submodules: recursive
4343
- name: Setup Rust (cache & toolchain)
@@ -53,7 +53,7 @@ jobs:
5353
runs-on: ubuntu-latest
5454
steps:
5555
- name: Checkout sources
56-
uses: actions/checkout@v3
56+
uses: actions/checkout@v5
5757
with:
5858
submodules: recursive
5959
- name: Setup Rust (cache & toolchain)

.github/workflows/tests.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,9 @@ jobs:
2929
swap-storage: true
3030

3131
- name: Checkout sources
32-
uses: actions/checkout@v3
32+
uses: actions/checkout@v5
3333
with:
34+
persist-credentials: false # prevents writing the extraheader
3435
submodules: recursive
3536

3637
- name: Setup Rust (cache & toolchain)
@@ -39,10 +40,10 @@ jobs:
3940
- name: Build
4041
run: cargo build --release --verbose
4142

42-
- name: Set up Python 3.9
43+
- name: Set up Python 3.11
4344
uses: actions/setup-python@v4
4445
with:
45-
python-version: '3.9'
46+
python-version: '3.11'
4647
cache: 'pip'
4748

4849
- name: Install dependencies

Cargo.lock

Lines changed: 26 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@ enr = { path = "version-meld/enr" }
1616
discv5 = { path = "version-meld/discv5" }
1717

1818
[workspace.dependencies]
19-
append_merkle = { git = "https://github.com/0glabs/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
20-
merkle_light = { git = "https://github.com/0glabs/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
21-
merkle_tree = { git = "https://github.com/0glabs/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
22-
shared_types = { git = "https://github.com/0glabs/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
23-
task_executor = { git = "https://github.com/0glabs/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
24-
storage = { git = "https://github.com/0glabs/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54", package = "storage" }
25-
contract-interface = { git = "https://github.com/0glabs/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
19+
append_merkle = { git = "https://github.com/0gfoundation/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
20+
merkle_light = { git = "https://github.com/0gfoundation/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
21+
merkle_tree = { git = "https://github.com/0gfoundation/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
22+
shared_types = { git = "https://github.com/0gfoundation/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
23+
task_executor = { git = "https://github.com/0gfoundation/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
24+
storage = { git = "https://github.com/0gfoundation/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54", package = "storage" }
25+
contract-interface = { git = "https://github.com/0gfoundation/0g-storage-node.git",rev = "96f846073f111adfa31df926be0e4a25e0b85f54" }
2626
metrics = { git = "https://github.com/Conflux-Chain/conflux-rust.git", rev = "992ebc5483d937c8f6b883e266f8ed2a67a7fa9a" }

node/rpc/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ tokio = { version = "1.19.2", features = ["macros", "sync"] }
1717
tracing = "0.1.35"
1818
merkle_light = { workspace = true }
1919
merkle_tree = { workspace = true }
20-
zgs_rpc = { git = "https://github.com/0glabs/0g-storage-node.git", rev = "96f846073f111adfa31df926be0e4a25e0b85f54", package = "rpc" }
20+
zgs_rpc = { git = "https://github.com/0gfoundation/0g-storage-node.git", rev = "96f846073f111adfa31df926be0e4a25e0b85f54", package = "rpc" }
2121
futures-channel = "^0.3"
2222
ethereum-types = "0.14"
2323
storage_with_stream = { path = "../storage_with_stream" }

node/stream/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ ethers = { version = "^2", features = ["ws"] }
2020
serde_json = "1.0.127"
2121
storage_with_stream = { path = "../storage_with_stream" }
2222
rpc = {path = "../rpc"}
23-
zgs_rpc = { git = "https://github.com/0glabs/0g-storage-node.git", rev = "96f846073f111adfa31df926be0e4a25e0b85f54", package = "rpc" }
24-
zgs_storage = { git = "https://github.com/0glabs/0g-storage-node.git", rev = "96f846073f111adfa31df926be0e4a25e0b85f54", package = "storage" }
23+
zgs_rpc = { git = "https://github.com/0gfoundation/0g-storage-node.git", rev = "96f846073f111adfa31df926be0e4a25e0b85f54", package = "rpc" }
24+
zgs_storage = { git = "https://github.com/0gfoundation/0g-storage-node.git", rev = "96f846073f111adfa31df926be0e4a25e0b85f54", package = "storage" }
2525
contract-interface = { workspace = true }
2626
rusqlite = { version = "0.28.0", features = ["bundled"] }
2727
tracing = "0.1.35"

requirements.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
jsonrpcclient==4.0.3
22
pyyaml==6.0.1
3-
pysha3==1.0.2
4-
coincurve==18.0.0
5-
eth-utils==3.0.0
3+
safe-pysha3==1.0.4
4+
coincurve==20.0.0
5+
eth-utils==5.1.0
66
py-ecc==7.0.0
7-
web3==6.14.0
7+
web3==7.5.0
88
eth_tester
99
cffi==1.16.0
10-
rtoml==0.10.0
10+
rtoml==0.11.0

rust-toolchain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.75.0
1+
1.78.0

0 commit comments

Comments
 (0)