Skip to content

Commit c4a25f7

Browse files
Cynocracyrht
authored andcommitted
IonQ: Explicitly select lang (quantumlib#5348)
We were planning on making this arg optional, but it shouldn't hurt to also send it explicitly
1 parent c4f72f7 commit c4a25f7

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

cirq-ionq/cirq_ionq/ionq_client.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,11 @@ def create_job(
118118
"""
119119
actual_target = self._target(target)
120120

121-
json: Dict[str, Any] = {'target': actual_target, 'body': serialized_program.body}
121+
json: Dict[str, Any] = {
122+
'target': actual_target,
123+
'lang': 'json',
124+
'body': serialized_program.body,
125+
}
122126
if name:
123127
json['name'] = name
124128
# We have to pass measurement keys through the metadata.

cirq-ionq/cirq_ionq/ionq_client_test.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ def test_ionq_client_create_job(mock_post):
102102

103103
expected_json = {
104104
'target': 'qpu',
105+
'lang': 'json',
105106
'body': {'job': 'mine'},
106107
'name': 'bacon',
107108
'shots': '200',

0 commit comments

Comments
 (0)