eth-fun icon indicating copy to clipboard operation
eth-fun copied to clipboard

we cannot parse transaction input data

Open TimDaub opened this issue 3 years ago • 0 comments

  • catalog v2 stores the creator's address in an ethereum transaction's call data: https://github.com/neume-network/strategies/issues/324#issuecomment-1285501936 (sometimes also called "input data")
  • surprisingly, there isn't a good way to parse call data using web3js, e.g. there's no "decodeFunctionCall" method available https://github.com/web3/web3.js/issues/3555#issuecomment-1285768317
  • but ethers.js has a parseTransaction function which might work: https://docs.ethers.io/v5/api/utils/abi/interface/#Interface--parsing
  • and there are other libraries too. But I want to be conscious of eth-fun's footprint (bundle size). Maybe we don't integrate web3js and ethers at the same time. Potentially we may need to replace ethers with web3 now... or what are some other options?
  • we also wanna be conscious of not breaking the existingly exported web3-abi functionality either as this would require wide-scale changes to e.g. the neume infrastructure: https://github.com/rugpullindex/eth-fun/blob/master/API.md#web3-eth-abi-functions

TimDaub avatar Oct 20 '22 15:10 TimDaub