qiskit-community / qiskit-nature

Qiskit Nature is an open-source, quantum computing, framework for solving quantum mechanical natural science problems.
https://qiskit-community.github.io/qiskit-nature/
Apache License 2.0
291 stars 197 forks source link

fix: do not use `normal_order` as part of commutator methods #1299

Closed mrossinek closed 7 months ago

mrossinek commented 7 months ago

Summary

Fixes #1298

Details and comments

In #1208 we had discussed the inclusion of normal_order into the commutator methods without realizing that this breaks API. Here, I simply remove this call and update the unittests accordingly. Basically, this means that the user needs to normal-order the result themselves if needed (which is totally fine).

coveralls commented 7 months ago

Pull Request Test Coverage Report for Build 7125855649


Totals Coverage Status
Change from base Build 7083968559: 0.0%
Covered Lines: 8785
Relevant Lines: 10125

💛 - Coveralls
mrossinek commented 7 months ago

Sorry, looks like we got into a race on requesting a review and approving. Please re-approve :sweat_smile: