TL/DR: WaitForLocalExecution
will be removed from JSON RPC on 9/18. dapps must migrate to client.waitForTransaction({ digest })
.
In version 1.33 (scheduled to be released on September 18th), JSON RPC will ignore the requestType: 'WaitForLocalExecution'
option, and the JSON RPC API has been updated to support returning object and balance changes without the need for local execution. Many dapps have also used WaitForLocalExecution
to ensure read-after-write consistency, which will no longer be possible through JSON RPC.
To make this migration as painless as possible, we have updated the Typescript SDK to detect the requestType: 'WaitForLocalExecution'
option, and automatically use client.waitForTransaction
to ensure that the transaction has been indexed after execution. This means that ensuring read-after-write consistency with the typescript SDK is as simple as updating the SDK to the latest version (@mysten/sui@1.6.0
), and setting requestType
to WaitForLocalExecution
. This option is marked as deprecated, and will be removed in the next major release, but we don’t anticipate a major release of the typescript SDK any time soon.
Going forward, dapps should use client.waitForTransaction({ digest })
to ensure a transaction has been indexed when they need read-after-write consistency. This will allow dapps to opt in to the latency costs associated with this, while allowing more efficient execution for dapps and wallets that do not have those constraints.