Skip to content
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

[P2P][Bug] Fix expected disconnections after not-connectable block #2361

Merged

Conversation

random-zebra
Copy link

@random-zebra random-zebra commented May 4, 2021

Built on top of:

Fix a couple bugs discovered with feature_block.
Nodes not being disconnected after sending a block rejected during ConnectBlock, as the block source is not updated yet, and nodes not being disconnected after sending a block with invalid PoW (this only affects regtest chain).

@random-zebra random-zebra added this to the 6.0.0 milestone May 4, 2021
@random-zebra random-zebra self-assigned this May 4, 2021
@random-zebra random-zebra force-pushed the 202105_bug-connectblock_disconnectnode branch 4 times, most recently from fae68b5 to cfedd01 Compare May 11, 2021 13:16
This bug is visible in the numerous commented "expected_disconnect"
lines in feature_block.py.
When the validation state is sent via the BlockChecked signal, after
ConnectBlock failures in ConnectTip, the mapBlockSource is not updated
yet, so there is no node to disconnect.
@random-zebra random-zebra force-pushed the 202105_bug-connectblock_disconnectnode branch from cfedd01 to 2605f5b Compare May 17, 2021 10:43
@random-zebra
Copy link
Author

Rebased on master. Ready for review.

Copy link

@furszy furszy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice find 👌 , ACK 2605f5b

Copy link
Collaborator

@Fuzzbawls Fuzzbawls left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 2605f5b

@furszy furszy merged commit 32e99d8 into PIVX-Project:master May 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants