Git Product home page Git Product logo

Comments (1)

kasparkallas avatar kasparkallas commented on September 23, 2024

1

Approved is sorting correctly. "Ascending" means to go from lower to higher. "No" is 0, "yes" is 1. This means that the first entry in the sorted list should be "no" which it is.

"Total amount received" is indeed sorting incorrectly because we can only look at totalAmountReceivedUntilUpdatedAt which can be behind the actual amount received (which is displayed). To remedy this, I disabled the search.

2

Great catch! The algorithm was wrong. It's a touchy one because it showed false positives in certain scenarios.

The current formula is as follows:

  1. We query both IndexUpdatedEvents and SubscriptionUnitsUpdatedEvents.
  2. For each IndexUpdatedEvent, we match the closes SubscriptionUnitsUpdatedEvent to get subscriptions units at the point of IndexUpdatedEvent.
  3. We get the current total distribution value of the index by subtracting indexUpdatedEvent.oldIndexValue from indexUpdatedEvent.newIndexValue.
  4. We get the subscription's distribution amount by multiplying the previous result (total index distribution value) with the subscription's units.

3

"Approved index update is no"
I don't understand this one. Please clarify.

4

"Don't show distributions or add an option to hide distributions where the subscriber received 0 tokens"
Done by finding the period when the subscription started and ended. If there's a period in the middle with zeroes then I can't hide that.

But... doing this brought out couple of accounts with discrepancies with "total amount received". Example: http://localhost:3000/matic/index-subscriptions/0x007de57773b6eb4ebbf6a740dfde1efdd5629630-0x98d463a3f29f259e67176482eb15107f364c7e18-0x263026e7e53dbfdce5ae55ade22493f828922965-0 I'm trying hard but I can't figure out where the error is coming from.

EDIT: Okay, I figured it out... Long story short, I have to look at log indexes when IndexUpdatedEvent and SubscriptionUnitsUpdatedEvent have the same timestamp...

5 "Sort units updated by date in index subscription page"

Done.

6 "Make the column sizes changeable"

Resizable columns come with paid version of MUI DataGrid (Material-UI is 98% free and this is the only paid component)...

7 "Show None instead of 0x000000 as the underlying token for native super tokens"

Done.

8 "If possible add details to individual distributions in the Index page showing the amount of tokens that got sent to which address"

Nice idea but let's put it in the icebox.

from superfluid-console.

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.