Skip to content
This repository was archived by the owner on May 29, 2025. It is now read-only.

Conversation

@jmoreira-valory
Copy link
Collaborator

Update mech_events to use subgraph

EXCLUDED_BLOCKS_THRESHOLD = 2 * BLOCKS_CHUNK_SIZE
NUM_EXCLUDED_BLOCKS = 10
MECH_EVENTS_DB_VERSION = 2
MECH_EVENTS_DB_VERSION = 3
Copy link
Collaborator Author

@jmoreira-valory jmoreira-valory Feb 8, 2024

Choose a reason for hiding this comment

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

@DavidMinarsch The easiest way of implementing the subgraph integration is by using a new db version.
This will require to recreate the local DB (a few minutes the first time is run).
Fortunately, after some tests, it seems this approach is way more robust than querying the blockchain directly in the following sense:

  • It has not been observed that the process is interrupted (by RPC issues as before, obviously)
  • Even if it takes some time, it is always eventually successful, in the tests performed.
  • The user can decide to interrupt the mech update, and it will have stored progress locally (so it will retake from where it was left, next time the script is run)

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes let's do a new db version

@dagacha dagacha merged commit 664ef6a into develop Feb 9, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants