-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Websocket: newBlockHeaders misses several blocks #9865
Comments
Probably related to the other issue you reported (#9858) |
This is an important issue, I believe many companies rely on this. It's also a major differentiator if it works in Parity, also Geth is unreliable. |
@joshua-mir why is it expected behavior? |
@joshua-mir : Yes both are related, we were trying to get a reliable stream of canonical blocks. |
@jpzk sorry, you're right about this issue being a bug. The other one is "expected behavior" as newBlockFilter returns new blocks, not reorgs of known blocks. (it won't return past blocks that are now canonical, as you may have noticed.) |
@joshua-mir to clarify the past issue is also not "expected behavior", ~1 out of 50 blocks |
Isn't that more important than "Sometime soon"? |
This is actually a really important issue for a lot of people. In fact, there are open source projects such as:
that have sprung up solely to mitigate this type of behavior from the node clients. |
The labels are purely cosmetic, milestones are more important. Importance is mostly decided by activity in reality because more active issues are constantly pinging our inboxes 😅 It is mostly up to devs familiar with the parts of the codebase affected to decide their own priorities and pick up issues themselves. |
Any updates on this one? |
Not yet assigned, @joshua-mir do you by chance know who worked on that component? |
@ankitchiplunkar Please provide parity logs from when it happens. The subscription doesn't return blocks in case the node goes into "syncing" mode (which usually indicates peering / performance issue). |
hi @tomusdrw Missing block = 6646730Output from websocket subscription
Corresponding Parity logs
Missing block = 6646738Output of websocker subscription
Corresponding Parity logs
|
@ankitchiplunkar Thank you! It seems that we don't trigger a notification if we already have another block queued up for verification. @mattrutherford is investigating the issue and will provide a fix when ready. |
Correct - I'm just testing a fix for 9858 - hopefully that will solve some problems; this one will follow... |
Thanks for fixing. We appreciate at it a lot! 👍 |
Thanks. Parity <3 |
Before filing a new issue, please provide the following information.
Expected behaviour
The websocket when subscribed using
newBlockHeaders
should return the forked blocks and also the canonical blocks.Actual behaviour
The websocket when subscribed using
newBlockHeaders
does not return the canonical blocks (for almost every ~50 blocks)Steps to reproduce the behaviour
I have a local parity node, am using web3.js for subscribing to
newBlockHeaders
, below is the code to get new blocks.The subscription service regularly misses blocks, in the example below we get the blocks
6630351
and6630353
but not the block in between6630352
.This has been documented before: web3/web3.js#1375
Is there a reliable method to get stream of new blockheaders?
The text was updated successfully, but these errors were encountered: