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

Fix premature session closure error #608

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

takh04
Copy link

@takh04 takh04 commented Dec 9, 2024

This issue shows pennylane-qiskit session closes prematurely. Simply adding _if self.session is None: fixes the problem. The fix is tested on both IBM fake device and real devices.

Copy link

codecov bot commented Dec 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (40a4d24) to head (b15c90e).

Additional details and impacted files
@@            Coverage Diff            @@
##            master      #608   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            9         9           
  Lines          868       869    +1     
=========================================
+ Hits           868       869    +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@austingmhuang
Copy link
Contributor

austingmhuang commented Dec 17, 2024

Hi @takh04, thanks for opening this PR. The CI is failing right now because of some codefactor issue, likely because we updated our standards and this code hasn't been updated in a while. We can fix this just by appending too-many-positional-arguments to this statement # pylint: disable=too-many-instance-attributes,attribute-defined-outside-init at the top of qiskit_device.py (Line 18).

Additionally, please write a changelog entry in CHANGELOG.md in the section Bug Fixes, and add your name to the list of contributors :)

@takh04
Copy link
Author

takh04 commented Dec 17, 2024

Hi @austingmhuang, thanks for the reply! I have appended too-many-positional-arguments and added changelog entry!

CHANGELOG.md Outdated Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants