Skip to content

fix: blocks may not be in the blockstore yet #215

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

Closed
wants to merge 1 commit into from

Conversation

achingbrain
Copy link
Member

Because some blockstore implementations batch up write before committing them to disk or wherever, they may not be available when we think they should be.

I noticed this module throwing unhandledPromiseRejections around this so the change here handles missing blocks by putting the task back into the queue to process later, with a fairly arbitrary 5x limit on processing a given task.

Because some blockstore implementations batch up write before committing
them to disk or wherever, they may not be available when we think
they should be.

I noticed this module throwing unhandledPromiseRejections around this
so the change here handles missing blocks by putting the task back
into the queue to process later, with a fairly arbitrary 5x limit on
processing a given task.
@achingbrain achingbrain force-pushed the fix/unhandled-promise-rejection branch from 98d6514 to d77adf8 Compare March 4, 2020 20:27
@dirkmc
Copy link
Contributor

dirkmc commented Mar 5, 2020

The way this works has changed with #211, which is close to being merged. My preference would be to concentrate on getting that PR merged and then tackle this issue.

@achingbrain
Copy link
Member Author

I think the code can still cause UnhandledPromiseRejections but the implementation has changed. I will address it in a subsequent PR.

@achingbrain achingbrain deleted the fix/unhandled-promise-rejection branch May 27, 2020 15:19
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.

3 participants