AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Informational 15 Bitcoin

pytests: fix flakes in grpc tests by waiting for the channel to be ready first

Public commit record

What the developer wrote

Authored by daywalker90

83/100 · Strong
pytests: fix flakes in grpc tests by waiting for the channel to be ready first

`test_grpc_custommsg_notification` was often failing with a timeout here:

```
def test_grpc_custommsg_notification(node_factory):
l1, l2 = node_factory.get_nodes(2)

# Test the connect notification
custommsg_stream = l1.grpc.SubscribeCustomMsg(clnpb.StreamCustomMsgRequest())
l2.connect(l1)

# Send the custom-msg to node l1
# The payload doesn't matter.
# It just needs to be valid hex which encodes to an odd BOLT-8 msg id
l2.rpc.sendcustommsg(l1.info["id"], "3131313174657374")

> for custommsg in custommsg_stream:
```

Changelog-None
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
The short version

What changed, and why it matters

This commit fixes flaky automated tests for the gRPC interface. It makes the test framework wait until the gRPC connection is fully ready before using it, preventing random timeouts. There is no security issue here—just a test reliability improvement.

Recommended action

No security action needed. Treat as a normal test-infrastructure fix.

Security signals we found

No strong security signals were identified.

Risk score

Why this scored 15/100

Our methodology →
Potential impact 0/30
Exploitability 0/25
Stealth signal 0/15
Affected reach 0/15
Confidence 10/10
Evidence quality 5/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.