From ce96d1f97b5e27c95c9c59e6f406efa2a55f799c Mon Sep 17 00:00:00 2001 From: ThomasV Date: Sun, 29 May 2022 12:37:33 +0200 Subject: [PATCH] lnworker: create_routes_for_payment: try random order without this, we keep retrying with the same trampoline when payment fails --- electrum/lnworker.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/electrum/lnworker.py b/electrum/lnworker.py index be5ecad2a..b550886c5 100644 --- a/electrum/lnworker.py +++ b/electrum/lnworker.py @@ -1532,6 +1532,8 @@ class LNWallet(LNWorker): my_active_channels = [ chan for chan in self.channels.values() if chan.is_active() and not chan.is_frozen_for_sending()] + # try random order + random.shuffle(my_active_channels) try: self.logger.info("trying single-part payment") # try to send over a single channel