From 9ac8fbaccb4fa49e16dd31c3d80b370cfbbc6d5c Mon Sep 17 00:00:00 2001 From: Pierre-Marie Padiou Date: Fri, 8 Dec 2023 18:37:27 +0100 Subject: [PATCH] Unlock utxos when peer is unavailable for splice (#564) If the peer is offline when the swap-in job requests a splice-in, the request will be ignored, but we weren't unlocking UTXOs, preventing any further attempt. --- src/commonMain/kotlin/fr/acinq/lightning/io/Peer.kt | 1 + 1 file changed, 1 insertion(+) diff --git a/src/commonMain/kotlin/fr/acinq/lightning/io/Peer.kt b/src/commonMain/kotlin/fr/acinq/lightning/io/Peer.kt index 3f500b1de..ae2bf0590 100644 --- a/src/commonMain/kotlin/fr/acinq/lightning/io/Peer.kt +++ b/src/commonMain/kotlin/fr/acinq/lightning/io/Peer.kt @@ -1076,6 +1076,7 @@ class Peer( } else { // There are existing channels but not immediately usable (e.g. creating, disconnected), we don't do anything yet logger.info { "ignoring channel request, existing channels are not ready for splice-in: ${channels.values.map { it::class.simpleName }}" } + swapInCommands.trySend(SwapInCommand.UnlockWalletInputs(cmd.walletInputs.map { it.outPoint }.toSet())) } } }