Skip to content

DOC: pandas.Index.astype says it raises ValueError instead of TypeError #37012

Closed
@coelhudo

Description

@coelhudo

Location of the documentation

The documentation is located at https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.Index.astype.html

Documentation problem

The documentation says " When conversion is impossible, a ValueError exception is raised." However, checking the code it can be seen that a TypeError is raised instead of ValueError.

Suggested fix for documentation

Just change ValueError to TypeError in the docstring.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions