Skip to content
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

Documentation missing Arguments #426

Closed
Z035 opened this issue Sep 29, 2023 · 4 comments
Closed

Documentation missing Arguments #426

Z035 opened this issue Sep 29, 2023 · 4 comments
Labels
bug 🐛 Something isn't working qbraid-lab 🔬 Relating to qBraid Lab platform

Comments

@Z035
Copy link

Z035 commented Sep 29, 2023

Environment

  • Python version:
  • Operating system:

What happened?

in # Executing Circuit section

>>> qiskit_circuit = circuit0()
>>> cirq_circuit = circuit1()
>>> qjob0 = qdevice.run(qiskit_circuit)
>>> qjob1 = qdevice.run(cirq_circuit)

The qjobs are missing arguments ("shots"=50).

The problem is, when executing without specifying 'shots', the code result in an error:

ClientError: An error occurred (400) when calling the CreateQuantumTask operation: Not enough qbraid credits

which does not tell you that the real problem is missing shot counts.

What is the expected outcome?

Any suggestion?

@ryanhill1
Copy link
Member

@Z035 Thanks for opening this issue! I tried to recreate the error using the AWS SV1 device

from qbraid import device_wrapper

qdevice = device_wrapper("aws_sv_sim")

qdevice.run(qiskit_circuit)

but instead got the following:

ValueError: No result types specified for circuit and shots=0. See `braket.circuits.result_types

Which quantum device were you targeting when this happened?

@Z035
Copy link
Author

Z035 commented Sep 30, 2023 via email

@ryanhill1
Copy link
Member

@Z035 Ahh, ok I was able to re-produce! The problem occurred when I tried submitting the task through the qBraid-SDK and through the Amazon Braket SDK directly. So it seems like this bug is caused by the order of error-handling in the qBraid Quantum Jobs API.

I will open the necessary issue in the private qBraid API repository and close this issue when it is resolved. Thanks!

@ryanhill1 ryanhill1 added bug 🐛 Something isn't working qbraid-lab 🔬 Relating to qBraid Lab platform labels Oct 2, 2023
@Z035
Copy link
Author

Z035 commented Oct 2, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something isn't working qbraid-lab 🔬 Relating to qBraid Lab platform
Projects
None yet
Development

No branches or pull requests

2 participants