electrum
electrum copied to clipboard
wallet stop syncing
electrum runs perfectly for hours, then I don't know what happens (also using verbose logging) but it prints set up_to_date true then false and then stops receiving txs or setting true the up_to_date but it prints the "could connect {height}" 3hrs and wallet not up to date
2022-08-23T00:21:02.235438308Z I/w | wallet.Standard_Wallet.[default_wallet] | set_up_to_date: True
2022-08-23T00:21:29.774620846Z I | address_synchronizer.AddressSynchronizer | set_up_to_date: False
2022-08-23T00:21:29.785233502Z I/w | wallet.Standard_Wallet.[default_wallet] | set_up_to_date: False
2022-08-23T00:21:30.026298800Z I | synchronizer | receiving history 52416
2022-08-23T00:22:48.824088267Z I | synchronizer | received tx height: 0 bytes: 3568
2022-08-23T00:22:48.875686734Z I/n | network | fee_histogram [[13, 106031], [10, 109233], [7, 166782], [6, 108723], [5, 122304], [1, 280550], [0, 2020848]]
2022-08-23T00:22:49.123090303Z I | synchronizer | receiving history 52418
2022-08-23T00:22:49.177672714Z I | synchronizer | error: status mismatch: . we'll wait a bit for status update.
2022-08-23T00:22:49.335908570Z I | synchronizer | receiving history 52418
2022-08-23T00:24:17.590340758Z I | synchronizer | received tx height: 0 bytes: 490
2022-08-23T00:24:17.591143732Z I | synchronizer | received tx height: 0 bytes: 496
2022-08-23T00:24:17.638461921Z I/n | network | fee_histogram [[13, 124406], [11, 88552], [8, 122009], [6, 209051], [5, 127757], [2, 148794], [1, 152482], [0, 2029137]]
2022-08-23T00:24:17.912902373Z I | synchronizer | receiving history 52420
2022-08-23T00:24:17.957662530Z I | synchronizer | error: status mismatch: . we'll wait a bit for status update.
2022-08-23T00:24:18.099837968Z I | synchronizer | receiving history 52420
2022-08-23T00:25:30.870122141Z I | synchronizer | received tx height: 0 bytes: 1516
2022-08-23T00:25:30.871131805Z I | synchronizer | received tx height: 0 bytes: 832
2022-08-23T00:25:30.872025839Z I/i | interface.[] | could connect 750654
2022-08-23T00:25:30.951551381Z I/n | network | fee_histogram [[14, 103802], [11, 117218], [8, 127774], [6, 219053], [5, 134142], [3, 99008], [1, 209399], [0, 2035420]]
2022-08-23T00:25:30.951635912Z I/n | network | fee_estimates {25: 1013, 10: 2126, 5: 4981, 2: 11875}
2022-08-23T00:25:31.194185945Z I | synchronizer | receiving history 52421
2022-08-23T00:25:31.238958843Z I | synchronizer | error: status mismatch: . we'll wait a bit for status update.
2022-08-23T00:25:31.386038814Z I | synchronizer | receiving history 52421
2022-08-23T00:26:43.306903093Z I | verifier | requested merkle
2022-08-23T00:26:43.306930833Z I | verifier | requested merkle
2022-08-23T00:26:43.306963083Z I | verifier | requested merkle
2022-08-23T00:26:43.307014493Z I | verifier | requested merkle
2022-08-23T00:26:43.307670916Z I | verifier | requested merkle
2022-08-23T00:26:43.309936787Z I/i | interface.[] | could connect 750655
2022-08-23T00:26:43.329340073Z I | synchronizer | received tx height: 0 bytes: 1180
2022-08-23T00:26:43.362018788Z I/n | network | fee_histogram []
2022-08-23T00:26:43.362330249Z I | verifier | verified
2022-08-23T00:26:43.362915162Z I | verifier | verified
2022-08-23T00:26:43.363406824Z I | verifier | verified
2022-08-23T00:26:43.615878173Z I | synchronizer | receiving history 52421
2022-08-23T00:28:04.119999200Z I | verifier | requested merkle
2022-08-23T00:28:04.155293696Z I/n | network | fee_histogram [[5, 102476]]
2022-08-23T00:28:04.155467607Z I | verifier | verified
2022-08-23T00:28:04.430630029Z I | synchronizer | receiving history 52422
2022-08-23T00:29:18.999013143Z I | synchronizer | received tx height: 0 bytes: 838
2022-08-23T00:29:18.999552836Z I/n | network | fee_histogram [[6, 118236], [0, 114142]]
2022-08-23T00:30:19.067727502Z I/n | network | fee_histogram [[7, 121672], [3, 106462], [0, 133965]]
2022-08-23T00:31:19.153754929Z I/n | network | fee_histogram [[11, 104957], [6, 106755], [1, 147035], [0, 313675]]
2022-08-23T00:31:30.226118643Z I/i | interface.[] | could connect 750656
2022-08-23T00:32:19.036283285Z I/n | network | fee_estimates {25: 1000, 10: 1932, 5: 4981, 2: 11877}
2022-08-23T00:32:19.218533678Z I/n | network | fee_histogram []
2022-08-23T00:33:19.291081653Z I/n | network | fee_histogram [[0, 103011]]
2022-08-23T00:34:19.322310234Z I/n | network | fee_histogram [[5, 106406]]
2022-08-23T00:35:19.385572996Z I/n | network | fee_histogram [[6, 117660], [1, 142012]]
2022-08-23T00:36:19.441323312Z I/n | network | fee_histogram [[7, 115893], [4, 109701], [0, 115717]]
2022-08-23T00:37:19.493838380Z I/n | network | fee_histogram [[7, 139970], [5, 100256], [1, 125442]]
2022-08-23T00:38:19.578306448Z I/n | network | fee_histogram [[8, 117810], [5, 161541], [2, 56416], [0, 186866]]
2022-08-23T00:39:19.605387018Z I/n | network | fee_histogram [[10, 106140], [6, 133949], [4, 110456], [1, 150974]]
2022-08-23T00:40:19.610677509Z I/n | network | fee_histogram [[10, 115583], [7, 94985], [5, 136918], [1, 194374], [0, 83205]]
2022-08-23T00:41:19.696021897Z I/n | network | fee_histogram [[11, 113738], [7, 123230], [5, 143714], [1, 228314], [0, 148073]]
2022-08-23T00:42:19.731205591Z I/n | network | fee_histogram [[12, 107175], [8, 110901], [6, 135187], [4, 198154], [1, 210483], [0, 155397]]
2022-08-23T00:43:19.820213318Z I/n | network | fee_histogram [[13, 100656], [8, 130776], [6, 147406], [5, 92173], [2, 161289], [1, 172011], [0, 156088]]
2022-08-23T00:44:19.900318981Z I/n | network | fee_histogram [[13, 104534], [8, 137929], [6, 155245], [5, 96965], [3, 131529], [1, 212421], [0, 167359]]
2022-08-23T00:44:54.253139845Z I/i | interface.[] | could connect 750657
2022-08-23T00:45:19.162888089Z I/n | network | fee_estimates {25: 1000, 10: 1932, 5: 4981, 2: 11881}
2022-08-23T00:45:19.982552703Z I/n | network | fee_histogram [[14, 100161], [9, 110808], [7, 128202], [5, 169226], [4, 108314], [1, 240644], [0, 167359]]
2022-08-23T00:46:20.038939783Z I/n | network | fee_histogram []
2022-08-23T00:47:20.072036851Z I/n | network | fee_histogram [[1, 118034]]
2022-08-23T00:48:20.148107575Z I/n | network | fee_histogram [[5, 108742]]
2022-08-23T00:49:20.227401514Z I/n | network | fee_histogram [[7, 104245], [1, 129880]]
2022-08-23T00:50:20.292165523Z I/n | network | fee_histogram [[7, 124381], [3, 87790], [0, 126737]]
2022-08-23T00:51:20.386309286Z I/n | network | fee_histogram [[8, 113752], [5, 119658], [1, 144068]]
2022-08-23T00:52:20.472134998Z I/n | network | fee_histogram [[8, 124778], [5, 133493], [2, 87836], [0, 149928]]
2022-08-23T00:53:20.519152545Z I/n | network | fee_histogram [[9, 106990], [6, 116497], [3, 109092], [0, 226616]]
2022-08-23T00:54:20.595017824Z I/n | network | fee_histogram [[10, 105175], [6, 141898], [4, 89510], [1, 152345]]
2022-08-23T00:55:20.680124329Z I/n | network | fee_histogram [[11, 103572], [7, 115011], [5, 116942], [1, 186406], [0, 112863]]
2022-08-23T00:56:20.752787608Z I/n | network | fee_histogram [[11, 113655], [7, 122919], [5, 125754], [2, 106164], [0, 204563]]
2022-08-23T00:57:20.834123653Z I/n | network | fee_histogram [[11, 122525], [7, 132289], [5, 133407], [2, 113729], [1, 140037], [0, 131228]]
2022-08-23T00:58:20.892579545Z I/n | network | fee_histogram [[11, 129030], [7, 141576], [5, 139639], [3, 64709], [1, 208132], [0, 137797]]
2022-08-23T00:59:20.978412329Z I/n | network | fee_histogram [[11, 137984], [8, 75751], [6, 140044], [4, 113215], [1, 252305], [0, 145470]]
2022-08-23T01:00:20.992382848Z I/n | network | fee_histogram [[11, 147153], [8, 83663], [6, 147022], [5, 87074], [1, 294199], [0, 148665]]
2022-08-23T01:01:21.089697920Z I/n | network | fee_histogram [[12, 100001], [8, 150563], [7, 84305], [5, 163931], [2, 140890], [1, 169737], [0, 151054]]
2022-08-23T01:02:21.112280965Z I/n | network | fee_histogram [[12, 106910], [9, 103175], [7, 147037], [5, 168588], [3, 99146], [1, 259351], [0, 330810]]
2022-08-23T01:03:21.182769503Z I/n | network | fee_histogram [[12, 112180], [9, 107557], [7, 150637], [5, 173882], [3, 103158], [1, 277093], [0, 342048]]
2022-08-23T01:04:12.891367755Z I/i | interface.[] | could connect 750658
2022-08-23T01:04:19.346610097Z I/n | network | fee_estimates {25: 1000, 10: 1933, 5: 4981, 2: 11886}
Could you test with this patch? Please post new logs after you manage to reproduce.
diff --git a/electrum/synchronizer.py b/electrum/synchronizer.py
index 1e8ee4f69f..4979abf3c3 100644
--- a/electrum/synchronizer.py
+++ b/electrum/synchronizer.py
@@ -247,11 +247,20 @@ class Synchronizer(SynchronizerBase):
for addr in random_shuffled_copy(self.adb.get_addresses()):
await self._add_address(addr)
# main loop
+ import time
+ log_ts = time.time()
while True:
await asyncio.sleep(0.1)
hist_done = self.is_up_to_date()
spv_done = self.adb.verifier.is_up_to_date() if self.adb.verifier else True
up_to_date = hist_done and spv_done
+ if time.time() > log_ts + 10:
+ log_ts = time.time()
+ self.logger.debug(f"{hist_done=!r}, {spv_done=!r}, {self.adb.is_up_to_date()=}")
+ if not hist_done:
+ self.logger.debug(f"{len(self.requested_addrs)=!r}, {len(self.requested_tx)=!r}, {len(self.requested_histories)=!r}, {len(self._stale_histories)=!r}")
+ if not spv_done:
+ self.logger.debug(f"{len(self.adb.verifier.requested_merkle)=!r}, {len(self.adb.unverified_tx)=!r}")
# see if status changed
if (up_to_date != self.adb.is_up_to_date()
or up_to_date and self._processed_some_notifications):