Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ test = [
"hypothesis>=6.130.0",
"lxml>=4.9.4",
"lxml-stubs>=0.4.0",
"mypy>=1.16.0",
"mypy>=1.20.0",
"pandas-stubs>=1.2.0.1",
"pytest>=8.2.0",
"pytest-asyncio>=0.24.0",
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ matplotlib-inline==0.2.1
# ipython
mistune==3.2.0
# via nbconvert
mypy==1.19.1
mypy==1.20.0
# via qcodes (pyproject.toml)
mypy-extensions==1.1.0
# via mypy
Expand Down
6 changes: 3 additions & 3 deletions src/qcodes/extensions/infer.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from __future__ import annotations

from collections.abc import Sequence
from typing import TYPE_CHECKING, ClassVar, TypeVar, cast
from typing import TYPE_CHECKING, ClassVar, TypeVar

from qcodes.instrument import Instrument, InstrumentBase, InstrumentModule
from qcodes.parameters import DelegateParameter, Parameter, ParameterBase
Expand Down Expand Up @@ -230,7 +230,7 @@ def get_chain_links_of_type(
) -> tuple[C, ...]:
"""Gets all parameters in a chain of linked parameters that match a given type"""
chain_links: list[C] = [
cast("C", param)
param
for param in get_parameter_chain(parameter)
if isinstance(param, link_param_type)
]
Expand Down Expand Up @@ -265,7 +265,7 @@ def get_parent_instruments_from_chain_of_type(
param_chain = get_parameter_chain(parameter)
return tuple(
[
cast("TInstrument", param.instrument)
param.instrument
for param in param_chain
if isinstance(param.instrument, instrument_type)
]
Expand Down
4 changes: 2 additions & 2 deletions src/qcodes/instrument_drivers/AlazarTech/dll_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,10 +179,10 @@ def __apply_signatures(self) -> None:
if ret_type is RETURN_CODE:
# since RETURN_CODE is a NewType checking that
# ret_type is RETURN_CODE only narrows the type
# of it to type. The type checker therefor does not know
# of it to type. The type checker therefore does not know
# that this type has a __supertype__ attribute
ret_type = (
ret_type.__supertype__ # pyright: ignore[reportFunctionMemberAccess]
ret_type.__supertype__ # type: ignore[attr-defined]
)
c_func.errcheck = _check_error_code
elif ret_type in (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,7 @@ def clear_timer_count(self) -> None:

class StatusMixin:
def __init__(self) -> None:
self.names = tuple(["param1", "param2"])
self.names: tuple[str, ...] = ("param1", "param2")

def status_summary(self) -> dict[str, str]:
return_dict: dict[str, str] = {}
Expand Down
Loading