Skip to content

Commit f8505e8

Browse files
authored
Merge pull request #2148 from CosmWasm/cosmwasm_2_1-capability
Add `cosmwasm_2_1` capability
2 parents 7b9354c + fcf571e commit f8505e8

File tree

9 files changed

+16
-10
lines changed

9 files changed

+16
-10
lines changed

.circleci/config.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -438,15 +438,15 @@ jobs:
438438
- run:
439439
name: Build library for native target (all features)
440440
working_directory: ~/project/packages/std
441-
command: cargo build --locked --features abort,iterator,staking,stargate,cosmwasm_2_0
441+
command: cargo build --locked --all-features
442442
- run:
443443
name: Build library for wasm target (all features)
444444
working_directory: ~/project/packages/std
445-
command: cargo wasm --locked --features abort,iterator,staking,stargate,cosmwasm_2_0
445+
command: cargo wasm --locked --all-features
446446
- run:
447447
name: Run unit tests (all features)
448448
working_directory: ~/project/packages/std
449-
command: cargo test --locked --features abort,iterator,staking,stargate,cosmwasm_2_0
449+
command: cargo test --locked --all-features
450450
- save_cache:
451451
paths:
452452
- /usr/local/cargo/registry
@@ -1037,7 +1037,7 @@ jobs:
10371037
- run:
10381038
name: Clippy linting on std (all feature flags)
10391039
working_directory: ~/project/packages/std
1040-
command: cargo clippy --all-targets --tests --features abort,iterator,staking,stargate,cosmwasm_2_0 -- -D warnings
1040+
command: cargo clippy --all-targets --tests --all-features -- -D warnings
10411041
- run:
10421042
name: Clippy linting on vm (no feature flags)
10431043
working_directory: ~/project/packages/vm

.vscode/settings.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
"abort",
44
"stargate",
55
"staking",
6-
"cosmwasm_2_0"
6+
"cosmwasm_2_1"
77
]
88
}

docs/CAPABILITIES-BUILT-IN.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,5 @@ might define others.
2525
`1.4.0` or higher support this.
2626
- `cosmwasm_2_0` enables `CosmosMsg::Any` and `QueryRequest::Grpc`. Only chains
2727
running CosmWasm `2.0.0` or higher support this.
28+
- `cosmwasm_2_1` enables `IbcMsg::WriteAcknowledgement`. Only chains running
29+
CosmWasm `2.1.0` or higher support this.

packages/check/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use cosmwasm_vm::capabilities_from_csv;
1111
use cosmwasm_vm::internals::{check_wasm, compile, make_compiling_engine};
1212

1313
const DEFAULT_AVAILABLE_CAPABILITIES: &str =
14-
"iterator,staking,stargate,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0";
14+
"iterator,staking,stargate,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0,cosmwasm_2_1";
1515

1616
pub fn main() {
1717
let matches = Command::new("Contract checking")

packages/go-gen/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ edition = "2021"
66
publish = false
77

88
[dependencies]
9-
cosmwasm-std = { version = "2.0.1", path = "../std", features = ["cosmwasm_2_0", "staking", "stargate"] }
9+
cosmwasm-std = { version = "2.0.1", path = "../std", features = ["cosmwasm_2_1", "staking", "stargate"] }
1010
cosmwasm-schema = { version = "2.0.1", path = "../schema" }
1111
anyhow = "1"
1212
Inflector = "0.11.4"

packages/std/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ license = "Apache-2.0"
99
readme = "README.md"
1010

1111
[package.metadata.docs.rs]
12-
features = ["abort", "stargate", "staking", "cosmwasm_2_0"]
12+
features = ["abort", "stargate", "staking", "cosmwasm_2_1"]
1313

1414
[features]
1515
default = ["iterator", "abort"]

packages/std/src/exports.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,10 @@ extern "C" fn requires_cosmwasm_1_4() -> () {}
6565
#[no_mangle]
6666
extern "C" fn requires_cosmwasm_2_0() -> () {}
6767

68+
#[cfg(feature = "cosmwasm_2_1")]
69+
#[no_mangle]
70+
extern "C" fn requires_cosmwasm_2_1() -> () {}
71+
6872
/// interface_version_* exports mark which Wasm VM interface level this contract is compiled for.
6973
/// They can be checked by cosmwasm_vm.
7074
/// Update this whenever the Wasm VM interface breaks.

packages/vm/examples/heap_profiling.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ fn app(runtime: u64) {
106106

107107
let options = CacheOptions::new(
108108
TempDir::new().unwrap().into_path(),
109-
capabilities_from_csv("iterator,staking,stargate,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0"),
109+
capabilities_from_csv("iterator,staking,stargate,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0,cosmwasm_2_1"),
110110
MEMORY_CACHE_SIZE,
111111
DEFAULT_MEMORY_LIMIT,
112112
);

packages/vm/src/testing/instance.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ impl MockInstanceOptions<'_> {
9797
fn default_capabilities() -> HashSet<String> {
9898
#[allow(unused_mut)]
9999
let mut out = capabilities_from_csv(
100-
"iterator,staking,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0",
100+
"iterator,staking,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3,cosmwasm_1_4,cosmwasm_2_0,cosmwasm_2_1",
101101
);
102102
#[cfg(feature = "stargate")]
103103
out.insert("stargate".to_string());

0 commit comments

Comments
 (0)