-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Gateset: Invalid repr if the gateset is empty #5197
Labels
area/gatesets
kind/bug-report
Something doesn't seem to work.
triage/accepted
A consensus emerged that this bug report, feature request, or other action should be worked on
Comments
verult
added
triage/discuss
Needs decision / discussion, bring these up during Cirq Cynque
kind/bug-report
Something doesn't seem to work.
time/before-1.0
labels
Apr 5, 2022
MichaelBroughton
added
triage/accepted
A consensus emerged that this bug report, feature request, or other action should be worked on
and removed
triage/discuss
Needs decision / discussion, bring these up during Cirq Cynque
labels
Apr 6, 2022
tanujkhattar
added
triage/discuss
Needs decision / discussion, bring these up during Cirq Cynque
and removed
triage/discuss
Needs decision / discussion, bring these up during Cirq Cynque
labels
Apr 6, 2022
We should fix this. |
CirqBot
pushed a commit
that referenced
this issue
May 2, 2022
CirqBot
pushed a commit
that referenced
this issue
May 9, 2022
Part of #5050 * Implemented qubit set, qubit pairs, and op validation. Gateset and gate duration will be done in a follow-up. * Added a `device_specification_validation` module shell, to be used by the QCS server side to validate the DeviceSpecification proto against things like: * Qubit self-loops in qubit pairs * Qubit pairs contain qubits not in the valid qubit set. * Gate durations contains a gate which is missing in the gateset. `__str__()` and `_repr_pretty_` are nearly all copied from `SerializableDevice`. Part of #5050 Also fixes #5197 **Question:** Does this definition of device equality make sense, or should it contain device name as well? Implementing equality is convenient for json and repr tests but not sure if it make sense in general. @dstrain115 @MichaelBroughton
rht
pushed a commit
to rht/Cirq
that referenced
this issue
May 1, 2023
rht
pushed a commit
to rht/Cirq
that referenced
this issue
May 1, 2023
…5203) Part of quantumlib#5050 * Implemented qubit set, qubit pairs, and op validation. Gateset and gate duration will be done in a follow-up. * Added a `device_specification_validation` module shell, to be used by the QCS server side to validate the DeviceSpecification proto against things like: * Qubit self-loops in qubit pairs * Qubit pairs contain qubits not in the valid qubit set. * Gate durations contains a gate which is missing in the gateset. `__str__()` and `_repr_pretty_` are nearly all copied from `SerializableDevice`. Part of quantumlib#5050 Also fixes quantumlib#5197 **Question:** Does this definition of device equality make sense, or should it contain device name as well? Implementing equality is convenient for json and repr tests but not sure if it make sense in general. @dstrain115 @MichaelBroughton
harry-phasecraft
pushed a commit
to PhaseCraft/Cirq
that referenced
this issue
Oct 31, 2024
harry-phasecraft
pushed a commit
to PhaseCraft/Cirq
that referenced
this issue
Oct 31, 2024
…5203) Part of quantumlib#5050 * Implemented qubit set, qubit pairs, and op validation. Gateset and gate duration will be done in a follow-up. * Added a `device_specification_validation` module shell, to be used by the QCS server side to validate the DeviceSpecification proto against things like: * Qubit self-loops in qubit pairs * Qubit pairs contain qubits not in the valid qubit set. * Gate durations contains a gate which is missing in the gateset. `__str__()` and `_repr_pretty_` are nearly all copied from `SerializableDevice`. Part of quantumlib#5050 Also fixes quantumlib#5197 **Question:** Does this definition of device equality make sense, or should it contain device name as well? Implementing equality is convenient for json and repr tests but not sure if it make sense in general. @dstrain115 @MichaelBroughton
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area/gatesets
kind/bug-report
Something doesn't seem to work.
triage/accepted
A consensus emerged that this bug report, feature request, or other action should be worked on
Description of the issue
If a
Gateset
doesn't contain any gates, the repr contains an extra comma:Cirq/cirq-core/cirq/ops/gateset.py
Lines 408 to 411 in e31b48d
@tanujkhattar Should we fix the repr or make empty Gatesets invalid?
Cirq version
0.14
The text was updated successfully, but these errors were encountered: