Fix code examples#13178
Conversation
|
One or more of the following people are relevant to this code:
|
jakelishman
left a comment
There was a problem hiding this comment.
Thanks for looking at this Frank. Longer term, I think we'll want to consider when it's appropriate to show imports to users - repeating the same imports several times in quick succession over the course of a run of examples probably feels like it could get noisy quickly.
Similarly, things like import numpy as np and from qiskit.circuit import QuantumCircuit probably happen enough that if they're the only imports, or if the only import is the class/function in question (whose documentation should already clearly imply how to import it), maybe it's best not to include the noise?
Anyway, that's for the future - doesn't need thinking about right now, particularly.
Pull Request Test Coverage Report for Build 10922719194Details
💛 - Coveralls |
Co-authored-by: Jake Lishman <jake.lishman@ibm.com>
ihincks
left a comment
There was a problem hiding this comment.
Thanks @frankharkins , all of the primitive blocks look correct to me
|
The pulse changes look okay to me, but keep in mind that pulse is being moved out of this repo (#13164). |
* Fix code examples * Incorporate feedback Co-authored-by: Jake Lishman <jake.lishman@ibm.com> --------- Co-authored-by: Jake Lishman <jake.lishman@ibm.com> (cherry picked from commit cc1f30f)
Summary
Minor fixes to code examples in docstrings to make sure they run without error. Mostly adding imports and defining variables. Some syntax errors too.
These were identified as part of Qiskit/documentation#1893.