Repository navigation
test: Wait until is_connected in add_p2p_connection - #19657
Merged
Merged
Conversation
Member
Author
maflcko
force-pushed
the
2008-testWaitConn
branch
from
August 4, 2020 14:13
fa9c81c to
fa4dfd2
Compare
theStack
approved these changes
Aug 6, 2020
theStack
left a comment
Contributor
There was a problem hiding this comment.
ACK fa4dfd2 ☕
Code-reviewed, checked that all now redundant wait-for-connection constructs (wait_until(... .is_connected, ...)) after add_p2p_connection(...) in other tests were tackled and ran the functional tests locally.
jnewbery
reviewed
Aug 6, 2020
jnewbery
left a comment
Contributor
There was a problem hiding this comment.
Concept ACK. One question inline
|
|
||
| # Node that never sends a version. We'll use this to send a bunch of messages | ||
| # anyway, and eventually get disconnected. | ||
| class CNodeNoVersionMisbehavior(CLazyNode): |
Contributor
There was a problem hiding this comment.
Any reason not to remove this class entirely?
Contributor
|
Code review ACK fa4dfd2 We should consider removing |
fanquake
added a commit
that referenced
this pull request
Aug 20, 2020
ed5cd12 test: Distinguish between nodes(bitcoind) and peers(mininodes) in p2p_leak.py (Dhruv Mehta) f6f082b test: remove `CNodeNoVersionIdle` from p2p_leak.py (Dhruv Mehta) 45cf55c test: remove `CNodeNoVersionMisbehavior` from p2p_leak.py (Dhruv Mehta) Pull request description: - Removes `CNodeNoVersionMisbehavior` per recommendation at #19657 (comment) - Removes `CNodeNoVersionIdle` because it is similarly unnecessary - As someone new to the codebase, I found it easier to understand it if `no_version_disconnect_node` tries to overwhelm the peer with any message that is not version/verack. - Per recommendation at #19727 (review), made a clear distinction between nodes(bitcoind) and peers(mininode interface implementations) ACKs for top commit: jnewbery: tested ACK ed5cd12 amitiuttarwar: utACK ed5cd12 Tree-SHA512: 310a24c91fd837e7f65177edb55fe6142fb3559fae7867c5cdd9c9a23b1a02202b935ca9a82633fa7649f3de2fa221f6da906a7b5e499fc20f7254085033757d
Fabcien
pushed a commit
to Bitcoin-ABC/bitcoin-abc
that referenced
this pull request
Sep 7, 2021
Summary: The discouragement threshold is modified to account for the change in D6036, which caused a peer to be banned after only 10 out-of-order messages instead of 100. Using the wrong value in this test could potentially cause the node to be banned before all messages are sent, and cause the next `self.send_message(msg_verack())` to break the test, because this method fails when trying to send a message if the connection is closed. I observed this failure while trying [[bitcoin/bitcoin#19657 | core#19657]] (D10063), in which the message is sent a bit later in the test and the node bans the p2p connection faster. Test Plan: `test/functional/test_runner.py p2p_leak` Reviewers: #bitcoin_abc, majcosta Reviewed By: #bitcoin_abc, majcosta Subscribers: majcosta Differential Revision: https://reviews.bitcoinabc.org/D10064
Fabcien
pushed a commit
to Bitcoin-ABC/bitcoin-abc
that referenced
this pull request
Sep 7, 2021
Summary: Moving the wait_until from the individual test scripts to the test framework simplifies two tests This is a backport of [[bitcoin/bitcoin#19657 | core#19657]] Depends on D10064 Test Plan: `ninja check-functional-extended` Reviewers: #bitcoin_abc, majcosta Reviewed By: #bitcoin_abc, majcosta Differential Revision: https://reviews.bitcoinabc.org/D10063
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Moving the wait_until from the individual test scripts to the test framework simplifies two tests