mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-20 10:51:15 +08:00
Bump flake8-pyi to 24.6.0 (#12132)
This commit is contained in:
4
.flake8
4
.flake8
@@ -8,10 +8,6 @@ extend-ignore = Y090
|
||||
per-file-ignores =
|
||||
# We should only need to noqa Y and F821 codes in .pyi files
|
||||
*.py: NQA
|
||||
# Ignore Y052 in this file: there are loads of false positives
|
||||
# due to the fact that flake8-pyi doesn't understand subclasses of `CoerciveEnum`
|
||||
# as being enum classes
|
||||
stubs/fpdf2/fpdf/enums.pyi: Y052
|
||||
# Generated protobuf files:
|
||||
# Y021: Include docstrings
|
||||
# Y023: Alias typing as typing_extensions
|
||||
|
||||
@@ -36,7 +36,7 @@ repos:
|
||||
- id: flake8
|
||||
additional_dependencies:
|
||||
- "flake8-noqa==1.4.0" # must match requirements-tests.txt
|
||||
- "flake8-pyi==24.4.1" # must match requirements-tests.txt
|
||||
- "flake8-pyi==24.6.0" # must match requirements-tests.txt
|
||||
types: [file]
|
||||
types_or: [python, pyi]
|
||||
- repo: meta
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
black==24.3.0 # must match .pre-commit-config.yaml
|
||||
flake8==7.0.0 # must match .pre-commit-config.yaml
|
||||
flake8-noqa==1.4.0 # must match .pre-commit-config.yaml
|
||||
flake8-pyi==24.4.1 # must match .pre-commit-config.yaml
|
||||
flake8-pyi==24.6.0 # must match .pre-commit-config.yaml
|
||||
mypy==1.10.0
|
||||
pre-commit-hooks==4.5.0 # must match .pre-commit-config.yaml
|
||||
pyright==1.1.366
|
||||
|
||||
@@ -11,7 +11,7 @@ if sys.version_info >= (3, 13):
|
||||
PyCF_OPTIMIZED_AST: Literal[33792]
|
||||
|
||||
# Used for node end positions in constructor keyword arguments
|
||||
_EndPositionT = typing_extensions.TypeVar("_EndPositionT", int, int | None, default=int | None) # noqa: Y023
|
||||
_EndPositionT = typing_extensions.TypeVar("_EndPositionT", int, int | None, default=int | None)
|
||||
|
||||
# Alias used for fields that must always be valid identifiers
|
||||
# A string `x` counts as a valid identifier if both the following are True
|
||||
|
||||
@@ -162,9 +162,9 @@ def get_precision(geometry: Geometry | None, **kwargs) -> float: ...
|
||||
def get_precision(geometry: OptGeoArrayLikeSeq, **kwargs) -> NDArray[np.float64]: ...
|
||||
|
||||
class SetPrecisionMode(ParamEnum):
|
||||
valid_output = 0 # noqa: Y052
|
||||
pointwise = 1 # noqa: Y052
|
||||
keep_collapsed = 2 # noqa: Y052
|
||||
valid_output = 0
|
||||
pointwise = 1
|
||||
keep_collapsed = 2
|
||||
|
||||
@overload
|
||||
def set_precision(geometry: OptGeoT, grid_size: float, mode: _PrecisionMode = "valid_output", **kwargs) -> OptGeoT: ...
|
||||
|
||||
@@ -39,14 +39,14 @@ __all__ = [
|
||||
]
|
||||
|
||||
class BufferCapStyle(ParamEnum):
|
||||
round = 1 # noqa: Y052
|
||||
flat = 2 # noqa: Y052
|
||||
square = 3 # noqa: Y052
|
||||
round = 1
|
||||
flat = 2
|
||||
square = 3
|
||||
|
||||
class BufferJoinStyle(ParamEnum):
|
||||
round = 1 # noqa: Y052
|
||||
mitre = 2 # noqa: Y052
|
||||
bevel = 3 # noqa: Y052
|
||||
round = 1
|
||||
mitre = 2
|
||||
bevel = 3
|
||||
|
||||
@overload
|
||||
def boundary(geometry: Point | MultiPoint, **kwargs) -> GeometryCollection: ...
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
from array import array
|
||||
from collections.abc import Iterator
|
||||
from typing import Any, Generic, Literal, NoReturn, overload
|
||||
from typing_extensions import Self, TypeVar, deprecated # noqa: Y023
|
||||
from typing_extensions import Self, TypeVar, deprecated
|
||||
|
||||
import numpy as np
|
||||
from numpy.typing import NDArray
|
||||
|
||||
@@ -18,8 +18,8 @@ __all__ = ["from_geojson", "from_ragged_array", "from_wkb", "from_wkt", "to_geoj
|
||||
DecodingErrorOptions: Incomplete
|
||||
|
||||
class WKBFlavorOptions(ParamEnum):
|
||||
extended = 1 # noqa: Y052
|
||||
iso = 2 # noqa: Y052
|
||||
extended = 1
|
||||
iso = 2
|
||||
|
||||
@overload
|
||||
def to_wkt(
|
||||
|
||||
@@ -15,15 +15,15 @@ _BinaryPredicate: TypeAlias = Literal[
|
||||
]
|
||||
|
||||
class BinaryPredicate(ParamEnum):
|
||||
intersects = 1 # noqa: Y052
|
||||
within = 2 # noqa: Y052
|
||||
contains = 3 # noqa: Y052
|
||||
overlaps = 4 # noqa: Y052
|
||||
crosses = 5 # noqa: Y052
|
||||
touches = 6 # noqa: Y052
|
||||
covers = 7 # noqa: Y052
|
||||
covered_by = 8 # noqa: Y052
|
||||
contains_properly = 9 # noqa: Y052
|
||||
intersects = 1
|
||||
within = 2
|
||||
contains = 3
|
||||
overlaps = 4
|
||||
crosses = 5
|
||||
touches = 6
|
||||
covers = 7
|
||||
covered_by = 8
|
||||
contains_properly = 9
|
||||
|
||||
class STRtree:
|
||||
def __init__(self, geoms: GeoArrayLikeSeq, node_capacity: SupportsIndex = 10) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user