HausDAO / daohaus-app

long live pokemol
https://daohaus.club/
Other
134 stars 79 forks source link

UI token `amount` results in different numbers on chain #2053

Open shayanb opened 1 year ago

shayanb commented 1 year ago

Describe the bug Seems that the number formatter for the number of voting tokens is different in different views. Sometimes 10 means 10 voting tokens, some other times it means 10 / 10^18 tokens. I'll explain the work flow we used that resulted in such issue in to reproduce

To Reproduce Steps to reproduce the behavior:

  1. Summoned a DAO with 2 initial members each having 10 voting tokens (this resulted in 2 members with 10 voting tokens each)
  2. Propose to add 5 members each with 10 voting tokens. (this resulted in each new member having 0.00000000000000001 tokens.

Expected behavior

When typing in 10 in the DAOHaus form, expected behaviour is to always result in the same number on chain. either both to be 10 or both to be 10 "wei".

Actual behavior

On the summoning DAO form 10 means 10 * 10^18 in the sense of token amount On the proposal view to add members 10 means 10 wei in the sense of token amount

Screenshots

Screenshot 2023-03-12 at 4 32 41 PM Screenshot 2023-03-12 at 4 32 26 PM

Additional Questions

  1. [ Maybe?] Is there a loss of funds, shares or loot?

Application area

Where in the app is this happening?

dekanbro commented 1 year ago

thank you for reporting the issue. Can i confirm this is on the v2 summoner or the v3?

this is v2 https://app.daohaus.club/summon

and this is the v3 summoner https://summon.daohaus.club/

shayanb commented 1 year ago

I believe V3, I used this url though: https://admin.daohaus.fun/