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

Make MockFidelity also compatible with Qiskit Algorithms >= 0.3.0 #761

Merged
merged 3 commits into from
Feb 7, 2024

Conversation

woodsp-ibm
Copy link
Member

Summary

Fixes #729

The BaseStateFidelity was changed in qiskit algorithms as to the type _run returns in order to fix a threading problem. See the above issue this fixes for more information and a link to PR done in algorithms for further detail. This updates the MockFidelity so the test using it works with the current release of algorithms at this time (0.2.2.), so CI passes now, and will work when algorithms releases a new version (0.3.0), which I tested locally but will not go through that path here in CI until that happens. On the slim chance it does not work (despite it working for me the altered code from algorithms main branch) then this can always be tweaked - without this change its guaranteed to fail!

Details and comments

I noted in a comment by the change that in the future we can choose to remove present logic in the path that tests current versions as this will no longer be needed.

I marked this as backport in order to keep stable CI passing when the new algs come out.

@woodsp-ibm woodsp-ibm added stable backport potential The bug might be minimal and/or import enough to be port to stable type: ci 🔧 Related to Continuous Integration workflows labels Feb 7, 2024
@coveralls
Copy link

Pull Request Test Coverage Report for Build 7816289214

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 92.567%

Totals Coverage Status
Change from base Build 7733010920: 0.0%
Covered Lines: 1868
Relevant Lines: 2018

💛 - Coveralls

@woodsp-ibm woodsp-ibm merged commit ce24989 into qiskit-community:main Feb 7, 2024
15 checks passed
@woodsp-ibm woodsp-ibm deleted the fix_fidelity_test branch February 7, 2024 15:01
mergify bot pushed a commit that referenced this pull request Feb 7, 2024
* Make MockFidelity also compatible with Qiskit Algorithms >= 0.3.0

* Run black on the changed file

(cherry picked from commit ce24989)
mergify bot added a commit that referenced this pull request Feb 7, 2024
…) (#762)

* Make MockFidelity also compatible with Qiskit Algorithms >= 0.3.0

* Run black on the changed file

(cherry picked from commit ce24989)

Co-authored-by: Steve Wood <[email protected]>
oscar-wallis pushed a commit that referenced this pull request Feb 16, 2024
* Make MockFidelity also compatible with Qiskit Algorithms >= 0.3.0

* Run black on the changed file
@woodsp-ibm woodsp-ibm mentioned this pull request Feb 21, 2024
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stable backport potential The bug might be minimal and/or import enough to be port to stable type: ci 🔧 Related to Continuous Integration workflows
Projects
None yet
Development

Successfully merging this pull request may close these issues.

MockFidelity in test_fidelity_qkernel incompatibility
4 participants