raulk
raulk
@jannikluhn > Curious about this, could you please elaborate a little on how this works? I'm guessing the DHT maps CIDs to a list of node ids? I briefly thought...
The problem is that the library is losing information along the way. The library needs to catch/lower the exception at the call site, parse the exit code, and propagate it...
To be more concrete, the library should not unconditionally REVERT here: https://github.com/Zondax/filecoin-solidity/blob/461d99318dd5b0114141e128e6c4ec72b33534f5/contracts/v0.8/utils/Actor.sol#L123-L125 Instead, it should parse the exit code from the data returned by the precompile, and propagate it back.
@rllola we might be talking past each other. The **correct** solution is for this library to not force a revert, but rather relay the exit code to the user via...
Can we please build a PoC?
> @raulk We are parsing it here. > https://github.com/Zondax/filecoin-solidity/blob/master/contracts/v0.8/utils/Actor.sol#L187-L189 Good, but the library still reverts unconditionally, making the exit code useless for the contract that's actually using the library.
This can be solved in Solidity like Alex Wade solved it here: https://github.com/wadealexc/fevmate/blob/main/contracts/utils/CallNative.sol#L53-L63 This basically "hides" the delegatecall from the compiler; it's not the best solution but it works today....
@bkolad would be fantastic to apply @marten-seemann's suggestions and report back numbers, even if it's at a smaller scale (please don't deploy 500 AWS instances for this) ;-)
+ populating on snapshot import if not already doing
@rvagg Given you've been dipping your toes in Ethereum standards as a member of FilOz, I think you'd see the value in this quite clearly ;-)