Skip to content
This repository has been archived by the owner on Mar 19, 2024. It is now read-only.

发布合约的时候gas是怎么估算的? #50

Answered by bruceeewong
ruizer asked this question in Q&A
Discussion options

You must be logged in to vote

可以通过 Dry Run 来模拟任何Transaction的花销(包括发布合约),其返回包含了预估Gas开销,结合这个返回再加点Gas做Buffer防止波动,基本上就能以不太高出实际gas的效果完成transaction
https://docs.sui.io/sui-api-ref#sui_dryruntransactionblock

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by ruizer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants