Skip to content

BUG: out-of-bounds datetime parsing #15829

Closed
@jreback

Description

@jreback
In [2]: pd.__version__
Out[2]: '0.19.0+695.g2e64614'

suprisingly [2] and [3] return the same as [1] on linux-64 (meaning they don't raise).
This is from macosx. This is the correct behavior (raising).

In [1]: pd.Timestamp('01-01-01')
Out[1]: Timestamp('2001-01-01 00:00:00')

In [2]: pd.Timestamp('001-01-01')
OutOfBoundsDatetime: Out of bounds nanosecond timestamp: 1-01-01 00:00:00

In [3]: pd.Timestamp('0001-01-01')
OutOfBoundsDatetime: Out of bounds nanosecond timestamp: 1-01-01 00:00:00

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions