Skip to content
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

Split mappings file according to contract event emitter #16

Merged
merged 2 commits into from
Jun 17, 2022

Conversation

manumonti
Copy link
Member

Note: This PR must be merged after #11

The Threshold Subgraph receives events from several sources (contracts). So a logical division of events handlers can be each contract.

To achieve this, the generic mappings.ts file has been split into pre-app.ts and staking.ts.

Also, the TokenStaking entities list in subgraph manifest has been updated.

@manumonti manumonti requested review from cygnusv and r-czajkowski June 8, 2022 08:26
@manumonti manumonti changed the title Split mappings file according to event contract emitter Split mappings file according to contract event emitter Jun 8, 2022
@manumonti manumonti force-pushed the operator-events branch 3 times, most recently from a0ae207 to e4a63ea Compare June 10, 2022 12:43
Copy link
Contributor

@r-czajkowski r-czajkowski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything makes sense, well done 👍

Base automatically changed from operator-events to main June 17, 2022 08:55
Threshold Subgraph recieves events from several sources (contracts). So
a logical division of events handlers can be each contract.

To achieve this, the generic "mappings.ts" file have been splitted in
"pre-app.ts" and "staking.ts".

Also, TokenStaking entities list in subgraph manifest has been updated.
Since all the event handler functions placed in mappings.ts are related
to Token Staking contract, staking.ts seems to be a more precise name
for this mapping file.
@r-czajkowski r-czajkowski merged commit 914f5af into main Jun 17, 2022
@r-czajkowski r-czajkowski deleted the split-mappings branch June 17, 2022 10:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants