Open oswy-cpu opened 7 months ago
Is this a token allowance issue? Are they supposed to be able to bridge without setting an allowance here? Any info would help
2 tickets now in Intercom Continue collecting https://app.intercom.com/a/inbox/qge2vd8z/inbox/conversation/837?view=List
Now here is 6 tickets: https://app.intercom.com/a/inbox/qge2vd8z/inbox/conversation/837?view=List
@ekbainova I'm looking through Intercom. I see one user indicates they have 0 allowance, which I believe is why we're throwing an error when calling allowance()
. Other users don't specify their allowance.
At this point, I'm assuming the allowance()
call is failing when the user does not have the required allowance.
What should we do in this situation to resolve this issue?
@regexpressyourself what sort of allowance? I don't get it, sorry.
@regexpressyourself There's an sdk.approveIfNeeded
call that should happen prior to xcall
. The approveIfNeeded
call checks if the asset is an xERC20. If so, it looks up the allowance on the LockboxAdapter otherwise it looks it up for the Connext contract. If there isn't sufficient allowance, the txn object returned by approveIfNeeded
should be sent by the user first. Only after that should the txn object returned by xcall
be sent to the user to send. I think we need to look into the sequencing of these events.
@regexpressyourself There's an
sdk.approveIfNeeded
call that should happen prior toxcall
. TheapproveIfNeeded
call checks if the asset is an xERC20. If so, it looks up the allowance on the LockboxAdapter otherwise it looks it up for the Connext contract. If there isn't sufficient allowance, the txn object returned byapproveIfNeeded
should be sent by the user first. Only after that should the txn object returned byxcall
be sent to the user to send. I think we need to look into the sequencing of these events.
@just-a-node Got it.
The sequence appears correct when looking through the code and cross referencing the logs in the screenshot above. The approveIfNeeded
call happens before the "set for an XERC20" logs, which we see in the screenshot logs. So it appears the sequencing there is ok.
Following the approveIfNeeded
call, we "setup for an XERC20". The first step from there is a series of allowance()
calls.
The failure here seems to occur on one of the calls to allowance()
when working with an XERC20 asset. For XERC20 assets, we make 6 different allowance()
calls at once. At least one of these calls is failing and returning the "call revert exception" error.
I've still been unable to reproduce this myself. When bridging XERC20 assets, I see the correct sequence of calls, and am able to approveIfNeeded
and get through to the next txn:
Any more info on how to reproduce this, or some extra logging data would be super helpful in tracking this down. In the meantime, I've opened a PR with some additional logging that we can collect when reports of this come in: https://github.com/connext/frontend/pull/74
Merged logs PR
Describe the bug
Link to ticket in discord https://discord.com/channels/454734546869551114/1232897391233994774
Additional context A bunch of different users facing the same issue bridging ezETH from L1.
@oncall
SLA: 2 working days