question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Wallet does not properly reflect the decimals of FT in the post conditions correctly

See original GitHub issue

So in our app https://mia.derupt.io Users can interact with the Derupt smart contract. When doing so they are supposed to be transferring exactly 100 MIA per action. (when creating a New Chime, Liking an existing Chime, or Disliking an existing Chime.)

When clicking a button to invoke the action and thus present the Hiro Web Wallet popup window, it will show 100 MIA to be transferred as expected. However when viewing the transaction on the explorer it shows only the 0.0001 MIA is the post condition amount.

No matter what, we can’t seem to get the Hiro Web Wallet popup window and the actual amount per the explorer to both be indicative of 100 MIA.

In our source code we set my amount with new BigNum(100000000); The transaction per the Explorer settles correctly, eg 100 MIA is transferred as intended. HOWEVER during this instance the Hiro window says the user is its going to xfer 100000000 MIA instead. Which most def will create cause for pause as a user.

The best we can tell is that the Hiro Web Wallet does not properly reflect the decimals of FT in the post conditions correctly during the confirmation popup window.

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:2
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
cryptocracycommented, Oct 2, 2022

Thanks for this report, even if it it did seem to automatically resolve itself. Is it possible that the relevant contract had been very recently deployed and the API that the wallet uses to load standardized contract data may not have loaded the decimals data in time for your initial testing? Or had the contract been deployed for awhile already?

The contract in question that I was calling is our derupt alpha version 11 contract. SP3T3JC6V4S94PPB7WFEK17863HPG3EYP6CJ65E7M.derupt-mia-alpha-v11 which was deployed over 4months ago.

1reaction
cryptocracycommented, Sep 29, 2022

Trying to educate users about decimal precision errors outside of our control does make for a good UX, …can’t just be like “trust me bro…”

Read more comments on GitHub >

github_iconTop Results From Across the Web

1 Algebra 1 Keystone Review A1.1.1.1 Represent and/or use ...
A1.1.1.1 Represent and/or use numbers in equivalent forms (e.g., integers, fractions, decimals, percents, square roots, and exponents). 1. Which number is ...
Read more >
Convert feet-inches to decimal feet - YouTube
Fancy specialty calculators may not be around on the job site, learn to convert in writing using a basic calculator.To multiply 7`- 5...
Read more >
Middle School Math Solution
Mathematics is so much more than memorizing rules. It is learning to reason, to make connections, and to make sense of the world....
Read more >
Grade 6 B.E.S.T. Instructional Guide for Mathematics
The B.E.S.T. Instructional Guide for Mathematics (B1G-M) is intended to assist educators with planning for student learning and instruction aligned to ...
Read more >
Practice: Word Problems - SharpSchool
a board of cedar lumber that was. 0.80 feet long. Alberto said the cedar board was longer. Is he correct? Explain. No; 0.8...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found