Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hotfixes #70

Merged
merged 20 commits into from
Feb 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
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 .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install coverage pytest pytest-cases pytest-mock pytest-qt pytest-xvfb
pip install coverage pytest==7.4.4 pytest-cases pytest-mock pytest-qt pytest-xvfb
- name: Install package
run: python -m pip install -e .
- name: Test with pytest
Expand Down
2 changes: 1 addition & 1 deletion src/qumada/instrument/mapping/QDevil/qdac.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def ramp(
raise Exception("Maximum length of rampable parameters is 8.")

# check, if all parameters are from the same instrument
instruments = [parameter.root_instrument for parameter in parameters]
instruments = {parameter.root_instrument for parameter in parameters}
if len(instruments) > 1:
raise Exception("Parameters are from more than one instrument. This would lead to non synchronized ramps.")

Expand Down
18 changes: 10 additions & 8 deletions src/qumada/measurement/doNd_enhanced/doNd_enhanced.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,16 @@
_register_actions,
_register_parameters,
_set_write_period,
catch_interrupts,
)

try:
from qcodes.dataset.dond.do_nd_utils import _catch_interrupts
except ImportError:
from qcodes.dataset.dond.do_nd_utils import catch_interrupts as _catch_interrupts

from qcodes.dataset.experiment_container import Experiment
from qcodes.dataset.measurements import Measurement
from qcodes.dataset.threading import (
SequentialParamsCaller,
ThreadPoolParamsCaller,
from qcodes.dataset.threading import ( # SequentialParamsCaller,; ThreadPoolParamsCaller,
process_params_meas,
)
from qcodes.parameters import ParameterBase
Expand Down Expand Up @@ -176,12 +179,12 @@
if use_threads is None:
use_threads = config.dataset.use_threads

param_meas_caller = ThreadPoolParamsCaller(*param_meas) if use_threads else SequentialParamsCaller(*param_meas)
tracked_setpoints = list()
# do1D enforces a simple relationship between measured parameters
# and set parameters. For anything more complicated this should be
# reimplemented from scratch
with catch_interrupts() as interrupted, meas.run() as datasaver, param_meas_caller as call_param_meas: # noqa: F841

with _catch_interrupts() as interrupted, meas.run() as datasaver:

Check warning on line 187 in src/qumada/measurement/doNd_enhanced/doNd_enhanced.py

View check run for this annotation

Codecov / codecov/patch

src/qumada/measurement/doNd_enhanced/doNd_enhanced.py#L187

Added line #L187 was not covered by tests
dataset = datasaver.dataset
additional_setpoints_data = process_params_meas(additional_setpoints)

Expand Down Expand Up @@ -340,12 +343,11 @@
if use_threads is None:
use_threads = config.dataset.use_threads

param_meas_caller = ThreadPoolParamsCaller(*param_meas) if use_threads else SequentialParamsCaller(*param_meas)
tracked_setpoints = list([] for _ in param_set)
# do1D enforces a simple relationship between measured parameters
# and set parameters. For anything more complicated this should be
# reimplemented from scratch
with catch_interrupts() as interrupted, meas.run() as datasaver, param_meas_caller as call_param_meas: # noqa: F841
with _catch_interrupts() as interrupted, meas.run() as datasaver:

Check warning on line 350 in src/qumada/measurement/doNd_enhanced/doNd_enhanced.py

View check run for this annotation

Codecov / codecov/patch

src/qumada/measurement/doNd_enhanced/doNd_enhanced.py#L350

Added line #L350 was not covered by tests
dataset = datasaver.dataset
additional_setpoints_data = process_params_meas(additional_setpoints)

Expand Down
2 changes: 2 additions & 0 deletions src/qumada/measurement/scripts/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@
# Only relevant if you want to use spectrometer.
# Requires access to Bluhm Group GitLab
pass
except ImportError:
pass

Check warning on line 42 in src/qumada/measurement/scripts/__init__.py

View check run for this annotation

Codecov / codecov/patch

src/qumada/measurement/scripts/__init__.py#L41-L42

Added lines #L41 - L42 were not covered by tests

__all__ = [
"Generic_1D_Sweep",
Expand Down
Loading