I spent weeks auditing 50 quantum circuits — line by line, gate by gate.
Most ran fine. Some didn't. But "it runs" is not the same as "it's correct."
Three bugs that taught me more than I expected:
𝟏. My H₂ VQE had a wrong Hamiltonian coefficient.
The optimizer compensated and still found approximately the right ground state energy. It gave the right answer. The Hamiltonian was wrong.
I only caught it by re-deriving from second quantization and comparing term-by-term against O'Malley et al. 2016.
𝟐. 4 out of 50 circuits broke after a dependency update.
All PennyLane. A NumPy update changed array creation semantics, and the autograd ArrayBox wrapper was rejected. A circuit that works one week can break the next.
𝟑. Qubit ordering conventions cause subtle bugs.
Qiskit uses little-endian qubit ordering. If you port code between frameworks without accounting for this, results silently change. I found it in my Phase Estimation circuit and in a 3-qubit error correction code.
Both circuits ran. Both produced output. Both were wrong.
—
Three lessons:
→ "It converges" ≠ "it's correct." Variational circuits can mask bugs.
→ Version pinning matters. Framework updates can break quantum code without warning.
→ Cross-framework comparison is a powerful debugging tool.
Full blog post publishing Monday, April 7 with all six findings.
All 50 circuits are on QubitHub: https://qubithub.co
#QuantumComputing #LearningInPublic

