spesmilo / spesmilo/electrum

KeyError: "x/0'"

Open
#6,973 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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 "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/gui/qt/__init__.py", line 245, in wrapper
    return func(self, *args, **kwargs)
  File "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/gui/qt/__init__.py", line 269, in start_new_window
    wallet = self._start_wizard_to_select_or_create_wallet(path)
  File "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/gui/qt/__init__.py", line 314, in _start_wizard_to_select_or_create_wallet
    db = WalletDB(storage.read(), manual_upgrades=False)
  File "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/wallet_db.py", line 72, in __init__
    self.load_data(raw)
  File "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/wallet_db.py", line 105, in load_data
    self.upgrade()
  File "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/util.py", line 408, in <lambda>
    return lambda *args, **kw_args: do_profile(args, kw_args)
  File "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/util.py", line 404, in do_profile
    o = func(*args, **kw_args)
  File "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/wallet_db.py", line 161, in upgrade
    self._convert_wallet_type()
  File "/tmp/.mount_electryTFkXz/usr/lib/python3.7/site-packages/electrum/wallet_db.py", line 249, in _convert_wallet_type
    xpub = xpubs["x/0'"]

KeyError: "x/0'"

Reporter

This issue was reported by 1 user(s):

Electrum Version Python Version Operating System Wallet Type Locale Stack
4.0.9 3.7.9 (default, Jun 28 2018, 19:01:02) [GCC 5.4.0 20160609] Linux-5.4.0-62-generic-x86_64-with-debian-bullseye-sid standard,imported en_US

Additional Information

The reporting user(s) did not provide additional information.

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/wallet_db.py, following WalletDB.load_data(), upgrade(), and _convert_wallet_type() from the reported traceback. Reproduce the wallet upgrade path for the reported standard, imported wallet and determine why x/0' is absent. Done means the wallet upgrade no longer crashes with this KeyError.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
databases
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.