Skip to content

Commit

Permalink
feat(runtime): upgrade to Wasmer 0.17 and nightly 2020-05-15
Browse files Browse the repository at this point in the history
Used https://crates.io/crates/rust-latest to find latest suitable nightly.

Fixes #2055

Test plan
---------
cargo test --all
  • Loading branch information
olonho committed May 21, 2020
1 parent aac1460 commit af1b4d9
Show file tree
Hide file tree
Showing 10 changed files with 157 additions and 87 deletions.
131 changes: 56 additions & 75 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion core/chain-configs/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ pub use genesis_config::{
};

/// Current latest version of the protocol
pub const PROTOCOL_VERSION: u32 = 13;
pub const PROTOCOL_VERSION: u32 = 14 ;
9 changes: 9 additions & 0 deletions runtime/near-vm-errors/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,12 @@ pub enum WasmTrap {
IllegalArithmetic,
/// Misaligned atomic access trap.
MisalignedAtomicAccess,
/// Breakpoint trap.
BreakpointTrap,
/// Stack overflow.
StackOverflow,
/// Generic trap.
GenericTrap,
}

#[derive(
Expand Down Expand Up @@ -244,6 +250,9 @@ impl fmt::Display for WasmTrap {
write!(f, "An arithmetic exception, e.g. divided by zero.")
}
WasmTrap::MisalignedAtomicAccess => write!(f, "Misaligned atomic access trap."),
WasmTrap::GenericTrap => write!(f, "Generic trap."),
WasmTrap::BreakpointTrap => write!(f, "Breakpoint trap."),
WasmTrap::StackOverflow => write!(f, "Stack overflow."),
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions runtime/near-vm-runner/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ This crate implements the specification of the interface that Near blockchain ex

[dependencies]
cached = "0.12"
wasmer-runtime = { version = "0.13.1", features = ["default-backend-singlepass"], default-features = false }
wasmer-runtime-core = { version = "0.13.1" }
wasmer-runtime = { version = "=0.17.0", features = ["default-backend-singlepass"], default-features = false }
wasmer-runtime-core = { version = "=0.17.0" }
pwasm-utils = "0.12"
parity-wasm = "0.41"

Expand Down
Loading

0 comments on commit af1b4d9

Please sign in to comment.