DA0-DA0 / polytone

An account on every blockchain for every smart contract.
42 stars 5 forks source link

Add gas limit to voice message execution and ACK on out-of-gas. #22

Closed 0xekez closed 1 year ago

0xekez commented 1 year ago

This adds a manually tuned gas limit to voice packet handling so that even if the packet causes an out-of-gas error, the module reserves enough gas to return an ACK informing the caller of the out-of-gas error.

0xekez commented 1 year ago

This is blocked on two things:

  1. At least in the IBC testing framework, gas usage is non-deterministic. See https://github.com/DA0-DA0/polytone/issues/23 which describes how I was able to write a test to reproduce this.
  2. In response to gas usage being non-dererministic, I want to test this change against a real chain because I am paranoid, but at the moment interchaintest doesn't use the gas limits you specify so I can't instantiate the voice module: https://github.com/strangelove-ventures/interchaintest/issues/482
0xekez commented 1 year ago

@Art3miX - lmk what you think of this. i reorganized the tests, set up CI, found a bug, and made some progress reproducing the handshake bug in interchaintest so i'm now pretty sure that's a problem with IBC and not with our handshake process.

0xekez commented 1 year ago

now blocked on more SDK quirks:tm: https://github.com/cosmos/ibc-go/issues/3428