Skip to content

CI flake check-doc-examples (listchannels disabled/enabled race) #9327

Description

@ksedgwic

The Update examples in doc schemas job fails intermittently: regenerating the examples flips one direction of the l3-l4 channel (132x1x0) in doc/schemas/listchannels.json between disabled and enabled:

             "message_flags": 1,
-            "channel_flags": 3,
-            "active": false,
-            "last_update": 1738000002,
+            "channel_flags": 1,
+            "active": true,
+            "last_update": 1738000001,

Two occurrences today on unrelated PRs, with byte-identical diffs (aa81c794..d7ed1e9b):

Root cause: tests/autogenerate-rpc-examples.py generates the recoverchannel example by stopping l4, deleting its database, and restarting it. From l3's point of view the peer is gone, and l3 eventually broadcasts a disabled channel_update for its side of the channel - but that disable is lazy (channel_gossip.c only emits it via an error reply or the refresh timer). The committed example captured the post-disable state, so whether the disable lands in l3's gossip store before the listchannels snapshot later in the script is a race.

Proposed fix: wait for l3's own direction of the l3-l4 channel to show active: false before taking the listchannels snapshot, matching the existing wait_for pattern the script already uses for the post-close listchannels race.

Part of #9222.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions