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

Removing consider-using-enumerate from lint exclusions and updates #12286

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

joesho112358
Copy link
Contributor

Summary

#9614 - removing consider-using-enumerate

Details and comments

Updates for removing this rule if wanted. Open to suggestions on variable names

@qiskit-bot qiskit-bot added the Community PR PRs from contributors that are not 'members' of the Qiskit repo label Apr 20, 2024
@coveralls
Copy link

coveralls commented Apr 20, 2024

Pull Request Test Coverage Report for Build 9080728698

Details

  • 17 of 20 (85.0%) changed or added relevant lines in 6 files are covered.
  • 9 unchanged lines in 3 files lost coverage.
  • Overall coverage increased (+0.01%) to 89.618%

Changes Missing Coverage Covered Lines Changed/Added Lines %
qiskit/visualization/bloch.py 5 6 83.33%
qiskit/circuit/library/arithmetic/piecewise_polynomial_pauli_rotations.py 0 2 0.0%
Files with Coverage Reduction New Missed Lines %
qiskit/visualization/bloch.py 1 49.83%
crates/qasm2/src/lex.rs 2 92.62%
crates/qasm2/src/parse.rs 6 96.69%
Totals Coverage Status
Change from base Build 9080271824: 0.01%
Covered Lines: 62297
Relevant Lines: 69514

💛 - Coveralls

@joesho112358 joesho112358 marked this pull request as ready for review April 21, 2024 13:01
@qiskit-bot
Copy link
Collaborator

Thank you for opening a new pull request.

Before your PR can be merged it will first need to pass continuous integration tests and be reviewed. Sometimes the review process can be slow, so please be patient.

While you're waiting, please feel free to review other open PRs. While only a subset of people are authorized to approve pull requests for merging, everyone is encouraged to review open pull requests. Doing reviews helps reduce the burden on the core team and helps make the project's code better for everyone.

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

@joesho112358
Copy link
Contributor Author

@mtreinish as a heads up, the latest commit probably needs your eyes. specifically in the passmanager.py file. i made a change there that i think is in line with the intention, although a bit weird in implementation.

Comment on lines 122 to 125
original_qubits_reverse = {v: k for k, v in original_qubit_indices.items()}
original_qubits = []
for i in range(len(original_qubits_reverse)):
original_qubits.append(original_qubits_reverse[i])
for v, k in original_qubits_reverse.items():
original_qubits.append(k)
Copy link
Member

Choose a reason for hiding this comment

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

This looks like a behavioural change to me. Dictionary iteration order is insertion order, but the previous form was specifically looking up in numerical order of the v items.

The vs are ints here (from 0 to n-1) and the k are Qubit instances.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ah, i see it now. ok, i'll have to update this

@joesho112358 joesho112358 marked this pull request as draft May 10, 2024 16:12
@joesho112358 joesho112358 marked this pull request as ready for review May 13, 2024 02:53
@qiskit-bot
Copy link
Collaborator

Thank you for opening a new pull request.

Before your PR can be merged it will first need to pass continuous integration tests and be reviewed. Sometimes the review process can be slow, so please be patient.

While you're waiting, please feel free to review other open PRs. While only a subset of people are authorized to approve pull requests for merging, everyone is encouraged to review open pull requests. Doing reviews helps reduce the burden on the core team and helps make the project's code better for everyone.

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Community PR PRs from contributors that are not 'members' of the Qiskit repo
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

None yet

4 participants