@@ -2674,20 +2674,17 @@ def unique(
26742674 subset : str | list [str ] | None = None ,
26752675 * ,
26762676 keep : Literal ["any" , "none" ] = "any" ,
2677- maintain_order : bool | None = None ,
26782677 ) -> Self :
26792678 """Drop duplicate rows from this LazyFrame.
26802679
26812680 Arguments:
26822681 subset: Column name(s) to consider when identifying duplicate rows.
26832682 If set to `None`, use all columns.
2684- keep: {'first ', 'none'}
2683+ keep: {'any ', 'none'}
26852684 Which of the duplicate rows to keep.
26862685
26872686 * 'any': Does not give any guarantee of which row is kept.
2688- This allows more optimizations.
26892687 * 'none': Don't keep duplicate rows.
2690- maintain_order: Has no effect and is kept around only for backwards-compatibility.
26912688
26922689 Returns:
26932690 The LazyFrame with unique rows.
@@ -2715,15 +2712,6 @@ def unique(
27152712 f"'any' and 'none' are supported for `keep` in `unique`. Got: { keep } ."
27162713 )
27172714 raise ValueError (msg )
2718- if maintain_order :
2719- msg = "`maintain_order=True` is not supported for LazyFrame.unique."
2720- raise ValueError (msg )
2721- if maintain_order is not None :
2722- msg = (
2723- "`maintain_order` has no effect and is only kept around for backwards-compatibility. "
2724- "You can safely remove this argument."
2725- )
2726- warn (message = msg , category = UserWarning , stacklevel = find_stacklevel ())
27272715 if isinstance (subset , str ):
27282716 subset = [subset ]
27292717 return self ._from_compliant_dataframe (
0 commit comments