NVIDIA / NVIDIA/cudf

[FEA] Support `"raise"` option for `ambiguous` and `nonexistent` in tz_localize

Open
#13,999 0 comments 0 reactions 0 assignees View on GitHub
feature request Python
Dominant language
C++
Stars
9.8k
Forks
1.1k
Avg merge
3d 6m
Merged PRs (30d)
278

Description

**Is your feature request related to a problem? Please describe.**
pandas currently defaults to raising `pytz` exceptions (possibly zoneinfo exceptions when the pytz changes as the default) when localizing an ambiguous or nonexistent time. It would be useful to have this functionality in cudf as well.

**Describe the solution you'd like**
Supporting a `ambiguous="raise"` and `nonexistent="raise"` option

**Describe alternatives you've considered**
None

**Additional context**
https://pandas.pydata.org/docs/reference/api/pandas.Series.dt.tz_localize.html

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.