From 5186178d901983891c0bd49af51ac4e681592f3a Mon Sep 17 00:00:00 2001 From: Alexandru Fikl Date: Sat, 22 Nov 2025 11:52:19 +0200 Subject: [PATCH 1/7] chore: remove a bunch of mypy comments --- arraycontext/container/__init__.py | 6 ++---- arraycontext/container/traversal.py | 7 ++----- arraycontext/pytest.py | 2 +- test/testlib.py | 9 +++------ 4 files changed, 8 insertions(+), 16 deletions(-) diff --git a/arraycontext/container/__init__.py b/arraycontext/container/__init__.py index 8598a8fc..0e6bbe33 100644 --- a/arraycontext/container/__init__.py +++ b/arraycontext/container/__init__.py @@ -299,8 +299,7 @@ def _serialize_ndarray_container(ary: numpy.ndarray) -> SerializedContainer: @deserialize_container.register(np.ndarray) -# https://github.com/python/mypy/issues/13040 -def _deserialize_ndarray_container( # type: ignore[misc] +def _deserialize_ndarray_container( template: numpy.ndarray, serialized: SerializedContainer) -> numpy.ndarray: # disallow subclasses @@ -309,8 +308,7 @@ def _deserialize_ndarray_container( # type: ignore[misc] result = type(template)(template.shape, dtype=object) for i, subary in serialized: - # FIXME: numpy annotations don't seem to handle object arrays very well - result[i] = subary # type: ignore[call-overload] + result[i] = subary return result diff --git a/arraycontext/container/traversal.py b/arraycontext/container/traversal.py index 2e0d428b..ff64e643 100644 --- a/arraycontext/container/traversal.py +++ b/arraycontext/container/traversal.py @@ -1,5 +1,3 @@ -# mypy: disallow-untyped-defs - """ .. currentmodule:: arraycontext @@ -976,7 +974,6 @@ def unflatten( checking is performed on the unflattened array. Otherwise, these checks are skipped. """ - # NOTE: https://github.com/python/mypy/issues/7057 offset: int = 0 common_dtype = None @@ -1046,12 +1043,12 @@ def _unflatten( # Checking strides for 0 sized arrays is ill-defined # since they cannot be indexed if ( - # Mypy has a point: nobody promised a .strides attribute. + # pyright has a point: nobody promised a .strides attribute. template_subary_c.strides != subary.strides # pyright: ignore[reportAttributeAccessIssue] and template_subary_c.size != 0 ): raise ValueError( - # Mypy has a point: nobody promised a .strides attribute. + # pyright has a point: nobody promised a .strides attribute. f"strides do not match template: got {subary.strides}, " # pyright: ignore[reportAttributeAccessIssue] f"expected {template_subary_c.strides}") from None diff --git a/arraycontext/pytest.py b/arraycontext/pytest.py index 45319ea5..0dc99be1 100644 --- a/arraycontext/pytest.py +++ b/arraycontext/pytest.py @@ -325,7 +325,7 @@ def pytest_generate_tests_for_array_contexts( if env_factory_string is not None: unique_factories = set(env_factory_string.split(",")) else: - unique_factories = set(factories) # type: ignore[arg-type] + unique_factories = set(factories) if not unique_factories: raise ValueError("no array context factories were selected") diff --git a/test/testlib.py b/test/testlib.py index c58381a4..25aa18c0 100644 --- a/test/testlib.py +++ b/test/testlib.py @@ -114,8 +114,7 @@ def _serialize_dof_container(ary: DOFArray): @deserialize_container.register(DOFArray) -# https://github.com/python/mypy/issues/13040 -def _deserialize_dof_container( # type: ignore[misc] +def _deserialize_dof_container( template, iterable): def _raise_index_inconsistency(i, stream_i): raise ValueError( @@ -130,8 +129,7 @@ def _raise_index_inconsistency(i, stream_i): @with_array_context.register(DOFArray) -# https://github.com/python/mypy/issues/13040 -def _with_actx_dofarray(ary: DOFArray, actx: ArrayContext) -> DOFArray: # type: ignore[misc] +def _with_actx_dofarray(ary: DOFArray, actx: ArrayContext) -> DOFArray: return type(ary)(actx, ary.data) # }}} @@ -227,6 +225,5 @@ class Velocity3D(Velocity2D): @with_array_context.register(Velocity2D) -# https://github.com/python/mypy/issues/13040 -def _with_actx_velocity_2d(ary, actx): # type: ignore[misc] +def _with_actx_velocity_2d(ary, actx): return type(ary)(ary.u, ary.v, actx) From 8996ad00a9942da038d06e76ee2891ddd1cedf90 Mon Sep 17 00:00:00 2001 From: Alexandru Fikl Date: Sat, 22 Nov 2025 11:53:12 +0200 Subject: [PATCH 2/7] chore: remove a bunch of pylint comments --- arraycontext/impl/pytato/compile.py | 2 +- arraycontext/impl/pytato/utils.py | 2 -- test/test_arraycontext.py | 2 -- 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/arraycontext/impl/pytato/compile.py b/arraycontext/impl/pytato/compile.py index 323eb791..fe42a020 100644 --- a/arraycontext/impl/pytato/compile.py +++ b/arraycontext/impl/pytato/compile.py @@ -440,7 +440,7 @@ def _dag_to_transformed_pytato_prg(self, dict_of_named_arrays, *, prg_id=None): options=opts, function_name=_prg_id_to_kernel_name(prg_id), target=self.actx.get_target(), - ).bind_to_context(self.actx.context) # pylint: disable=no-member + ).bind_to_context(self.actx.context) assert isinstance(pytato_program, BoundPyOpenCLExecutable) self.actx._compile_trace_callback( diff --git a/arraycontext/impl/pytato/utils.py b/arraycontext/impl/pytato/utils.py index 0c205f49..8266e1d7 100644 --- a/arraycontext/impl/pytato/utils.py +++ b/arraycontext/impl/pytato/utils.py @@ -222,8 +222,6 @@ def map_data_wrapper(self, expr: DataWrapper) -> Array: actx_ary = self.actx.from_numpy(expr.data) assert isinstance(actx_ary, DataWrapper) - # https://github.com/pylint-dev/pylint/issues/3893 - # pylint: disable=unexpected-keyword-arg return DataWrapper( data=actx_ary.data, shape=expr.shape, diff --git a/test/test_arraycontext.py b/test/test_arraycontext.py index ddb8df05..6d7a38a4 100644 --- a/test/test_arraycontext.py +++ b/test/test_arraycontext.py @@ -134,14 +134,12 @@ def _get_test_containers(actx, ambient_dim=2, shapes=50_000): x = DOFArray(actx, tuple(actx.from_numpy(randn(shape, np.float64)) for shape in shapes)) - # pylint: disable=unexpected-keyword-arg, no-value-for-parameter dataclass_of_dofs = MyContainer( name="container", mass=x, momentum=obj_array.new_1d([x] * ambient_dim), enthalpy=x) - # pylint: disable=unexpected-keyword-arg, no-value-for-parameter bcast_dataclass_of_dofs = MyContainerDOFBcast( name="container", mass=x, From 96660b59169ec19bbe0c2001ef1a7bf690b035ae Mon Sep 17 00:00:00 2001 From: Alexandru Fikl Date: Sat, 22 Nov 2025 11:48:26 +0200 Subject: [PATCH 3/7] feat(typing): improve types in arraycontext.pytest --- arraycontext/pytest.py | 86 +++++++++++++++++++++++------------------- 1 file changed, 47 insertions(+), 39 deletions(-) diff --git a/arraycontext/pytest.py b/arraycontext/pytest.py index 0dc99be1..2e3c03a0 100644 --- a/arraycontext/pytest.py +++ b/arraycontext/pytest.py @@ -33,7 +33,7 @@ THE SOFTWARE. """ -from typing import TYPE_CHECKING, Any, cast +from typing import TYPE_CHECKING, Any, ClassVar, cast from typing_extensions import override @@ -43,6 +43,8 @@ if TYPE_CHECKING: from collections.abc import Callable, Sequence + import pytest + import pyopencl as cl from arraycontext.context import ArrayContext @@ -66,7 +68,7 @@ class PytestPyOpenCLArrayContextFactory(PytestArrayContextFactory): """ device: cl.Device - def __init__(self, device: cl.Device): + def __init__(self, device: cl.Device) -> None: """ :arg device: a :class:`pyopencl.Device`. """ @@ -76,12 +78,12 @@ def __init__(self, device: cl.Device): @override def is_available(cls) -> bool: try: - import pyopencl # noqa: F401 + import pyopencl # noqa: F401 # pyright: ignore[reportUnusedImport] return True except ImportError: return False - def get_command_queue(self): + def get_command_queue(self) -> tuple[cl.Context, cl.CommandQueue]: # Get rid of leftovers from past tests. # CL implementations are surprisingly limited in how many # simultaneous contexts they allow... @@ -101,22 +103,24 @@ def get_command_queue(self): class _PytestPyOpenCLArrayContextFactoryWithClass(PytestPyOpenCLArrayContextFactory): # Deprecated, remove in 2025. - _force_device_scalars = True + _force_device_scalars: ClassVar[bool] = True @property - def force_device_scalars(self): + def force_device_scalars(self) -> bool: from warnings import warn warn( "force_device_scalars is deprecated and will be removed in 2025.", DeprecationWarning, stacklevel=2) + return self._force_device_scalars @property - def actx_class(self): + def actx_class(self) -> type[ArrayContext]: from arraycontext import PyOpenCLArrayContext return PyOpenCLArrayContext - def __call__(self): + @override + def __call__(self) -> ArrayContext: # The ostensibly pointless assignment to *ctx* keeps the CL context alive # long enough to create the array context, which will then start # holding a reference to the context to keep it alive in turn. @@ -125,7 +129,6 @@ def __call__(self): _ctx, queue = self.get_command_queue() alloc = None - if queue.device.platform.name == "NVIDIA CUDA": from pyopencl.tools import ImmediateAllocator alloc = ImmediateAllocator(queue) @@ -136,11 +139,10 @@ def __call__(self): "See https://github.com/inducer/arraycontext/issues/196", stacklevel=1) - return self.actx_class( - queue, - allocator=alloc) + return self.actx_class(queue, allocator=alloc) - def __str__(self): + @override + def __str__(self) -> str: return (f"<{self.actx_class.__name__} " f"for >") @@ -148,22 +150,22 @@ def __str__(self): class _PytestPytatoPyOpenCLArrayContextFactory(PytestPyOpenCLArrayContextFactory): @classmethod + @override def is_available(cls) -> bool: try: - import pyopencl # noqa: F401 - import pytato # noqa: F401 + import pyopencl # noqa: F401 # pyright: ignore[reportUnusedImport] + import pytato # noqa: F401 # pyright: ignore[reportUnusedImport] return True except ImportError: return False @property - def actx_class(self): + def actx_class(self) -> type[ArrayContext]: from arraycontext import PytatoPyOpenCLArrayContext - actx_cls = PytatoPyOpenCLArrayContext - return actx_cls + return PytatoPyOpenCLArrayContext @override - def __call__(self): + def __call__(self) -> ArrayContext: # The ostensibly pointless assignment to *ctx* keeps the CL context alive # long enough to create the array context, which will then start # holding a reference to the context to keep it alive in turn. @@ -186,67 +188,71 @@ def __call__(self): return self.actx_class(queue, allocator=alloc) @override - def __str__(self): - return (" str: + return (f"<{self.actx_class.__name__} for " f">") class _PytestEagerJaxArrayContextFactory(PytestArrayContextFactory): - def __init__(self, *args, **kwargs): + def __init__(self, *args, **kwargs) -> None: pass @classmethod @override def is_available(cls) -> bool: try: - import jax # noqa: F401 + import jax # noqa: F401 # pyright: ignore[reportUnusedImport] return True except ImportError: return False @override - def __call__(self): - from jax import config + def __call__(self) -> ArrayContext: + import jax from arraycontext import EagerJAXArrayContext - config.update("jax_enable_x64", True) + + jax.config.update("jax_enable_x64", True) return EagerJAXArrayContext() @override - def __str__(self): + def __str__(self) -> str: return "" class _PytestPytatoJaxArrayContextFactory(PytestArrayContextFactory): - def __init__(self, *args, **kwargs): + def __init__(self, *args, **kwargs) -> None: pass @classmethod + @override def is_available(cls) -> bool: try: - import jax # noqa: F401 - import pytato # noqa: F401 + import jax # noqa: F401 # pyright: ignore[reportUnusedImport] + import pytato # noqa: F401 # pyright: ignore[reportUnusedImport] return True except ImportError: return False - def __call__(self): - from jax import config + @override + def __call__(self) -> ArrayContext: + import jax from arraycontext import PytatoJAXArrayContext - config.update("jax_enable_x64", True) + + jax.config.update("jax_enable_x64", True) return PytatoJAXArrayContext() @override - def __str__(self): + def __str__(self) -> str: return "" # {{{ _PytestArrayContextFactory class _PytestNumpyArrayContextFactory(PytestArrayContextFactory): - def __init__(self, *args, **kwargs): + def __init__(self, *args, **kwargs) -> None: super().__init__() @override @@ -254,7 +260,7 @@ def __call__(self) -> NumpyArrayContext: return NumpyArrayContext() @override - def __str__(self): + def __str__(self) -> str: return "" # }}} @@ -322,6 +328,7 @@ def pytest_generate_tests_for_array_contexts( import os env_factory_string = os.environ.get("ARRAYCONTEXT_TEST", None) + unique_factories: set[str | type[PytestArrayContextFactory]] if env_factory_string is not None: unique_factories = set(env_factory_string.split(",")) else: @@ -345,7 +352,8 @@ def pytest_generate_tests_for_array_contexts( raise ValueError(f"unknown array contexts: {unknown_factories}") available_factories = { - factory for key in unique_factories + factory + for key in unique_factories for factory in [_ARRAY_CONTEXT_FACTORY_REGISTRY.get(key, key)] if ( not isinstance(factory, str) @@ -360,7 +368,7 @@ def pytest_generate_tests_for_array_contexts( # }}} - def inner(metafunc): + def inner(metafunc: pytest.Metafunc) -> None: # {{{ get pyopencl devices import pyopencl.tools as cl_tools @@ -383,7 +391,7 @@ def inner(metafunc): f"Cannot use both an '{factory_arg_name}' and a " "'ctx_factory' / 'ctx_getter' as arguments.") - arg_values_with_actx = [] + arg_values_with_actx: list[dict[str, Any]] = [] if pyopencl_factories: for arg_dict in arg_values: From 3b1937e64ea0af88c9b8d482d52ad41cdef66c97 Mon Sep 17 00:00:00 2001 From: Alexandru Fikl Date: Sat, 22 Nov 2025 20:15:03 +0200 Subject: [PATCH 4/7] feat(typing): improve types in arraycontext.fake_numpy --- arraycontext/fake_numpy.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/arraycontext/fake_numpy.py b/arraycontext/fake_numpy.py index 0f4f967f..7074fb33 100644 --- a/arraycontext/fake_numpy.py +++ b/arraycontext/fake_numpy.py @@ -30,7 +30,7 @@ import operator from abc import ABC, abstractmethod from dataclasses import dataclass -from typing import TYPE_CHECKING, Any, Literal, cast, overload +from typing import TYPE_CHECKING, Any, ClassVar, Literal, cast, overload import numpy as np from typing_extensions import deprecated @@ -78,7 +78,7 @@ def __init__(self, array_context: ArrayContext): def _get_fake_numpy_linalg_namespace(self): return BaseFakeNumpyLinalgNamespace(self._array_context) - _numpy_math_functions = frozenset({ + _numpy_math_functions: ClassVar[frozenset[str]] = frozenset({ # https://numpy.org/doc/stable/reference/routines.math.html # FIXME: Heads up: not all of these are supported yet. @@ -560,7 +560,9 @@ def logical_not(self, x: ArrayOrContainerOrScalar, / # {{{ BaseFakeNumpyLinalgNamespace -def _reduce_norm(actx: ArrayContext, arys: Iterable[ArrayOrScalar], ord: float | None): +def _reduce_norm(actx: ArrayContext, + arys: Iterable[ArrayOrScalar], + ord: float | None) -> ArrayOrScalar: from functools import reduce from numbers import Number @@ -617,7 +619,7 @@ def norm(self, raise NotImplementedError("only vector norms are implemented") if ary.size == 0: - return ary.dtype.type(0) + return cast("ScalarLike", ary.dtype.type(0)) from numbers import Number if ord == 2: From 34fce2371df4fd9cb16375bb6e208f16ace7287d Mon Sep 17 00:00:00 2001 From: Alexandru Fikl Date: Sat, 22 Nov 2025 20:15:38 +0200 Subject: [PATCH 5/7] feat(typing): improve types in arraycontext.loopy --- arraycontext/loopy.py | 32 ++++++++++++++++++++------------ 1 file changed, 20 insertions(+), 12 deletions(-) diff --git a/arraycontext/loopy.py b/arraycontext/loopy.py index ca62b8f6..7201e5fc 100644 --- a/arraycontext/loopy.py +++ b/arraycontext/loopy.py @@ -56,7 +56,8 @@ THE SOFTWARE. """ -from typing import TYPE_CHECKING, ClassVar +from abc import ABC +from typing import TYPE_CHECKING, ClassVar, cast import numpy as np @@ -83,6 +84,8 @@ from loopy.kernel.instruction import InstructionBase from pytools.tag import ToTagSetConvertible + from arraycontext import ArrayContext + from arraycontext.typing import ArrayOrScalar, ScalarLike # {{{ loopy @@ -116,7 +119,7 @@ def make_loopy_program( tags=tags) -def get_default_entrypoint(t_unit): +def get_default_entrypoint(t_unit: lp.TranslationUnit) -> lp.LoopKernel: try: # main and "kernel callables" branch return t_unit.default_entrypoint @@ -128,9 +131,11 @@ def get_default_entrypoint(t_unit): "translation unit") from err -def _get_scalar_func_loopy_program(actx, c_name, nargs, naxes): +def _get_scalar_func_loopy_program( + actx: ArrayContext, c_name: str, nargs: int, naxes: int, + ) -> lp.TranslationUnit: @memoize_in(actx, _get_scalar_func_loopy_program) - def get(c_name, nargs, naxes): + def get(c_name: str, nargs: int, naxes: int) -> lp.TranslationUnit: from pymbolic.primitives import Subscript, Variable var_names = [f"i{i}" for i in range(naxes)] @@ -170,7 +175,7 @@ def sub(name: str) -> Variable | Subscript: return get(c_name, nargs, naxes) -class LoopyBasedFakeNumpyNamespace(BaseFakeNumpyNamespace): +class LoopyBasedFakeNumpyNamespace(BaseFakeNumpyNamespace, ABC): _numpy_to_c_arc_functions: ClassVar[Mapping[str, str]] = { "arcsin": "asin", "arccos": "acos", @@ -185,12 +190,15 @@ class LoopyBasedFakeNumpyNamespace(BaseFakeNumpyNamespace): _c_to_numpy_arc_functions: ClassVar[Mapping[str, str]] = {c_name: numpy_name for numpy_name, c_name in _numpy_to_c_arc_functions.items()} - def __getattr__(self, name): - def loopy_implemented_elwise_func(*args): + def __getattr__(self, name: str): + def loopy_implemented_elwise_func(*args: ArrayOrScalar) -> ArrayOrScalar: if all(np.isscalar(ary) for ary in args): - return getattr( - np, self._c_to_numpy_arc_functions.get(name, name) - )(*args) + result = getattr( + np, self._c_to_numpy_arc_functions.get(name, name) + )(*args) + + return cast("ScalarLike", result) + actx = self._array_context prg = _get_scalar_func_loopy_program(actx, c_name, nargs=len(args), naxes=len(args[0].shape)) @@ -199,8 +207,8 @@ def loopy_implemented_elwise_func(*args): return outputs["out"] if name in self._c_to_numpy_arc_functions: - raise RuntimeError(f"'{name}' in ArrayContext.np has been removed. " - f"Use '{self._c_to_numpy_arc_functions[name]}' as in numpy. ") + raise RuntimeError(f"'{name}' in ArrayContext.np has been removed: " + f"use '{self._c_to_numpy_arc_functions[name]}' (as in numpy)") # normalize to C names anyway c_name = self._numpy_to_c_arc_functions.get(name, name) From a6c4378e21219207c4224dd5e8d88d8c1fedc1fa Mon Sep 17 00:00:00 2001 From: Alexandru Fikl Date: Sat, 22 Nov 2025 20:35:44 +0200 Subject: [PATCH 6/7] ci: set python-version for ruff job --- .github/workflows/ci.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2c0ed12b..df9aaf5a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,8 +24,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v5 - - - uses: actions/setup-python@v6 + - uses: actions/setup-python@v6 + with: + python-version: '3.x' - name: "Main Script" run: | pip install ruff From d62d5f1281680b77b2e6b4cef3f4195a5d52bcd5 Mon Sep 17 00:00:00 2001 From: Alexandru Fikl Date: Sat, 22 Nov 2025 20:01:04 +0200 Subject: [PATCH 7/7] chore: update baseline --- .basedpyright/baseline.json | 652 +++++------------------------------- 1 file changed, 82 insertions(+), 570 deletions(-) diff --git a/.basedpyright/baseline.json b/.basedpyright/baseline.json index f18796ab..b2469fe4 100644 --- a/.basedpyright/baseline.json +++ b/.basedpyright/baseline.json @@ -965,14 +965,6 @@ } ], "./arraycontext/fake_numpy.py": [ - { - "code": "reportUnannotatedClassAttribute", - "range": { - "startColumn": 4, - "endColumn": 25, - "lineCount": 1 - } - }, { "code": "reportAny", "range": { @@ -997,14 +989,6 @@ "lineCount": 1 } }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 4, - "endColumn": 16, - "lineCount": 1 - } - }, { "code": "reportUnknownVariableType", "range": { @@ -1012,22 +996,6 @@ "endColumn": 59, "lineCount": 1 } - }, - { - "code": "reportUnknownVariableType", - "range": { - "startColumn": 19, - "endColumn": 27, - "lineCount": 3 - } - }, - { - "code": "reportAny", - "range": { - "startColumn": 19, - "endColumn": 36, - "lineCount": 1 - } } ], "./arraycontext/impl/jax/__init__.py": [ @@ -8785,14 +8753,6 @@ "lineCount": 1 } }, - { - "code": "reportUnknownMemberType", - "range": { - "startColumn": 15, - "endColumn": 34, - "lineCount": 1 - } - }, { "code": "reportImplicitOverride", "range": { @@ -9059,46 +9019,6 @@ } ], "./arraycontext/loopy.py": [ - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 4, - "endColumn": 26, - "lineCount": 1 - } - }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 27, - "endColumn": 33, - "lineCount": 1 - } - }, - { - "code": "reportMissingParameterType", - "range": { - "startColumn": 27, - "endColumn": 33, - "lineCount": 1 - } - }, - { - "code": "reportUnknownMemberType", - "range": { - "startColumn": 15, - "endColumn": 40, - "lineCount": 1 - } - }, - { - "code": "reportUnknownVariableType", - "range": { - "startColumn": 15, - "endColumn": 40, - "lineCount": 1 - } - }, { "code": "reportUnknownMemberType", "range": { @@ -9116,646 +9036,238 @@ } }, { - "code": "reportUnknownParameterType", + "code": "reportAttributeAccessIssue", "range": { - "startColumn": 35, - "endColumn": 39, + "startColumn": 26, + "endColumn": 37, "lineCount": 1 } }, { - "code": "reportMissingParameterType", + "code": "reportUnknownMemberType", "range": { - "startColumn": 35, - "endColumn": 39, + "startColumn": 20, + "endColumn": 32, "lineCount": 1 } }, { - "code": "reportUnknownParameterType", + "code": "reportUnknownMemberType", "range": { - "startColumn": 41, - "endColumn": 47, + "startColumn": 20, + "endColumn": 32, "lineCount": 1 } }, { - "code": "reportMissingParameterType", + "code": "reportAny", "range": { - "startColumn": 41, - "endColumn": 47, + "startColumn": 16, + "endColumn": 22, "lineCount": 1 } }, { - "code": "reportUnknownParameterType", + "code": "reportUnknownMemberType", "range": { - "startColumn": 49, - "endColumn": 54, + "startColumn": 55, + "endColumn": 68, "lineCount": 1 } }, { - "code": "reportMissingParameterType", + "code": "reportUnknownArgumentType", "range": { - "startColumn": 49, - "endColumn": 54, + "startColumn": 55, + "endColumn": 68, "lineCount": 1 } }, { - "code": "reportUnknownParameterType", + "code": "reportAttributeAccessIssue", "range": { - "startColumn": 56, - "endColumn": 61, + "startColumn": 63, + "endColumn": 68, "lineCount": 1 } }, { - "code": "reportMissingParameterType", + "code": "reportAttributeAccessIssue", "range": { - "startColumn": 56, - "endColumn": 61, + "startColumn": 63, + "endColumn": 68, "lineCount": 1 } }, { - "code": "reportUnknownArgumentType", + "code": "reportAttributeAccessIssue", "range": { - "startColumn": 22, - "endColumn": 52, + "startColumn": 63, + "endColumn": 68, "lineCount": 1 } }, { - "code": "reportUnknownArgumentType", + "code": "reportAttributeAccessIssue", "range": { - "startColumn": 22, - "endColumn": 52, + "startColumn": 63, + "endColumn": 68, "lineCount": 1 } - }, + } + ], + "./arraycontext/pytest.py": [ { - "code": "reportUnknownParameterType", + "code": "reportCallIssue", "range": { - "startColumn": 12, - "endColumn": 18, + "startColumn": 31, + "endColumn": 36, "lineCount": 1 } }, { - "code": "reportMissingParameterType", + "code": "reportCallIssue", "range": { - "startColumn": 12, - "endColumn": 18, + "startColumn": 31, + "endColumn": 36, "lineCount": 1 } }, { "code": "reportUnknownParameterType", "range": { - "startColumn": 20, - "endColumn": 25, + "startColumn": 24, + "endColumn": 28, "lineCount": 1 } }, { "code": "reportMissingParameterType", "range": { - "startColumn": 20, - "endColumn": 25, + "startColumn": 24, + "endColumn": 28, "lineCount": 1 } }, { "code": "reportUnknownParameterType", "range": { - "startColumn": 27, - "endColumn": 32, + "startColumn": 32, + "endColumn": 38, "lineCount": 1 } }, { "code": "reportMissingParameterType", "range": { - "startColumn": 27, - "endColumn": 32, + "startColumn": 32, + "endColumn": 38, "lineCount": 1 } }, { - "code": "reportUnknownArgumentType", + "code": "reportUnknownMemberType", "range": { - "startColumn": 44, - "endColumn": 49, + "startColumn": 8, + "endColumn": 25, "lineCount": 1 } }, { - "code": "reportUnknownArgumentType", + "code": "reportUnknownParameterType", "range": { - "startColumn": 45, - "endColumn": 50, + "startColumn": 24, + "endColumn": 28, "lineCount": 1 } }, { - "code": "reportUnknownArgumentType", + "code": "reportMissingParameterType", "range": { - "startColumn": 33, - "endColumn": 39, + "startColumn": 24, + "endColumn": 28, "lineCount": 1 } }, { - "code": "reportUnknownArgumentType", + "code": "reportUnknownParameterType", "range": { - "startColumn": 73, - "endColumn": 78, + "startColumn": 32, + "endColumn": 38, "lineCount": 1 } }, { - "code": "reportUnknownMemberType", + "code": "reportMissingParameterType", "range": { - "startColumn": 20, - "endColumn": 32, + "startColumn": 32, + "endColumn": 38, "lineCount": 1 } }, { "code": "reportUnknownMemberType", "range": { - "startColumn": 20, - "endColumn": 32, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 35, - "endColumn": 40, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 15, - "endColumn": 21, + "startColumn": 8, + "endColumn": 25, "lineCount": 1 } }, { - "code": "reportUnknownArgumentType", + "code": "reportUnknownParameterType", "range": { - "startColumn": 23, + "startColumn": 24, "endColumn": 28, "lineCount": 1 } }, { - "code": "reportUnknownArgumentType", + "code": "reportMissingParameterType", "range": { - "startColumn": 30, - "endColumn": 35, + "startColumn": 24, + "endColumn": 28, "lineCount": 1 } }, { - "code": "reportImplicitAbstractClass", + "code": "reportUnknownParameterType", "range": { - "startColumn": 6, - "endColumn": 34, + "startColumn": 32, + "endColumn": 38, "lineCount": 1 } }, { - "code": "reportUnknownParameterType", + "code": "reportMissingParameterType", "range": { - "startColumn": 26, - "endColumn": 30, + "startColumn": 32, + "endColumn": 38, "lineCount": 1 } }, { - "code": "reportMissingParameterType", + "code": "reportUnknownVariableType", "range": { - "startColumn": 26, - "endColumn": 30, + "startColumn": 12, + "endColumn": 19, "lineCount": 1 } }, { - "code": "reportUnknownParameterType", + "code": "reportCallIssue", "range": { - "startColumn": 43, - "endColumn": 47, + "startColumn": 24, + "endColumn": 69, "lineCount": 1 } }, { - "code": "reportMissingParameterType", - "range": { - "startColumn": 43, - "endColumn": 47, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 31, - "endColumn": 34, - "lineCount": 1 - } - }, - { - "code": "reportUnknownVariableType", - "range": { - "startColumn": 40, - "endColumn": 43, - "lineCount": 1 - } - }, - { - "code": "reportAny", - "range": { - "startColumn": 23, - "endColumn": 33, - "lineCount": 3 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 64, - "endColumn": 68, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 70, - "endColumn": 74, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 38, - "endColumn": 42, - "lineCount": 1 - } - }, - { - "code": "reportUnknownMemberType", - "range": { - "startColumn": 55, - "endColumn": 68, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 55, - "endColumn": 68, - "lineCount": 1 - } - }, - { - "code": "reportUnknownVariableType", - "range": { - "startColumn": 45, - "endColumn": 48, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 62, - "endColumn": 66, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 52, - "endColumn": 56, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 58, - "endColumn": 62, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 53, - "endColumn": 82, - "lineCount": 1 - } - } - ], - "./arraycontext/pytest.py": [ - { - "code": "reportUnusedImport", - "range": { - "startColumn": 19, - "endColumn": 27, - "lineCount": 1 - } - }, - { - "code": "reportUnannotatedClassAttribute", - "range": { - "startColumn": 4, - "endColumn": 25, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 16, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 15, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 20, - "lineCount": 1 - } - }, - { - "code": "reportUnusedImport", - "range": { - "startColumn": 19, - "endColumn": 27, - "lineCount": 1 - } - }, - { - "code": "reportUnusedImport", - "range": { - "startColumn": 19, - "endColumn": 25, - "lineCount": 1 - } - }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 24, - "endColumn": 28, - "lineCount": 1 - } - }, - { - "code": "reportMissingParameterType", - "range": { - "startColumn": 24, - "endColumn": 28, - "lineCount": 1 - } - }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 32, - "endColumn": 38, - "lineCount": 1 - } - }, - { - "code": "reportMissingParameterType", - "range": { - "startColumn": 32, - "endColumn": 38, - "lineCount": 1 - } - }, - { - "code": "reportUnusedImport", - "range": { - "startColumn": 19, - "endColumn": 22, - "lineCount": 1 - } - }, - { - "code": "reportUnknownMemberType", - "range": { - "startColumn": 8, - "endColumn": 21, - "lineCount": 1 - } - }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 24, - "endColumn": 28, - "lineCount": 1 - } - }, - { - "code": "reportMissingParameterType", - "range": { - "startColumn": 24, - "endColumn": 28, - "lineCount": 1 - } - }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 32, - "endColumn": 38, - "lineCount": 1 - } - }, - { - "code": "reportMissingParameterType", - "range": { - "startColumn": 32, - "endColumn": 38, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 20, - "lineCount": 1 - } - }, - { - "code": "reportUnusedImport", - "range": { - "startColumn": 19, - "endColumn": 22, - "lineCount": 1 - } - }, - { - "code": "reportUnusedImport", - "range": { - "startColumn": 19, - "endColumn": 25, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 16, - "lineCount": 1 - } - }, - { - "code": "reportUnknownMemberType", - "range": { - "startColumn": 8, - "endColumn": 21, - "lineCount": 1 - } - }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 24, - "endColumn": 28, - "lineCount": 1 - } - }, - { - "code": "reportMissingParameterType", - "range": { - "startColumn": 24, - "endColumn": 28, - "lineCount": 1 - } - }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 32, - "endColumn": 38, - "lineCount": 1 - } - }, - { - "code": "reportMissingParameterType", - "range": { - "startColumn": 32, - "endColumn": 38, - "lineCount": 1 - } - }, - { - "code": "reportUnknownVariableType", - "range": { - "startColumn": 12, - "endColumn": 19, - "lineCount": 1 - } - }, - { - "code": "reportCallIssue", - "range": { - "startColumn": 24, - "endColumn": 69, - "lineCount": 1 - } - }, - { - "code": "reportArgumentType", + "code": "reportArgumentType", "range": { "startColumn": 60, "endColumn": 63, "lineCount": 1 } - }, - { - "code": "reportUnknownParameterType", - "range": { - "startColumn": 14, - "endColumn": 22, - "lineCount": 1 - } - }, - { - "code": "reportMissingParameterType", - "range": { - "startColumn": 14, - "endColumn": 22, - "lineCount": 1 - } - }, - { - "code": "reportUnknownArgumentType", - "range": { - "startColumn": 16, - "endColumn": 24, - "lineCount": 1 - } - }, - { - "code": "reportUnknownMemberType", - "range": { - "startColumn": 20, - "endColumn": 47, - "lineCount": 1 - } - }, - { - "code": "reportUnknownMemberType", - "range": { - "startColumn": 16, - "endColumn": 43, - "lineCount": 1 - } - }, - { - "code": "reportUnknownMemberType", - "range": { - "startColumn": 8, - "endColumn": 28, - "lineCount": 1 - } - }, - { - "code": "reportUnknownVariableType", - "range": { - "startColumn": 11, - "endColumn": 16, - "lineCount": 1 - } } ], "./arraycontext/version.py": [