Conversation
|
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:
|
qiskit/utils/mitigation/_filters.py
Outdated
| return self._cal_matrix | ||
|
|
||
| @cal_matrix.setter | ||
| def cal_matrix(self, new_cal_matrix): |
There was a problem hiding this comment.
Is there a reason why this method definition is moved here? Looks like a merge conflict due to an old code to me.
There was a problem hiding this comment.
The reason is this: python/mypy#1465
It may be better just to leave a comment since its a mypy bug, but the change is cheap, so I just went for it (admittedly, I did it before I found out it was a bug)
03fadc0 to
2ed4b7d
Compare
Pull Request Test Coverage Report for Build 5079651444
💛 - Coveralls |
| ) -> tuple[str, Type[DeprecationWarning] | Type[PendingDeprecationWarning]]: | ||
| if pending: | ||
| category = PendingDeprecationWarning | ||
| category: Type[DeprecationWarning] | Type[ |
There was a problem hiding this comment.
I think it would be clearer to declare the type for category before the if pending line.
qiskit/utils/mitigation/_filters.py
Outdated
| additional_msg="For code migration guidelines, visit https://qisk.it/qi_migration.", | ||
| ) | ||
| def __init__(self, cal_matrices: np.matrix, substate_labels_list: list, mit_pattern: list): | ||
| def __init__(self, cal_matrices: np.matrix, substate_labels_list: list[str], mit_pattern: list): |
There was a problem hiding this comment.
The docstring indicates that it's not just a list of strings:
a list of the states (as strings, states in the subspace)
There was a problem hiding this comment.
As far as I understand this means "as strings (states in the subspace)" not "as strings or states in the subspace"
|
Except for |
Summary
Following discussion, I'm splitting #8187 by module.
Details and comments
I've moved a setter and getter to be one after another (as per python/mypy#1465)
The are ~40 errors left:
All error list
Large chunk of errors is due to
Backend/Jobnot having properties. There is also set of errors due to casting inqiskit/utils/mitigation/circuits.py