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

Deprecate returning JobStatus in RuntimeJob #1933

Merged
merged 5 commits into from
Sep 23, 2024

Conversation

kt474
Copy link
Member

@kt474 kt474 commented Sep 18, 2024

Summary

Details and comments

Fixes #

@kt474 kt474 added the Changelog: Deprecation Include in Deprecated section of changelog label Sep 18, 2024
@kt474 kt474 added this to the 0.30.0 milestone Sep 18, 2024
@jyu00
Copy link
Collaborator

jyu00 commented Sep 19, 2024

We should make sure internal calls to status() don't surface this deprecation warning. For example, job.logs() calls job.status() under the cover, but that call shouldn't surface this warning.

Also issuing the warning once is probably good enough. It'd be excessive if someone is using job.status() in a loop to poll for status lol.

@kt474
Copy link
Member Author

kt474 commented Sep 20, 2024

We should make sure internal calls to status() don't surface this deprecation warning. For example, job.logs() calls job.status() under the cover, but that call shouldn't surface this warning.

With a stack level of 2, other internal calls to status() don't show the deprecation warning

Also issuing the warning once is probably good enough. It'd be excessive if someone is using job.status() in a loop to poll for status lol.

Python deprecation warnings are only shown once per session for a specific call, so looping job.status() only shows the warning once

@kt474 kt474 merged commit 936a5e6 into Qiskit:main Sep 23, 2024
18 checks passed
@kt474 kt474 deleted the deprecate-jobstatus branch September 23, 2024 17:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Changelog: Deprecation Include in Deprecated section of changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants