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

chore: update go.mod to prevent CI build breakages (add ICS v4.1.0-lsm-rc2) #3039

Merged
merged 8 commits into from
Apr 9, 2024

Conversation

MSalopek
Copy link
Contributor

@MSalopek MSalopek commented Apr 3, 2024

This PR fixes a CI issue where the build breaks during liveness and upgrade tests.

Part of the fix is updating ICS version to v4.1.0-rc1.

@MSalopek MSalopek marked this pull request as draft April 3, 2024 12:42
@MSalopek MSalopek changed the title chore: update CI actions go version chore: update go.mod to prevent CI build breakages Apr 3, 2024
@MSalopek MSalopek marked this pull request as ready for review April 3, 2024 14:05
@@ -26,6 +27,11 @@ func CreateUpgradeHandler(
// Enable ICA controller
keepers.ICAControllerKeeper.SetParams(ctx, icacontrollertypes.DefaultParams())

// Set default blocks per epoch
providerParams := keepers.ProviderKeeper.GetParams(ctx)
Copy link
Contributor

Choose a reason for hiding this comment

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

This will panic since BlocksPerEpoch key doesn't exist in the paramstore at this point.

Copy link
Contributor Author

@MSalopek MSalopek Apr 4, 2024

Choose a reason for hiding this comment

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

The upgrade code is in cosmos/interchain-security#1757

It will should be available in the next release candidate of [email protected]

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changes are available here:

providerParams := keepers.ProviderKeeper.GetParams(ctx)
providerParams.BlocksPerEpoch = providertypes.DefaultBlocksPerEpoch
keepers.ProviderKeeper.SetParams(ctx, providerParams)

Copy link
Contributor

@sainoe sainoe Apr 4, 2024

Choose a reason for hiding this comment

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

We can do this instead:

subspace := keepers.GetSubspace(providertypes.ModuleName)
subspace.Set(ctx, providertypes.KeyBlocksPerEpoch, int64(providertypes.DefaultBlocksPerEpoch))

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The upgrade code is in cosmos/interchain-security#1757

It will should be available in the next release candidate of [email protected]

Copy link
Contributor

Choose a reason for hiding this comment

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

Okay, that makes sense to do the upgrade in ICS. So why is the BlocksPerEpoch param set to default here (again)?

Copy link
Contributor Author

@MSalopek MSalopek Apr 5, 2024

Choose a reason for hiding this comment

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

Making it explicit. Otherwise you have to reference ICS docs - reviewing and tracking changelogs becomes a pain.

We did a similar thing for ICA controller.

@MSalopek
Copy link
Contributor Author

MSalopek commented Apr 8, 2024

Please wait with the merge.

ICS v4.1.0-rc2 needs to be linked in go.mod.

EDIT:
Done

@MSalopek MSalopek marked this pull request as draft April 8, 2024 11:19
@MSalopek MSalopek changed the title chore: update go.mod to prevent CI build breakages chore: update go.mod to prevent CI build breakages (add ICS v4.1.0-lsm-rc1) Apr 8, 2024
@MSalopek MSalopek marked this pull request as ready for review April 8, 2024 14:18
@MSalopek MSalopek marked this pull request as draft April 8, 2024 15:21
@MSalopek MSalopek marked this pull request as ready for review April 8, 2024 20:34
@MSalopek MSalopek changed the title chore: update go.mod to prevent CI build breakages (add ICS v4.1.0-lsm-rc1) chore: update go.mod to prevent CI build breakages (add ICS v4.1.0-lsm-rc2) Apr 9, 2024
@MSalopek MSalopek merged commit 876136e into main Apr 9, 2024
16 checks passed
@MSalopek MSalopek deleted the masa/update-test-goactions branch April 9, 2024 06:52
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.

4 participants