Skip to content

Confused with jwt.decode return type #392

@Hanaasagi

Description

@Hanaasagi

I am using mypy to check my code. And I find that the annotation of jwt.decode's return value is Mapping[str, Any]. It's immutable, so if i change it, mypy will complain Unsupported target for indexed assignment. I think the type should be Dict[str, Any] or MutableMapping[str, Any]. Are there someone give a official solution?

More detail, please see python/typeshed#2764

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions