Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Combines two to simplify block lookup code:
1. Remove child_components, cache them inside the existing request
State
enumAdd a new intermediary state where a single block request state can be paused if its parent is unknown, and resumed once the parent is processed.
2. Re-use single lookups to do parent requests
Parent lookups are cached separately to bound:
We can iterate the existing single block lookups and enforce those conditions
Point 1. unlocks this simplification, adding some more logic in the known parent path to:
We lose a slight optimization of processing the pending chain of unknown parent blocks as a batch, but this shouldn't make a big different IMO, but please tell me otherwise.
The simplification is quite big, preview this over to @realbigsean who really dig with it.
Next steps
Action
enum?