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

Increase tolerance for a flaky test (test_single_return_value) #703

Merged
merged 6 commits into from
Apr 29, 2024
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
3 changes: 3 additions & 0 deletions .github/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,9 @@
* Update the version of `codecov-action` to v4 and fix the CodeCov issue with the PL-Lightning check-compatibility actions.
[(#682)](https://github.com/PennyLaneAI/pennylane-lightning/pull/682)

* Increase tolerance for a flaky test.
[(#703)](https://github.com/PennyLaneAI/pennylane-lightning/pull/703)

### Contributors

This release contains contributions from (in alphabetical order):
Expand Down
2 changes: 1 addition & 1 deletion pennylane_lightning/core/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@
Version number (major.minor.patch[-label])
"""

__version__ = "0.36.0-dev44"
__version__ = "0.36.0-dev45"
2 changes: 1 addition & 1 deletion tests/lightning_qubit/test_measurements_class.py
Original file line number Diff line number Diff line change
Expand Up @@ -474,7 +474,7 @@ def test_single_return_value(self, measurement, observable, lightning_sv, tol):
result = m.measure_final_state(tape)

# a few tests may fail in single precision, and hence we increase the tolerance
assert np.allclose(result, expected, max(tol, 1.0e-5))
assert np.allclose(result, expected, max(tol, 1.0e-4))

@flaky(max_runs=5)
@pytest.mark.parametrize("shots", [None, 1000000])
Expand Down
Loading