-
Notifications
You must be signed in to change notification settings - Fork 43
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
adjust scripts for API v5's BNS import #90
Comments
if i understand this correctly - the API env var maybe i'm a bit confused since your comment says are there docs you can share on how this is changing in the API rep? |
That is correct. The event replay process will now be the one to look at
I modified a part of the README here: https://github.com/hirosystems/stacks-blockchain-api/blob/ed8b6f5839c0c28339bb123e0411902ec78a0209/readme.md#event-replay-instructions |
I think i understand - functionally, i don't see any changes to this repo outside of docs. It's not clear to me from the link though - if you download/extract the data, and define the |
That is correct. That is a good question, though, because IIRC the import will fail if you don't have a replay file even though you do have the BNS data. |
well, good thing i plan on testing this to see what happens! |
One issue i've found is if you're trying to run the import before having the tsv file...the process fails and the BNS data isn't imported. syncing for a few blocks, then re-running the import works as expected (with BNS data being imported). I'm wondering if there can/should be a check in the API code if the tsv doesn't exist, but BNS_IMPORT_DIR is defined...import the bns data only and exit vs trying to import events. |
attaching a test i ran, where i built the API from master - downloaded the BNS data and defined the variable, with an empty postgres DB.
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This issue has been automatically closed. Please reopen if needed. |
We're in the process of releasing Hiro API v5 which fixes a bunch of bugs related to BNS data.
One of those changes is that now we import BNS data (if available) before event replay, because the API needs to know which namespaces exist so it can calculate names' expiration block heights if it sees a name registered, updated or transferred in a tx during replay. Launching the API no longer imports BNS data as it did before.
This import is handled automatically i.e. there's no need for users to run a command other than
import-events
, however, this repo might need some adjusting (maybe just on docs) so it can consider the availability of BNS data before performing a replay.The text was updated successfully, but these errors were encountered: