Skip to content

Feature/sensor compensation #221

Feature/sensor compensation

Feature/sensor compensation #221

GitHub Actions / Test Results failed May 27, 2024 in 0s

2 errors, 1 fail, 22 pass in 6s

 3 files   3 suites   6s ⏱️
25 tests 22 ✅ 0 💤 1 ❌ 2 🔥
75 runs  66 ✅ 0 💤 3 ❌ 6 🔥

Results for commit d973db0.

Annotations

Check failure on line 0 in src.tests.mapping_test

See this annotation in the file changed.

@github-actions github-actions / Test Results

All 3 runs with error: test_save_mapped_terminal_parameters (src.tests.mapping_test)

artifacts/pytest-results-3.10/test-results.xml [took 0s]
artifacts/pytest-results-3.11/test-results.xml [took 0s]
artifacts/pytest-results-3.9/test-results.xml [took 0s]
Raw output
failed on setup with "AttributeError: 'DummyDac' object and its delegates have no attribute 'voltage'"
station_with_instruments = <qcodes.station.Station object at 0x7fbefc518490>

    @pytest.fixture(name="mapped_terminal_parameters")
    def fixture_mapped_terminal_parameters(station_with_instruments):  # valid for given fixture_station_with_instruments
        terminal_params = {
            "dmm": {"voltage": station_with_instruments.dmm.voltage, "current": station_with_instruments.dmm.current},
>           "dac": {"voltage": station_with_instruments.dac.voltage},
            "T1": {"test_parameter": station_with_instruments.dci.A.temperature},
            "T2": {"test_parameter": station_with_instruments.dci.B.temperature},
        }

src/tests/mapping_test.py:123: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <DummyDac: dac>, key = 'voltage'

    def __getattr__(self, key: str) -> Any:
        if key in self.omit_delegate_attrs:
            raise AttributeError(
                f"'{self.__class__.__name__}' does not delegate attribute {key}"
            )
    
        for name in self.delegate_attr_dicts:
            if key == name:
                # needed to prevent infinite loops!
                raise AttributeError(
                    f"dict '{key}' has not been created in object '{self.__class__.__name__}'"
                )
            try:
                d = getattr(self, name, None)
                if d is not None:
                    return d[key]
            except KeyError:
                pass
    
        for name in self.delegate_attr_objects:
            if key == name:
                raise AttributeError(
                    f"object '{key}' has not been created in object '{self.__class__.__name__}'"
                )
            try:
                obj = getattr(self, name, None)
                if obj is not None:
                    return getattr(obj, key)
            except AttributeError:
                pass
    
>       raise AttributeError(
            f"'{self.__class__.__name__}' object and its delegates have no attribute '{key}'"
        )
E       AttributeError: 'DummyDac' object and its delegates have no attribute 'voltage'

/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/qcodes/utils/attribute_helpers.py:71: AttributeError

Check failure on line 0 in src.tests.mapping_test

See this annotation in the file changed.

@github-actions github-actions / Test Results

All 3 runs with error: test_load_mapped_terminal_parameters (src.tests.mapping_test)

artifacts/pytest-results-3.10/test-results.xml [took 0s]
artifacts/pytest-results-3.11/test-results.xml [took 0s]
artifacts/pytest-results-3.9/test-results.xml [took 0s]
Raw output
failed on setup with "AttributeError: 'DummyDac' object and its delegates have no attribute 'voltage'"
station_with_instruments = <qcodes.station.Station object at 0x7fbefc518490>

    @pytest.fixture(name="mapped_terminal_parameters")
    def fixture_mapped_terminal_parameters(station_with_instruments):  # valid for given fixture_station_with_instruments
        terminal_params = {
            "dmm": {"voltage": station_with_instruments.dmm.voltage, "current": station_with_instruments.dmm.current},
>           "dac": {"voltage": station_with_instruments.dac.voltage},
            "T1": {"test_parameter": station_with_instruments.dci.A.temperature},
            "T2": {"test_parameter": station_with_instruments.dci.B.temperature},
        }

src/tests/mapping_test.py:123: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <DummyDac: dac>, key = 'voltage'

    def __getattr__(self, key: str) -> Any:
        if key in self.omit_delegate_attrs:
            raise AttributeError(
                f"'{self.__class__.__name__}' does not delegate attribute {key}"
            )
    
        for name in self.delegate_attr_dicts:
            if key == name:
                # needed to prevent infinite loops!
                raise AttributeError(
                    f"dict '{key}' has not been created in object '{self.__class__.__name__}'"
                )
            try:
                d = getattr(self, name, None)
                if d is not None:
                    return d[key]
            except KeyError:
                pass
    
        for name in self.delegate_attr_objects:
            if key == name:
                raise AttributeError(
                    f"object '{key}' has not been created in object '{self.__class__.__name__}'"
                )
            try:
                obj = getattr(self, name, None)
                if obj is not None:
                    return getattr(obj, key)
            except AttributeError:
                pass
    
>       raise AttributeError(
            f"'{self.__class__.__name__}' object and its delegates have no attribute '{key}'"
        )
E       AttributeError: 'DummyDac' object and its delegates have no attribute 'voltage'

/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/qcodes/utils/attribute_helpers.py:71: AttributeError

Check warning on line 0 in src.tests.mapping_test

See this annotation in the file changed.

@github-actions github-actions / Test Results

All 3 runs failed: test_mapping_gui_map_automatically (src.tests.mapping_test)

artifacts/pytest-results-3.10/test-results.xml [took 0s]
artifacts/pytest-results-3.11/test-results.xml [took 0s]
artifacts/pytest-results-3.9/test-results.xml [took 0s]
Raw output
AttributeError: 'DummyDac' object and its delegates have no attribute 'voltage'
mocker = <pytest_mock.plugin.MockerFixture object at 0x7fbefc287fd0>
qtbot = <pytestqt.qtbot.QtBot object at 0x7fbefc2a9ad0>
station_with_instruments = <qcodes.station.Station object at 0x7fbefc518490>
script = <qumada.measurement.scripts.generic_measurement.Generic_1D_Sweep object at 0x7fbefc2abfd0>

    def test_mapping_gui_map_automatically(mocker, qtbot, station_with_instruments, script):
        # mock dialogs (specify behaviour in return_value and skip)
        mocker.patch("qumada.instrument.mapping.mapping_gui.MessageBox_notallmapped.exec", return_value=QMessageBox.No)
        mocker.patch("qumada.instrument.mapping.mapping_gui.MessageBox_duplicates.exec", return_value=QMessageBox.No)
        mocker.patch("qumada.instrument.mapping.mapping_gui.MessageBox_overwrite.exec", return_value=QMessageBox.No)
    
        w = MainWindow(
            station_with_instruments.components,
            script.gate_parameters,
        )
        w.show()
        qtbot.addWidget(w)
    
        # wanted mapping
        terminal_params = {
            "dmm": {"voltage": station_with_instruments.dmm.voltage, "current": station_with_instruments.dmm.current},
>           "dac": {"voltage": station_with_instruments.dac.voltage},
            "T1": {"test_parameter": station_with_instruments.dci.A.temperature},
            "T2": {"test_parameter": station_with_instruments.dci.B.temperature},
        }

src/tests/mapping_test.py:384: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <DummyDac: dac>, key = 'voltage'

    def __getattr__(self, key: str) -> Any:
        if key in self.omit_delegate_attrs:
            raise AttributeError(
                f"'{self.__class__.__name__}' does not delegate attribute {key}"
            )
    
        for name in self.delegate_attr_dicts:
            if key == name:
                # needed to prevent infinite loops!
                raise AttributeError(
                    f"dict '{key}' has not been created in object '{self.__class__.__name__}'"
                )
            try:
                d = getattr(self, name, None)
                if d is not None:
                    return d[key]
            except KeyError:
                pass
    
        for name in self.delegate_attr_objects:
            if key == name:
                raise AttributeError(
                    f"object '{key}' has not been created in object '{self.__class__.__name__}'"
                )
            try:
                obj = getattr(self, name, None)
                if obj is not None:
                    return getattr(obj, key)
            except AttributeError:
                pass
    
>       raise AttributeError(
            f"'{self.__class__.__name__}' object and its delegates have no attribute '{key}'"
        )
E       AttributeError: 'DummyDac' object and its delegates have no attribute 'voltage'

/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/qcodes/utils/attribute_helpers.py:71: AttributeError