Skip to content

Commit 860bf6f

Browse files
committed
bindings -> contract-bindings
1 parent 7676b00 commit 860bf6f

File tree

21 files changed

+24
-25
lines changed

21 files changed

+24
-25
lines changed

.github/workflows/build.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,11 @@ jobs:
5252
path: |
5353
./contracts/out
5454
./contracts/cache
55-
./crates/bindings
55+
./crates/contract-bindings
5656
## TODO maybe add the rust version and solc version to the key
5757
key: v2-contracts-abi-${{ hashFiles('./contracts/**/*.sol') }}
5858

59-
- name: Generate ABI and bindings
59+
- name: Generate ABI and contract-bindings
6060
run: cd contracts && make gen
6161

6262
- name: Install Rust nightly

.github/workflows/contracts-test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
path: |
2727
./contracts/out
2828
./contracts/cache
29-
./crates/bindings
29+
./crates/contract-bindings
3030
key: v2-contracts-abi-${{ hashFiles('./contracts/**/*.sol') }}
3131

3232
- name: Run tests

.github/workflows/tests-e2e.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
path: |
4242
./contracts/out
4343
./contracts/cache
44-
./crates/bindings
44+
./crates/contract-bindings
4545
key: v2-contracts-abi-${{ hashFiles('./contracts/**/*.sol') }}
4646

4747
- uses: Swatinem/rust-cache@v2

.github/workflows/tests-unit.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
path: |
3131
./contracts/out
3232
./contracts/cache
33-
./crates/bindings
33+
./crates/contract-bindings
3434
key: v2-contracts-abi-${{ hashFiles('./contracts/**/*.sol') }}
3535

3636
- uses: Swatinem/rust-cache@v2

contracts/.gitattributes

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
out/* linguist-generated=true
2-
bindings/* linguist-generated=true
2+
contract-bindings/* linguist-generated=true

contracts/.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ deployments.json
2121
scripts/*.out
2222
scripts/deploy-registry.ts
2323
scripts/deploy-gateway.ts
24-
bindings/target
24+
contract-bindings/target
2525
subnet.registry.json
2626
subnet.actor.json
2727

contracts/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ compile-abi: node_modules | forge
4949
./ops/compile-abi.sh $(OUTPUT)
5050

5151
rust-binding:
52-
OUTPUT=$(OUTPUT) cargo build --locked --release --manifest-path ../crates/bindings/Cargo.toml -p ipc_actors_abis
52+
OUTPUT=$(OUTPUT) cargo build --locked --release --manifest-path ../crates/contract-bindings/Cargo.toml -p ipc_actors_abis
5353

5454
# ==============================================================================
5555
# Running security checks within the local computer

contracts/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ Also:
168168

169169
1. Use `make storage` to check that the storage layout has not been corrupted.
170170
2. Use `make coverage` to get the test coverage report.
171-
3. Use `make rust-binding` to generate bindings in Rust.
171+
3. Use `make rust-binding` to generate contract-bindings in Rust.
172172

173173
# Vulnerability Management
174174

crates/Cargo.toml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
[workspace]
22
resolver = "2"
33
members = [
4-
# contracts bindings
5-
"bindings",
4+
"contract-bindings",
65

76
# merkle
87
"patched_external/merkle-tree-rs",
@@ -183,7 +182,7 @@ ipc-wallet = { path = "ipc/wallet", features = ["with-ethers"] }
183182
ipc_ipld_resolver = { path = "ipld/resolver" }
184183
ipc-types = { path = "ipc/types" }
185184
ipc-observability = { path = "ipc/observability" }
186-
ipc_actors_abis = { path = "bindings" }
185+
ipc_actors_abis = { path = "contract-bindings" }
187186
fendermint_actors_api = { path = "client/actors/api" }
188187

189188
# Vendored for cross-compilation, see https://github.com/cross-rs/cross/wiki/Recipes#openssl
@@ -194,7 +193,7 @@ openssl = { version = "0.10", features = ["vendored"] }
194193

195194
# NOTE: When upgrading the FVM it may cause our client/actors/build.rs to fail as it can
196195
# pull in crates as transitive dependencies that do not support Wasm architector. If this
197-
# happens, try removing "crypto" feature from fvm_shared dependency in contracts/bindings/Cargo.toml
196+
# happens, try removing "crypto" feature from fvm_shared dependency in contracts/contract-bindings/Cargo.toml
198197
# and run `cargo build`. Then add the "crypto" feature back and run `cargo build` again.
199198
fvm = { version = "4.4.0", features = [
200199
"verify-signature",

crates/client/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,15 @@ make e2e
3636

3737
## IPC Solidity Actors
3838

39-
We generate Rust bindings for the Solidity actors we need to invoke from the [contracts](../contracts/) folder, some of which are deployed during the genesis process. The bindings live in [contracts/bindings/](../contracts/binding), and are generated automatically during the build, or with the following command:
39+
We generate Rust contract-bindings for the Solidity actors we need to invoke from the [contracts](../contracts/) folder, some of which are deployed during the genesis process. The contract-bindings live in [contracts/contract-bindings/](../contracts/binding), and are generated automatically during the build, or with the following command:
4040

4141
```bash
4242
make gen
4343
```
4444

4545
To run it, you will have to install [forge](https://book.getfoundry.sh/getting-started/installation).
4646

47-
The list of contracts for which we generate Rust bindings are in [build.rs](../contracts/bindings/build.rs) and needs to be maintained by hand, for example if a new "diamond facet" is added to a contract, it has to be added here. Diamond facets also have to be added manually in [ipc.rs](./vm/actor_interface/src/ipc.rs) where the contracts which need to be deployed during genesis are described. These facets cannot be divined from the ABI description, so they have to be maintained explicitly.
47+
The list of contracts for which we generate Rust contract-bindings are in [build.rs](../contracts/contract-bindings/build.rs) and needs to be maintained by hand, for example if a new "diamond facet" is added to a contract, it has to be added here. Diamond facets also have to be added manually in [ipc.rs](./vm/actor_interface/src/ipc.rs) where the contracts which need to be deployed during genesis are described. These facets cannot be divined from the ABI description, so they have to be maintained explicitly.
4848

4949
To test whether the genesis process works, we can run the following unit test:
5050

0 commit comments

Comments
 (0)