rs client: Use finalized commitment for blockhash
confirmed say occasional errors
This commit is contained in:
parent
7722c66826
commit
add1647d37
|
@ -1722,7 +1722,7 @@ impl TransactionBuilder {
|
||||||
rpc: &RpcClientAsync,
|
rpc: &RpcClientAsync,
|
||||||
) -> anyhow::Result<solana_sdk::transaction::VersionedTransaction> {
|
) -> anyhow::Result<solana_sdk::transaction::VersionedTransaction> {
|
||||||
let (latest_blockhash, _) = rpc
|
let (latest_blockhash, _) = rpc
|
||||||
.get_latest_blockhash_with_commitment(CommitmentConfig::confirmed())
|
.get_latest_blockhash_with_commitment(CommitmentConfig::finalized())
|
||||||
.await?;
|
.await?;
|
||||||
self.transaction_with_blockhash(latest_blockhash)
|
self.transaction_with_blockhash(latest_blockhash)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue