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

fix(poolincentives): band-aid state export fix for cwpool gauges (backport #6476) #6479

Merged
merged 1 commit into from
Sep 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,11 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## Unreleased

### Misc Improvements

* [#6476](https://github.com/osmosis-labs/osmosis/pull/6476) band-aid state export fix for cwpool gauges

## v19.1.0

Expand Down
9 changes: 9 additions & 0 deletions x/pool-incentives/keeper/genesis.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,15 @@ func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState {
if err != nil {
panic(err)
}

if pool.GetType() == poolmanagertypes.CosmWasm {
// TODO: remove this post-v19. In v19 we did not create a hook for cw pool gauges.
// Fix tracked in:
// https://github.com/osmosis-labs/osmosis/issues/6122
ctx.Logger().Info("Skipping pool ID", "poolId", poolId, "reason", "cosmwasm pool")
continue
}

isCLPool := pool.GetType() == poolmanagertypes.Concentrated
if isCLPool {
incParams := k.incentivesKeeper.GetEpochInfo(ctx)
Expand Down