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

Bridging of assets is blocked unless user has a positive balance of this asset ("Network is not available")

Open VolodLytvynenko opened this issue 1 year ago • 12 comments

Preconditions:

Recover user that has an asset on network 1 only (current asset should not be ETH, DAI, or SNT)

Steps:

  1. Recover user with assets that are supported on 3 networks (Example: USDC)
  2. Go to the routes generation page 3.Attempt to bridge assets from the network where the user holds assets to another network.

Actual result:

On send page: "Network is not available" is shown in the TO section for the receiver, even though asset (a token available on all networks) is selected for sending.

https://github.com/user-attachments/assets/e8567210-8210-4c4a-9fd9-455345f933b2

On Bridge Page: The user cannot select networks on which they do not hold the asset (e.g., if the user has USDC on Optimism, they cannot select Arbitrum or Mainnet for bridging).

Image

Expected result:

The app should allow the user to select networks where the asset is supported, even if the user does not have an available balance on those networks.

OS:

IOS, Android

Devices:

  • Pixel 7a, Android 13
  • iPhone 11 Pro Max, IOS 17

Logs

Status-debug-logs.zip

VolodLytvynenko avatar Aug 08 '24 13:08 VolodLytvynenko

@shivekkhurana, @ilmotta @status-im/mobile-qa @xAlisher @vkjr - If simple send is happening in 2.31 will this still be needed? I think you should properly plan ahead for this to spare any double work.

J-Son89 avatar Aug 19 '24 12:08 J-Son89

Good question @J-Son89. I don't know as well. It depends on how simple send will overlap with the existing complex send feature. Will complex send be removed/disabled and will we only support simple send until we reach a butter smooth experience?

ilmotta avatar Aug 19 '24 17:08 ilmotta

Good question @J-Son89. I don't know as well. It depends on how simple send will overlap with the existing complex send feature. Will complex send be removed/disabled and will we only support simple send until we reach a butter smooth experience?

Imo it should absolutely be this, remove the complexity complete and have the simple things working exceptionally. The network preferences should be removed as even that is another set of complications to support and add no value with simple send. @xAlisher should have the clearest picture on this but I think both of us agreed on that approach

J-Son89 avatar Aug 19 '24 17:08 J-Son89

@J-Son89, good point! No work done yet regarding this issue and there is no reason to do anything before simple send is in place. But when implemented, it is worth rechecking the simple send with the account @VolodLytvynenko mentioned in the description. So we can put blocked label until that time. Wdyt, @shivekkhurana @ilmotta ?

vkjr avatar Aug 20 '24 11:08 vkjr

@J-Son89 @ilmotta @vkjr I'm working on it. Will share with you ASAP.

xAlisher avatar Aug 23 '24 13:08 xAlisher

still valid. Not related to new rpc from https://github.com/status-im/status-mobile/pull/21378

VolodLytvynenko avatar Oct 07 '24 15:10 VolodLytvynenko

Issue wouldn't be valid after re-design of Send flow (as per this comment ), also it is not really block user from sending tx, so I don't think that we need to work on anything blocked now.

Removed from milestone, cc @shivekkhurana

churik avatar Oct 09 '24 09:10 churik

More context: Image

churik avatar Oct 10 '24 14:10 churik

Additionally, such wrong validation is performed within the network edit drawer Image

VolodLytvynenko avatar Oct 10 '24 15:10 VolodLytvynenko

@pavloburykh @churik

  1. Is this needed for 2.31 or not ?
  2. Is this still a bug ?

shivekkhurana avatar Oct 14 '24 08:10 shivekkhurana

@shivekkhurana
It is still a bug and it blocks bridging, but there are more problems with bridging, i.e. https://github.com/status-im/status-mobile/issues/21180 and https://github.com/status-im/status-mobile/pull/21116, which basically make our bridge not usable.

Up to you and @ilmotta to decide, but I'd consider to block this functionality if we're facing these issues.

More info: this thread

churik avatar Oct 14 '24 10:10 churik

Preliminary update:

Mobile actually depends on the token data (balances-per-chain key) for networks supported by the token.

If the token is actually supported in a network but has no positive balance, mobile expects 0 balance in that chain ID/network. I will check how Desktop does.

smohamedjavid avatar Oct 16 '24 12:10 smohamedjavid