Skip to content

Commit

Permalink
Fix all reportAssignmentType (#329)
Browse files Browse the repository at this point in the history
  • Loading branch information
Avasam authored Nov 7, 2024
1 parent 7e9bfa9 commit 53334cc
Show file tree
Hide file tree
Showing 7 changed files with 4 additions and 8 deletions.
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ reportSelfClsParameterName = false
# Error reports to fix in code
reportArgumentType = "none" # TODO
reportAssertTypeFailure = "none" # TODO
reportAssignmentType = "none" # TODO
reportAttributeAccessIssue = "none" # TODO
reportFunctionMemberAccess = "none" # TODO
reportGeneralTypeIssues = "none" # TODO
Expand Down
3 changes: 2 additions & 1 deletion stubs/matplotlib/projections/geo.pyi
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from typing import Sequence
from typing_extensions import NoReturn

import numpy as np
from matplotlib.axes import Axes
Expand All @@ -23,7 +24,7 @@ class GeoAxes(Axes):
def set_yscale(self, *args, **kwargs) -> None: ...

set_xscale = set_yscale
def set_xlim(self, *args, **kwargs) -> None: ...
def set_xlim(self, *args, **kwargs) -> NoReturn: ...
set_ylim = set_xlim
def format_coord(self, lon, lat) -> str: ...
def set_longitude_grid(self, degrees: float) -> None: ...
Expand Down
1 change: 0 additions & 1 deletion stubs/skimage/measure/_regionprops.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import numpy as np
from numpy.typing import ArrayLike
from scipy import ndimage as ndi
from scipy.spatial.distance import pdist
from skimage.measure._regionprops import RegionProperties

from . import _moments
from ._find_contours import find_contours
Expand Down
1 change: 0 additions & 1 deletion stubs/vispy/geometry/rect.pyi
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import numpy as np
from vispy.util.svg.shapes import Rect

class Rect(object):
def __init__(self, *args, **kwargs): ...
Expand Down
1 change: 0 additions & 1 deletion stubs/vispy/visuals/line/arrow.pyi
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import numpy as np
from numpy.typing import ArrayLike
from vispy.util.svg.color import Color
from vispy.visuals.line.arrow import ArrowVisual

from ... import gloo, glsl
from ..transforms._util import as_vec4
Expand Down
1 change: 0 additions & 1 deletion stubs/vispy/visuals/transforms/linear.pyi
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import numpy as np
from numpy import ndarray
from numpy.typing import ArrayLike, NDArray
from vispy.visuals.transforms.linear import STTransform

from ...geometry import Rect
from ...util import transforms
Expand Down
4 changes: 2 additions & 2 deletions utils/validate_stubs.py
Original file line number Diff line number Diff line change
Expand Up @@ -389,9 +389,9 @@ def has_module(path: str, name: str, node: Item, stub: Item):


def find_module(package: Item, module: str):
module = module.split(".")[1:]
modules = module.split(".")[1:]
root = package
for m in module:
for m in modules:
if m not in root.children:
return
root = root.children[m]
Expand Down

0 comments on commit 53334cc

Please sign in to comment.