-
Notifications
You must be signed in to change notification settings - Fork 48
[Horizon] Stage 1 upgrade #296
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
feat: invert cuts to keep meaning consistent with pre-horizon
…o/horizon-legacy-locked-tokens
…cy-locked-tokens feat: added legacy fields for locked tokens and lockedUntil
…ute-period feat: added DisputePeriodSet handler
…ing-until feat: adding latest value for thawingUntil on Indexer and Provision
Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
fix: added cancellableAt and LegacyDispute
…ake-lockeduntil
Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
src/mappings/graphTallyCollector.ts
Outdated
let payer = createOrLoadPayer(event.params.payer) | ||
let receiver = createOrLoadReceiver(event.params.receiver) | ||
let escrow = createOrLoadEscrowAccount(event.params.payer, event.params.dataService, event.params.receiver) | ||
escrow.balance = escrow.balance.minus(event.params.tokens) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should update the escrow as part of the payments escrow handlers, specifically in EscrowCollected
handler as that is where the actual state is changed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And we should add tokensCollected
to the graph tally global state
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point. My initial implementation was updating the balance in EscrowCollected
, but that event doesn't have the collectionId
so I changed it to PaymentCollected
. But we can split it up, create the transaction here and update the escrow balance separately.
Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
No description provided.