-
Notifications
You must be signed in to change notification settings - Fork 49
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
A0-3032: Handle own blocks in sync #1426
Conversation
10f00e7
to
f590a10
Compare
f590a10
to
3440fce
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I approve not to block, but I would need more context to understand better how Aura interacts with this code. I'd be grateful for a short explanation or some reference.
I understand that we have a wrapper for block_import
which is adjusted for Aura. I get that check_block
is aligned with inner.check_block
, but import_block
doesn't check_block
which I perceive as some simplification which Aura won't break.
Tho I don't get why it doesn't break with Aura, and why we need this wrapper in the first place. Was there an issue that Aura sometimes didn't work with the original block_import
?
The issue this is dealing with is passing the blocks Aura produces through sync, so that they can be broadcast. The wrapper intercepts created blocks and first passes them through our sync, which only afterwards forwards them to the proper import queue. Aura only makes very limited use of the results returned by the import queue we give it (as I outlined in one of the responses above), so intercepting the newly created blocks this way cannot impact its logic. I haven't checked whether |
f7c7a90
Description
Blocks created by us should go through sync and get broadcast as soon as we create them.
Type of change
Checklist:
(I might need to add tests, but I wanted to have this mostly done before my days off.)