You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While I was implementing TestAppSimulationAfterImport simulation test for the fundraising module, I encountered this panic panic: no validator commission to withdraw. This is due to the error handling in WithdrawValidatorCommission function in app/export.go. I think it is worth of sharing with the SPN team to minimize debugging time if there is a plan to implement the simulation test.
To share a little more in detail, the simulation of Cosmos SDK staking module allows to set a validator's commission rate as zero. See this lines of code for reference. This may be the reason why error handling is ignored in CanWithdrawInvariant and here.
The text was updated successfully, but these errors were encountered:
Summary
While I was implementing
TestAppSimulationAfterImport
simulation test for thefundraising
module, I encountered this panicpanic: no validator commission to withdraw
. This is due to the error handling in WithdrawValidatorCommission function inapp/export.go
. I think it is worth of sharing with the SPN team to minimize debugging time if there is a plan to implement the simulation test.To share a little more in detail, the simulation of Cosmos SDK
staking
module allows to set a validator's commission rate as zero. See this lines of code for reference. This may be the reason why error handling is ignored in CanWithdrawInvariant and here.The text was updated successfully, but these errors were encountered: