Skip to content
This repository was archived by the owner on Jul 12, 2021. It is now read-only.
This repository was archived by the owner on Jul 12, 2021. It is now read-only.

Node.delete_key() , IndexError: list index out of range #183

@kaykurokawa

Description

@kaykurokawa

I ran into this problem while running a heavily modified electrum server for an altcoin. The problem occurred during a block reorg. I believe unmodified electrum-server also have the same issue, but I might not be understanding the problem fully. Sorry if this is the case.

On line https://github.com/spesmilo/electrum-server/blob/master/src/storage.py#L539 ,
it tries to access the grandparent of the node to delete, but there is no check to see if there is a grandparent(it might be a node under the root ). An IndexError exception will then be thrown.

Seems like there needs to be an if statement to check for a grandparent that wraps around line 539 to line 554?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions