diff --git a/pandas/core/frame.py b/pandas/core/frame.py index 5468406b2ea219..0ec4caaabb6b51 100644 --- a/pandas/core/frame.py +++ b/pandas/core/frame.py @@ -10100,7 +10100,7 @@ def merge( sort: bool = False, suffixes: Suffixes = ("_x", "_y"), copy: bool = True, - indicator: bool = False, + indicator: str | bool = False, validate: str | None = None, ) -> DataFrame: from pandas.core.reshape.merge import merge diff --git a/pandas/core/reshape/merge.py b/pandas/core/reshape/merge.py index 7ec91b23c54f25..a84f8af7d4c386 100644 --- a/pandas/core/reshape/merge.py +++ b/pandas/core/reshape/merge.py @@ -107,7 +107,7 @@ def merge( sort: bool = False, suffixes: Suffixes = ("_x", "_y"), copy: bool = True, - indicator: bool = False, + indicator: str | bool = False, validate: str | None = None, ) -> DataFrame: op = _MergeOperation( @@ -625,7 +625,7 @@ class _MergeOperation: sort: bool suffixes: Suffixes copy: bool - indicator: bool + indicator: str | bool validate: str | None join_names: list[Hashable] right_join_keys: list[AnyArrayLike] @@ -644,7 +644,7 @@ def __init__( right_index: bool = False, sort: bool = True, suffixes: Suffixes = ("_x", "_y"), - indicator: bool = False, + indicator: str | bool = False, validate: str | None = None, ) -> None: _left = _validate_operand(left)