Skip to content

Commit

Permalink
feat: for rollapp, query unbonding period from x/sequencers (#44)
Browse files Browse the repository at this point in the history
  • Loading branch information
danwt authored Sep 6, 2024
1 parent b0f2fde commit ba342ed
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions relayer/chains/cosmos/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,13 @@ func (cc *CosmosProvider) QueryCanonicalLightClient(ctx context.Context, rollapp

// QueryUnbondingPeriod returns the unbonding period of the chain
func (cc *CosmosProvider) QueryUnbondingPeriod(ctx context.Context) (time.Duration, error) {
if cc.PCfg.DymRollapp {
ret, err := cc.queryParamsSubspaceTime(ctx, "sequencers", "UnbondingTime")
if err == nil {
return ret, nil
}
}

// Attempt ICS query
consumerUnbondingPeriod, consumerErr := cc.queryParamsSubspaceTime(ctx, "ccvconsumer", "UnbondingPeriod")
if consumerErr == nil {
Expand Down

0 comments on commit ba342ed

Please sign in to comment.