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

Extend deprecation of QuantumCircuit.duration and DAGCircuit.duration #13960

Merged
merged 1 commit into from
Mar 5, 2025

Conversation

mtreinish
Copy link
Member

Summary

Since we're unlikely to be able to include these removals as part of Qiskit 2.0.0 given the dependencies on them and that the removals are not critical for any work we have in the 2.x series this commit opts to just update the deprecation message to say the removal will occur in Qiskit 3.0.0 not 2.0.0 like was originally planned.

Details and comments

Since we're unlikely to be able to include these removals as part of
Qiskit 2.0.0 given the dependencies on them and that the removals are
not critical for any work we have in the 2.x series this commit opts to
just update the deprecation message to say the removal will occur in
Qiskit 3.0.0 not 2.0.0 like was originally planned.
@mtreinish mtreinish added priority: high Changelog: Deprecation Include in "Deprecated" section of changelog labels Mar 5, 2025
@mtreinish mtreinish added this to the 2.0.0 milestone Mar 5, 2025
@mtreinish mtreinish requested a review from a team as a code owner March 5, 2025 12:33
@qiskit-bot
Copy link
Collaborator

One or more of the following people are relevant to this code:

  • @Qiskit/terra-core

@coveralls
Copy link

Pull Request Test Coverage Report for Build 13676091912

Details

  • 4 of 4 (100.0%) changed or added relevant lines in 2 files are covered.
  • 3 unchanged lines in 1 file lost coverage.
  • Overall coverage remained the same at 87.154%

Files with Coverage Reduction New Missed Lines %
crates/qasm2/src/lex.rs 3 91.98%
Totals Coverage Status
Change from base Build 13675663441: 0.0%
Covered Lines: 76599
Relevant Lines: 87889

💛 - Coveralls

Copy link
Contributor

@alexanderivrii alexanderivrii left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Just one minor question about the release notes: we are suggesting to use :meth:.QuantumCircuit.estimate_duration for DAGCircuits as well?

@mtreinish
Copy link
Member Author

LGTM! Just one minor question about the release notes: we are suggesting to use :meth:.QuantumCircuit.estimate_duration for DAGCircuits as well?

We are as the method isn't publicly exposed for DAGCircuit we could add it because it's actually internally operating on a dag, but at the time we added estimate_duration it was only really thought of as being useful for a circuit post-transpilation. We can look at adding it to DAGCircuit in 2.1, I'll open an issue to discuss/track this.

@mtreinish
Copy link
Member Author

Actually I remember now it wasn't straightforward to add it to DAGCircuit. The issue is that DAGCircuit is in the circuit crate and Target is in the accelerate crate. We need both objects for estimate_duration and I couldn't add a dependency in circuit on accelerate because accelerate depends on circuit. So I added it as a standalone function in accelerate: https://github.com/Qiskit/qiskit/blob/main/crates/accelerate/src/circuit_duration.rs and the method is added in Python. This is not trivial to do for DAGCircuit because it is all written in rust right now so I can't just add a method in Python space.

@alexanderivrii alexanderivrii enabled auto-merge March 5, 2025 14:31
@alexanderivrii alexanderivrii added this pull request to the merge queue Mar 5, 2025
Merged via the queue into Qiskit:main with commit bad3be0 Mar 5, 2025
20 checks passed
@mtreinish mtreinish deleted the extend-deprecation-duration branch March 5, 2025 15:50
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 priority: high
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants