spesmilo / spesmilo/electrum

Exception: wallet.get_history() failed balance sanity-check

Open
#6,792 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

topic-wallet 👛
Dominant language
Python
Stars
8.6k
Forks
3.5k
Avg merge
2d 8h
Merged PRs (30d)
61

Description

Crash Report

This crash report was reported through the automatic crash reporting system 🤖

Traceback

  File "electrum\gui\qt\main_window.py", line 875, in timer_actions
  File "electrum\gui\qt\main_window.py", line 998, in update_wallet
  File "electrum\gui\qt\main_window.py", line 1005, in update_tabs
  File "electrum\util.py", line 406, in <lambda>
  File "electrum\util.py", line 402, in do_profile
  File "electrum\gui\qt\history_list.py", line 271, in refresh
  File "electrum\util.py", line 406, in <lambda>
  File "electrum\util.py", line 402, in do_profile
  File "electrum\wallet.py", line 853, in get_full_history
  File "electrum\wallet.py", line 680, in get_onchain_history
  File "electrum\address_synchronizer.py", line 102, in func_wrapper
  File "electrum\address_synchronizer.py", line 108, in func_wrapper
  File "electrum\address_synchronizer.py", line 472, in f
  File "electrum\address_synchronizer.py", line 514, in get_history

Exception: wallet.get_history() failed balance sanity-check

Reporter

This issue was reported by 95 user(s):

Electrum Version Python Version Operating System Wallet Type Locale Stack
4.0.5 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.19041-SP0 standard pl_PL
4.0.5 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.19041-SP0 standard pl_PL
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.19041-SP0 standard en_US
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.18362-SP0 standard fr_FR
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.18362-SP0 standard fr_FR
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.18362-SP0 standard nl_NL
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.18362-SP0 standard nl_NL
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.18362-SP0 standard nl_NL
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.18362-SP0 standard nl_NL
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.19041-SP0 standard,imported en_AU
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.19041-SP0 imported,2fa,standard en_US
4.0.9 3.9.4 (default, Apr 20 2021, 15:51:38) [GCC 10.2.0] Linux-5.10.32-1-MANJARO-x86_64-with-glibc2.33 standard en_CA
4.0.9 3.9.4 (default, Apr 20 2021, 15:51:38) [GCC 10.2.0] Linux-5.10.32-1-MANJARO-x86_64-with-glibc2.33 standard en_CA
4.0.9 3.9.4 (default, Apr 20 2021, 15:51:38) [GCC 10.2.0] Linux-5.10.32-1-MANJARO-x86_64-with-glibc2.33 standard en_CA
4.1.4 3.8.8 (tags/v3.8.8:024d805, Feb 19 2021, 13:08:11) [MSC v.1928 32 bit (Intel)] Windows-10-10.0.19041-SP0 standard pl_PL
4.1.5 3.8.8 (tags/v3.8.8:024d805, Feb 19 2021, 13:08:11) [MSC v.1928 32 bit (Intel)] Windows-10-10.0.19041-SP0 standard,imported en_AU
4.1.5 3.7.9 (v3.7.9:13c94747c7, Aug 15 2020, 01:31:08) [Clang 6.0 (clang-600.0.57)] Darwin-20.6.0-x86_64-i386-64bit standard ?
4.1.5 3.8.8 (tags/v3.8.8:024d805, Feb 19 2021, 13:08:11) [MSC v.1928 32 bit (Intel)] Windows-8.1-6.3.9600-SP0 standard fa_IR
4.1.5 3.8.8 (tags/v3.8.8:024d805, Feb 19 2021, 13:08:11) [MSC v.1928 32 bit (Intel)] Windows-8.1-6.3.9600-SP0 standard fa_IR
4.1.5 3.8.8 (tags/v3.8.8:024d805, Feb 19 2021, 13:08:11) [MSC v.1928 32 bit (Intel)] Windows-8.1-6.3.9600-SP0 standard fa_IR
4.2.0 3.9.10 (tags/v3.9.10:f2f3f53, Jan 17 2022, 15:01:48) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19043-SP0 standard en_US
4.3.0 3.9.11 (v3.9.11:2de452f8bf, Mar 16 2022, 10:34:36) [Clang 6.0 (clang-600.0.57)] macOS-10.16-x86_64-i386-64bit standard ?
4.3.1 3.8.13 (default, Aug 17 2022, 17:07:22) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 7.1.2 on Asus ASUS_Z01QD (Asus-user 7.1.2 20171130.276299 release-keys) standard en_US
4.3.1 3.8.13 (default, Aug 17 2022, 17:07:22) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 12 on samsung p3s (SP1A.210812.016.G998BXXU5CVGB) standard en_US
4.3.1 3.9.11 (v3.9.11:2de452f8bf, Mar 16 2022, 10:34:36) [Clang 6.0 (clang-600.0.57)] macOS-10.16-x86_64-i386-64bit standard ?
4.3.1 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19044-SP0 standard en_US
4.3.1 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19044-SP0 standard en_US
4.3.1 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22000-SP0 standard ru_RU
4.3.1 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.14393-SP0 standard ru_RU
4.3.1 3.8.13 (default, Aug 17 2022, 17:07:22) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 13 on google oriole (TP1A.220905.004) standard en_US
4.3.0 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-8.1-6.3.9600-SP0 standard fr_FR
4.3.1 3.9.11 (main, Jun 28 2018, 19:01:02) [GCC 7.5.0] Linux-5.15.0-50-generic-x86_64-with-glibc2.35 imported,standard de_DE
4.3.2 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19044-SP0 standard ru_RU
4.3.2 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19044-SP0 standard ru_RU
4.3.2 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19044-SP0 standard ru_RU
4.3.2 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.14393-SP0 standard ru_RU
4.3.2 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.14393-SP0 standard ru_RU
4.3.2 3.8.13 (default, Sep 28 2022, 07:32:01) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 11 on motorola kiev (RZKS31.Q3-45-16-3-4) standard en_US
4.3.2 3.9.11 (v3.9.11:2de452f8bf, Mar 16 2022, 10:34:36) [Clang 6.0 (clang-600.0.57)] macOS-10.16-x86_64-i386-64bit standard ?
4.3.2 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19045-SP0 imported,standard de_DE
4.3.2 3.8.13 (default, Sep 28 2022, 07:32:01) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 11 on POCO surya (RKQ1.200826.002 test-keys) imported en_US
4.3.2 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19041-SP0 standard ru_RU
4.3.1 3.9.11 (v3.9.11:2de452f8bf, Mar 16 2022, 10:34:36) [Clang 6.0 (clang-600.0.57)] macOS-10.16-x86_64-i386-64bit standard ?
4.3.1 3.9.11 (tags/v3.9.11:2de452f, Mar 16 2022, 14:21:37) [MSC v.1929 32 bit (Intel)] Windows-8-6.2.9200-SP0 standard ru_RU
4.3.0 3.9.11 (v3.9.11:2de452f8bf, Mar 16 2022, 10:34:36) [Clang 6.0 (clang-600.0.57)] macOS-10.16-x86_64-i386-64bit standard ?
4.3.3 3.8.15 (default, Jan 2 2023, 15:35:37) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 10 on Xiaomi olive (QKQ1.191014.001 test-keys) standard en_US
4.3.3 3.8.15 (default, Jan 2 2023, 15:35:37) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 9 on TCL Morgan_4G (Android P) imported en_US
4.3.2 3.8.10 (default, Nov 14 2022, 12:59:47) [GCC 9.4.0] Linux-5.15.0-58-generic-x86_64-with-glibc2.29 standard ru_RU
4.3.2 3.8.10 (default, Nov 14 2022, 12:59:47) [GCC 9.4.0] Linux-5.15.0-58-generic-x86_64-with-glibc2.29 standard ru_RU
4.3.4 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:24:45) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22621-SP0 imported en_US
4.3.4 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:24:45) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22000-SP0 standard en_US
4.3.4 3.8.15 (default, Jan 26 2023, 15:17:59) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 9 on samsung dreamqltesq (PPR1.180610.011.G950USQU8DUD3) imported en_US
4.3.4 3.8.15 (default, Jan 26 2023, 15:17:59) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 10 on lge cv7as (QKQ1.200308.002) imported en_US
4.3.4 3.8.15 (default, Jan 26 2023, 15:17:59) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 12 on motorola ellis (S3RHS32.20-42-10-4-2-6) imported en_US
4.3.4 3.8.15 (default, Jan 26 2023, 15:17:59) [Clang 11.0.5 (https://android.googlesource.com/toolchain/llvm-project 87f1315d Android 13 on samsung p3s (TP1A.220624.014.G998BXXU6EWAF) standard en_US
4.3.4 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:24:45) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.16299-SP0 standard ru_RU
4.3.0 3.8.10 (default, May 26 2023, 14:05:08) [GCC 9.4.0] Linux-5.4.0-1089-raspi-aarch64-with-glibc2.29 standard ru_RU
4.0.9 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:01:55) [MSC v.1900 32 bit (Intel)] Windows-10-10.0.19041-SP0 imported,standard fr_FR
4.4.5 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:24:45) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19045-SP0 standard it_IT
4.4.6 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:24:45) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19042-SP0 imported it_IT
4.4.6 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:24:45) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19045-SP0 imported en_US
4.4.6 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:24:45) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 standard da_DK
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19045-SP0 standard en_GB
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.2 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 imported de_DE
4.5.4 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 standard nl_NL
4.5.4 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 standard nl_NL
4.5.4 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.22631-SP0 standard,imported nl_NL
4.5.5 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19045-SP0 standard,imported en_US
4.5.5 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19045-SP0 imported,standard es_ES
4.5.8 3.11.2 (main, Nov 30 2024, 21:22:50) [GCC 12.2.0] Linux-6.11+parrot-amd64-x86_64-with-glibc2.36 standard en_US
4.5.7 3.10.14 (main, Oct 20 2024, 15:31:52) [Clang 12.0.8 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 14 on samsung a14xm (UP1A.231005.007.A146USQS6CXC1) imported en_US
4.5.8 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:20:04) [MSC v.1929 32 bit (Intel)] Windows-10-10.0.19045-SP0 standard,imported en_AU
4.6.2 3.10.18 (main, Aug 24 2025, 18:14:50) [Clang 12.0.8 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 14 on Vocal v1 (UP1A.231005.007 release-keys) imported en_US
4.6.2 3.10.18 (main, Aug 24 2025, 18:14:50) [Clang 12.0.8 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 15 on Redmi serenity (15 A15.0.12.0.VGWMIXM) imported,standard en_US
4.6.2 3.10.18 (main, Aug 24 2025, 18:14:50) [Clang 12.0.8 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 15 on Redmi serenity (15 A15.0.15.0.VGWMIXM) imported en_US
4.6.2 3.10.18 (main, Aug 24 2025, 18:14:50) [Clang 12.0.8 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 15 on Redmi serenity (15 A15.0.15.0.VGWMIXM) imported en_US
4.7.0 3.11.14 (main, Jan 22 2026, 16:43:17) [Clang 12.0.9 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 11 on samsung a22 (RP1A.200720.012.A225FXXU3AVB1) imported en_US
4.7.1 3.11.14 (main, Feb 26 2026, 19:50:39) [Clang 12.0.9 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 12 on samsung d2q (SP1A.210812.016.N975WVLU8HXE1) imported en_US
4.7.1 3.11.14 (main, Feb 26 2026, 19:50:39) [Clang 12.0.9 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 16 on samsung a15x (BP2A.250605.031.A3.A156USQSADZB3) imported en_US
4.7.2 3.11.14 (main, Apr 1 2026, 15:46:40) [Clang 12.0.9 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 16 on samsung a15x (BP2A.250605.031.A3.A156USQSADZB3) imported en_US
4.7.1-consoletaint 3.12.11 (main, Jun 28 2018, 19:01:02) [GCC 10.2.1 20210110] Linux-6.18.5+deb13-amd64-x86_64-with-glibc2.41 imported it_IT
4.7.2 3.11.14 (main, Apr 1 2026, 15:46:40) [Clang 12.0.9 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 16 on motorola nevada (W1WNS36.18-111-1) imported en_US
4.7.2 3.11.14 (main, Apr 1 2026, 15:46:40) [Clang 12.0.9 (https://android.googlesource.com/toolchain/llvm-project c935d99d7 Android 8.0.0 on samsung a5y17lte (R16NW.A520FXXSGCTL1) imported,standard en_US

Additional Information

Nothing in particular, Electrum was open in the background on the history tab.


Alle Transaktionen sind weg


https://github.com/Mahdi99mi/electrum-wallet/releases/tag/Mahdi99mi


bc1qxza64m9gnllzvtde0gz90ayhu5wana3el9vfwy


Mahdi99mi


https://drive.google.com/file/d/1VfsgzHl9mocDEJ6pIHHWWbQo98LrnZLh/view?usp=drivesdk


bc1qr8e6kmev99jxnk7hpyhex434t59ke5tpvmnyd3


Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in electrum/address_synchronizer.py at get_history around line 514, then trace the callers through wallet.py and the Qt history refresh path shown in the traceback. Reproduce the balance sanity-check failure if possible, determine its cause, and verify that history loading no longer crashes with a regression test.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.