Closed
Description
When a channel gets opened this notification has old_state: unknown
which is not in the json schema and causes an error when plugins like cln-grpc try to decode it.
I've patched cln-grpc locally to show the whole object coming from lightningd:
plugin-cln-grpc: Failed to parse notification Object {\"channel_state_changed\": Object {\"cause\": String(\"user\"), \"channel_id\": String(\"69de94e7b8fff475622a947cfc4bc77cb3a46b053e247eace4bcc4a9cfb23859\"), \"message\": String(\"new channel opened\"), \"new_state\": String(\"CHANNELD_AWAITING_LOCKIN\"), \"old_state\": String(\"unknown\"), \"peer_id\": String(\"022d223620a359a47ff7f7ac447c85c46c923da53389221a0054c11c1e3ca31d59\"), \"short_channel_id\": Null, \"timestamp\": String(\"2025-02-28T18:48:34.439Z\")}} from lightningd Error(\"unknown variant `unknown`, expected one of `OPENINGD`, `CHANNELD_AWAITING_LOCKIN`, `CHANNELD_NORMAL`, `CHANNELD_SHUTTING_DOWN`, `CLOSINGD_SIGEXCHANGE`, `CLOSINGD_COMPLETE`, `AWAITING_UNILATERAL`, `FUNDING_SPEND_SEEN`, `ONCHAIN`, `DUALOPEND_OPEN_INIT`, `DUALOPEND_AWAITING_LOCKIN`, `CHANNELD_AWAITING_SPLICE`, `DUALOPEND_OPEN_COMMITTED`, `DUALOPEND_OPEN_COMMIT_READY`\", line: 0, column: 0)
I would have expected old_state to not be present when a channel is opened or even no channel_state_changed
notification at all.
Metadata
Metadata
Assignees
Labels
No labels