Skip to content

Conversation

@Subham2804
Copy link
Contributor

No description provided.

@Subham2804 Subham2804 changed the title add CM , RB migration Migration-2.4.1 Nov 19, 2025
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 9 to +13
pub fn migrate(deps: DepsMut) -> Result<Response, ContractError> {
// make sure we're migrating the correct contract and from the correct version
assert_contract_version(deps.storage, &format!("crates.io:{CONTRACT_NAME}"), FROM_VERSION)?;

set_contract_version(deps.storage, format!("crates.io:{CONTRACT_NAME}"), CONTRACT_VERSION)?;
set_contract_version(deps.storage, format!("crates.io:{CONTRACT_NAME}"), TO_VERSION)?;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Set migration version to deployed code level

The v2_2_0→v2_3_0 migration writes the cw2 contract version to the hard-coded TO_VERSION "2.3.0" while the package/CONTRACT_VERSION has been bumped to 2.3.1. Migrating a 2.2.0 deployment with this new binary will therefore leave state reporting 2.3.0, and any later migration that asserts from 2.3.1 will fail for those contracts. The migration should record the current code version (2.3.1) or perform the full 2.2.0→2.3.1 step in one call.

Useful? React with 👍 / 👎.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

codex getting confused haha

Comment on lines 9 to +13
pub fn migrate(deps: DepsMut) -> Result<Response, ContractError> {
// make sure we're migrating the correct contract and from the correct version
assert_contract_version(deps.storage, &format!("crates.io:{CONTRACT_NAME}"), FROM_VERSION)?;

set_contract_version(deps.storage, format!("crates.io:{CONTRACT_NAME}"), CONTRACT_VERSION)?;
set_contract_version(deps.storage, format!("crates.io:{CONTRACT_NAME}"), TO_VERSION)?;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

codex getting confused haha

@Subham2804 Subham2804 merged commit 01d994a into RC-events Nov 27, 2025
3 checks passed
markonmars pushed a commit that referenced this pull request Dec 3, 2025
* add reward collector fee events in CM and RB

* update tests

* add CM , RB migration (#46)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants