Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(upgrade): move drs check to begin blocker to allow time-based upgrades #1272

Merged
merged 2 commits into from
Dec 10, 2024

Conversation

srene
Copy link
Contributor

@srene srene commented Dec 10, 2024

PR Standards

This PR goes with with dymensionxyz/rollapp-evm#393

where drs rollapp param validation is moved to the begin blocker function to be aligned with upgrade flow, otherwise its not possible to run a new version (it will fail in dymint validation) before the drs is updated in the upgrade handler.

Opening a pull request should be able to meet the following requirements

--

PR naming convention: https://hackmd.io/@nZpxHZ0CT7O5ngTp0TP9mg/HJP_jrm7A


Close #1271

<-- Briefly describe the content of this pull request -->

For Author:

  • Targeted PR against correct branch
  • included the correct type prefix in the PR title
  • Linked to Github issue with discussion and accepted design
  • Targets only one github issue
  • Wrote unit and integration tests
  • All CI checks have passed
  • Added relevant godoc comments

For Reviewer:

  • confirmed the correct type prefix in the PR title
  • Reviewers assigned
  • confirmed all author checklist items have been addressed

After reviewer approval:

  • In case targets main branch, PR should be squashed and merged.
  • In case PR targets a release branch, PR should be rebased.

@srene srene requested a review from a team as a code owner December 10, 2024 10:50
@srene srene linked an issue Dec 10, 2024 that may be closed by this pull request
@@ -375,14 +374,6 @@ func (m *Manager) UpdateTargetHeight(h uint64) {

// ValidateConfigWithRollappParams checks the configuration params are consistent with the params in the dymint state (e.g. DA and version)
func (m *Manager) ValidateConfigWithRollappParams() error {
drsVersion, err := version.GetDRSVersion()
Copy link
Contributor

Choose a reason for hiding this comment

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

where it's gonna be validated now?
if the DRS changed in the rollapp params (through the RDK)
where it's validated against local version?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

its validated in the begin blocker function of the app dymensionxyz/rollapp-evm#393. this way it allows using a different version when upgrade is required, but if using wrong version it will fail in begin blocker

@mtsitrin mtsitrin merged commit b7f6555 into main Dec 10, 2024
4 checks passed
@mtsitrin mtsitrin deleted the srene/upgrade-rollappparam branch December 10, 2024 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can't update rollapp to new DRS using gov prop
3 participants