Skip to content

Commit a2f566f

Browse files
tuhinsharma121KevsterAmp
authored andcommitted
DOC: fix SA01,ES01 for pandas.errors.DuplicateLabelError (pandas-dev#60399)
1 parent cba66dc commit a2f566f

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

ci/code_checks.sh

-1
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
109109
-i "pandas.core.resample.Resampler.std SA01" \
110110
-i "pandas.core.resample.Resampler.transform PR01,RT03,SA01" \
111111
-i "pandas.core.resample.Resampler.var SA01" \
112-
-i "pandas.errors.DuplicateLabelError SA01" \
113112
-i "pandas.errors.IntCastingNaNError SA01" \
114113
-i "pandas.errors.InvalidIndexError SA01" \
115114
-i "pandas.errors.NullFrequencyError SA01" \

pandas/errors/__init__.py

+13
Original file line numberDiff line numberDiff line change
@@ -393,6 +393,19 @@ class DuplicateLabelError(ValueError):
393393
"""
394394
Error raised when an operation would introduce duplicate labels.
395395
396+
This error is typically encountered when performing operations on objects
397+
with `allows_duplicate_labels=False` and the operation would result in
398+
duplicate labels in the index. Duplicate labels can lead to ambiguities
399+
in indexing and reduce data integrity.
400+
401+
See Also
402+
--------
403+
Series.set_flags : Return a new ``Series`` object with updated flags.
404+
DataFrame.set_flags : Return a new ``DataFrame`` object with updated flags.
405+
Series.reindex : Conform ``Series`` object to new index with optional filling logic.
406+
DataFrame.reindex : Conform ``DataFrame`` object to new index with optional filling
407+
logic.
408+
396409
Examples
397410
--------
398411
>>> s = pd.Series([0, 1, 2], index=["a", "b", "c"]).set_flags(

0 commit comments

Comments
 (0)