Skip to content

Commit

Permalink
Fix clippy errors from latest rust stable (#794)
Browse files Browse the repository at this point in the history
* Fix clippy errors from latest rust stable

* Remove unused deps, closes #751
  • Loading branch information
JakeHartnell authored Jan 8, 2024
1 parent 3ead037 commit bc3a449
Show file tree
Hide file tree
Showing 20 changed files with 10 additions and 65 deletions.
36 changes: 1 addition & 35 deletions Cargo.lock

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

1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ cosm-tome = "0.2"
cosmos-sdk-proto = "0.19"
cosmwasm-schema = { version = "1.2" }
cosmwasm-std = { version = "1.5.0", features = ["ibc3"] }
cosmwasm-storage = { version = "1.2" }
cw-controllers = "1.1"
cw-multi-test = "0.18"
cw-storage-plus = { version = "1.1" }
Expand Down
1 change: 0 additions & 1 deletion contracts/external/cw-admin-factory/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ library = []

[dependencies]
cosmwasm-std = { workspace = true }
cosmwasm-storage = { workspace = true }
cosmwasm-schema = { workspace = true }
cw-storage-plus = { workspace = true }
cw2 = { workspace = true }
Expand Down
8 changes: 4 additions & 4 deletions contracts/external/cw-fund-distributor/src/testing/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1398,7 +1398,7 @@ fn test_query_cw20_entitlements() {
.unwrap();

assert_eq!(res.len(), 1);
let entitlement = res.get(0).unwrap();
let entitlement = res.first().unwrap();
assert_eq!(entitlement.amount.u128(), 500000);
assert_eq!(entitlement.token_contract, token_address);
}
Expand Down Expand Up @@ -1451,7 +1451,7 @@ fn test_query_native_entitlements() {
.unwrap();

assert_eq!(res.len(), 1);
let entitlement = res.get(0).unwrap();
let entitlement = res.first().unwrap();
assert_eq!(entitlement.amount.u128(), 500000);
assert_eq!(entitlement.denom, FEE_DENOM);
}
Expand Down Expand Up @@ -1601,7 +1601,7 @@ fn test_query_cw20_tokens() {
.unwrap();

assert_eq!(res.len(), 1);
let cw20 = res.get(0).unwrap();
let cw20 = res.first().unwrap();
assert_eq!(cw20.token, "contract1");
assert_eq!(cw20.contract_balance.u128(), 500000);
}
Expand Down Expand Up @@ -1642,7 +1642,7 @@ fn test_query_native_denoms() {

// assert distributor now contains one expected native token
assert_eq!(res.len(), 1);
let denom = res.get(0).unwrap();
let denom = res.first().unwrap();
assert_eq!(denom.denom, FEE_DENOM.to_string());
assert_eq!(denom.contract_balance.u128(), 500000);
}
Expand Down
1 change: 0 additions & 1 deletion contracts/external/cw-tokenfactory-issuer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ cosmwasm_tokenfactory = ["cw-tokenfactory-types/cosmwasm_tokenfactory"]
[dependencies]
cosmwasm-schema = { workspace = true }
cosmwasm-std = { workspace = true }
cosmwasm-storage = { workspace = true }
cw2 = { workspace = true }
cw-ownable = { workspace = true }
cw-storage-plus = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion contracts/external/cw-vesting/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ cosmwasm-schema = { workspace = true }
cosmwasm-std = { workspace = true, features = ["staking"] }
cw-denom = { workspace = true }
cw-ownable = { workspace = true }
cw-paginate-storage = { workspace = true }
cw-stake-tracker = { workspace = true }
cw-storage-plus = { workspace = true }
cw-utils = { workspace = true }
Expand Down
2 changes: 0 additions & 2 deletions contracts/proposal/dao-proposal-multiple/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,11 @@ library = []

[dependencies]
cosmwasm-std = { workspace = true, features = ["ibc3"] }
cosmwasm-storage = { workspace = true }
cosmwasm-schema = { workspace = true }
cw-storage-plus = { workspace = true }
cw-utils = { workspace = true }
cw2 = { workspace = true }
cw20 = { workspace = true }
cw3 = { workspace = true }
thiserror = { workspace = true }
dao-dao-macros = { workspace = true }
dao-pre-propose-base = { workspace = true }
Expand Down
11 changes: 4 additions & 7 deletions contracts/proposal/dao-proposal-single/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,18 @@ library = []

[dependencies]
cosmwasm-std = { workspace = true, features = ["ibc3"] }
cosmwasm-storage = { workspace = true }
cosmwasm-schema = { workspace = true }
cw-hooks = { workspace = true }
cw-storage-plus = { workspace = true }
cw-utils = { workspace = true }
cw2 = { workspace = true }
cw20 = { workspace = true }
cw3 = { workspace = true }
thiserror = { workspace = true }

dao-dao-macros = { workspace = true }
dao-pre-propose-base = { workspace = true }
dao-hooks = { workspace = true }
dao-interface = { workspace = true }
dao-pre-propose-base = { workspace = true }
dao-voting = { workspace = true }
cw-hooks = { workspace = true }
dao-hooks = { workspace = true }
thiserror = { workspace = true }

cw-utils-v1 = { workspace = true}
voting-v1 = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion contracts/staking/cw20-stake-external-rewards/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ library = []
[dependencies]
cosmwasm-std = { workspace = true }
cosmwasm-schema = { workspace = true }
cosmwasm-storage = { workspace = true }
cw-storage-plus = { workspace = true }
cw-controllers = { workspace = true }
cw20 = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion contracts/staking/cw20-stake/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ library = []

[dependencies]
cosmwasm-std = { workspace = true }
cosmwasm-storage = { workspace = true }
cosmwasm-schema = { workspace = true }
cw-storage-plus = { workspace = true }
cw-controllers = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion contracts/test/dao-proposal-sudo/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ library = []
[dependencies]
cosmwasm-std = { workspace = true }
cosmwasm-schema = { workspace = true }
cosmwasm-storage = { workspace = true }
cw-storage-plus = { workspace = true }
cw2 = { workspace = true }
thiserror = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion contracts/test/dao-test-custom-factory/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ library = []
[dependencies]
cosmwasm-std = { workspace = true }
cosmwasm-schema = { workspace = true }
cosmwasm-storage = { workspace = true }
cw2 = { workspace = true }
cw721 = { workspace = true }
cw721-base = { workspace = true, features = ["library"] }
Expand Down
1 change: 0 additions & 1 deletion contracts/voting/dao-voting-cw20-staked/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ library = []
[dependencies]
cosmwasm-std = { workspace = true }
cosmwasm-schema = { workspace = true }
cosmwasm-storage = { workspace = true }
cw-storage-plus = { workspace = true }
cw-utils = { workspace = true }
cw2 = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion contracts/voting/dao-voting-cw4/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ library = []

[dependencies]
cosmwasm-std = { workspace = true }
cosmwasm-storage = { workspace = true }
cw-storage-plus = { workspace = true }
cw2 = { workspace = true }
cw-utils = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion contracts/voting/dao-voting-cw721-roles/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ dao-interface = { workspace = true }
cw721-base = { workspace = true, features = ["library"] }
cw721-controllers = { workspace = true }
cw-ownable = { workspace = true }
cw-paginate-storage = { workspace = true }
cw721 = { workspace = true }
cw-utils = { workspace = true }
cw2 = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion contracts/voting/dao-voting-cw721-staked/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ cw-hooks = { workspace = true }
cw721 = { workspace = true }
cw721-base = { workspace = true, features = ["library"] }
cw721-controllers = { workspace = true }
cw-paginate-storage = { workspace = true }
cw-utils = { workspace = true }
cw2 = { workspace = true }
dao-dao-macros = { workspace = true }
Expand Down
2 changes: 0 additions & 2 deletions contracts/voting/dao-voting-token-staked/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ test-tube = []
[dependencies]
cosmwasm-std = { workspace = true, features = ["cosmwasm_1_1"] }
cosmwasm-schema = { workspace = true }
cosmwasm-storage = { workspace = true }
cw-ownable = { workspace = true }
cw-storage-plus = { workspace = true }
cw2 = { workspace = true }
Expand All @@ -36,7 +35,6 @@ dao-dao-macros = { workspace = true }
dao-hooks = { workspace = true }
dao-interface = { workspace = true }
dao-voting = { workspace = true }
cw-paginate-storage = { workspace = true }
cw-tokenfactory-issuer = { workspace = true, features = ["library"] }

[dev-dependencies]
Expand Down
1 change: 0 additions & 1 deletion packages/cw-paginate-storage/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ version = { workspace = true }

[dependencies]
cosmwasm-std = { workspace = true }
cosmwasm-storage = { workspace = true }
cw-storage-plus = { workspace = true }
serde = { workspace = true }

Expand Down
2 changes: 1 addition & 1 deletion packages/cw-paginate-storage/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ mod tests {
map.save(
&mut deps.storage,
ctr,
&Uint128::new(ctr.try_into().unwrap()),
&Uint128::new(<u32 as std::convert::Into<u128>>::into(ctr)),
env.block.height,
)
.unwrap();
Expand Down
1 change: 0 additions & 1 deletion packages/dao-interface/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ cosmwasm-schema = { workspace = true }
cw2 = { workspace = true }
cw20 = { workspace = true }
cw721 = { workspace = true }
cw-hooks = { workspace = true }
cw-utils = { workspace = true }
osmosis-std = { workspace = true }

Expand Down

0 comments on commit bc3a449

Please sign in to comment.