sora-xor / sora2-parachain

SORA is a new economic system aimed at creating a supranational, world economic system with built-in tools for decentralized finance (DeFi). The SORA network implements a new way of parachain architecture on Polkadot and Kusama network, with the capability to bridge external blockchains (like Ethereum) to the Polkadot ecosystem.
The Unlicense
14 stars 4 forks source link

[Bug]: substrateBridgeApp.WrongAmount when user trasnfers with wrong dimension #146

Open ra9mls opened 9 months ago

ra9mls commented 9 months ago

Preconditions

User has a ROC tokens

Steps to reproduce

Call data: 0x6700010300dc9b4341fde46c9ac80b623d0d43afd9ac205baabdc087cadaa06f92b309c7020301010100bcc5ecf679ebd776866a04c212a4ec5dc45cefab57d7aa858c389844e212693fe040944dff51970f0000000000000000

Actual behavior

User sees error substrateBridgeApp.WrongAmount https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fws.framenode-2.s1.stg1.sora2.soramitsu.co.jp#/explorer/query/0xb8954820ca19ae0a40fad4fd401692de99f048aa21baf25e9f9b04bdaea4f6db

Expected behavior

??? When user inputs 1123456789012300000 with larger dimension (ROC has 12) it need to be converted according asset

Environment

{"label"=>"Development"}

Operating System

No response

Additional context

No response

Aha! Link: https://soramitsucoltd.aha.io/features/SKP-6

bgodlin commented 9 months ago

@ra9mls please check for duplication with #117

ra9mls commented 9 months ago

Some problems can be if it works with token with 21 precision. When user will send this token and it will be applied with fee, this transfer will be failed because sora has 18 precision.

Tieumsan commented 8 months ago

@N1ghtStorm @ra9mls what is the status of this task ? Has it been fixed ?

cc. @vovac12