File tree Expand file tree Collapse file tree 2 files changed +14
-5
lines changed
Expand file tree Collapse file tree 2 files changed +14
-5
lines changed Original file line number Diff line number Diff line change @@ -27,11 +27,11 @@ integration = []
2727[dependencies ]
2828init4-bin-base = { version = " 0.4.2" , features = [" perms" ] }
2929
30- signet-constants = { git = " https://github.com/init4tech/signet-sdk" }
31- signet-sim = { git = " https://github.com/init4tech/signet-sdk" }
32- signet-tx-cache = { git = " https://github.com/init4tech/signet-sdk" }
33- signet-types = { git = " https://github.com/init4tech/signet-sdk" }
34- signet-zenith = { git = " https://github.com/init4tech/signet-sdk" }
30+ signet-constants = { git = " https://github.com/init4tech/signet-sdk" , branch = " dylan/logging " }
31+ signet-sim = { git = " https://github.com/init4tech/signet-sdk" , branch = " dylan/logging " }
32+ signet-tx-cache = { git = " https://github.com/init4tech/signet-sdk" , branch = " dylan/logging " }
33+ signet-types = { git = " https://github.com/init4tech/signet-sdk" , branch = " dylan/logging " }
34+ signet-zenith = { git = " https://github.com/init4tech/signet-sdk" , branch = " dylan/logging " }
3535
3636trevm = { version = " 0.23.4" , features = [" concurrent-db" , " test-utils" ] }
3737
Original file line number Diff line number Diff line change @@ -69,10 +69,19 @@ async fn main() {
6969
7070async fn send_transaction ( provider : & HostProvider , recipient_address : Address ) {
7171 // construct simple transaction to send ETH to a recipient
72+ let nonce = match provider. get_transaction_count ( provider. default_signer_address ( ) ) . await {
73+ Ok ( count) => count + 1 ,
74+ Err ( e) => {
75+ error ! ( error = ?e, "failed to get transaction count" ) ;
76+ return ;
77+ } ,
78+ } ;
79+
7280 let tx = TransactionRequest :: default ( )
7381 . with_from ( provider. default_signer_address ( ) )
7482 . with_to ( recipient_address)
7583 . with_value ( U256 :: from ( 1 ) )
84+ . with_nonce ( nonce)
7685 . with_gas_limit ( 30_000 ) ;
7786
7887 // start timer to measure how long it takes to mine the transaction
You can’t perform that action at this time.
0 commit comments