Skip to content

Conversation

@kvinwang
Copy link
Collaborator

Summary

  • When deploying with --with-app-impl, Step 1 (DstackApp) and Step 2 (DstackKms proxy) run back-to-back
  • Public RPC endpoints may return a stale nonce after Step 1's transaction is mined, causing Step 2 to fail with nonce too low
  • Added a poll loop on getTransactionCount("latest") to wait until the nonce reflects Step 1 before proceeding to Step 2

Test plan

  • Tested on Base Sepolia with echo "y" | npx hardhat kms:deploy --with-app-impl --network custom — deployment completes successfully without nonce errors

When deploying with --with-app-impl, Step 1 (DstackApp) and Step 2
(DstackKms proxy) run back-to-back. Public RPC endpoints may return a
stale nonce after Step 1's transaction is mined, causing Step 2 to fail
with "nonce too low". Poll getTransactionCount("latest") until it
reflects the Step 1 nonce before proceeding.
@kvinwang kvinwang merged commit dfbf34e into master Feb 13, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant