status-im / status-desktop

Status Desktop client made in Nim & QML
https://status.app
Mozilla Public License 2.0
301 stars 79 forks source link

[Browser plugin connector] Paraswap cannot change the chain to operate on L2 #16772

Open alexjba opened 3 days ago

alexjba commented 3 days ago

Bug Report

Description

Cannot change the chain when using Paraswap. It is stuck on Mainnet. It looks like the the dApp requests chain change, but the connector doesn't change it.

Steps to reproduce

  1. Go to Paraswap and connect it to Status using the plugin
  2. Configure a swap on L2

Expected behavior

The swap can be configured on supported L2 chains

Actual behavior

The swap cannot be configured on L2 chains Image

Acceptance criteria

  1. The connector sends a valid response on wallet_switchEthereumChain RPC request
  2. If the dApp requests chain change to a supported chain, Status automatically changes the chain for the dApp interaction
  3. The chain change is cached by status for the dApp that successfully changed the chain
  4. Next responses to eth_chainId coming from the dApp are inline with the wallet_switchEthereumChain response