forked from cosmos/cosmos-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: validator.Jailed continue instead of panic
- Loading branch information
1 parent
bb9f451
commit 0898425
Showing
2 changed files
with
18 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
diff --git a/x/staking/keeper/val_state_change.go b/x/staking/keeper/val_state_change.go | ||
index 444633983c..cb5d01f7eb 100644 | ||
--- a/x/staking/keeper/val_state_change.go | ||
+++ b/x/staking/keeper/val_state_change.go | ||
@@ -159,7 +159,9 @@ func (k Keeper) ApplyAndReturnValidatorSetUpdates(ctx context.Context) (updates | ||
validator := k.mustGetValidator(ctx, valAddr) | ||
|
||
if validator.Jailed { | ||
- panic("should never retrieve a jailed validator from the power store") | ||
+ // https://github.com/cosmos/cosmos-sdk/pull/20059 | ||
+ // panic("should never retrieve a jailed validator from the power store") | ||
+ continue | ||
} | ||
|
||
// if we get to a zero-power validator (which we don't bond), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters