The Lightning Development Kit (LDK), a library used to build Bitcoin Lightning software, merged a fix on Nov. 23 for a crash‑recovery bug that could affect routing nodes.
Bug description
The issue occurs when a routing node forwards a payment on one channel while awaiting funds on another. If the node crashes before its asynchronous channel‑recovery data is fully written, it may restart without the information needed to claim the incoming funds. Loss is possible when the node has already paid the outgoing side and the on‑chain claim for the incoming side fails to confirm before its deadline.
Technical details of the fix
LDK previously treated a recovery update as saved while the underlying write was still in progress. The new patch keeps the update pending until the write completes, storing it in a channel monitor that can be used to recover funds after a channel closes. The change also updates the contract for custom storage integrations, requiring them to report when full channel‑monitor writes finish.
Checking for the fix
The fix was merged via pull request #5663 on LDK’s main branch. As of Nov. 29, no tagged release explicitly includes the change. Operators can verify their build by inspecting the Cargo lockfile for the exact library version or Git revision, or by consulting release notes from their distribution. Developers who compile their own software should confirm that the selected dependency includes #5663.
Related tools
A separate Core Lightning recovery tool handles pending payments when channel data has already been lost.


