Skip to content

flaky test: TestDeployOPChain_WithForge (op-deployer forge-script tests hang until job timeout) #22010

Description

@claude

Claude: op-deployer tests that spawn forge script against a local anvil devnet intermittently hang forever, burning the full 90-minute go-tests-full budget until either the Go test panic (panic: test timed out after 1h30m0s) or CircleCI's no-output watchdog kills the job. The hang, not an assertion failure, is the flake signature — gotestsum reruns never engage.

Occurrences (all on develop, neighbors green):

Root cause (2026-07-17 triage): forge (pinned foundry v1.2.3) stalls inside its broadcast receipt-wait loop for a transaction that entered anvil's pool but was never mined. check_tx_status has a 120s per-attempt timeout but returns a non-decrementing RetryError::Continue while the node still knows the tx, so the loop is unbounded by design (upstream shape: foundry-rs/foundry#6796, foundry-rs/foundry#7642; forge's --timeout bounds one attempt, not the loop). The suspected trigger is a nonce/pool race under forge's default concurrent broadcast (no --slow, up to 7 txs in flight). The Go side waits along with it: forge.Client.execCmd uses exec.CommandContext but tests pass context.Background(), and there is no cmd.WaitDelay, so nothing bounds the subprocess.

Evidence from the hung runs: forge alive at minute 89, os/exec drain goroutines blocked in empty reads (rules out pipe-full deadlock), anvil still serving RPC in the hang's final minute, and every incident stops at the same lifecycle point — after gas estimation, before ONCHAIN EXECUTION COMPLETE.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions