Skip to content

TYP: ensure_platform_int probably needs a dtype annotation #43391

Closed
@twoertwein

Description

@twoertwein

ensure_platform_int is annotated as returning a np.ndarray but its output is used in places that require a Sequence[int]. I assume this can be fixed by adding a dtype to the np.ndarray.

pandas/core/groupby/ops.py:858: error: Argument 1 to "take" of "ExtensionArray" has incompatible type "ndarray[Any, Any]"; expected "Sequence[int]" [arg-type]

Metadata

Metadata

Assignees

No one assigned

    Labels

    Typingtype annotations, mypy/pyright type checking

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions