From 517861bbcd8773a1ccde5c0e2baddb813f58c19f Mon Sep 17 00:00:00 2001 From: Buckram Date: Tue, 10 Jan 2023 14:15:16 +0200 Subject: [PATCH 1/4] dao-update --- Cargo.lock | 552 +++++++++++++--------- Cargo.toml | 29 +- ci/gas-benchmark/Cargo.toml | 4 +- contracts/cw-croncat/Cargo.toml | 10 +- contracts/cw-croncat/src/tests/helpers.rs | 48 +- contracts/cw-croncat/src/tests/manager.rs | 21 +- contracts/cw-rules/Cargo.toml | 12 +- contracts/cw-rules/src/tests/daodao.rs | 182 +++---- contracts/cw-rules/src/tests/helpers.rs | 36 +- 9 files changed, 514 insertions(+), 380 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 4bff284d..9ccd892c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -623,7 +623,7 @@ dependencies = [ "cw-storage-plus 0.13.4", "cw-utils 0.13.4", "cw2 0.13.4", - "cw20", + "cw20 0.13.4", "cw721 0.13.4", "schemars", "serde", @@ -664,18 +664,18 @@ dependencies = [ "cw-rules", "cw-rules-core", "cw-storage-plus 0.16.0", - "cw-utils 0.13.4", + "cw-utils 0.16.0", "cw2 0.16.0", - "cw20", - "cw20-base", - "cw20-stake", + "cw20 0.16.0", + "cw20-base 0.16.0", + "cw20-stake 2.0.0-beta", "cw4", "cw4-group", - "cwd-core", - "cwd-interface", - "cwd-proposal-single", - "cwd-voting", - "cwd-voting-cw20-staked", + "dao-core", + "dao-interface", + "dao-proposal-single", + "dao-voting", + "dao-voting-cw20-staked", "generic-query", "hex", "rusty-hook", @@ -697,8 +697,8 @@ dependencies = [ "cw-rules-core", "cw-storage-plus 0.16.0", "cw2 0.16.0", - "cw20", - "cw20-base", + "cw20 0.16.0", + "cw20-base 0.16.0", "generic-query", "hex", "rusty-hook", @@ -712,13 +712,23 @@ dependencies = [ [[package]] name = "cw-denom" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", - "cw20", - "schemars", - "serde", + "cw20 0.16.0", + "thiserror", +] + +[[package]] +name = "cw-hooks" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" +dependencies = [ + "cosmwasm-schema", + "cosmwasm-std", + "cw-storage-plus 0.16.0", "thiserror", ] @@ -740,6 +750,29 @@ dependencies = [ "thiserror", ] +[[package]] +name = "cw-ownable" +version = "0.3.0" +source = "git+https://github.com/steak-enjoyers/cw-plus-plus?rev=50d4d9333305894457e5028072a0465f4635b15b#50d4d9333305894457e5028072a0465f4635b15b" +dependencies = [ + "cosmwasm-schema", + "cosmwasm-std", + "cw-ownable-derive", + "cw-storage-plus 1.0.0", + "cw-utils 1.0.0", + "thiserror", +] + +[[package]] +name = "cw-ownable-derive" +version = "0.2.0" +source = "git+https://github.com/steak-enjoyers/cw-plus-plus?rev=50d4d9333305894457e5028072a0465f4635b15b#50d4d9333305894457e5028072a0465f4635b15b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "cw-paginate" version = "0.1.0" @@ -753,12 +786,12 @@ dependencies = [ [[package]] name = "cw-paginate" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ "cosmwasm-std", "cosmwasm-storage", - "cw-storage-plus 0.13.4", + "cw-storage-plus 0.16.0", "serde", ] @@ -775,8 +808,8 @@ dependencies = [ "cw-storage-plus 0.13.4", "cw-utils 0.13.4", "cw2 0.13.4", - "cw20", - "cw3", + "cw20 0.13.4", + "cw3 0.13.4", "indexable-hooks", "proposal-hooks", "schemars", @@ -796,21 +829,21 @@ dependencies = [ "cw-multi-test", "cw-rules-core", "cw-storage-plus 0.16.0", - "cw-utils 0.13.4", + "cw-utils 0.16.0", "cw2 0.16.0", - "cw20", - "cw20-base", - "cw20-stake", + "cw20 0.16.0", + "cw20-base 0.16.0", + "cw20-stake 2.0.0-beta", "cw4", "cw4-group", "cw721 0.15.0", "cw721-base", - "cwd-core", - "cwd-interface", - "cwd-proposal-multiple", - "cwd-proposal-single", - "cwd-voting", - "cwd-voting-cw20-staked", + "dao-core", + "dao-interface", + "dao-proposal-multiple", + "dao-proposal-single", + "dao-voting", + "dao-voting-cw20-staked", "generic-query", "rusty-hook", "schemars", @@ -828,7 +861,7 @@ version = "0.1.2" dependencies = [ "cosmwasm-schema", "cosmwasm-std", - "cw20", + "cw20 0.16.0", "generic-query", "rusty-hook", "schemars", @@ -870,6 +903,19 @@ dependencies = [ "serde", ] +[[package]] +name = "cw-storage-plus" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ea7f23066698f2792fd6ede927dfe8297486537516e6f9993764986bcb89933" +dependencies = [ + "cosmwasm-std", + "k256", + "schemars", + "serde", + "thiserror", +] + [[package]] name = "cw-utils" version = "0.13.4" @@ -912,6 +958,23 @@ dependencies = [ "thiserror", ] +[[package]] +name = "cw-utils" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b50d0cac456f98b4339b78e890fbe60e4dfe888c87abacc1129fc3fe34bbe20a" +dependencies = [ + "anyhow", + "cosmwasm-schema", + "cosmwasm-std", + "cw2 0.16.0", + "k256", + "schemars", + "semver", + "serde", + "thiserror", +] + [[package]] name = "cw2" version = "0.13.4" @@ -962,6 +1025,19 @@ dependencies = [ "serde", ] +[[package]] +name = "cw20" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a45a8794a5dd33b66af34caee52a7beceb690856adcc1682b6e3db88b2cdee62" +dependencies = [ + "cosmwasm-schema", + "cosmwasm-std", + "cw-utils 0.16.0", + "schemars", + "serde", +] + [[package]] name = "cw20-base" version = "0.13.4" @@ -972,31 +1048,69 @@ dependencies = [ "cw-storage-plus 0.13.4", "cw-utils 0.13.4", "cw2 0.13.4", - "cw20", + "cw20 0.13.4", "schemars", "serde", "thiserror", ] +[[package]] +name = "cw20-base" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61d826fa1084d026d0abdb54faa5956972efa3a9053473bfcefb5388960aab69" +dependencies = [ + "cosmwasm-schema", + "cosmwasm-std", + "cw-storage-plus 0.16.0", + "cw-utils 0.16.0", + "cw2 0.16.0", + "cw20 0.16.0", + "schemars", + "semver", + "serde", + "thiserror", +] + [[package]] name = "cw20-stake" version = "0.2.6" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +source = "git+https://github.com/DA0-DA0/dao-contracts.git?tag=v1.0.0#e531c760a5d057329afd98d62567aaa4dca2c96f" dependencies = [ "cosmwasm-std", "cosmwasm-storage", "cw-controllers 0.13.4", - "cw-paginate 0.2.0", "cw-storage-plus 0.13.4", "cw-utils 0.13.4", "cw2 0.13.4", - "cw20", - "cw20-base", + "cw20 0.13.4", + "cw20-base 0.13.4", "schemars", "serde", "thiserror", ] +[[package]] +name = "cw20-stake" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" +dependencies = [ + "cosmwasm-schema", + "cosmwasm-std", + "cosmwasm-storage", + "cw-controllers 0.16.0", + "cw-ownable", + "cw-paginate 2.0.0-beta", + "cw-storage-plus 0.16.0", + "cw-utils 0.13.4", + "cw-utils 0.16.0", + "cw2 0.16.0", + "cw20 0.16.0", + "cw20-base 0.16.0", + "cw20-stake 0.2.6", + "thiserror", +] + [[package]] name = "cw3" version = "0.13.4" @@ -1009,6 +1123,19 @@ dependencies = [ "serde", ] +[[package]] +name = "cw3" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4054911cd88826fc7472851d4e799e6ca7246925cf318d6acd21a102486be30c" +dependencies = [ + "cosmwasm-schema", + "cosmwasm-std", + "cw-utils 0.16.0", + "schemars", + "serde", +] + [[package]] name = "cw4" version = "0.16.0" @@ -1065,6 +1192,19 @@ dependencies = [ "serde", ] +[[package]] +name = "cw721" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94a1ea6e6277bdd6dfc043a9b1380697fe29d6e24b072597439523658d21d791" +dependencies = [ + "cosmwasm-schema", + "cosmwasm-std", + "cw-utils 0.16.0", + "schemars", + "serde", +] + [[package]] name = "cw721-base" version = "0.15.0" @@ -1083,263 +1223,233 @@ dependencies = [ ] [[package]] -name = "cwd-core" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "cxx" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4a41a86530d0fe7f5d9ea779916b7cadd2d4f9add748b99c2c029cbbdfaf453" dependencies = [ - "cosmwasm-std", - "cosmwasm-storage", - "cw-core", - "cw-paginate 0.2.0", - "cw-storage-plus 0.13.4", - "cw-utils 0.13.4", - "cw2 0.13.4", - "cw20", - "cw721 0.13.4", - "cwd-interface", - "cwd-macros", - "schemars", - "serde", - "thiserror", + "cc", + "cxxbridge-flags", + "cxxbridge-macro", + "link-cplusplus", ] [[package]] -name = "cwd-hooks" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "cxx-build" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06416d667ff3e3ad2df1cd8cd8afae5da26cf9cec4d0825040f88b5ca659a2f0" +dependencies = [ + "cc", + "codespan-reporting", + "once_cell", + "proc-macro2", + "quote", + "scratch", + "syn", +] + +[[package]] +name = "cxxbridge-flags" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "820a9a2af1669deeef27cb271f476ffd196a2c4b6731336011e0ba63e2c7cf71" + +[[package]] +name = "cxxbridge-macro" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a08a6e2fcc370a089ad3b4aaf54db3b1b4cee38ddabce5896b33eb693275f470" dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "dao-core" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" +dependencies = [ + "cosmwasm-schema", "cosmwasm-std", - "cw-storage-plus 0.13.4", - "schemars", - "serde", + "cw-core", + "cw-paginate 2.0.0-beta", + "cw-storage-plus 0.16.0", + "cw-utils 0.16.0", + "cw2 0.16.0", + "cw20 0.16.0", + "cw721 0.16.0", + "dao-interface", + "dao-macros", "thiserror", ] [[package]] -name = "cwd-interface" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-interface" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", - "cw2 0.13.4", - "cwd-macros", - "schemars", - "serde", + "cw-hooks", + "cw2 0.16.0", + "dao-macros", ] [[package]] -name = "cwd-macros" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-macros" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "proc-macro2", "quote", "syn", ] [[package]] -name = "cwd-pre-propose-base" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-pre-propose-base" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", "cw-denom", - "cw-storage-plus 0.13.4", - "cw2 0.13.4", - "cwd-interface", - "cwd-proposal-hooks", - "cwd-voting", - "schemars", + "cw-hooks", + "cw-storage-plus 0.16.0", + "cw-utils 0.16.0", + "cw2 0.16.0", + "dao-interface", + "dao-proposal-hooks", + "dao-voting", "serde", "thiserror", ] [[package]] -name = "cwd-pre-propose-multiple" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" -dependencies = [ - "cosmwasm-std", - "cw2 0.13.4", - "cwd-pre-propose-base", - "cwd-voting", - "schemars", - "serde", -] - -[[package]] -name = "cwd-pre-propose-single" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-pre-propose-multiple" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", - "cw2 0.13.4", - "cwd-pre-propose-base", - "schemars", - "serde", + "cw2 0.16.0", + "dao-pre-propose-base", + "dao-voting", ] [[package]] -name = "cwd-proposal-hooks" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-proposal-hooks" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", - "cwd-hooks", - "cwd-voting", - "schemars", - "serde", + "cw-hooks", + "dao-voting", ] [[package]] -name = "cwd-proposal-multiple" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-proposal-multiple" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", "cosmwasm-storage", - "cw-storage-plus 0.13.4", - "cw-utils 0.13.4", - "cw2 0.13.4", - "cw20", - "cw3", - "cwd-core", - "cwd-hooks", - "cwd-interface", - "cwd-macros", - "cwd-pre-propose-base", - "cwd-pre-propose-multiple", - "cwd-proposal-hooks", - "cwd-vote-hooks", - "cwd-voting", - "schemars", - "serde", + "cw-hooks", + "cw-storage-plus 0.16.0", + "cw-utils 0.16.0", + "cw2 0.16.0", + "cw20 0.16.0", + "cw3 0.16.0", + "dao-core", + "dao-interface", + "dao-macros", + "dao-pre-propose-base", + "dao-pre-propose-multiple", + "dao-proposal-hooks", + "dao-vote-hooks", + "dao-voting", "thiserror", "voting", ] [[package]] -name = "cwd-proposal-single" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-proposal-single" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", "cosmwasm-storage", + "cw-hooks", "cw-proposal-single", - "cw-storage-plus 0.13.4", + "cw-storage-plus 0.16.0", "cw-utils 0.13.4", - "cw2 0.13.4", - "cw20", - "cw3", - "cwd-core", - "cwd-hooks", - "cwd-interface", - "cwd-macros", - "cwd-pre-propose-base", - "cwd-pre-propose-single", - "cwd-proposal-hooks", - "cwd-vote-hooks", - "cwd-voting", - "schemars", - "serde", + "cw-utils 0.16.0", + "cw2 0.16.0", + "cw20 0.16.0", + "cw3 0.16.0", + "dao-core", + "dao-interface", + "dao-macros", + "dao-pre-propose-base", + "dao-proposal-hooks", + "dao-vote-hooks", + "dao-voting", "thiserror", "voting", ] [[package]] -name = "cwd-vote-hooks" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-vote-hooks" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", - "cwd-hooks", - "cwd-voting", - "schemars", - "serde", + "cw-hooks", + "dao-voting", ] [[package]] -name = "cwd-voting" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-voting" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", "cw-denom", - "cw-storage-plus 0.13.4", - "cw-utils 0.13.4", - "cw20", - "cwd-core", - "cwd-interface", - "cwd-macros", - "schemars", - "serde", + "cw-storage-plus 0.16.0", + "cw-utils 0.16.0", + "cw20 0.16.0", + "dao-core", + "dao-interface", + "dao-macros", "thiserror", ] [[package]] -name = "cwd-voting-cw20-staked" -version = "0.2.0" -source = "git+https://github.com/DA0-DA0/dao-contracts#474e20183f74e64dafe396b16f40dfd285f235c2" +name = "dao-voting-cw20-staked" +version = "2.0.0-beta" +source = "git+https://github.com/DA0-DA0/dao-contracts?tag=v2.0.0#2aeea7464ce7fd484320269067a9149b01d7ee6d" dependencies = [ + "cosmwasm-schema", "cosmwasm-std", "cosmwasm-storage", - "cw-storage-plus 0.13.4", - "cw-utils 0.13.4", - "cw2 0.13.4", - "cw20", - "cw20-base", - "cw20-stake", - "cwd-interface", - "cwd-macros", - "schemars", - "serde", + "cw-storage-plus 0.16.0", + "cw-utils 0.16.0", + "cw2 0.16.0", + "cw20 0.16.0", + "cw20-base 0.16.0", + "cw20-stake 2.0.0-beta", + "dao-interface", + "dao-macros", "thiserror", ] -[[package]] -name = "cxx" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4a41a86530d0fe7f5d9ea779916b7cadd2d4f9add748b99c2c029cbbdfaf453" -dependencies = [ - "cc", - "cxxbridge-flags", - "cxxbridge-macro", - "link-cplusplus", -] - -[[package]] -name = "cxx-build" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06416d667ff3e3ad2df1cd8cd8afae5da26cf9cec4d0825040f88b5ca659a2f0" -dependencies = [ - "cc", - "codespan-reporting", - "once_cell", - "proc-macro2", - "quote", - "scratch", - "syn", -] - -[[package]] -name = "cxxbridge-flags" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "820a9a2af1669deeef27cb271f476ffd196a2c4b6731336011e0ba63e2c7cf71" - -[[package]] -name = "cxxbridge-macro" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a08a6e2fcc370a089ad3b4aaf54db3b1b4cee38ddabce5896b33eb693275f470" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - [[package]] name = "der" version = "0.6.0" @@ -1691,8 +1801,8 @@ dependencies = [ "cw-croncat", "cw-croncat-core", "cw-rules-core", - "cw20", - "cw20-base", + "cw20 0.16.0", + "cw20-base 0.16.0", "env_logger", "generic-query", "serde", diff --git a/Cargo.toml b/Cargo.toml index 8d38e2af..08579bb8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -22,7 +22,14 @@ overflow-checks = true [workspace.package] version = "0.0.3" -authors = ["meow@cron.cat", "@tjtc", "@mikedotexe","@NinoLipartiia","@Buckram123","deveusss"] +authors = [ + "meow@cron.cat", + "@tjtc", + "@mikedotexe", + "@NinoLipartiia", + "@Buckram123", + "deveusss", +] edition = "2021" description = "Croncat provides a general purpose, fully autonomous network that enables scheduled function calls for blockchain contract execution. It allows any application to schedule logic to get executed in the future, once or many times, triggered by an approved “agent,” in an economically stable format." documentation = "https://docs.cron.cat/" @@ -39,9 +46,9 @@ rusty-hook = "0.11.2" #For some reason it tries to deploy cw_core here # voting = { version = "0.2.0", default-features = false, git = "https://github.com/DA0-DA0/dao-contracts" } smart-query = { version = "0.1.0", path = "./packages/smart-query" } -cw20 = { version = "0.13.4" } +cw20 = { version = "0.16.0" } cw-multi-test = { version = "0.16.0" } -cw20-base = { version = "0.13.4", features = ["library"] } +cw20-base = { version = "0.16.0", features = ["library"] } cw-rules-core = { version = "0.1.2", path = "./packages/cw-rules-core" } cw-storage-plus = "0.16.0" cron_schedule = "0.2.3" @@ -49,16 +56,16 @@ cw2 = "0.16.0" hex = { version = "0.4", default-features = false } sha2 = { version = "0.10.6", default-features = false } serde-json-wasm = { version = "0.5.0" } -cw-utils = "0.13.4" +cw-utils = "0.16.0" cw721 = "0.15.0" # DAO contracts -cwd-voting = { version = "0.2.0", git = "https://github.com/DA0-DA0/dao-contracts.git" } -cwd-proposal-single = { version = "0.2.0", git = "https://github.com/DA0-DA0/dao-contracts" } -cwd-proposal-multiple = { version = "0.2.0", git = "https://github.com/DA0-DA0/dao-contracts" } -cwd-voting-cw20-staked = { version = "0.2.0", git = "https://github.com/DA0-DA0/dao-contracts" } -cw20-stake = { version = "0.2.6", git = "https://github.com/DA0-DA0/dao-contracts" } -cwd-core = { version = "0.2.0", git = "https://github.com/DA0-DA0/dao-contracts" } -cwd-interface = { version = "0.2.0", git = "https://github.com/DA0-DA0/dao-contracts" } +dao-voting = { version = "2.0.0-beta", git = "https://github.com/DA0-DA0/dao-contracts.git", tag = "v2.0.0" } +dao-proposal-single = { version = "2.0.0-beta", git = "https://github.com/DA0-DA0/dao-contracts", tag = "v2.0.0" } +dao-proposal-multiple = { version = "2.0.0-beta", git = "https://github.com/DA0-DA0/dao-contracts", tag = "v2.0.0" } +dao-voting-cw20-staked = { version = "2.0.0-beta", git = "https://github.com/DA0-DA0/dao-contracts", tag = "v2.0.0" } +cw20-stake = { version = "2.0.0-beta", git = "https://github.com/DA0-DA0/dao-contracts", tag = "v2.0.0" } +dao-core = { version = "2.0.0-beta", git = "https://github.com/DA0-DA0/dao-contracts", tag = "v2.0.0" } +dao-interface = { version = "2.0.0-beta", git = "https://github.com/DA0-DA0/dao-contracts", tag = "v2.0.0" } # Testing generic msg cw4 = "0.16.0" cw4-group = "0.16.0" diff --git a/ci/gas-benchmark/Cargo.toml b/ci/gas-benchmark/Cargo.toml index bd726400..f45e241c 100644 --- a/ci/gas-benchmark/Cargo.toml +++ b/ci/gas-benchmark/Cargo.toml @@ -13,8 +13,8 @@ serde_json = "1.0" serde = "1.0" env_logger = "0.9.0" -cw20-base = "0.13.4" -cw20 = "0.13.4" +cw20-base = "0.16.0" +cw20 = "0.16.0" cw-croncat-core = { version = "0.1.4", path = "../../packages/cw-croncat-core" } cw-rules-core = { version = "0.1.2", path = "../../packages/cw-rules-core" } diff --git a/contracts/cw-croncat/Cargo.toml b/contracts/cw-croncat/Cargo.toml index df3f9629..48c6816a 100644 --- a/contracts/cw-croncat/Cargo.toml +++ b/contracts/cw-croncat/Cargo.toml @@ -50,10 +50,10 @@ cw4 = { workspace = true } cw4-group = { workspace = true, features = ["library"] } smart-query = { workspace = true } generic-query = { workspace = true } -cwd-voting-cw20-staked = { workspace = true } +dao-voting-cw20-staked = { workspace = true } cw20-stake = { workspace = true } -cwd-core = { workspace = true } -cwd-interface = { workspace = true } -cwd-proposal-single = { workspace = true } -cwd-voting = { workspace = true } +dao-core = { workspace = true } +dao-interface = { workspace = true } +dao-proposal-single = { workspace = true } +dao-voting = { workspace = true } rusty-hook = { workspace = true } diff --git a/contracts/cw-croncat/src/tests/helpers.rs b/contracts/cw-croncat/src/tests/helpers.rs index 898315a1..a02e8b14 100644 --- a/contracts/cw-croncat/src/tests/helpers.rs +++ b/contracts/cw-croncat/src/tests/helpers.rs @@ -9,8 +9,8 @@ use cw_croncat_core::{ types::{BoundaryValidated, Interval, Task}, }; use cw_multi_test::{App, AppBuilder, Contract, ContractWrapper, Executor}; -use cwd_voting::threshold::{PercentageThreshold, Threshold}; -use cwd_voting_cw20_staked::msg::ActiveThreshold; +use dao_voting::threshold::{PercentageThreshold, Threshold}; +use dao_voting_cw20_staked::msg::ActiveThreshold; use crate::{helpers::CwTemplateContract, ContractError, CwCroncat}; @@ -88,32 +88,32 @@ pub fn cw20_stake_contract() -> Box> { pub fn cw20_staked_balances_voting() -> Box> { let contract = ContractWrapper::new( - cwd_voting_cw20_staked::contract::execute, - cwd_voting_cw20_staked::contract::instantiate, - cwd_voting_cw20_staked::contract::query, + dao_voting_cw20_staked::contract::execute, + dao_voting_cw20_staked::contract::instantiate, + dao_voting_cw20_staked::contract::query, ) - .with_reply(cwd_voting_cw20_staked::contract::reply); + .with_reply(dao_voting_cw20_staked::contract::reply); Box::new(contract) } pub fn cw_gov_contract() -> Box> { let contract = ContractWrapper::new( - cwd_core::contract::execute, - cwd_core::contract::instantiate, - cwd_core::contract::query, + dao_core::contract::execute, + dao_core::contract::instantiate, + dao_core::contract::query, ) - .with_reply(cwd_core::contract::reply); + .with_reply(dao_core::contract::reply); Box::new(contract) } pub fn single_proposal_contract() -> Box> { let contract = ContractWrapper::new( - cwd_proposal_single::contract::execute, - cwd_proposal_single::contract::instantiate, - cwd_proposal_single::contract::query, + dao_proposal_single::contract::execute, + dao_proposal_single::contract::instantiate, + dao_proposal_single::contract::query, ) - .with_reply(cwd_proposal_single::contract::reply) - .with_migrate(cwd_proposal_single::contract::migrate); + .with_reply(dao_proposal_single::contract::reply) + .with_migrate(dao_proposal_single::contract::migrate); Box::new(contract) } @@ -245,29 +245,29 @@ pub fn proper_instantiate_with_dao( percentage: PercentageThreshold::Majority {}, }; let max_voting_period = cw_utils::Duration::Height(6); - let instantiate_govmod = cwd_proposal_single::msg::InstantiateMsg { + let instantiate_govmod = dao_proposal_single::msg::InstantiateMsg { threshold, max_voting_period, min_voting_period: None, only_members_execute: false, allow_revoting: false, close_proposal_on_execution_failure: true, - pre_propose_info: cwd_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, + pre_propose_info: dao_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, }; to_binary(&instantiate_govmod).unwrap() }); - let governance_instantiate = cwd_core::msg::InstantiateMsg { + let governance_instantiate = dao_core::msg::InstantiateMsg { admin: None, name: "DAO DAO".to_string(), description: "A DAO that builds DAOs".to_string(), image_url: None, automatically_add_cw20s: true, automatically_add_cw721s: true, - voting_module_instantiate_info: cwd_interface::ModuleInstantiateInfo { + voting_module_instantiate_info: dao_interface::ModuleInstantiateInfo { code_id: votemod_id, - msg: to_binary(&cwd_voting_cw20_staked::msg::InstantiateMsg { - token_info: cwd_voting_cw20_staked::msg::TokenInfo::New { + msg: to_binary(&dao_voting_cw20_staked::msg::InstantiateMsg { + token_info: dao_voting_cw20_staked::msg::TokenInfo::New { code_id: cw20_id, label: "DAO DAO governance token".to_string(), name: "DAO".to_string(), @@ -282,13 +282,13 @@ pub fn proper_instantiate_with_dao( active_threshold, }) .unwrap(), - admin: Some(cwd_interface::Admin::CoreModule {}), + admin: Some(dao_interface::Admin::CoreModule {}), label: "DAO DAO voting module".to_string(), }, - proposal_modules_instantiate_info: vec![cwd_interface::ModuleInstantiateInfo { + proposal_modules_instantiate_info: vec![dao_interface::ModuleInstantiateInfo { code_id: proposal_module_code_id, msg: proposal_module_instantiate, - admin: Some(cwd_interface::Admin::CoreModule {}), + admin: Some(dao_interface::Admin::CoreModule {}), label: "DAO DAO governance module".to_string(), }], initial_items: None, diff --git a/contracts/cw-croncat/src/tests/manager.rs b/contracts/cw-croncat/src/tests/manager.rs index c18a6268..bdd556eb 100644 --- a/contracts/cw-croncat/src/tests/manager.rs +++ b/contracts/cw-croncat/src/tests/manager.rs @@ -20,7 +20,8 @@ use cw_croncat_core::msg::{ use cw_croncat_core::types::{Action, Boundary, Interval, Transform}; use cw_multi_test::Executor; use cw_rules_core::types::{CroncatQuery, HasBalanceGte}; -use cwd_core::state::ProposalModule; +use dao_core::state::ProposalModule; +use dao_voting::proposal::SingleChoiceProposeMsg; use generic_query::{GenericQuery, PathToValue, ValueIndex, ValueOrdering}; use smart_query::{SmartQueries, SmartQuery, SmartQueryHead}; @@ -2959,7 +2960,7 @@ fn test_error_in_reply() { .wrap() .query_wasm_smart( governance_addr.clone(), - &cwd_core::msg::QueryMsg::ProposalModules { + &dao_core::msg::QueryMsg::ProposalModules { start_after: None, limit: None, }, @@ -2968,30 +2969,30 @@ fn test_error_in_reply() { let govmod_single = governance_modules.into_iter().next().unwrap().address; - let govmod_config: cwd_proposal_single::state::Config = app + let govmod_config: dao_proposal_single::state::Config = app .wrap() .query_wasm_smart( govmod_single.clone(), - &cwd_proposal_single::msg::QueryMsg::Config {}, + &dao_proposal_single::msg::QueryMsg::Config {}, ) .unwrap(); let dao = govmod_config.dao; let voting_module: Addr = app .wrap() - .query_wasm_smart(dao, &cwd_core::msg::QueryMsg::VotingModule {}) + .query_wasm_smart(dao, &dao_core::msg::QueryMsg::VotingModule {}) .unwrap(); let staking_contract: Addr = app .wrap() .query_wasm_smart( voting_module.clone(), - &cwd_voting_cw20_staked::msg::QueryMsg::StakingContract {}, + &dao_voting_cw20_staked::msg::QueryMsg::StakingContract {}, ) .unwrap(); let token_contract: Addr = app .wrap() .query_wasm_smart( voting_module, - &cwd_interface::voting::Query::TokenContract {}, + &dao_interface::voting::Query::TokenContract {}, ) .unwrap(); @@ -3008,17 +3009,17 @@ fn test_error_in_reply() { app.execute_contract( Addr::unchecked(ADMIN), govmod_single.clone(), - &cwd_proposal_single::msg::ExecuteMsg::Propose { + &dao_proposal_single::msg::ExecuteMsg::Propose(SingleChoiceProposeMsg { title: "Cron".to_string(), description: "Cat".to_string(), msgs: vec![], proposer: None, - }, + }), &[], ) .unwrap(); - let execute_msg = cwd_proposal_single::msg::ExecuteMsg::Execute { proposal_id: 1 }; + let execute_msg = dao_proposal_single::msg::ExecuteMsg::Execute { proposal_id: 1 }; // create a task for executing proposal let wasm = WasmMsg::Execute { diff --git a/contracts/cw-rules/Cargo.toml b/contracts/cw-rules/Cargo.toml index 1e36083e..1309fc3f 100644 --- a/contracts/cw-rules/Cargo.toml +++ b/contracts/cw-rules/Cargo.toml @@ -50,13 +50,13 @@ cw-multi-test = { workspace = true } cw-utils = { workspace = true } cw20-base = { workspace = true } # DAO contracts -cwd-voting = { workspace = true } -cwd-proposal-single = { workspace = true } -cwd-proposal-multiple = { workspace = true } -cwd-voting-cw20-staked = { workspace = true } +dao-voting = { workspace = true } +dao-proposal-single = { workspace = true } +dao-proposal-multiple = { workspace = true } +dao-voting-cw20-staked = { workspace = true } cw20-stake = { workspace = true } -cwd-core = { workspace = true } -cwd-interface = { workspace = true } +dao-core = { workspace = true } +dao-interface = { workspace = true } # Testing generic msg cw4 = { workspace = true } cw4-group = { workspace = true } diff --git a/contracts/cw-rules/src/tests/daodao.rs b/contracts/cw-rules/src/tests/daodao.rs index f7bb78e1..52b2a278 100644 --- a/contracts/cw-rules/src/tests/daodao.rs +++ b/contracts/cw-rules/src/tests/daodao.rs @@ -2,18 +2,19 @@ use cosmwasm_std::{to_binary, Addr, Binary, Uint128}; use cw20::Cw20Coin; use cw_multi_test::{next_block, App, Executor}; use cw_rules_core::types::{CheckPassedProposals, CheckProposalStatus, Status}; -use cwd_core::state::ProposalModule; -use cwd_proposal_multiple::proposal::MultipleChoiceProposal; -use cwd_proposal_single::proposal::SingleChoiceProposal; -use cwd_voting::{ +use dao_core::state::ProposalModule; +use dao_proposal_multiple::proposal::MultipleChoiceProposal; +use dao_proposal_single::proposal::SingleChoiceProposal; +use dao_voting::{ multiple_choice::{ CheckedMultipleChoiceOption, MultipleChoiceOption, MultipleChoiceOptionType, MultipleChoiceOptions, MultipleChoiceVote, MultipleChoiceVotes, VotingStrategy, }, + proposal::SingleChoiceProposeMsg, threshold::{PercentageThreshold, Threshold}, voting::{Vote, Votes}, }; -use cwd_voting_cw20_staked::msg::ActiveThreshold; +use dao_voting_cw20_staked::msg::ActiveThreshold; use cw_rules_core::msg::{InstantiateMsg, QueryMsg, QueryResponse}; @@ -44,17 +45,17 @@ fn instantiate_with_staking_active_threshold( }] }); - let governance_instantiate = cwd_core::msg::InstantiateMsg { + let governance_instantiate = dao_core::msg::InstantiateMsg { admin: None, name: "DAO DAO".to_string(), description: "A DAO that builds DAOs".to_string(), image_url: None, automatically_add_cw20s: true, automatically_add_cw721s: true, - voting_module_instantiate_info: cwd_interface::ModuleInstantiateInfo { + voting_module_instantiate_info: dao_interface::ModuleInstantiateInfo { code_id: votemod_id, - msg: to_binary(&cwd_voting_cw20_staked::msg::InstantiateMsg { - token_info: cwd_voting_cw20_staked::msg::TokenInfo::New { + msg: to_binary(&dao_voting_cw20_staked::msg::InstantiateMsg { + token_info: dao_voting_cw20_staked::msg::TokenInfo::New { code_id: cw20_id, label: "DAO DAO governance token".to_string(), name: "DAO".to_string(), @@ -69,13 +70,13 @@ fn instantiate_with_staking_active_threshold( active_threshold, }) .unwrap(), - admin: Some(cwd_interface::Admin::CoreModule {}), + admin: Some(dao_interface::Admin::CoreModule {}), label: "DAO DAO voting module".to_string(), }, - proposal_modules_instantiate_info: vec![cwd_interface::ModuleInstantiateInfo { + proposal_modules_instantiate_info: vec![dao_interface::ModuleInstantiateInfo { code_id: proposal_module_code_id, msg: proposal_module_instantiate, - admin: Some(cwd_interface::Admin::CoreModule {}), + admin: Some(dao_interface::Admin::CoreModule {}), label: "DAO DAO governance module".to_string(), }], initial_items: None, @@ -115,14 +116,14 @@ fn test_dao_single_proposal_ready() { percentage: PercentageThreshold::Majority {}, }; let max_voting_period = cw_utils::Duration::Height(6); - let instantiate_govmod = cwd_proposal_single::msg::InstantiateMsg { + let instantiate_govmod = dao_proposal_single::msg::InstantiateMsg { threshold: threshold.clone(), max_voting_period, min_voting_period: None, only_members_execute: false, allow_revoting: false, close_proposal_on_execution_failure: true, - pre_propose_info: cwd_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, + pre_propose_info: dao_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, }; let governance_addr = instantiate_with_staking_active_threshold( &mut app, @@ -135,7 +136,7 @@ fn test_dao_single_proposal_ready() { .wrap() .query_wasm_smart( governance_addr, - &cwd_core::msg::QueryMsg::ProposalModules { + &dao_core::msg::QueryMsg::ProposalModules { start_after: None, limit: None, }, @@ -145,30 +146,30 @@ fn test_dao_single_proposal_ready() { assert_eq!(governance_modules.len(), 1); let govmod_single = governance_modules.into_iter().next().unwrap().address; - let govmod_config: cwd_proposal_single::state::Config = app + let govmod_config: dao_proposal_single::state::Config = app .wrap() .query_wasm_smart( govmod_single.clone(), - &cwd_proposal_single::msg::QueryMsg::Config {}, + &dao_proposal_single::msg::QueryMsg::Config {}, ) .unwrap(); let dao = govmod_config.dao; let voting_module: Addr = app .wrap() - .query_wasm_smart(dao, &cwd_core::msg::QueryMsg::VotingModule {}) + .query_wasm_smart(dao, &dao_core::msg::QueryMsg::VotingModule {}) .unwrap(); let staking_contract: Addr = app .wrap() .query_wasm_smart( voting_module.clone(), - &cwd_voting_cw20_staked::msg::QueryMsg::StakingContract {}, + &dao_voting_cw20_staked::msg::QueryMsg::StakingContract {}, ) .unwrap(); let token_contract: Addr = app .wrap() .query_wasm_smart( voting_module, - &cwd_interface::voting::Query::TokenContract {}, + &dao_interface::voting::Query::TokenContract {}, ) .unwrap(); @@ -190,12 +191,12 @@ fn test_dao_single_proposal_ready() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_single::msg::ExecuteMsg::Propose { + &dao_proposal_single::msg::ExecuteMsg::Propose(SingleChoiceProposeMsg { title: "Cron".to_string(), description: "Cat".to_string(), msgs: vec![], proposer: None, - }, + }), &[], ) .unwrap(); @@ -216,7 +217,7 @@ fn test_dao_single_proposal_ready() { res, QueryResponse { result: false, - data: to_binary(&cwd_proposal_single::query::ProposalResponse { + data: to_binary(&dao_proposal_single::query::ProposalResponse { id: 1, proposal: SingleChoiceProposal { title: "Cron".to_string(), @@ -228,7 +229,7 @@ fn test_dao_single_proposal_ready() { threshold: threshold.clone(), total_power: Uint128::new(2000), msgs: vec![], - status: cwd_voting::status::Status::Open, + status: dao_voting::status::Status::Open, votes: Votes { yes: Uint128::zero(), no: Uint128::zero(), @@ -245,9 +246,10 @@ fn test_dao_single_proposal_ready() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_single::msg::ExecuteMsg::Vote { + &dao_proposal_single::msg::ExecuteMsg::Vote { proposal_id: 1, vote: Vote::Yes, + rationale: None, }, &[], ) @@ -269,7 +271,7 @@ fn test_dao_single_proposal_ready() { res, QueryResponse { result: true, - data: to_binary(&cwd_proposal_single::query::ProposalResponse { + data: to_binary(&dao_proposal_single::query::ProposalResponse { id: 1, proposal: SingleChoiceProposal { title: "Cron".to_string(), @@ -281,7 +283,7 @@ fn test_dao_single_proposal_ready() { threshold: threshold.clone(), total_power: Uint128::new(2000), msgs: vec![], - status: cwd_voting::status::Status::Passed, + status: dao_voting::status::Status::Passed, votes: Votes { yes: Uint128::new(2000), no: Uint128::zero(), @@ -296,7 +298,7 @@ fn test_dao_single_proposal_ready() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_single::msg::ExecuteMsg::Execute { proposal_id: 1 }, + &dao_proposal_single::msg::ExecuteMsg::Execute { proposal_id: 1 }, &[], ) .unwrap(); @@ -318,7 +320,7 @@ fn test_dao_single_proposal_ready() { res, QueryResponse { result: true, - data: to_binary(&cwd_proposal_single::query::ProposalResponse { + data: to_binary(&dao_proposal_single::query::ProposalResponse { id: 1, proposal: SingleChoiceProposal { title: "Cron".to_string(), @@ -330,7 +332,7 @@ fn test_dao_single_proposal_ready() { threshold: threshold.clone(), total_power: Uint128::new(2000), msgs: vec![], - status: cwd_voting::status::Status::Executed, + status: dao_voting::status::Status::Executed, votes: Votes { yes: Uint128::new(2000), no: Uint128::zero(), @@ -365,14 +367,14 @@ fn test_dao_multiple_proposal_ready() { quorum: PercentageThreshold::Majority {}, }; let max_voting_period = cw_utils::Duration::Height(6); - let instantiate_govmod = cwd_proposal_multiple::msg::InstantiateMsg { + let instantiate_govmod = dao_proposal_multiple::msg::InstantiateMsg { voting_strategy: voting_strategy.clone(), max_voting_period, min_voting_period: None, only_members_execute: false, allow_revoting: false, close_proposal_on_execution_failure: true, - pre_propose_info: cwd_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, + pre_propose_info: dao_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, }; let governance_addr = instantiate_with_staking_active_threshold( &mut app, @@ -385,7 +387,7 @@ fn test_dao_multiple_proposal_ready() { .wrap() .query_wasm_smart( governance_addr, - &cwd_core::msg::QueryMsg::ProposalModules { + &dao_core::msg::QueryMsg::ProposalModules { start_after: None, limit: None, }, @@ -395,30 +397,30 @@ fn test_dao_multiple_proposal_ready() { assert_eq!(governance_modules.len(), 1); let govmod_single = governance_modules.into_iter().next().unwrap().address; - let govmod_config: cwd_proposal_multiple::state::Config = app + let govmod_config: dao_proposal_multiple::state::Config = app .wrap() .query_wasm_smart( govmod_single.clone(), - &cwd_proposal_multiple::msg::QueryMsg::Config {}, + &dao_proposal_multiple::msg::QueryMsg::Config {}, ) .unwrap(); let dao = govmod_config.dao; let voting_module: Addr = app .wrap() - .query_wasm_smart(dao, &cwd_core::msg::QueryMsg::VotingModule {}) + .query_wasm_smart(dao, &dao_core::msg::QueryMsg::VotingModule {}) .unwrap(); let staking_contract: Addr = app .wrap() .query_wasm_smart( voting_module.clone(), - &cwd_voting_cw20_staked::msg::QueryMsg::StakingContract {}, + &dao_voting_cw20_staked::msg::QueryMsg::StakingContract {}, ) .unwrap(); let token_contract: Addr = app .wrap() .query_wasm_smart( voting_module, - &cwd_interface::voting::Query::TokenContract {}, + &dao_interface::voting::Query::TokenContract {}, ) .unwrap(); @@ -440,18 +442,20 @@ fn test_dao_multiple_proposal_ready() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_multiple::msg::ExecuteMsg::Propose { + &dao_proposal_multiple::msg::ExecuteMsg::Propose { title: "Cron".to_string(), description: "Cat".to_string(), choices: MultipleChoiceOptions { options: vec![ MultipleChoiceOption { + title: "b".to_string(), description: "a".to_string(), - msgs: None, + msgs: vec![], }, MultipleChoiceOption { + title: "a".to_string(), description: "b".to_string(), - msgs: None, + msgs: vec![], }, ], }, @@ -477,7 +481,7 @@ fn test_dao_multiple_proposal_ready() { res, QueryResponse { result: false, - data: to_binary(&cwd_proposal_multiple::query::ProposalResponse { + data: to_binary(&dao_proposal_multiple::query::ProposalResponse { id: 1, proposal: MultipleChoiceProposal { title: "Cron".to_string(), @@ -487,31 +491,34 @@ fn test_dao_multiple_proposal_ready() { min_voting_period: None, expiration: cw_utils::Expiration::AtHeight(12352), total_power: Uint128::new(2000), - status: cwd_voting::status::Status::Open, + status: dao_voting::status::Status::Open, votes: MultipleChoiceVotes { vote_weights: vec![Uint128::zero(), Uint128::zero(), Uint128::zero()] }, allow_revoting: false, choices: vec![ CheckedMultipleChoiceOption { + title: "b".to_string(), index: 0, option_type: MultipleChoiceOptionType::Standard, description: "a".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() }, CheckedMultipleChoiceOption { + title: "a".to_string(), index: 1, option_type: MultipleChoiceOptionType::Standard, description: "b".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() }, CheckedMultipleChoiceOption { + title: "None of the above".to_string(), index: 2, option_type: MultipleChoiceOptionType::None, description: "None of the above".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() } ], @@ -526,7 +533,7 @@ fn test_dao_multiple_proposal_ready() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_multiple::msg::ExecuteMsg::Vote { + &dao_proposal_multiple::msg::ExecuteMsg::Vote { proposal_id: 1, vote: MultipleChoiceVote { option_id: 0 }, }, @@ -550,7 +557,7 @@ fn test_dao_multiple_proposal_ready() { res, QueryResponse { result: true, - data: to_binary(&cwd_proposal_multiple::query::ProposalResponse { + data: to_binary(&dao_proposal_multiple::query::ProposalResponse { id: 1, proposal: MultipleChoiceProposal { title: "Cron".to_string(), @@ -560,31 +567,34 @@ fn test_dao_multiple_proposal_ready() { min_voting_period: None, expiration: cw_utils::Expiration::AtHeight(12352), total_power: Uint128::new(2000), - status: cwd_voting::status::Status::Passed, + status: dao_voting::status::Status::Passed, votes: MultipleChoiceVotes { vote_weights: vec![Uint128::new(2000), Uint128::zero(), Uint128::zero()] }, allow_revoting: false, choices: vec![ CheckedMultipleChoiceOption { + title: "b".to_string(), index: 0, option_type: MultipleChoiceOptionType::Standard, description: "a".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() }, CheckedMultipleChoiceOption { + title: "a".to_string(), index: 1, option_type: MultipleChoiceOptionType::Standard, description: "b".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() }, CheckedMultipleChoiceOption { + title: "None of the above".to_string(), index: 2, option_type: MultipleChoiceOptionType::None, description: "None of the above".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() } ], @@ -598,7 +608,7 @@ fn test_dao_multiple_proposal_ready() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_multiple::msg::ExecuteMsg::Execute { proposal_id: 1 }, + &dao_proposal_multiple::msg::ExecuteMsg::Execute { proposal_id: 1 }, &[], ) .unwrap(); @@ -620,7 +630,7 @@ fn test_dao_multiple_proposal_ready() { res, QueryResponse { result: true, - data: to_binary(&cwd_proposal_multiple::query::ProposalResponse { + data: to_binary(&dao_proposal_multiple::query::ProposalResponse { id: 1, proposal: MultipleChoiceProposal { title: "Cron".to_string(), @@ -630,31 +640,34 @@ fn test_dao_multiple_proposal_ready() { min_voting_period: None, expiration: cw_utils::Expiration::AtHeight(12352), total_power: Uint128::new(2000), - status: cwd_voting::status::Status::Executed, + status: dao_voting::status::Status::Executed, votes: MultipleChoiceVotes { vote_weights: vec![Uint128::new(2000), Uint128::zero(), Uint128::zero()] }, allow_revoting: false, choices: vec![ CheckedMultipleChoiceOption { + title: "b".to_string(), index: 0, option_type: MultipleChoiceOptionType::Standard, description: "a".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() }, CheckedMultipleChoiceOption { + title: "a".to_string(), index: 1, option_type: MultipleChoiceOptionType::Standard, description: "b".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() }, CheckedMultipleChoiceOption { + title: "None of the above".to_string(), index: 2, option_type: MultipleChoiceOptionType::None, description: "None of the above".to_owned(), - msgs: None, + msgs: vec![], vote_count: Uint128::zero() } ], @@ -688,14 +701,14 @@ fn test_single_check_passed_proposals() { percentage: PercentageThreshold::Majority {}, }; let max_voting_period = cw_utils::Duration::Height(6); - let instantiate_govmod = cwd_proposal_single::msg::InstantiateMsg { + let instantiate_govmod = dao_proposal_single::msg::InstantiateMsg { threshold, max_voting_period, min_voting_period: None, only_members_execute: false, allow_revoting: false, close_proposal_on_execution_failure: true, - pre_propose_info: cwd_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, + pre_propose_info: dao_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, }; let governance_addr = instantiate_with_staking_active_threshold( &mut app, @@ -708,7 +721,7 @@ fn test_single_check_passed_proposals() { .wrap() .query_wasm_smart( governance_addr, - &cwd_core::msg::QueryMsg::ProposalModules { + &dao_core::msg::QueryMsg::ProposalModules { start_after: None, limit: None, }, @@ -718,30 +731,30 @@ fn test_single_check_passed_proposals() { assert_eq!(governance_modules.len(), 1); let govmod_single = governance_modules.into_iter().next().unwrap().address; - let govmod_config: cwd_proposal_single::state::Config = app + let govmod_config: dao_proposal_single::state::Config = app .wrap() .query_wasm_smart( govmod_single.clone(), - &cwd_proposal_single::msg::QueryMsg::Config {}, + &dao_proposal_single::msg::QueryMsg::Config {}, ) .unwrap(); let dao = govmod_config.dao; let voting_module: Addr = app .wrap() - .query_wasm_smart(dao, &cwd_core::msg::QueryMsg::VotingModule {}) + .query_wasm_smart(dao, &dao_core::msg::QueryMsg::VotingModule {}) .unwrap(); let staking_contract: Addr = app .wrap() .query_wasm_smart( voting_module.clone(), - &cwd_voting_cw20_staked::msg::QueryMsg::StakingContract {}, + &dao_voting_cw20_staked::msg::QueryMsg::StakingContract {}, ) .unwrap(); let token_contract: Addr = app .wrap() .query_wasm_smart( voting_module, - &cwd_interface::voting::Query::TokenContract {}, + &dao_interface::voting::Query::TokenContract {}, ) .unwrap(); @@ -769,12 +782,12 @@ fn test_single_check_passed_proposals() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_single::msg::ExecuteMsg::Propose { + &dao_proposal_single::msg::ExecuteMsg::Propose(SingleChoiceProposeMsg { title, description, msgs: vec![], proposer: None, - }, + }), &[], ) .unwrap(); @@ -797,9 +810,10 @@ fn test_single_check_passed_proposals() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_single::msg::ExecuteMsg::Vote { + &dao_proposal_single::msg::ExecuteMsg::Vote { proposal_id: 2 * num as u64, vote: Vote::Yes, + rationale: None, }, &[], ) @@ -832,7 +846,7 @@ fn test_single_check_passed_proposals() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_single::msg::ExecuteMsg::Execute { proposal_id: index }, + &dao_proposal_single::msg::ExecuteMsg::Execute { proposal_id: index }, &[], ) .unwrap(); @@ -873,14 +887,14 @@ fn test_multiple_check_passed_proposals() { quorum: PercentageThreshold::Majority {}, }; let max_voting_period = cw_utils::Duration::Height(6); - let instantiate_govmod = cwd_proposal_multiple::msg::InstantiateMsg { + let instantiate_govmod = dao_proposal_multiple::msg::InstantiateMsg { voting_strategy, max_voting_period, min_voting_period: None, only_members_execute: false, allow_revoting: false, close_proposal_on_execution_failure: true, - pre_propose_info: cwd_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, + pre_propose_info: dao_voting::pre_propose::PreProposeInfo::AnyoneMayPropose {}, }; let governance_addr = instantiate_with_staking_active_threshold( &mut app, @@ -893,7 +907,7 @@ fn test_multiple_check_passed_proposals() { .wrap() .query_wasm_smart( governance_addr, - &cwd_core::msg::QueryMsg::ProposalModules { + &dao_core::msg::QueryMsg::ProposalModules { start_after: None, limit: None, }, @@ -903,30 +917,30 @@ fn test_multiple_check_passed_proposals() { assert_eq!(governance_modules.len(), 1); let govmod_single = governance_modules.into_iter().next().unwrap().address; - let govmod_config: cwd_proposal_multiple::state::Config = app + let govmod_config: dao_proposal_multiple::state::Config = app .wrap() .query_wasm_smart( govmod_single.clone(), - &cwd_proposal_multiple::msg::QueryMsg::Config {}, + &dao_proposal_multiple::msg::QueryMsg::Config {}, ) .unwrap(); let dao = govmod_config.dao; let voting_module: Addr = app .wrap() - .query_wasm_smart(dao, &cwd_core::msg::QueryMsg::VotingModule {}) + .query_wasm_smart(dao, &dao_core::msg::QueryMsg::VotingModule {}) .unwrap(); let staking_contract: Addr = app .wrap() .query_wasm_smart( voting_module.clone(), - &cwd_voting_cw20_staked::msg::QueryMsg::StakingContract {}, + &dao_voting_cw20_staked::msg::QueryMsg::StakingContract {}, ) .unwrap(); let token_contract: Addr = app .wrap() .query_wasm_smart( voting_module, - &cwd_interface::voting::Query::TokenContract {}, + &dao_interface::voting::Query::TokenContract {}, ) .unwrap(); @@ -954,18 +968,20 @@ fn test_multiple_check_passed_proposals() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_multiple::msg::ExecuteMsg::Propose { + &dao_proposal_multiple::msg::ExecuteMsg::Propose { title, description, choices: MultipleChoiceOptions { options: vec![ MultipleChoiceOption { + title: "b".to_string(), description: "a".to_string(), - msgs: None, + msgs: vec![], }, MultipleChoiceOption { + title: "a".to_string(), description: "b".to_string(), - msgs: None, + msgs: vec![], }, ], }, @@ -993,7 +1009,7 @@ fn test_multiple_check_passed_proposals() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_multiple::msg::ExecuteMsg::Vote { + &dao_proposal_multiple::msg::ExecuteMsg::Vote { proposal_id: 2 * num as u64, vote: MultipleChoiceVote { option_id: 0 }, }, @@ -1029,7 +1045,7 @@ fn test_multiple_check_passed_proposals() { app.execute_contract( Addr::unchecked(CREATOR_ADDR), govmod_single.clone(), - &cwd_proposal_multiple::msg::ExecuteMsg::Execute { proposal_id: index }, + &dao_proposal_multiple::msg::ExecuteMsg::Execute { proposal_id: index }, &[], ) .unwrap(); diff --git a/contracts/cw-rules/src/tests/helpers.rs b/contracts/cw-rules/src/tests/helpers.rs index 2e2da34a..3e92befd 100644 --- a/contracts/cw-rules/src/tests/helpers.rs +++ b/contracts/cw-rules/src/tests/helpers.rs @@ -57,43 +57,43 @@ pub fn cw20_stake_contract() -> Box> { pub fn single_proposal_contract() -> Box> { let contract = ContractWrapper::new( - cwd_proposal_single::contract::execute, - cwd_proposal_single::contract::instantiate, - cwd_proposal_single::contract::query, + dao_proposal_single::contract::execute, + dao_proposal_single::contract::instantiate, + dao_proposal_single::contract::query, ) - .with_reply(cwd_proposal_single::contract::reply) - .with_migrate(cwd_proposal_single::contract::migrate); + .with_reply(dao_proposal_single::contract::reply) + .with_migrate(dao_proposal_single::contract::migrate); Box::new(contract) } pub fn multiple_proposal_contract() -> Box> { let contract = ContractWrapper::new( - cwd_proposal_multiple::contract::execute, - cwd_proposal_multiple::contract::instantiate, - cwd_proposal_multiple::contract::query, + dao_proposal_multiple::contract::execute, + dao_proposal_multiple::contract::instantiate, + dao_proposal_multiple::contract::query, ) - .with_reply(cwd_proposal_multiple::contract::reply) - .with_migrate(cwd_proposal_multiple::contract::migrate); + .with_reply(dao_proposal_multiple::contract::reply) + .with_migrate(dao_proposal_multiple::contract::migrate); Box::new(contract) } pub fn cw_gov_contract() -> Box> { let contract = ContractWrapper::new( - cwd_core::contract::execute, - cwd_core::contract::instantiate, - cwd_core::contract::query, + dao_core::contract::execute, + dao_core::contract::instantiate, + dao_core::contract::query, ) - .with_reply(cwd_core::contract::reply); + .with_reply(dao_core::contract::reply); Box::new(contract) } pub fn cw20_staked_balances_voting() -> Box> { let contract = ContractWrapper::new( - cwd_voting_cw20_staked::contract::execute, - cwd_voting_cw20_staked::contract::instantiate, - cwd_voting_cw20_staked::contract::query, + dao_voting_cw20_staked::contract::execute, + dao_voting_cw20_staked::contract::instantiate, + dao_voting_cw20_staked::contract::query, ) - .with_reply(cwd_voting_cw20_staked::contract::reply); + .with_reply(dao_voting_cw20_staked::contract::reply); Box::new(contract) } From 572c81fe8dbd0af1979d6c41a9e5d86da89647ca Mon Sep 17 00:00:00 2001 From: Buckram Date: Tue, 10 Jan 2023 14:19:57 +0200 Subject: [PATCH 2/4] let else stable --- .github/workflows/Basic.yml | 4 ++-- .github/workflows/checksum.yml | 2 +- .github/workflows/gas_benchmark.yml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/Basic.yml b/.github/workflows/Basic.yml index 08679623..3d4f808e 100644 --- a/.github/workflows/Basic.yml +++ b/.github/workflows/Basic.yml @@ -17,7 +17,7 @@ jobs: uses: actions-rs/toolchain@v1 with: profile: minimal - toolchain: 1.64.0 + toolchain: 1.66.0 target: wasm32-unknown-unknown override: true @@ -48,7 +48,7 @@ jobs: uses: actions-rs/toolchain@v1 with: profile: minimal - toolchain: 1.64.0 + toolchain: 1.66.0 override: true components: rustfmt, clippy diff --git a/.github/workflows/checksum.yml b/.github/workflows/checksum.yml index 7f4209b8..5981fa58 100644 --- a/.github/workflows/checksum.yml +++ b/.github/workflows/checksum.yml @@ -16,7 +16,7 @@ jobs: uses: actions-rs/toolchain@v1 with: profile: minimal - toolchain: 1.64.0 + toolchain: 1.66.0 target: wasm32-unknown-unknown override: true diff --git a/.github/workflows/gas_benchmark.yml b/.github/workflows/gas_benchmark.yml index e9cff444..225dd24b 100644 --- a/.github/workflows/gas_benchmark.yml +++ b/.github/workflows/gas_benchmark.yml @@ -19,7 +19,7 @@ jobs: uses: actions-rs/toolchain@v1 with: profile: minimal - toolchain: 1.64.0 + toolchain: 1.66.0 target: wasm32-unknown-unknown override: true From 66859c6cda552fe81557de4ccceb9f89ac530310 Mon Sep 17 00:00:00 2001 From: Buckram Date: Tue, 10 Jan 2023 14:20:05 +0200 Subject: [PATCH 3/4] checksum --- checksum | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/checksum b/checksum index aca2110b..3891ed8c 100644 --- a/checksum +++ b/checksum @@ -1,2 +1,2 @@ -b589630b11c5c0b1734b5c2cd7163efdbf7d4f25e7401d0662bd589c8225b628 cw_croncat.wasm -ce9221c037fb3c97b88fab2441130533d52df2e1f684663906444b2046bcdfb0 cw_rules.wasm +9884618521f86628a3b4832a5e12e09b1ee4490c813f69e4fdd6f3c527d0e308 cw_croncat.wasm +eedc7ddb135af983d75c6f95030fb25e736e218e48754746e43ae9d4d677e027 cw_rules.wasm From 87bb486a0dd9022749dc12c206141582d94a4228 Mon Sep 17 00:00:00 2001 From: Buckram Date: Tue, 10 Jan 2023 14:27:25 +0200 Subject: [PATCH 4/4] schema --- packages/cw-croncat-core/schema/croncat.json | 6 ++++-- packages/cw-croncat-core/schema/execute_msg.json | 9 ++++++--- packages/cw-croncat-core/schema/get_agent_response.json | 3 ++- .../cw-croncat-core/schema/get_agent_tasks_response.json | 3 ++- packages/cw-croncat-core/schema/get_task_response.json | 3 ++- .../schema/get_tasks_by_owner_response.json | 3 ++- packages/cw-croncat-core/schema/get_tasks_response.json | 3 ++- .../schema/get_tasks_with_queries_response.json | 3 ++- packages/cw-croncat-core/schema/query_msg.json | 3 ++- packages/cw-rules-core/schema/croncat_query.json | 3 ++- packages/cw-rules-core/schema/has_balance_gte.json | 3 ++- packages/cw-rules-core/schema/query_construct.json | 3 ++- packages/cw-rules-core/schema/query_msg.json | 3 ++- .../contracts/cw-croncat-core/CwCroncatCore.types.ts | 3 --- typescript/contracts/cw-rules-core/CwRulesCore.types.ts | 1 - 15 files changed, 32 insertions(+), 20 deletions(-) diff --git a/packages/cw-croncat-core/schema/croncat.json b/packages/cw-croncat-core/schema/croncat.json index 74db5cef..6ff681d4 100644 --- a/packages/cw-croncat-core/schema/croncat.json +++ b/packages/cw-croncat-core/schema/croncat.json @@ -785,7 +785,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "Cw20CoinVerified": { "type": "object", @@ -800,7 +801,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "DistributionMsg": { "description": "The message types of the distribution module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.42.4/proto/cosmos/distribution/v1beta1/tx.proto", diff --git a/packages/cw-croncat-core/schema/execute_msg.json b/packages/cw-croncat-core/schema/execute_msg.json index 7c8b1476..df5d5c89 100644 --- a/packages/cw-croncat-core/schema/execute_msg.json +++ b/packages/cw-croncat-core/schema/execute_msg.json @@ -868,7 +868,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "Cw20CoinVerified": { "type": "object", @@ -883,7 +884,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "Cw20ReceiveMsg": { "description": "Cw20ReceiveMsg should be de/serialized under `Receive()` variant in a ExecuteMsg", @@ -903,7 +905,8 @@ "sender": { "type": "string" } - } + }, + "additionalProperties": false }, "DistributionMsg": { "description": "The message types of the distribution module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.42.4/proto/cosmos/distribution/v1beta1/tx.proto", diff --git a/packages/cw-croncat-core/schema/get_agent_response.json b/packages/cw-croncat-core/schema/get_agent_response.json index 6d602365..eb2ab577 100644 --- a/packages/cw-croncat-core/schema/get_agent_response.json +++ b/packages/cw-croncat-core/schema/get_agent_response.json @@ -85,7 +85,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "GenericBalance": { "type": "object", diff --git a/packages/cw-croncat-core/schema/get_agent_tasks_response.json b/packages/cw-croncat-core/schema/get_agent_tasks_response.json index 4b6624e6..37c4f85d 100644 --- a/packages/cw-croncat-core/schema/get_agent_tasks_response.json +++ b/packages/cw-croncat-core/schema/get_agent_tasks_response.json @@ -492,7 +492,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "DistributionMsg": { "description": "The message types of the distribution module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.42.4/proto/cosmos/distribution/v1beta1/tx.proto", diff --git a/packages/cw-croncat-core/schema/get_task_response.json b/packages/cw-croncat-core/schema/get_task_response.json index 7735e1e0..79334891 100644 --- a/packages/cw-croncat-core/schema/get_task_response.json +++ b/packages/cw-croncat-core/schema/get_task_response.json @@ -492,7 +492,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "DistributionMsg": { "description": "The message types of the distribution module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.42.4/proto/cosmos/distribution/v1beta1/tx.proto", diff --git a/packages/cw-croncat-core/schema/get_tasks_by_owner_response.json b/packages/cw-croncat-core/schema/get_tasks_by_owner_response.json index 8ae8ed9c..2ee1522e 100644 --- a/packages/cw-croncat-core/schema/get_tasks_by_owner_response.json +++ b/packages/cw-croncat-core/schema/get_tasks_by_owner_response.json @@ -488,7 +488,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "DistributionMsg": { "description": "The message types of the distribution module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.42.4/proto/cosmos/distribution/v1beta1/tx.proto", diff --git a/packages/cw-croncat-core/schema/get_tasks_response.json b/packages/cw-croncat-core/schema/get_tasks_response.json index 9914fb29..badc0d33 100644 --- a/packages/cw-croncat-core/schema/get_tasks_response.json +++ b/packages/cw-croncat-core/schema/get_tasks_response.json @@ -488,7 +488,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "DistributionMsg": { "description": "The message types of the distribution module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.42.4/proto/cosmos/distribution/v1beta1/tx.proto", diff --git a/packages/cw-croncat-core/schema/get_tasks_with_queries_response.json b/packages/cw-croncat-core/schema/get_tasks_with_queries_response.json index 2b321cac..743f6c8c 100644 --- a/packages/cw-croncat-core/schema/get_tasks_with_queries_response.json +++ b/packages/cw-croncat-core/schema/get_tasks_with_queries_response.json @@ -293,7 +293,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "GenericQuery": { "type": "object", diff --git a/packages/cw-croncat-core/schema/query_msg.json b/packages/cw-croncat-core/schema/query_msg.json index ce0158ea..e4aa3a21 100644 --- a/packages/cw-croncat-core/schema/query_msg.json +++ b/packages/cw-croncat-core/schema/query_msg.json @@ -711,7 +711,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "DistributionMsg": { "description": "The message types of the distribution module.\n\nSee https://github.com/cosmos/cosmos-sdk/blob/v0.42.4/proto/cosmos/distribution/v1beta1/tx.proto", diff --git a/packages/cw-rules-core/schema/croncat_query.json b/packages/cw-rules-core/schema/croncat_query.json index e34513a5..2e07477d 100644 --- a/packages/cw-rules-core/schema/croncat_query.json +++ b/packages/cw-rules-core/schema/croncat_query.json @@ -215,7 +215,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "GenericQuery": { "type": "object", diff --git a/packages/cw-rules-core/schema/has_balance_gte.json b/packages/cw-rules-core/schema/has_balance_gte.json index b5b4d38c..228e6726 100644 --- a/packages/cw-rules-core/schema/has_balance_gte.json +++ b/packages/cw-rules-core/schema/has_balance_gte.json @@ -75,7 +75,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "NativeBalance": { "type": "array", diff --git a/packages/cw-rules-core/schema/query_construct.json b/packages/cw-rules-core/schema/query_construct.json index 48485b41..df4d2ec4 100644 --- a/packages/cw-rules-core/schema/query_construct.json +++ b/packages/cw-rules-core/schema/query_construct.json @@ -229,7 +229,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "GenericQuery": { "type": "object", diff --git a/packages/cw-rules-core/schema/query_msg.json b/packages/cw-rules-core/schema/query_msg.json index 27afc641..3eb72a9d 100644 --- a/packages/cw-rules-core/schema/query_msg.json +++ b/packages/cw-rules-core/schema/query_msg.json @@ -351,7 +351,8 @@ "amount": { "$ref": "#/definitions/Uint128" } - } + }, + "additionalProperties": false }, "GenericQuery": { "type": "object", diff --git a/typescript/contracts/cw-croncat-core/CwCroncatCore.types.ts b/typescript/contracts/cw-croncat-core/CwCroncatCore.types.ts index dd7dc709..9b8f71ad 100644 --- a/typescript/contracts/cw-croncat-core/CwCroncatCore.types.ts +++ b/typescript/contracts/cw-croncat-core/CwCroncatCore.types.ts @@ -227,7 +227,6 @@ export interface GenericBalance { export interface Cw20CoinVerified { address: Addr; amount: Uint128; - [k: string]: unknown; } export interface Coin { amount: Uint128; @@ -421,7 +420,6 @@ export interface TaskRequest { export interface Cw20Coin { address: string; amount: Uint128; - [k: string]: unknown; } export type ExecuteMsg = { update_settings: { @@ -510,7 +508,6 @@ export interface Cw20ReceiveMsg { amount: Uint128; msg: Binary; sender: string; - [k: string]: unknown; } export type GetAgentResponse = AgentResponse | null; export type GetAgentTasksResponse = TaskResponse | null; diff --git a/typescript/contracts/cw-rules-core/CwRulesCore.types.ts b/typescript/contracts/cw-rules-core/CwRulesCore.types.ts index 03b05442..f4e6ed19 100644 --- a/typescript/contracts/cw-rules-core/CwRulesCore.types.ts +++ b/typescript/contracts/cw-rules-core/CwRulesCore.types.ts @@ -85,7 +85,6 @@ export interface Coin { export interface Cw20CoinVerified { address: Addr; amount: Uint128; - [k: string]: unknown; } export interface GenericQuery { contract_addr: string;