Outblock / FRW-Extension

Flow Reference Wallet - Chrome Extension Client
1 stars 5 forks source link

[BUG] FCL transaction executes but fails to resolve only when FRW extension is enabled #77

Open leontastic opened 4 months ago

leontastic commented 4 months ago

Describe the Bug

I have had the FRW extension installed on my Chrome browser for over a year now.

When running FCL transactions in Chrome against Dapper Wallet (not Flow Wallet), I noticed that FCL will successfully send and await execution, but will fail to resolve onceExecuted.

We submit FCL transactions with the textbook APIs:

    const txId = await send(interaction).then(decode);
    return await tx(txId).onceExecuted();

When inspecting the network calls made by FCL:

  1. The tx successfully executes.
  2. FCL polls for the tx.
  3. FCL stops polling once it reaches the Sealed state, as expected.
  4. The onceExecuted promise fails to resolve.

In investigating the regression, I found that when disabling the FRW extension, the onceExecuted promise resolves correctly, and when turning it back on, onceExecuted fails to resolve. This suggests there is a possible issue with FRW extension which causes FCL transactions to fail to resolve, or there is some kind of interaction between FCL and FRW that causes it to fail.

As far as I can see, our FCL configuration is also fairly vanilla, only specifying contract addresses, and setting NEXT_PUBLIC_WALLET_DISCOVERY to Dapper's authn services.

I have not found a root cause, but I am reporting this issue here so maintainers are aware and others can corroborate. It may be environment-specific, as I don't have any other reports of the issue.

Expected experience

fcl.tx(txId).onceExecuted should resolve when FRW is enabled

Steps To Reproduce

Please reach out directly for a reproduction of this case.

Environment

Browser: Chrome Version 126.0.6478.185 (Official Build) (arm64)
OS: macOS Ventura Version 13.6 (22G120)
FRW Extension: Version 2.3.0
Peppermint1020 commented 2 months ago

https://github.com/user-attachments/assets/9e52c98a-687e-4e90-af1d-d314c99330a7

Peppermint1020 commented 1 month ago

@leontastic Hi Leon, Thank you for your patience. We have not been able to replicate the issue you reported. Could you please let us know if you are still experiencing the problem?