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

Invalidate QuantumCircuit.parameters cache on global-phase modification #11641

Merged
merged 1 commit into from
Jan 25, 2024

Conversation

jakelishman
Copy link
Member

Summary

Previously, replacing a parametric global_phase with a non-parametric global phase would modify the ParameterTable without invalidating the parameters cache that the circuit kept.

Details and comments

Fix #11640. No release note because the bug isn't released (introduced in #11428).

…tion

Previously, replacing a parametric `global_phase` with a non-parametric
global phase would modify the `ParameterTable` without invalidating the
`parameters` cache that the circuit kept.
@jakelishman jakelishman added Changelog: None Do not include in changelog mod: circuit Related to the core of the `QuantumCircuit` class or the circuit library labels Jan 25, 2024
@jakelishman jakelishman added this to the 1.0.0 milestone Jan 25, 2024
@jakelishman jakelishman requested a review from a team as a code owner January 25, 2024 16:08
@qiskit-bot
Copy link
Collaborator

One or more of the the following people are requested to review this:

  • @Qiskit/terra-core

@coveralls
Copy link

Pull Request Test Coverage Report for Build 7657261534

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.007%) to 89.532%

Totals Coverage Status
Change from base Build 7654964150: -0.007%
Covered Lines: 59543
Relevant Lines: 66505

💛 - Coveralls

@Cryoris Cryoris added this pull request to the merge queue Jan 25, 2024
Merged via the queue into Qiskit:main with commit ec859e1 Jan 25, 2024
12 checks passed
@jakelishman jakelishman deleted the fix-parameter-cache-global-phase branch January 25, 2024 19:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Changelog: None Do not include in changelog mod: circuit Related to the core of the `QuantumCircuit` class or the circuit library
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Circuit parameters are not cleared via global_phase setter
4 participants