From 258f1a33b5a417408cfa015f421ecfb946cdba53 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Dec 2025 04:01:19 +0000 Subject: [PATCH 1/2] Bump pyvisa from 1.15.0 to 1.16.0 Bumps [pyvisa](https://github.com/pyvisa/pyvisa) from 1.15.0 to 1.16.0. - [Release notes](https://github.com/pyvisa/pyvisa/releases) - [Changelog](https://github.com/pyvisa/pyvisa/blob/main/ChangeLog) - [Commits](https://github.com/pyvisa/pyvisa/compare/1.15.0...1.16.0) --- updated-dependencies: - dependency-name: pyvisa dependency-version: 1.16.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- requirements.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 53e3fe9eff6..3892ab02497 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -35,7 +35,7 @@ dependencies = [ "packaging>=20.0", "pandas>=1.5.0", "pyarrow>=11.0.0", # will become a requirement of pandas. Installing explicitly silences a warning - "pyvisa>=1.11.0, <1.16.0", + "pyvisa>=1.11.0, <1.17.0", "ruamel.yaml>=0.16.0,!=0.16.6", "tabulate>=0.9.0", "typing_extensions>=4.6.0", diff --git a/requirements.txt b/requirements.txt index f8cd6d0c444..b9b0af62c4a 100644 --- a/requirements.txt +++ b/requirements.txt @@ -327,7 +327,7 @@ python-dateutil==2.9.0.post0 # pandas pytz==2025.2 # via pandas -pyvisa==1.15.0 +pyvisa==1.16.0 # via # qcodes (pyproject.toml) # pyvisa-sim From 297f8b3edc6c4c094fb496131d9401cf119f36d4 Mon Sep 17 00:00:00 2001 From: "Jens H. Nielsen" Date: Mon, 5 Jan 2026 13:03:22 +0100 Subject: [PATCH 2/2] Handle pyvisa changes in test --- tests/test_visa.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tests/test_visa.py b/tests/test_visa.py index 5f268158240..b74d607ab6f 100644 --- a/tests/test_visa.py +++ b/tests/test_visa.py @@ -148,9 +148,12 @@ def use_magnet() -> pyvisa.ResourceManager: # and the instrument should no longer be in the instrument registry assert len(Instrument._all_instruments) == 0 assert len(rm.list_opened_resources()) == 0 - assert ( - caplog.records[-1].message == "Closing VISA handle to x as there are no non " - "weak references to the instrument." + # the order of the log messages depends on the pyvisa version but regardless + # of which version we should see the message about closing the handle + assert any( + record.message + == "Closing VISA handle to x as there are no non weak references to the instrument." + for record in caplog.records )