diff --git a/.basedpyright/baseline.json b/.basedpyright/baseline.json index b944bc22..43b9e8e8 100644 --- a/.basedpyright/baseline.json +++ b/.basedpyright/baseline.json @@ -857,94 +857,6 @@ "lineCount": 1 } }, - { - "code": "reportUnannotatedClassAttribute", - "range": { - "startColumn": 4, - "endColumn": 14, - "lineCount": 1 - } - }, - { - "code": "reportIncompatibleMethodOverride", - "range": { - "startColumn": 4, - "endColumn": 14, - "lineCount": 1 - } - }, - { - "code": "reportAssignmentType", - "range": { - "startColumn": 17, - "endColumn": 37, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 16, - "lineCount": 1 - } - }, - { - "code": "reportUnannotatedClassAttribute", - "range": { - "startColumn": 4, - "endColumn": 14, - "lineCount": 1 - } - }, - { - "code": "reportIncompatibleMethodOverride", - "range": { - "startColumn": 4, - "endColumn": 14, - "lineCount": 1 - } - }, - { - "code": "reportAssignmentType", - "range": { - "startColumn": 17, - "endColumn": 43, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 16, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 16, - "lineCount": 1 - } - }, - { - "code": "reportUnannotatedClassAttribute", - "range": { - "startColumn": 4, - "endColumn": 14, - "lineCount": 1 - } - }, - { - "code": "reportImplicitOverride", - "range": { - "startColumn": 8, - "endColumn": 16, - "lineCount": 1 - } - }, { "code": "reportUnknownMemberType", "range": { @@ -1232,6 +1144,62 @@ "endColumn": 38, "lineCount": 1 } + }, + { + "code": "reportUnknownMemberType", + "range": { + "startColumn": 45, + "endColumn": 35, + "lineCount": 5 + } + }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 45, + "endColumn": 49, + "lineCount": 5 + } + }, + { + "code": "reportUnknownParameterType", + "range": { + "startColumn": 4, + "endColumn": 10, + "lineCount": 1 + } + }, + { + "code": "reportUnknownMemberType", + "range": { + "startColumn": 11, + "endColumn": 23, + "lineCount": 4 + } + }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 11, + "endColumn": 37, + "lineCount": 4 + } + }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 4, + "endColumn": 10, + "lineCount": 1 + } + }, + { + "code": "reportUnknownMemberType", + "range": { + "startColumn": 13, + "endColumn": 56, + "lineCount": 1 + } } ], "./grudge/interpolation.py": [ @@ -1583,6 +1551,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 4, + "endColumn": 10, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -1615,6 +1591,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 31, + "endColumn": 37, + "lineCount": 1 + } + }, { "code": "reportUnknownVariableType", "range": { @@ -2007,6 +1991,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 8, + "endColumn": 14, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -2039,6 +2031,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 38, + "endColumn": 44, + "lineCount": 1 + } + }, { "code": "reportUnknownMemberType", "range": { @@ -3431,6 +3431,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 4, + "endColumn": 10, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -4953,6 +4961,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 8, + "endColumn": 14, + "lineCount": 1 + } + }, { "code": "reportUnknownMemberType", "range": { @@ -5641,6 +5657,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 8, + "endColumn": 21, + "lineCount": 1 + } + }, { "code": "reportArgumentType", "range": { @@ -7427,6 +7451,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 8, + "endColumn": 12, + "lineCount": 1 + } + }, { "code": "reportUnknownVariableType", "range": { @@ -7531,6 +7563,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 79, + "endColumn": 83, + "lineCount": 1 + } + }, { "code": "reportMissingParameterType", "range": { @@ -7739,6 +7779,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 4, + "endColumn": 10, + "lineCount": 1 + } + }, { "code": "reportUnknownVariableType", "range": { @@ -8333,6 +8381,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 8, + "endColumn": 14, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -8373,6 +8429,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 30, + "endColumn": 36, + "lineCount": 1 + } + }, { "code": "reportUnknownMemberType", "range": { @@ -8413,6 +8477,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 41, + "endColumn": 47, + "lineCount": 1 + } + }, { "code": "reportUnknownMemberType", "range": { @@ -8637,6 +8709,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 8, + "endColumn": 18, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -8701,6 +8781,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 42, + "endColumn": 52, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -8717,6 +8805,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 35, + "endColumn": 45, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -9525,6 +9621,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 8, + "endColumn": 14, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -9597,6 +9701,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 46, + "endColumn": 52, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -9677,6 +9789,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 37, + "endColumn": 43, + "lineCount": 1 + } + }, { "code": "reportUnknownMemberType", "range": { @@ -10061,6 +10181,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownVariableType", + "range": { + "startColumn": 8, + "endColumn": 18, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -10221,6 +10349,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 43, + "endColumn": 53, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { @@ -10237,6 +10373,14 @@ "lineCount": 1 } }, + { + "code": "reportUnknownArgumentType", + "range": { + "startColumn": 35, + "endColumn": 45, + "lineCount": 1 + } + }, { "code": "reportUnknownArgumentType", "range": { diff --git a/grudge/array_context.py b/grudge/array_context.py index 583d2bb9..68b3374c 100644 --- a/grudge/array_context.py +++ b/grudge/array_context.py @@ -534,8 +534,12 @@ class MPIFusionContractorArrayContext( class PytestPyOpenCLArrayContextFactory( _PytestPyOpenCLArrayContextFactoryWithClass): - actx_class = PyOpenCLArrayContext + @property + @override + def actx_class(self) -> type[PyOpenCLArrayContext]: + return PyOpenCLArrayContext + @override def __call__(self): from pyopencl.tools import ImmediateAllocator, MemoryPool @@ -547,8 +551,12 @@ def __call__(self): class PytestPytatoPyOpenCLArrayContextFactory( _PytestPytatoPyOpenCLArrayContextFactory): - actx_class = PytatoPyOpenCLArrayContext + @property + @override + def actx_class(self) -> type[PytatoPyOpenCLArrayContext]: + return PytatoPyOpenCLArrayContext + @override def __call__(self): _ctx, queue = self.get_command_queue() @@ -561,13 +569,15 @@ def __call__(self): class PytestNumpyArrayContextFactory(_PytestNumpyArrayContextFactory): actx_class: ClassVar[type[NumpyArrayContext]] = NumpyArrayContext + @override def __call__(self): return self.actx_class() class PytestPytatoJAXArrayContextFactory(_PytestPytatoJaxArrayContextFactory): - actx_class = PytatoJAXArrayContext + actx_class: ClassVar[type[PytatoJAXArrayContext]] = PytatoJAXArrayContext + @override def __call__(self): import jax jax.config.update("jax_enable_x64", True)