You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When dealing with multi-contracts (see this), users might call ContractA, which calls ContractB.
ContractA will require an ABI, ContractB will not. So, if ContractB has some log() calls, those may bubble up to ContractA, which won't be able to decode them due to the lack of an ABI definition, and then we throw.
The issue is that the transaction may have been successful, in which case throwing an error can be confusing.
These solutions are worth considering, but requires more in-depth thought to understand if it can cause other problems.
We could print a warning instead of throwing an error when trying to decode ContractB logs as they come via ContractA.
This approach could acknowledge the possible successful transaction while alerting the user to the decoding issue.
Maybe the better approach would be to not throw it here, and just log a warning.
The text was updated successfully, but these errors were encountered:
Issue
When dealing with multi-contracts (see this), users might call
ContractA
, which callsContractB
.ContractA
will require an ABI,ContractB
will not. So, ifContractB
has somelog()
calls, those may bubble up toContractA
, which won't be able to decode them due to the lack of an ABI definition, and then we throw.The issue is that the transaction may have been successful, in which case throwing an error can be confusing.
Original Discussion.
Potential solutions
These solutions are worth considering, but requires more in-depth thought to understand if it can cause other problems.
We could print a warning instead of throwing an error when trying to decode ContractB logs as they come via ContractA.
This approach could acknowledge the possible successful transaction while alerting the user to the decoding issue.
Maybe the better approach would be to not throw it here, and just log a warning.
The text was updated successfully, but these errors were encountered: