diff --git a/electrum/lnwatcher.py b/electrum/lnwatcher.py index d6836521e..7927f650e 100644 --- a/electrum/lnwatcher.py +++ b/electrum/lnwatcher.py @@ -157,9 +157,6 @@ class LNWatcher(Logger, EventListener): chan = self.lnworker.channel_by_txo(funding_outpoint) if not chan: return False - if not chan.need_to_subscribe(): - return False - self.logger.info(f'sweep_commitment_transaction {funding_outpoint}') # detect who closed and get information about how to claim outputs is_local_ctx, sweep_info_dict = chan.get_ctx_sweep_info(closing_tx) # note: we need to keep watching *at least* until the closing tx is deeply mined, diff --git a/tests/regtest/regtest.sh b/tests/regtest/regtest.sh index af3dc8d78..718696a4b 100755 --- a/tests/regtest/regtest.sh +++ b/tests/regtest/regtest.sh @@ -344,6 +344,12 @@ if [[ $1 == "swapserver_forceclose" ]]; then wait_until_spent $ctx_id $output_index new_blocks 144 wait_for_balance bob 0.999 + # check that the closing tx is in alice's onchain_history. Since this tx does not + # touch alice's wallet addresses, this test requires accounting_addresses to be set + if [[ ! $($alice onchain_history| jq --arg txid $ctx_id '.[]|select(.txid == $txid)') ]]; then + echo "accounting_address not set" + exit 1 + fi fi