Files
pezkuwi-subxt/substrate/frame/contracts/Cargo.toml
T
Sasha Gryaznov f83fdeab53 contracts: switch from parity-wasm-based to wasmi-based module validation (#14449)
* upgrade to wasmi 0.29

* prepare cleanup

* sync ref_time w engine from the stack frame

* proc_macro: sync gas in host funcs

save: compiles, only gas pushing left to macro

WIP proc macro

proc macro: done

* clean benchmarks & schedule: w_base = w_i64const

* scale gas values btw engine and gas meter

* (re)instrumentation & code_cache removed

* remove gas() host fn, continue clean-up

save

* address review comments

* move from CodeStorage&PrefabWasmModule to PristineCode&WasmBlob

* refactor: no reftime_limit&schedule passes, no CodeStorage

* bugs fixing

* fix tests: expected deposit amount

* fix prepare::tests

* update tests and fix bugs

tests::run_out_of_gas_engine, need 2 more

save: 2 bugs with gas syncs: 1 of 2 tests done

gas_syncs_no_overcharge bug fixed, test passes!

cleaned out debug prints

second bug is not a bug

disabled_chain_extension test fix (err msg)

tests run_out_of_fuel_host, chain_extension pass

all tests pass

* update docs

* bump wasmi 0.30.0

* benchmarks updated, tests pass

* refactoring

* s/OwnerInfo/CodeInfo/g;

* migration: draft, compiles

* migration: draft, runs

* migration: draft, runs (fixing)

* deposits repaid non pro rata

* deposits repaid pro rata

* better try-runtime output

* even better try-runtime output

* benchmark migration

* fix merge leftover

* add forgotten fixtures, fix docs

* address review comments

* ci fixes

* cleanup

* benchmarks::prepare to return DispatchError

* ".git/.scripts/commands/bench/bench.sh" pallet dev pallet_contracts

* store memory limits to CodeInfo

* ci: roll back weights

* ".git/.scripts/commands/bench-vm/bench-vm.sh" pallet dev pallet_contracts

* drive-by: update Readme and pallet rustdoc

* ".git/.scripts/commands/bench/bench.sh" pallet dev pallet_contracts

* ".git/.scripts/commands/bench/bench.sh" pallet dev pallet_contracts

* use wasmi 0.29

* ".git/.scripts/commands/bench/bench.sh" pallet dev pallet_contracts

* use wasmi 0.30 again

* query memory limits from wasmi

* save: scan_exports ported, compiles

* save (wip, not compiles)

* query memory limits from wasmi

* better migration types

* ci: pull weights from master

* refactoring

* ".git/.scripts/commands/bench-vm/bench-vm.sh" pallet dev pallet_contracts

* scan_imports ported

* scan_export ported, other checks removed

* tests fixed

tests fixed

* drop wasmparser and parity-wasm dependencies

* typo fix

* addressing review comments

* refactor

* address review comments

* optimize migration

* ".git/.scripts/commands/bench/bench.sh" pallet dev pallet_contracts

* another review round comments addressed

* ci fix one

* clippy fix

* ci fix two

* allow stored modules to have no memory imports

* rollback: allow stored modules to have no memory imports

* ".git/.scripts/commands/bench/bench.sh" pallet dev pallet_contracts

* address review comments

---------

Co-authored-by: command-bot <>
2023-07-04 21:38:47 +00:00

92 lines
3.3 KiB
TOML

[package]
name = "pallet-contracts"
version = "4.0.0-dev"
authors = ["Parity Technologies <admin@parity.io>"]
edition = "2021"
license = "Apache-2.0"
homepage = "https://substrate.io"
repository = "https://github.com/paritytech/substrate/"
description = "FRAME pallet for WASM contracts"
readme = "README.md"
include = ["src/**/*", "README.md", "CHANGELOG.md"]
[package.metadata.docs.rs]
targets = ["x86_64-unknown-linux-gnu"]
[dependencies]
bitflags = "1.3"
codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false, features = [
"derive",
"max-encoded-len",
] }
scale-info = { version = "2.5.0", default-features = false, features = ["derive"] }
log = { version = "0.4", default-features = false }
serde = { version = "1", optional = true, features = ["derive"] }
smallvec = { version = "1", default-features = false, features = [
"const_generics",
] }
wasmi = { version = "0.30", default-features = false }
impl-trait-for-tuples = "0.2"
# Only used in benchmarking to generate contract code
wasm-instrument = { version = "0.4", optional = true, default-features = false }
rand = { version = "0.8", optional = true, default-features = false }
rand_pcg = { version = "0.3", optional = true }
# Substrate Dependencies
environmental = { version = "1.1.4", default-features = false }
frame-benchmarking = { version = "4.0.0-dev", default-features = false, path = "../benchmarking", optional = true }
frame-support = { version = "4.0.0-dev", default-features = false, path = "../support" }
frame-system = { version = "4.0.0-dev", default-features = false, path = "../system" }
pallet-contracts-primitives = { version = "24.0.0", default-features = false, path = "primitives" }
pallet-contracts-proc-macro = { version = "4.0.0-dev", path = "proc-macro" }
sp-api = { version = "4.0.0-dev", default-features = false, path = "../../primitives/api" }
sp-core = { version = "21.0.0", default-features = false, path = "../../primitives/core" }
sp-io = { version = "23.0.0", default-features = false, path = "../../primitives/io" }
sp-runtime = { version = "24.0.0", default-features = false, path = "../../primitives/runtime" }
sp-std = { version = "8.0.0", default-features = false, path = "../../primitives/std" }
[dev-dependencies]
array-bytes = "4.1"
assert_matches = "1"
env_logger = "0.9"
pretty_assertions = "1"
wat = "1"
# Substrate Dependencies
pallet-balances = { version = "4.0.0-dev", path = "../balances" }
pallet-timestamp = { version = "4.0.0-dev", path = "../timestamp" }
pallet-insecure-randomness-collective-flip = { version = "4.0.0-dev", path = "../insecure-randomness-collective-flip" }
pallet-utility = { version = "4.0.0-dev", path = "../utility" }
pallet-proxy = { version = "4.0.0-dev", path = "../proxy" }
sp-keystore = { version = "0.27.0", path = "../../primitives/keystore" }
[features]
default = ["std"]
std = [
"serde",
"codec/std",
"scale-info/std",
"sp-core/std",
"sp-runtime/std",
"sp-io/std",
"sp-std/std",
"frame-benchmarking?/std",
"frame-support/std",
"frame-system/std",
"wasm-instrument/std",
"wasmi/std",
"pallet-contracts-primitives/std",
"pallet-contracts-proc-macro/full",
"log/std",
"rand/std",
"environmental/std",
]
runtime-benchmarks = [
"frame-benchmarking/runtime-benchmarks",
"rand",
"rand_pcg",
"wasm-instrument",
]
try-runtime = ["frame-support/try-runtime"]