status-desktop icon indicating copy to clipboard operation
status-desktop copied to clipboard

L2 networks are disabled when bridging by default which leads to no route found

Open anastasiyaig opened this issue 10 months ago • 6 comments

Description

  1. open app
  2. click Bridge
  3. select ETH
  4. note that no route found
  5. open Advanced -> L2 networks are disabled
DBG 2024-04-16 17:51:08.317+03:00 [threadpool task thread] initiating task   topics="task-threadpool" tid=819149 file=threadpool.nim:54 messageType=GetSuggestedRoutesTaskArg:ObjectType threadid=819149 task="{\"$type\":\"GetSuggestedRoutesTaskArg:ObjectType\",\"accountFrom\":\"0xf38d2cd3c6ad02dd6f8b68e0a7b2f959819954b6\",\"accountTo\":\"0xf38d2cd3c6ad02dd6f8b68e0a7b2f959819954b6\",\"amount\":\"100000000000000000\",\"token\":\"ETH\",\"disabledFromChainIDs\":[],\"disabledToChainIDs\":[10,42161],\"preferredChainIDs\":[1,10,42161],\"sendType\":5,\"lockedInAmounts\":\"{}\",\"vptr\":105553121137248,\"slot\":\"suggestedRoutesReady\",\"tptr\":4335687644}"
  1. enable L2 networks -> route is calculated
DBG 2024-04-16 17:51:58.940+03:00 [threadpool task thread] initiating task   topics="task-threadpool" tid=819148 file=threadpool.nim:54 messageType=GetSuggestedRoutesTaskArg:ObjectType threadid=819148 task="{\"$type\":\"GetSuggestedRoutesTaskArg:ObjectType\",\"accountFrom\":\"0xf38d2cd3c6ad02dd6f8b68e0a7b2f959819954b6\",\"accountTo\":\"0xf38d2cd3c6ad02dd6f8b68e0a7b2f959819954b6\",\"amount\":\"100000000000000000\",\"token\":\"ETH\",\"disabledFromChainIDs\":[],\"disabledToChainIDs\":[],\"preferredChainIDs\":[1,10,42161],\"sendType\":5,\"lockedInAmounts\":\"{}\",\"vptr\":105553121137248,\"slot\":\"suggestedRoutesReady\",\"tptr\":4335687644}"

https://github.com/status-im/status-desktop/assets/82375995/102a65e5-9636-4178-be63-f274a1bb061e

anastasiyaig avatar Apr 16 '24 14:04 anastasiyaig

@anastasiyaig thats the way the bridge UI was as per design. on the simple routing view we need to choose which network we want to bridge to. In the view you shared on the simple view the user by default has bridge to mainnet selected. If you could switch to optimism in that view you would see a valid route. And maybe if this is confusing we need some help from design to sort this out. It could also be a misunderstanding on our end in implementing this.

Khushboo-dev-cpp avatar Apr 18 '24 09:04 Khushboo-dev-cpp

@Khushboo-dev-cpp thanks a lot with explanation of this! From user pov it is confusing as i am seeing No Route on simple view (which is defaulted) because app tries to bridge from L1 to L1 (is my understanding here correct?) @benjthayer wdyt?

anastasiyaig avatar Apr 18 '24 09:04 anastasiyaig

yes exactly l1 to l1 is not bridge but a simple tx and hence we do not show any routes for that. Only when user switches

Khushboo-dev-cpp avatar Apr 18 '24 10:04 Khushboo-dev-cpp

agree, maybe we need to design something on top of existing feature? @benjthayer

anastasiyaig avatar Apr 18 '24 11:04 anastasiyaig

agree, maybe we need to design something on top of existing feature? @benjthayer

Hey @anastasiyaig @Khushboo-dev-cpp just went to look into this but I don't see any flows in the Wallet v2 file for bridging? Do you know which designs were referenced for the implementation?

It looks like there were some designs here at some point but they seem to have been deleted? https://www.figma.com/file/FkFClTCYKf83RJWoifWgoX/Wallet-v2?type=design&node-id=2829-145815&mode=design

benjthayer avatar Apr 22 '24 06:04 benjthayer

@benjthayer the link you share seems like the reference point, but definitely is missing and shows some wrong flows too :(

Khushboo-dev-cpp avatar May 06 '24 09:05 Khushboo-dev-cpp

It could be that it's fixed via https://github.com/status-im/status-desktop/issues/14665 we need to check, but anyhow a thorough inspection of the router is about to happen and I hope after it all router-related issues will be fixed.

saledjenic avatar May 12 '24 08:05 saledjenic

This is not an issue, as Khushboo explained above, when bridging, the user needs to select which network wants to bridge to and if that's the same as "from network", bridge is not possible in that case.

@anastasiyaig you can test this in the router v2 integration PR https://github.com/status-im/status-desktop/pull/15344

saledjenic avatar Jun 28 '24 06:06 saledjenic