Skip to content

Commit

Permalink
Enable Ruff PLE (Pylint Error) (python#13305)
Browse files Browse the repository at this point in the history
  • Loading branch information
Avasam authored Mar 4, 2025
1 parent 641ca18 commit 63e6ea8
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ select = [
"N", # pep8-naming
"PGH", # pygrep-hooks
"PLC", # Pylint Convention
"PLE", # Pylint Error
"PLR", # Pylint Refactor
"RUF", # Ruff-specific and unused-noqa
"TRY", # tryceratops
Expand Down
2 changes: 1 addition & 1 deletion stubs/gevent/gevent/hub.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class _DefaultReturnProperty(Protocol[_T]):
@overload
def __get__(self, obj: object, owner: type[object] | None = None) -> _T: ...
def __set__(self, obj: object, value: _T | None) -> None: ...
def __del__(self, obj: object) -> None: ...
def __del__(self) -> None: ...

def spawn_raw(function: Callable[..., object], *args: object, **kwargs: object) -> greenlet.greenlet: ...
def sleep(seconds: float = 0, ref: bool = True) -> None: ...
Expand Down
6 changes: 3 additions & 3 deletions stubs/regex/regex/regex.pyi
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import sys
from _typeshed import ReadableBuffer
from _typeshed import ReadableBuffer, Unused
from collections.abc import Callable, Mapping
from typing import Any, AnyStr, Generic, Literal, TypeVar, final, overload
from typing_extensions import Self
Expand Down Expand Up @@ -568,7 +568,7 @@ class Pattern(Generic[AnyStr]):
timeout: float | None = None,
) -> _regex.Scanner[bytes]: ...
def __copy__(self) -> Self: ...
def __deepcopy__(self) -> Self: ...
def __deepcopy__(self, memo: Unused, /) -> Self: ...
if sys.version_info >= (3, 9):
def __class_getitem__(cls, item: Any, /) -> GenericAlias: ...

Expand Down Expand Up @@ -647,6 +647,6 @@ class Match(Generic[AnyStr]):
@overload
def __getitem__(self, key: int | str, /) -> AnyStr | Any: ...
def __copy__(self) -> Self: ...
def __deepcopy__(self) -> Self: ...
def __deepcopy__(self, memo: Unused, /) -> Self: ...
if sys.version_info >= (3, 9):
def __class_getitem__(cls, item: Any, /) -> GenericAlias: ...

0 comments on commit 63e6ea8

Please sign in to comment.