From 2de36ee864e12c871e4ba4fa55e7289e0e232d3a Mon Sep 17 00:00:00 2001 From: Ethan Frey Date: Wed, 28 Apr 2021 19:44:34 +0200 Subject: [PATCH 1/3] Bump to cosmwasm 0.14.0-beta5, fix compile issue --- Cargo.lock | 16 ++++++++-------- contracts/cw1-subkeys/Cargo.toml | 4 ++-- contracts/cw1-whitelist/Cargo.toml | 4 ++-- contracts/cw1155-base/Cargo.toml | 2 +- contracts/cw20-atomic-swap/Cargo.toml | 4 ++-- contracts/cw20-base/Cargo.toml | 4 ++-- contracts/cw20-bonding/Cargo.toml | 4 ++-- contracts/cw20-escrow/Cargo.toml | 4 ++-- contracts/cw20-ics20/src/contract.rs | 5 ++--- contracts/cw20-staking/Cargo.toml | 4 ++-- contracts/cw3-fixed-multisig/Cargo.toml | 4 ++-- contracts/cw3-flex-multisig/Cargo.toml | 4 ++-- contracts/cw4-group/Cargo.toml | 4 ++-- contracts/cw4-stake/Cargo.toml | 4 ++-- contracts/cw721-base/Cargo.toml | 4 ++-- packages/controllers/Cargo.toml | 2 +- packages/cw0/Cargo.toml | 2 +- packages/cw1/Cargo.toml | 4 ++-- packages/cw1155/Cargo.toml | 4 ++-- packages/cw2/Cargo.toml | 2 +- packages/cw20/Cargo.toml | 4 ++-- packages/cw3/Cargo.toml | 4 ++-- packages/cw4/Cargo.toml | 4 ++-- packages/cw721/Cargo.toml | 4 ++-- packages/multi-test/Cargo.toml | 2 +- packages/storage-plus/Cargo.toml | 2 +- 26 files changed, 52 insertions(+), 53 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index a97c42c0a..6d83548c7 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -87,9 +87,9 @@ checksum = "9f6b64db6932c7e49332728e3a6bd82c6b7e16016607d20923b537c3bc4c0d5f" [[package]] name = "cosmwasm-crypto" -version = "0.14.0-beta4" +version = "0.14.0-beta5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1c01da6cef92b4cfeff1f0f9c25faea38933336c8f518923d3fa2d3802e999e" +checksum = "287dbad1f4552104d7b60fef84c58eb7c9be88dfddfee733b1b116f92a6d29c5" dependencies = [ "digest 0.9.0", "ed25519-zebra", @@ -100,18 +100,18 @@ dependencies = [ [[package]] name = "cosmwasm-derive" -version = "0.14.0-beta4" +version = "0.14.0-beta5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a13cbe25d3df0636d4a1bad0880ea2dfd507740d0b851ed0bb39feee0352f4c" +checksum = "942b3993e5d2a8b20103aa10cbec68fa51b9d1bcbb112421004595a1c5adab81" dependencies = [ "syn", ] [[package]] name = "cosmwasm-schema" -version = "0.14.0-beta4" +version = "0.14.0-beta5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f077fb99158d345d76b309058573d4b0ce3e1609b2affb3da2405a6af572da8" +checksum = "292a3ed21dcdeaa2de5bbecb4c80a4d78b40d9d9dd25a1b820e6868ea366a5c4" dependencies = [ "schemars", "serde_json", @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "cosmwasm-std" -version = "0.14.0-beta4" +version = "0.14.0-beta5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcab389a0d8ea2a1399ad5416c1ca25cc860336ff7004a58128e487dcee8f109" +checksum = "075bc05cd2d387e043f39d3c5007d9347cef99b8640954972ffeb4f6f7fb4da5" dependencies = [ "base64", "cosmwasm-crypto", diff --git a/contracts/cw1-subkeys/Cargo.toml b/contracts/cw1-subkeys/Cargo.toml index 5b4d818e9..ba668e793 100644 --- a/contracts/cw1-subkeys/Cargo.toml +++ b/contracts/cw1-subkeys/Cargo.toml @@ -22,11 +22,11 @@ cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw1 = { path = "../../packages/cw1", version = "0.6.0-beta2" } cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw1-whitelist = { path = "../cw1-whitelist", version = "0.6.0-beta2", features = ["library"] } -cosmwasm-std = { version = "0.14.0-beta4", features = ["iterator", "staking"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["iterator", "staking"] } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/contracts/cw1-whitelist/Cargo.toml b/contracts/cw1-whitelist/Cargo.toml index aa146246b..ac8eab0b6 100644 --- a/contracts/cw1-whitelist/Cargo.toml +++ b/contracts/cw1-whitelist/Cargo.toml @@ -21,11 +21,11 @@ library = [] cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw1 = { path = "../../packages/cw1", version = "0.6.0-beta2" } cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4", features = ["iterator", "staking"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["iterator", "staking"] } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/contracts/cw1155-base/Cargo.toml b/contracts/cw1155-base/Cargo.toml index 2787cbc73..4217143e2 100644 --- a/contracts/cw1155-base/Cargo.toml +++ b/contracts/cw1155-base/Cargo.toml @@ -22,7 +22,7 @@ cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw1155 = { path = "../../packages/cw1155", version = "0.6.0-beta2" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2" , features = ["iterator"]} -cosmwasm-std = { version = "0.14.0-beta4", features = ["iterator"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } diff --git a/contracts/cw20-atomic-swap/Cargo.toml b/contracts/cw20-atomic-swap/Cargo.toml index 284ae8dfb..3ad02a0e3 100644 --- a/contracts/cw20-atomic-swap/Cargo.toml +++ b/contracts/cw20-atomic-swap/Cargo.toml @@ -18,7 +18,7 @@ library = [] cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw20 = { path = "../../packages/cw20", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4", features = ["iterator"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["iterator"] } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } @@ -27,4 +27,4 @@ hex = "0.3.1" sha2 = "0.8.0" [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/contracts/cw20-base/Cargo.toml b/contracts/cw20-base/Cargo.toml index cd16febcd..324d136b1 100644 --- a/contracts/cw20-base/Cargo.toml +++ b/contracts/cw20-base/Cargo.toml @@ -22,10 +22,10 @@ cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw20 = { path = "../../packages/cw20", version = "0.6.0-beta2" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } -cosmwasm-std = { version = "0.14.0-beta4", features = ["iterator"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/contracts/cw20-bonding/Cargo.toml b/contracts/cw20-bonding/Cargo.toml index 27a4381f0..c2591cded 100644 --- a/contracts/cw20-bonding/Cargo.toml +++ b/contracts/cw20-bonding/Cargo.toml @@ -25,7 +25,7 @@ cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw20 = { path = "../../packages/cw20", version = "0.6.0-beta2" } cw20-base = { path = "../../contracts/cw20-base", version = "0.6.0-beta2", features = ["library"] } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4", features = ["staking"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["staking"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } @@ -34,4 +34,4 @@ integer-sqrt = { version = "0.1.5" } integer-cbrt = { version = "0.1" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/contracts/cw20-escrow/Cargo.toml b/contracts/cw20-escrow/Cargo.toml index c23001a4e..fcec6578f 100644 --- a/contracts/cw20-escrow/Cargo.toml +++ b/contracts/cw20-escrow/Cargo.toml @@ -21,13 +21,13 @@ library = [] cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw20 = { path = "../../packages/cw20", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4", features = ["iterator"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["iterator"] } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } cw-multi-test = { path = "../../packages/multi-test", version = "0.6.0-beta2" } cw20-base = { path = "../cw20-base", version = "0.6.0-beta2", features = ["library"] } diff --git a/contracts/cw20-ics20/src/contract.rs b/contracts/cw20-ics20/src/contract.rs index 430787202..2edf8772b 100644 --- a/contracts/cw20-ics20/src/contract.rs +++ b/contracts/cw20-ics20/src/contract.rs @@ -92,7 +92,7 @@ pub fn execute_transfer( None => CONFIG.load(deps.storage)?.default_timeout, }; // timeout is in nanoseconds - let timeout = (env.block.time + timeout_delta) * 1_000_000_000; + let timeout = env.block.timestamp().plus_seconds(timeout_delta); // build ics20 packet let packet = Ics20Packet::new( @@ -107,8 +107,7 @@ pub fn execute_transfer( let msg = IbcMsg::SendPacket { channel_id: msg.channel, data: to_binary(&packet)?, - timeout_block: None, - timeout_timestamp: Some(timeout), + timeout: timeout.into(), }; // Note: we update local state when we get ack - do not count this transfer towards anything until acked diff --git a/contracts/cw20-staking/Cargo.toml b/contracts/cw20-staking/Cargo.toml index e100a5349..70ea8afbb 100644 --- a/contracts/cw20-staking/Cargo.toml +++ b/contracts/cw20-staking/Cargo.toml @@ -25,11 +25,11 @@ cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw20 = { path = "../../packages/cw20", version = "0.6.0-beta2" } cw-controllers = { path = "../../packages/controllers", version = "0.6.0-beta2" } cw20-base = { path = "../../contracts/cw20-base", version = "0.6.0-beta2", features = ["library"] } -cosmwasm-std = { version = "0.14.0-beta4", features = ["staking"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["staking"] } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/contracts/cw3-fixed-multisig/Cargo.toml b/contracts/cw3-fixed-multisig/Cargo.toml index a1ac5ed28..80584497e 100644 --- a/contracts/cw3-fixed-multisig/Cargo.toml +++ b/contracts/cw3-fixed-multisig/Cargo.toml @@ -22,13 +22,13 @@ cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw3 = { path = "../../packages/cw3", version = "0.6.0-beta2" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } -cosmwasm-std = { version = "0.14.0-beta4", features = ["iterator"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } cw20 = { path = "../../packages/cw20", version = "0.6.0-beta2" } cw20-base = { path = "../cw20-base", version = "0.6.0-beta2", features = ["library"] } cw-multi-test = { path = "../../packages/multi-test", version = "0.6.0-beta2" } diff --git a/contracts/cw3-flex-multisig/Cargo.toml b/contracts/cw3-flex-multisig/Cargo.toml index b3dc09836..291dbc45e 100644 --- a/contracts/cw3-flex-multisig/Cargo.toml +++ b/contracts/cw3-flex-multisig/Cargo.toml @@ -23,12 +23,12 @@ cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw3 = { path = "../../packages/cw3", version = "0.6.0-beta2" } cw4 = { path = "../../packages/cw4", version = "0.6.0-beta2" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } -cosmwasm-std = { version = "0.14.0-beta4", features = ["iterator"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["iterator"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } cw4-group = { path = "../cw4-group", version = "0.6.0-beta2" } cw-multi-test = { path = "../../packages/multi-test", version = "0.6.0-beta2" } diff --git a/contracts/cw4-group/Cargo.toml b/contracts/cw4-group/Cargo.toml index 99e5f7a14..41bad22b1 100644 --- a/contracts/cw4-group/Cargo.toml +++ b/contracts/cw4-group/Cargo.toml @@ -31,10 +31,10 @@ cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw4 = { path = "../../packages/cw4", version = "0.6.0-beta2" } cw-controllers = { path = "../../packages/controllers", version = "0.6.0-beta2" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.21" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/contracts/cw4-stake/Cargo.toml b/contracts/cw4-stake/Cargo.toml index 93dd5ba6d..6c16bb814 100644 --- a/contracts/cw4-stake/Cargo.toml +++ b/contracts/cw4-stake/Cargo.toml @@ -32,10 +32,10 @@ cw4 = { path = "../../packages/cw4", version = "0.6.0-beta2" } cw20 = { path = "../../packages/cw20", version = "0.6.0-beta2" } cw-controllers = { path = "../../packages/controllers", version = "0.6.0-beta2" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2", features = ["iterator"] } -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.21" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/contracts/cw721-base/Cargo.toml b/contracts/cw721-base/Cargo.toml index 8cc80da86..a48d42bd9 100644 --- a/contracts/cw721-base/Cargo.toml +++ b/contracts/cw721-base/Cargo.toml @@ -29,10 +29,10 @@ cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw2 = { path = "../../packages/cw2", version = "0.6.0-beta2" } cw721 = { path = "../../packages/cw721", version = "0.6.0-beta2" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2" , features = ["iterator"]} -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.20" } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/packages/controllers/Cargo.toml b/packages/controllers/Cargo.toml index cab8022cb..53d263086 100644 --- a/packages/controllers/Cargo.toml +++ b/packages/controllers/Cargo.toml @@ -12,7 +12,7 @@ documentation = "https://docs.cosmwasm.com" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } cw0 = { path = "../cw0", version = "0.6.0-beta2" } cw-storage-plus = { path = "../storage-plus", version = "0.6.0-beta2", features = ["iterator"] } schemars = "0.8.1" diff --git a/packages/cw0/Cargo.toml b/packages/cw0/Cargo.toml index 7dda277eb..a45d36052 100644 --- a/packages/cw0/Cargo.toml +++ b/packages/cw0/Cargo.toml @@ -12,7 +12,7 @@ documentation = "https://docs.cosmwasm.com" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } thiserror = { version = "1.0.21" } diff --git a/packages/cw1/Cargo.toml b/packages/cw1/Cargo.toml index 13e8a7463..8d0ede13e 100644 --- a/packages/cw1/Cargo.toml +++ b/packages/cw1/Cargo.toml @@ -10,9 +10,9 @@ homepage = "https://cosmwasm.com" documentation = "https://docs.cosmwasm.com" [dependencies] -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/packages/cw1155/Cargo.toml b/packages/cw1155/Cargo.toml index 0159ffa6b..ec1993f84 100644 --- a/packages/cw1155/Cargo.toml +++ b/packages/cw1155/Cargo.toml @@ -11,9 +11,9 @@ documentation = "https://docs.cosmwasm.com" [dependencies] cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/packages/cw2/Cargo.toml b/packages/cw2/Cargo.toml index ce290d094..ed2276f72 100644 --- a/packages/cw2/Cargo.toml +++ b/packages/cw2/Cargo.toml @@ -10,7 +10,7 @@ homepage = "https://cosmwasm.com" documentation = "https://docs.cosmwasm.com" [dependencies] -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } diff --git a/packages/cw20/Cargo.toml b/packages/cw20/Cargo.toml index 7b4d7e8cf..8b2cf7958 100644 --- a/packages/cw20/Cargo.toml +++ b/packages/cw20/Cargo.toml @@ -11,9 +11,9 @@ documentation = "https://docs.cosmwasm.com" [dependencies] cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/packages/cw3/Cargo.toml b/packages/cw3/Cargo.toml index 3f4a385a1..a4b116d55 100644 --- a/packages/cw3/Cargo.toml +++ b/packages/cw3/Cargo.toml @@ -11,9 +11,9 @@ documentation = "https://docs.cosmwasm.com" [dependencies] cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/packages/cw4/Cargo.toml b/packages/cw4/Cargo.toml index d1f37f95f..a8908d239 100644 --- a/packages/cw4/Cargo.toml +++ b/packages/cw4/Cargo.toml @@ -10,9 +10,9 @@ homepage = "https://cosmwasm.com" documentation = "https://docs.cosmwasm.com" [dependencies] -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/packages/cw721/Cargo.toml b/packages/cw721/Cargo.toml index b88deaf8b..bea72b696 100644 --- a/packages/cw721/Cargo.toml +++ b/packages/cw721/Cargo.toml @@ -11,9 +11,9 @@ documentation = "https://docs.cosmwasm.com" [dependencies] cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } [dev-dependencies] -cosmwasm-schema = { version = "0.14.0-beta4" } +cosmwasm-schema = { version = "0.14.0-beta5" } diff --git a/packages/multi-test/Cargo.toml b/packages/multi-test/Cargo.toml index a7ba6991c..2187cf64e 100644 --- a/packages/multi-test/Cargo.toml +++ b/packages/multi-test/Cargo.toml @@ -18,6 +18,6 @@ stargate = ["cosmwasm-std/stargate"] [dependencies] cw0 = { path = "../../packages/cw0", version = "0.6.0-beta2" } cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.0-beta2" } -cosmwasm-std = { version = "0.14.0-beta4", features = ["staking"] } +cosmwasm-std = { version = "0.14.0-beta5", features = ["staking"] } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } diff --git a/packages/storage-plus/Cargo.toml b/packages/storage-plus/Cargo.toml index b3ceb9d8c..d5e8f0465 100644 --- a/packages/storage-plus/Cargo.toml +++ b/packages/storage-plus/Cargo.toml @@ -13,6 +13,6 @@ documentation = "https://docs.cosmwasm.com" iterator = ["cosmwasm-std/iterator"] [dependencies] -cosmwasm-std = { version = "0.14.0-beta4" } +cosmwasm-std = { version = "0.14.0-beta5" } schemars = "0.8.1" serde = { version = "1.0.103", default-features = false, features = ["derive"] } From 8bbcbae0211f02be1d49550fc8d22f4e47908a8c Mon Sep 17 00:00:00 2001 From: Ethan Frey Date: Wed, 28 Apr 2021 19:47:51 +0200 Subject: [PATCH 2/3] fix tests --- contracts/cw20-ics20/src/contract.rs | 22 ++++++---------------- 1 file changed, 6 insertions(+), 16 deletions(-) diff --git a/contracts/cw20-ics20/src/contract.rs b/contracts/cw20-ics20/src/contract.rs index 2edf8772b..a6e6f2aa2 100644 --- a/contracts/cw20-ics20/src/contract.rs +++ b/contracts/cw20-ics20/src/contract.rs @@ -254,16 +254,11 @@ mod test { if let CosmosMsg::Ibc(IbcMsg::SendPacket { channel_id, data, - timeout_timestamp, - timeout_block, + timeout, }) = &res.messages[0] { - assert!(timeout_block.is_none()); - assert!(timeout_timestamp.is_some()); - assert_eq!( - timeout_timestamp.unwrap() / 1_000_000_000, - mock_env().block.time + DEFAULT_TIMEOUT - ); + let expected_timeout = mock_env().block.timestamp().plus_seconds(DEFAULT_TIMEOUT); + assert_eq!(timeout, &expected_timeout.into()); assert_eq!(channel_id.as_str(), send_channel); let msg: Ics20Packet = from_binary(data).unwrap(); assert_eq!(msg.amount, Uint128(1234567)); @@ -323,16 +318,11 @@ mod test { if let CosmosMsg::Ibc(IbcMsg::SendPacket { channel_id, data, - timeout_timestamp, - timeout_block, + timeout, }) = &res.messages[0] { - assert!(timeout_block.is_none()); - assert!(timeout_timestamp.is_some()); - assert_eq!( - timeout_timestamp.unwrap() / 1_000_000_000, - mock_env().block.time + 7777 - ); + let expected_timeout = mock_env().block.timestamp().plus_seconds(7777); + assert_eq!(timeout, &expected_timeout.into()); assert_eq!(channel_id.as_str(), send_channel); let msg: Ics20Packet = from_binary(data).unwrap(); assert_eq!(msg.amount, Uint128(888777666)); From e82bed9b0258c5743ff9a56209e575ee481a002c Mon Sep 17 00:00:00 2001 From: Ethan Frey Date: Wed, 28 Apr 2021 19:50:11 +0200 Subject: [PATCH 3/3] Update schemas --- contracts/cw1-subkeys/schema/execute_msg.json | 46 +++++++++++++++++++ contracts/cw1-subkeys/schema/query_msg.json | 46 +++++++++++++++++++ .../cw1-whitelist/schema/execute_msg.json | 46 +++++++++++++++++++ contracts/cw1-whitelist/schema/query_msg.json | 46 +++++++++++++++++++ .../schema/execute_msg.json | 46 +++++++++++++++++++ .../cw3-flex-multisig/schema/execute_msg.json | 46 +++++++++++++++++++ packages/cw1/schema/execute_msg.json | 46 +++++++++++++++++++ packages/cw1/schema/query_msg.json | 46 +++++++++++++++++++ packages/cw3/schema/execute_msg.json | 46 +++++++++++++++++++ .../cw3/schema/proposal_list_response.json | 46 +++++++++++++++++++ packages/cw3/schema/proposal_response.json | 46 +++++++++++++++++++ 11 files changed, 506 insertions(+) diff --git a/contracts/cw1-subkeys/schema/execute_msg.json b/contracts/cw1-subkeys/schema/execute_msg.json index eafc1fba3..d7adff3bd 100644 --- a/contracts/cw1-subkeys/schema/execute_msg.json +++ b/contracts/cw1-subkeys/schema/execute_msg.json @@ -636,6 +636,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/contracts/cw1-subkeys/schema/query_msg.json b/contracts/cw1-subkeys/schema/query_msg.json index 11c40e7f2..7a6192766 100644 --- a/contracts/cw1-subkeys/schema/query_msg.json +++ b/contracts/cw1-subkeys/schema/query_msg.json @@ -548,6 +548,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/contracts/cw1-whitelist/schema/execute_msg.json b/contracts/cw1-whitelist/schema/execute_msg.json index 8571bc134..db2487a74 100644 --- a/contracts/cw1-whitelist/schema/execute_msg.json +++ b/contracts/cw1-whitelist/schema/execute_msg.json @@ -471,6 +471,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/contracts/cw1-whitelist/schema/query_msg.json b/contracts/cw1-whitelist/schema/query_msg.json index 1887e787c..ab904822c 100644 --- a/contracts/cw1-whitelist/schema/query_msg.json +++ b/contracts/cw1-whitelist/schema/query_msg.json @@ -448,6 +448,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/contracts/cw3-fixed-multisig/schema/execute_msg.json b/contracts/cw3-fixed-multisig/schema/execute_msg.json index 70cfa93be..7e3e37aa1 100644 --- a/contracts/cw3-fixed-multisig/schema/execute_msg.json +++ b/contracts/cw3-fixed-multisig/schema/execute_msg.json @@ -578,6 +578,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/contracts/cw3-flex-multisig/schema/execute_msg.json b/contracts/cw3-flex-multisig/schema/execute_msg.json index c01db51db..850ec9e05 100644 --- a/contracts/cw3-flex-multisig/schema/execute_msg.json +++ b/contracts/cw3-flex-multisig/schema/execute_msg.json @@ -634,6 +634,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/packages/cw1/schema/execute_msg.json b/packages/cw1/schema/execute_msg.json index 2dcab7b3d..7ec1f62b0 100644 --- a/packages/cw1/schema/execute_msg.json +++ b/packages/cw1/schema/execute_msg.json @@ -277,6 +277,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/packages/cw1/schema/query_msg.json b/packages/cw1/schema/query_msg.json index e3d635ae6..a6f655a6b 100644 --- a/packages/cw1/schema/query_msg.json +++ b/packages/cw1/schema/query_msg.json @@ -278,6 +278,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/packages/cw3/schema/execute_msg.json b/packages/cw3/schema/execute_msg.json index 88c8d944e..85ef4530e 100644 --- a/packages/cw3/schema/execute_msg.json +++ b/packages/cw3/schema/execute_msg.json @@ -431,6 +431,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/packages/cw3/schema/proposal_list_response.json b/packages/cw3/schema/proposal_list_response.json index 09444ae7d..5829b92e0 100644 --- a/packages/cw3/schema/proposal_list_response.json +++ b/packages/cw3/schema/proposal_list_response.json @@ -463,6 +463,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] } diff --git a/packages/cw3/schema/proposal_response.json b/packages/cw3/schema/proposal_response.json index a56fe4097..909440222 100644 --- a/packages/cw3/schema/proposal_response.json +++ b/packages/cw3/schema/proposal_response.json @@ -449,6 +449,52 @@ } }, "additionalProperties": false + }, + { + "description": "Sets a new admin (for migrate) on the given contract. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "update_admin" + ], + "properties": { + "update_admin": { + "type": "object", + "required": [ + "admin", + "contract_addr" + ], + "properties": { + "admin": { + "type": "string" + }, + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false + }, + { + "description": "Clears the admin on the given contract, so no more migration possible. Fails if this contract is not currently admin of the target contract.", + "type": "object", + "required": [ + "clear_admin" + ], + "properties": { + "clear_admin": { + "type": "object", + "required": [ + "contract_addr" + ], + "properties": { + "contract_addr": { + "type": "string" + } + } + } + }, + "additionalProperties": false } ] }