Skip to content

Commit

Permalink
op-e2e: Increase timeout of traceProvider.Get when moving (#10053)
Browse files Browse the repository at this point in the history
The old 2 minute timeout is no longer sufficient. As cannon
execution sometimes requires more time to generate traces.
  • Loading branch information
Inphi committed Apr 5, 2024
1 parent 211f9e4 commit d5b1b75
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions op-e2e/e2eutils/disputegame/output_honest_helper.go
Expand Up @@ -11,6 +11,8 @@ import (
"github.com/stretchr/testify/require"
)

const getTraceTimeout = 10 * time.Minute

type OutputHonestHelper struct {
t *testing.T
require *require.Assertions
Expand Down Expand Up @@ -44,7 +46,7 @@ func (h *OutputHonestHelper) Attack(ctx context.Context, claimIdx int64, opts ..
// Ensure the claim exists
h.game.WaitForClaimCount(ctx, claimIdx+1)

ctx, cancel := context.WithTimeout(ctx, 2*time.Minute)
ctx, cancel := context.WithTimeout(ctx, getTraceTimeout)
defer cancel()

game, claim := h.loadState(ctx, claimIdx)
Expand All @@ -61,7 +63,7 @@ func (h *OutputHonestHelper) Defend(ctx context.Context, claimIdx int64, opts ..
// Ensure the claim exists
h.game.WaitForClaimCount(ctx, claimIdx+1)

ctx, cancel := context.WithTimeout(ctx, 2*time.Minute)
ctx, cancel := context.WithTimeout(ctx, getTraceTimeout)
defer cancel()
game, claim := h.loadState(ctx, claimIdx)
defendPos := claim.Position.Defend()
Expand Down

0 comments on commit d5b1b75

Please sign in to comment.