Skip to content

Stores should raise LookupError instead of KeyError #68

@thorwhalen

Description

@thorwhalen

LookupError is the mother of both KeyError and IndexError, which is used by some containers.

"Index" seems to refer to an incremental integer key.

In py2store containers though, keys are meant have (unless otherwise specified) a looser semantic. They can actually be anything (even a non-hashable) that references some content.

Therefore, it may be better, at least at the base(r) levels that we use LookupError instead of what is used now: KeyError.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions