Skip to content

Commit 019a336

Browse files
authored
Merge pull request #5350 from mpapierski/vm2-discoverability
VM2 discoverability
2 parents 16b8273 + e3414fa commit 019a336

File tree

127 files changed

+7401
-3113
lines changed

Some content is hidden

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

127 files changed

+7401
-3113
lines changed

.github/workflows/casper-node.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,6 @@ jobs:
6868

6969
- name: vm2 tests
7070
run: |
71-
./vm2-build-contracts.sh
71+
make build-vm2-contracts-rs
7272
cargo test -p casper-executor-wasm
7373
cargo test -p casper-contract-sdk

Cargo.lock

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

Cargo.toml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,11 +51,6 @@ exclude = ["utils/nctl/remotes/casper-client-rs"]
5151

5252
resolver = "2"
5353

54-
# Include debug symbols in the release build of `casper-engine-tests` so that `simple-transfer` will yield useful
55-
# perf data.
56-
[profile.release.package.casper-engine-tests]
57-
debug = true
58-
5954
[profile.release]
6055
codegen-units = 1
6156
lto = true

Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,7 @@ build-contract-rs/%:
2525
cd smart_contracts/contracts && RUSTFLAGS=$(RUSTC_FLAGS) $(CARGO) build --verbose --release $(filter-out --release, $(CARGO_FLAGS)) --package $*
2626

2727
build-vm2-contract-rs/%:
28-
RUSTFLAGS=$(RUSTC_FLAGS) $(CARGO) run -p vm2-cargo-casper --bin vm2-cargo-casper -- build-schema --allow-skipping-abi-schema --package $*
29-
cd smart_contracts/contracts/vm2 && RUSTFLAGS=$(RUSTC_FLAGS) $(CARGO) build --verbose --release $(filter-out --release, $(CARGO_FLAGS)) --package $*
28+
RUSTFLAGS=$(RUSTC_FLAGS) $(CARGO) run -p vm2-cargo-casper --bin vm2-cargo-casper -- build --allow-skipping-abi-schema --package $*
3029

3130
.PHONY: build-vm2-contracts-rs
3231
build-vm2-contracts-rs: $(patsubst %, build-vm2-contract-rs/%, $(VM2_CONTRACTS))

execution_engine/src/runtime_context/mod.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -763,7 +763,8 @@ where
763763
| StoredValue::MessageTopic(_)
764764
| StoredValue::Message(_)
765765
| StoredValue::Prepayment(_)
766-
| StoredValue::EntryPoint(_) => Ok(()),
766+
| StoredValue::EntryPoint(_)
767+
| StoredValue::TypeDef(_) => Ok(()),
767768
}
768769
}
769770

execution_engine_testing/tests/src/test/explorer/faucet.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -663,14 +663,14 @@ fn faucet_costs() {
663663
// This test will fail if execution costs vary. The expected costs should not be updated
664664
// without understanding why the cost has changed. If the costs do change, it should be
665665
// reflected in the "Costs by Entry Point" section of the faucet crate's README.md.
666-
const EXPECTED_FAUCET_INSTALL_COST: u64 = 149_415_277_468;
666+
const EXPECTED_FAUCET_INSTALL_COST: u64 = 151_604_674_976;
667667
const EXPECTED_FAUCET_INSTALL_COST_ALT: u64 = 149_230_872_143;
668668

669-
const EXPECTED_FAUCET_SET_VARIABLES_COST: u64 = 79_455_975;
669+
const EXPECTED_FAUCET_SET_VARIABLES_COST: u64 = 79_484_390;
670670

671-
const EXPECTED_FAUCET_CALL_BY_INSTALLER_COST: u64 = 2_652_626_533;
671+
const EXPECTED_FAUCET_CALL_BY_INSTALLER_COST: u64 = 2_652_651_263;
672672

673-
const EXPECTED_FAUCET_CALL_BY_USER_COST: u64 = 2_558_318_531;
673+
const EXPECTED_FAUCET_CALL_BY_USER_COST: u64 = 2_558_372_626;
674674

675675
let installer_account = AccountHash::new([1u8; 32]);
676676
let user_account: AccountHash = AccountHash::new([2u8; 32]);

executor/wasm/Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ casper-executor-wasm-common = { version = "0.1.3", path = "../wasm_common" }
1616
casper-executor-wasm-host = { version = "0.1.3", path = "../wasm_host" }
1717
casper-executor-wasm-interface = { version = "0.1.3", path = "../wasm_interface" }
1818
casper-executor-wasmer-backend = { version = "0.1.3", path = "../wasmer_backend" }
19+
casper-contract-sdk = { version = "0.1.3", path = "../../smart_contracts/vm2/sdk" }
1920
casper-storage = { version = "3.0.0", path = "../../storage" }
2021
casper-types = { version = "7.0.0", path = "../../types", features = ["std"] }
2122
casper-execution-engine = { version = "8.1.1", path = "../../execution_engine", features = [
@@ -42,4 +43,4 @@ casper-executor-wasm ={ path = "../wasm", features = ["testing"] }
4243
casper-wasm = "1.0.0"
4344

4445
[features]
45-
testing = ["tempfile", "once_cell", "fs_extra", "serde_json", "itertools"]
46+
testing = ["tempfile", "once_cell", "fs_extra", "serde_json", "itertools"]

0 commit comments

Comments
 (0)