oasislabs / oasis.js

🕸A web client for the Oasis platform

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Provide something like web3's estimateGas

omitar opened this issue · comments

What is the problem that you're trying to solve?

I am trying to determine what to set as a gas limit so that my calls do not hit the gas limit unnecessary.

Describe the solution you'd like

I think something like web3's estimateGas should be provided so that I could call it to get the gas estimate. I could then use that.

Describe alternatives you've considered

Currently this looks like manual trial & error and then I hard-code the value in the program. This seems very fragile and also not future proof.

Interesting. But how does one obtain "The transaction call object"? Is this documented anywhere and I missed it?

It's documented immediately under.

Oh, structure of that is so strange. So the bullet list is under the "The transaction call object", the contents of "The transaction call object"? To me it looked like the list of additional arguments.

How does one specify which service method to call and arguments to that method? Maybe some example of how this could be done would be useful?