Giter VIP home page Giter VIP logo

Comments (5)

djrtwo avatar djrtwo commented on June 10, 2024

We scale deposits as an optimization. We scale on the way in and the way out, rather than updating all validator deposits at each epoch depending on gains/losses. We use m as the unit deposits are scaled against. This extra unit helps with type checking when dealing with wei vs scaled wei

from casper.

ben-kaufman avatar ben-kaufman commented on June 10, 2024

Thanks, so currently you use m even though it means meter because you need to use some unit right?
I believe when VIP 752 (github.com/vyperlang/vyper/issues/752) will be implemented it will be better to use a custom unit for this case.

from casper.

djrtwo avatar djrtwo commented on June 10, 2024

Correct. Is there a unit currently that might make more sense?

from casper.

ben-kaufman avatar ben-kaufman commented on June 10, 2024

I don't think so, maybe currency or currency1 will sound more generic but I don't think it will help. This are the current units in Vyper: currency, wei, currency1, currency2, sec, m, kg.
I was thinking about adding some generic unit (e.g. unit or so) but if we are going to implement VIP 752 it won't be necessary.

from casper.

djrtwo avatar djrtwo commented on June 10, 2024

Heard that. Closing until the feature is released in vyper

from casper.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.