From 0253d1ed1eab0359aec0fbc0d16b02b6c07383d4 Mon Sep 17 00:00:00 2001 From: "Mr.Hoseini" Date: Fri, 15 May 2026 12:43:33 +0330 Subject: [PATCH 1/5] Set default category to DeprecationWarning in DeprecatedParams --- stubs/Deprecated/deprecated/params.pyi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stubs/Deprecated/deprecated/params.pyi b/stubs/Deprecated/deprecated/params.pyi index a15f07482bd5..ded386f89183 100644 --- a/stubs/Deprecated/deprecated/params.pyi +++ b/stubs/Deprecated/deprecated/params.pyi @@ -8,7 +8,7 @@ _R = TypeVar("_R") class DeprecatedParams: messages: dict[str, str] category: type[Warning] - def __init__(self, param: str | dict[str, str], reason: str = "", category: type[Warning] = ...) -> None: ... + def __init__(self, param: str | dict[str, str], reason: str = "", category: type[Warning] = DeprecationWarning) -> None: ... def populate_messages(self, param: str | dict[str, str], reason: str = "") -> None: ... def check_params( self, signature: Signature, *args: Any, **kwargs: Any # args and kwargs passing to Signature.bind method From b9de2fb1debe733b8bdc4d373365d32bcabacfd8 Mon Sep 17 00:00:00 2001 From: "Mr.Hoseini" Date: Tue, 19 May 2026 08:10:05 +0330 Subject: [PATCH 2/5] Update stubs/Deprecated/deprecated/params.pyi Co-authored-by: Sebastian Rittau --- stubs/Deprecated/deprecated/params.pyi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stubs/Deprecated/deprecated/params.pyi b/stubs/Deprecated/deprecated/params.pyi index ded386f89183..e021a9f053dd 100644 --- a/stubs/Deprecated/deprecated/params.pyi +++ b/stubs/Deprecated/deprecated/params.pyi @@ -8,7 +8,7 @@ _R = TypeVar("_R") class DeprecatedParams: messages: dict[str, str] category: type[Warning] - def __init__(self, param: str | dict[str, str], reason: str = "", category: type[Warning] = DeprecationWarning) -> None: ... + def __init__(self, param: str | dict[str, str], reason: str = "", category: type[Warning] = DeprecationWarning) -> None: ... # noqa: Y011 def populate_messages(self, param: str | dict[str, str], reason: str = "") -> None: ... def check_params( self, signature: Signature, *args: Any, **kwargs: Any # args and kwargs passing to Signature.bind method From f8f7e6ea64d6cf62bb946350059ce2a4f8d1e596 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 19 May 2026 04:41:59 +0000 Subject: [PATCH 3/5] [pre-commit.ci] auto fixes from pre-commit.com hooks --- stubs/Deprecated/deprecated/params.pyi | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/stubs/Deprecated/deprecated/params.pyi b/stubs/Deprecated/deprecated/params.pyi index e021a9f053dd..a76c2492b1a8 100644 --- a/stubs/Deprecated/deprecated/params.pyi +++ b/stubs/Deprecated/deprecated/params.pyi @@ -8,7 +8,9 @@ _R = TypeVar("_R") class DeprecatedParams: messages: dict[str, str] category: type[Warning] - def __init__(self, param: str | dict[str, str], reason: str = "", category: type[Warning] = DeprecationWarning) -> None: ... # noqa: Y011 + def __init__( + self, param: str | dict[str, str], reason: str = "", category: type[Warning] = DeprecationWarning + ) -> None: ... # noqa: Y011 def populate_messages(self, param: str | dict[str, str], reason: str = "") -> None: ... def check_params( self, signature: Signature, *args: Any, **kwargs: Any # args and kwargs passing to Signature.bind method From a65f9f1d8e52e106f828beb9bfde318dd6685748 Mon Sep 17 00:00:00 2001 From: "Mr.Hoseini" Date: Tue, 19 May 2026 08:35:22 +0330 Subject: [PATCH 4/5] Refactor DeprecatedParams constructor parameters --- stubs/Deprecated/deprecated/params.pyi | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/stubs/Deprecated/deprecated/params.pyi b/stubs/Deprecated/deprecated/params.pyi index a76c2492b1a8..4dbc7581106b 100644 --- a/stubs/Deprecated/deprecated/params.pyi +++ b/stubs/Deprecated/deprecated/params.pyi @@ -9,8 +9,11 @@ class DeprecatedParams: messages: dict[str, str] category: type[Warning] def __init__( - self, param: str | dict[str, str], reason: str = "", category: type[Warning] = DeprecationWarning - ) -> None: ... # noqa: Y011 + self, + param: str | dict[str, str], + reason: str = "", + category: type[Warning] = DeprecationWarning, # noqa: Y011 + ) -> None: ... def populate_messages(self, param: str | dict[str, str], reason: str = "") -> None: ... def check_params( self, signature: Signature, *args: Any, **kwargs: Any # args and kwargs passing to Signature.bind method From 5afd51b4f4cdb7a1d385d5a37cb942c1470431ad Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 19 May 2026 05:07:14 +0000 Subject: [PATCH 5/5] [pre-commit.ci] auto fixes from pre-commit.com hooks --- stubs/Deprecated/deprecated/params.pyi | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/stubs/Deprecated/deprecated/params.pyi b/stubs/Deprecated/deprecated/params.pyi index 4dbc7581106b..721d2d225900 100644 --- a/stubs/Deprecated/deprecated/params.pyi +++ b/stubs/Deprecated/deprecated/params.pyi @@ -9,10 +9,7 @@ class DeprecatedParams: messages: dict[str, str] category: type[Warning] def __init__( - self, - param: str | dict[str, str], - reason: str = "", - category: type[Warning] = DeprecationWarning, # noqa: Y011 + self, param: str | dict[str, str], reason: str = "", category: type[Warning] = DeprecationWarning # noqa: Y011 ) -> None: ... def populate_messages(self, param: str | dict[str, str], reason: str = "") -> None: ... def check_params(