From 2dc019eb8878e276ea72f6e03b3b9053f822cd11 Mon Sep 17 00:00:00 2001 From: tuhinsharma121 Date: Sat, 18 May 2024 09:38:41 +0530 Subject: [PATCH 1/2] DOC: add SA01 for pandas.Timestamp.ceil --- pandas/_libs/tslibs/nattype.pyx | 6 ++++++ pandas/_libs/tslibs/timestamps.pyx | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/pandas/_libs/tslibs/nattype.pyx b/pandas/_libs/tslibs/nattype.pyx index 8319af2148918..a87ccc44914a9 100644 --- a/pandas/_libs/tslibs/nattype.pyx +++ b/pandas/_libs/tslibs/nattype.pyx @@ -1216,6 +1216,12 @@ timedelta}, default 'raise' ------ ValueError if the freq cannot be converted. + See Also + -------- + Timestamp.floor : Round down a Timestamp to the specified resolution. + Timestamp.round : Round a Timestamp to the specified resolution. + Series.dt.ceil : Ceil the datetime values in a Series. + Notes ----- If the Timestamp has a timezone, ceiling will take place relative to the diff --git a/pandas/_libs/tslibs/timestamps.pyx b/pandas/_libs/tslibs/timestamps.pyx index a33df56e65873..95d93918ac296 100644 --- a/pandas/_libs/tslibs/timestamps.pyx +++ b/pandas/_libs/tslibs/timestamps.pyx @@ -2285,6 +2285,12 @@ timedelta}, default 'raise' ------ ValueError if the freq cannot be converted. + See Also + -------- + Timestamp.floor : Round down a Timestamp to the specified resolution. + Timestamp.round : Round a Timestamp to the specified resolution. + Series.dt.ceil : Ceil the datetime values in a Series. + Notes ----- If the Timestamp has a timezone, ceiling will take place relative to the From 1048321a736956bbcf227c8958259cb82e5ca730 Mon Sep 17 00:00:00 2001 From: tuhinsharma121 Date: Sat, 18 May 2024 09:38:58 +0530 Subject: [PATCH 2/2] DOC: remove SA01 for pandas.Timestamp.ceil --- ci/code_checks.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/ci/code_checks.sh b/ci/code_checks.sh index 180083dbbb742..d94c8740f8fe3 100755 --- a/ci/code_checks.sh +++ b/ci/code_checks.sh @@ -246,7 +246,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then -i "pandas.TimedeltaIndex.nanoseconds SA01" \ -i "pandas.TimedeltaIndex.seconds SA01" \ -i "pandas.TimedeltaIndex.to_pytimedelta RT03,SA01" \ - -i "pandas.Timestamp.ceil SA01" \ -i "pandas.Timestamp.combine PR01,SA01" \ -i "pandas.Timestamp.ctime SA01" \ -i "pandas.Timestamp.date SA01" \