Skip to content

Commit cb42c74

Browse files
authored
Bump deps and cleanup migration (#432)
* Bump minor cw version. * Update optimizer and rust version. * Mars ver to 2.1.0, cleanup migrations, fix clippy.
1 parent 3e01592 commit cb42c74

File tree

82 files changed

+148
-1852
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+148
-1852
lines changed

Cargo.lock

Lines changed: 75 additions & 76 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,13 @@ members = [
3838
]
3939

4040
[workspace.package]
41-
version = "2.0.0"
41+
version = "2.1.0"
4242
authors = [
43-
"Gabe R. <[email protected]>",
44-
"Larry Engineer <[email protected]>",
45-
"Piotr B. <[email protected]>",
43+
"Piotr B. <[email protected]>",
4644
"Bob v.d. H. <[email protected]>",
4745
"Mark Watney <[email protected]>",
46+
"Gabe R. <[email protected]>",
47+
"Larry Engineer <[email protected]>",
4848
"Spike Spiegel <[email protected]>",
4949
"Brianna M. <[email protected]>",
5050
"Ahmad Kaouk",
@@ -64,8 +64,8 @@ apollo-utils = "0.1.2"
6464
astroport = "2.8.0"
6565
astroport-v5 = { package = "astroport", version = "5.2.0" }
6666
bech32 = "0.11.0"
67-
cosmwasm-schema = "1.5.5"
68-
cosmwasm-std = "1.5.5"
67+
cosmwasm-schema = "1.5.7"
68+
cosmwasm-std = "1.5.7"
6969
cw2 = "1.1.2"
7070
cw721 = { git = "https://github.com/CosmWasm/cw-nfts/", branch = "main" }
7171
cw721-base = { git = "https://github.com/CosmWasm/cw-nfts/", branch = "main", features = ["library"] }

Makefile.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ default_to_workspace = false
1010
# Directory with wasm files used by integration tests (another directory can be used instead, for example 'artifacts' from rust-optimizer)
1111
ARTIFACTS_DIR_PATH = "target/wasm32-unknown-unknown/release"
1212
# If you bump this version, verify RUST_VERSION correctness
13-
RUST_OPTIMIZER_VERSION = "0.15.1"
14-
# Use rust version from rust-optimizer Dockerfile (see https://github.com/CosmWasm/optimizer/blob/v0.15.1/Dockerfile#L1)
13+
RUST_OPTIMIZER_VERSION = "0.16.0"
14+
# Use rust version from rust-optimizer Dockerfile (see https://github.com/CosmWasm/optimizer/blob/v0.16.0/Dockerfile#L1)
1515
# to be sure that we compile / test against the same version
16-
RUST_VERSION = "1.75.0"
16+
RUST_VERSION = "1.78.0"
1717

1818
[tasks.install-stable]
1919
script = '''

contracts/account-nft/src/contract.rs

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,11 @@ use cosmwasm_std::{
55
};
66
use cw2::set_contract_version;
77
use cw721_base::Cw721Contract;
8-
use mars_types::account_nft::{ExecuteMsg, InstantiateMsg, MigrateV1ToV2, NftConfig, QueryMsg};
8+
use mars_types::account_nft::{ExecuteMsg, InstantiateMsg, NftConfig, QueryMsg};
99

1010
use crate::{
1111
error::ContractError,
1212
execute::{burn, mint, update_config},
13-
migrations::{self},
1413
query::{query_config, query_next_id},
1514
state::{CONFIG, NEXT_ID},
1615
};
@@ -68,11 +67,6 @@ pub fn execute(
6867
ExecuteMsg::Burn {
6968
token_id,
7069
} => burn(deps, env, info, token_id),
71-
ExecuteMsg::Migrate(msg) => match msg {
72-
MigrateV1ToV2::BurnEmptyAccounts {
73-
limit,
74-
} => migrations::v2_0_0::burn_empty_accounts(deps, limit),
75-
},
7670
_ => Parent::default().execute(deps, env, info, msg.try_into()?).map_err(Into::into),
7771
}
7872
}
@@ -85,8 +79,3 @@ pub fn query(deps: Deps, env: Env, msg: QueryMsg) -> StdResult<Binary> {
8579
_ => Parent::default().query(deps, env, msg.try_into()?),
8680
}
8781
}
88-
89-
#[cfg_attr(not(feature = "library"), entry_point)]
90-
pub fn migrate(deps: DepsMut, _env: Env, _msg: Empty) -> Result<Response, ContractError> {
91-
migrations::v2_0_0::migrate(deps)
92-
}

contracts/account-nft/src/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
pub mod contract;
22
pub mod error;
33
pub mod execute;
4-
pub mod migrations;
54
pub mod query;
65
pub mod state;

contracts/account-nft/src/migrations/mod.rs

Lines changed: 0 additions & 1 deletion
This file was deleted.

contracts/account-nft/src/migrations/v2_0_0.rs

Lines changed: 0 additions & 138 deletions
This file was deleted.

contracts/account-nft/tests/tests/helpers/mock_env.rs

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@ use mars_mock_credit_manager::msg::ExecuteMsg::SetAccountKindResponse;
1111
use mars_mock_rover_health::msg::ExecuteMsg::SetHealthResponse;
1212
use mars_types::{
1313
account_nft::{
14-
ExecuteMsg, ExecuteMsg::UpdateConfig, MigrateV1ToV2, NftConfigUpdates, QueryMsg,
15-
UncheckedNftConfig,
14+
ExecuteMsg, ExecuteMsg::UpdateConfig, NftConfigUpdates, QueryMsg, UncheckedNftConfig,
1615
},
1716
health::{AccountKind, HealthValuesResponse},
1817
};
@@ -154,21 +153,6 @@ impl MockEnv {
154153
)
155154
}
156155

157-
pub fn burn_empty_accounts(
158-
&mut self,
159-
sender: &Addr,
160-
limit: Option<u32>,
161-
) -> AnyResult<AppResponse> {
162-
self.app.execute_contract(
163-
sender.clone(),
164-
self.nft_contract.clone(),
165-
&ExecuteMsg::Migrate(MigrateV1ToV2::BurnEmptyAccounts {
166-
limit,
167-
}),
168-
&[],
169-
)
170-
}
171-
172156
pub fn propose_new_minter(
173157
&mut self,
174158
sender: &Addr,
Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
mod helpers;
22

33
mod test_burn_allowance;
4-
mod test_burn_empty_accounts;
54
mod test_instantiate;
6-
mod test_migration;
75
mod test_mint;
86
mod test_proposed_minter;
97
mod test_update_config;

0 commit comments

Comments
 (0)