Skip to content
This repository was archived by the owner on Oct 29, 2024. It is now read-only.
This repository was archived by the owner on Oct 29, 2024. It is now read-only.

Pandas 0.23.4 TypeError: Already tz-aware #671

Closed
@fl4p-old

Description

@fl4p-old

The UTC tz localization raises a TypeError: Already tz-aware, use tz_convert to convert. with pandas 0.23.4 .

I think this a suitable fix:

            if df.index.tzinfo is None:
                df.index = df.index.tz_localize('UTC')

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