Skip to content

Commit badaafb

Browse files
committed
updated contract dependencies
1 parent 06108b2 commit badaafb

File tree

4 files changed

+32
-26
lines changed

4 files changed

+32
-26
lines changed

common/cosmwasm-smart-contracts/nym-pool-contract/Cargo.toml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,12 @@ thiserror = { workspace = true }
1616
serde = { workspace = true }
1717
schemars = { workspace = true }
1818

19-
cosmwasm-std = "2.2.0"
20-
cosmwasm-schema = "2.2.0"
21-
cw-controllers = "2.0.0"
19+
cosmwasm-std = { workspace = true }
20+
cosmwasm-schema = { workspace = true }
21+
cw-controllers = { workspace = true }
2222

2323
[dev-dependencies]
24-
time = { workspace = true, features = ["macros"] }
24+
time = { workspace = true, features = ["macros"] }
25+
26+
[features]
27+
schema = []

common/cosmwasm-smart-contracts/nym-pool-contract/src/msg.rs

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,17 @@
11
// Copyright 2025 - Nym Technologies SA <[email protected]>
22
// SPDX-License-Identifier: Apache-2.0
33

4+
use crate::{Allowance, TransferRecipient};
5+
use cosmwasm_schema::cw_serde;
6+
use cosmwasm_std::Coin;
7+
use std::collections::HashMap;
8+
9+
#[cfg(feature = "schema")]
410
use crate::types::{
511
AvailableTokensResponse, GrantResponse, GranterResponse, GrantersPagedResponse,
612
GrantsPagedResponse, LockedTokensPagedResponse, LockedTokensResponse,
713
TotalLockedTokensResponse,
814
};
9-
use crate::{Allowance, TransferRecipient};
10-
use cosmwasm_schema::{cw_serde, QueryResponses};
11-
use cosmwasm_std::Coin;
12-
use std::collections::HashMap;
1315

1416
#[cw_serde]
1517
pub struct InstantiateMsg {
@@ -69,27 +71,27 @@ pub enum ExecuteMsg {
6971
}
7072

7173
#[cw_serde]
72-
#[derive(QueryResponses)]
74+
#[cfg_attr(feature = "schema", derive(cosmwasm_schema::QueryResponses))]
7375
pub enum QueryMsg {
74-
#[returns(cw_controllers::AdminResponse)]
76+
#[cfg_attr(feature = "schema", returns(cw_controllers::AdminResponse))]
7577
Admin {},
7678

77-
#[returns(AvailableTokensResponse)]
79+
#[cfg_attr(feature = "schema", returns(AvailableTokensResponse))]
7880
GetAvailableTokens {},
7981

80-
#[returns(TotalLockedTokensResponse)]
82+
#[cfg_attr(feature = "schema", returns(TotalLockedTokensResponse))]
8183
GetTotalLockedTokens {},
8284

83-
#[returns(LockedTokensResponse)]
85+
#[cfg_attr(feature = "schema", returns(LockedTokensResponse))]
8486
GetLockedTokens { grantee: String },
8587

86-
#[returns(GrantResponse)]
88+
#[cfg_attr(feature = "schema", returns(GrantResponse))]
8789
GetGrant { grantee: String },
8890

89-
#[returns(GranterResponse)]
91+
#[cfg_attr(feature = "schema", returns(GranterResponse))]
9092
GetGranter { granter: String },
9193

92-
#[returns(LockedTokensPagedResponse)]
94+
#[cfg_attr(feature = "schema", returns(LockedTokensPagedResponse))]
9395
GetLockedTokensPaged {
9496
/// Controls the maximum number of entries returned by the query. Note that too large values will be overwritten by a saner default.
9597
limit: Option<u32>,
@@ -98,7 +100,7 @@ pub enum QueryMsg {
98100
start_after: Option<String>,
99101
},
100102

101-
#[returns(GrantersPagedResponse)]
103+
#[cfg_attr(feature = "schema", returns(GrantersPagedResponse))]
102104
GetGrantersPaged {
103105
/// Controls the maximum number of entries returned by the query. Note that too large values will be overwritten by a saner default.
104106
limit: Option<u32>,
@@ -107,7 +109,7 @@ pub enum QueryMsg {
107109
start_after: Option<String>,
108110
},
109111

110-
#[returns(GrantsPagedResponse)]
112+
#[cfg_attr(feature = "schema", returns(GrantsPagedResponse))]
111113
GetGrantsPaged {
112114
/// Controls the maximum number of entries returned by the query. Note that too large values will be overwritten by a saner default.
113115
limit: Option<u32>,

contracts/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ cw3-fixed-multisig = "=2.0.0"
4747
cw4 = "=2.0.0"
4848
cw20 = "=2.0.0"
4949
cw20-base = "2.0.0"
50+
rand = "0.8.5"
51+
rand_chacha = "0.3.1"
5052
semver = "1.0.21"
5153
serde = "1.0.196"
5254
sylvia = "1.3.3"

contracts/nym-pool/Cargo.toml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,10 @@ required-features = ["schema-gen"]
1414
crate-type = ["cdylib", "rlib"]
1515

1616
[dependencies]
17-
# don't inherit from the workspace as there are breaking changes in existing contracts that need to be fixed first
18-
cosmwasm-std = "2.2.0"
19-
cw2 = "2.0.0"
20-
cw-storage-plus = "2.0.0"
21-
cw-controllers = "2.0.0"
17+
cosmwasm-std = { workspace = true }
18+
cw2 = { workspace = true }
19+
cw-storage-plus = { workspace = true }
20+
cw-controllers = { workspace = true }
2221

2322
nym-contracts-common = { path = "../../common/cosmwasm-smart-contracts/contracts-common" }
2423
nym-pool-contract-common = { path = "../../common/cosmwasm-smart-contracts/nym-pool-contract" }
@@ -27,6 +26,6 @@ nym-pool-contract-common = { path = "../../common/cosmwasm-smart-contracts/nym-p
2726
[dev-dependencies]
2827
anyhow = { workspace = true }
2928
serde = { workspace = true }
30-
rand_chacha = "0.3"
31-
rand = "0.8.5"
32-
cw-multi-test = "2.3.1"
29+
rand_chacha = { workspace = true }
30+
rand = { workspace = true }
31+
cw-multi-test = { workspace = true }

0 commit comments

Comments
 (0)