Skip to content

Commit

Permalink
add changelog and fix repeteadly calling zone
Browse files Browse the repository at this point in the history
  • Loading branch information
ajansari95 committed Mar 15, 2023
1 parent 786b7bb commit 2325f84
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 12 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@

## Released

### v1.2.5
- Backport `GovRepenChannel` tx and `GovCloseChannel` proposal
- Add Logic to handle pending delegations on `regen-1` post upgrade once channel are open.
- Upgrade Handler:
- Fix `EpochProvisions` value
- Set DistributionProportions params

### v1.2.4
- Bump Tendermint to v0.34.26 (informalsystems/tendermint)
- Bump Cosmos-SDK to v0.46.10
Expand Down
26 changes: 14 additions & 12 deletions x/interchainstaking/keeper/abci.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,25 @@ func (k Keeper) BeginBlocker(ctx sdk.Context) {
defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyBeginBlocker)
// post upgrade-v1.2.5 processing
if ctx.BlockHeight() == 14540740 {
k.IterateReceipts(ctx, func(_ int64, receiptInfo types.Receipt) (stop bool) {
if receiptInfo.ChainId == "regen-1" && receiptInfo.Completed == nil {
sendMsg := banktypes.MsgSend{
FromAddress: "",
ToAddress: "",
Amount: receiptInfo.Amount,
}
zone, found := k.GetZone(ctx, "regen-1")
if found {
zone, found := k.GetZone(ctx, "regen-1")
if found {
k.IterateReceipts(ctx, func(_ int64, receiptInfo types.Receipt) (stop bool) {
if receiptInfo.ChainId == "regen-1" && receiptInfo.Completed == nil {
sendMsg := banktypes.MsgSend{
FromAddress: "",
ToAddress: "",
Amount: receiptInfo.Amount,
}
err := k.handleSendToDelegate(ctx, &zone, &sendMsg, receiptInfo.Txhash)
if err != nil {
k.Logger(ctx).Error("error in processing Pending delegations for regen-1 ", "error", err)
}

}
}
return false
})
return false
})
}

}
if ctx.BlockHeight()%30 == 0 {
if err := k.GCCompletedRedelegations(ctx); err != nil {
Expand Down

0 comments on commit 2325f84

Please sign in to comment.