question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error when using IBMQ.load_accounts()

See original GitHub issue

Information

  • Qiskit Terra version: 0.8.0
  • Python version: 3.7.1
  • Operating system: Windows 10 x64

What is the current behavior?

After registering for the beta version of IBM Q Experience my credentials no longer loaded using the command IBMQ.load_accounts()

Steps to reproduce the problem

  1. Sign in the beta version of IBM Q Experience;
  2. Generate a new token at the beta version;
  3. Try to load the account using: IBMQ.load_accounts()

What is the expected behavior?

>>> from qiskit import IBMQ
>>> IBMQ.load_accounts()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\ProgramData\Anaconda3\envs\quantum_env\lib\site-packages\qiskit\providers\ibmq\ibmqprovider.py", line 199, in load_accounts
    self._append_account(credentials)
  File "C:\ProgramData\Anaconda3\envs\quantum_env\lib\site-packages\qiskit\providers\ibmq\ibmqprovider.py", line 279, in _append_account
    single_provider = IBMQSingleProvider(credentials, self)
  File "C:\ProgramData\Anaconda3\envs\quantum_env\lib\site-packages\qiskit\providers\ibmq\ibmqsingleprovider.py", line 52, in __init__
    self._api = self._authenticate(self.credentials)
  File "C:\ProgramData\Anaconda3\envs\quantum_env\lib\site-packages\qiskit\providers\ibmq\ibmqsingleprovider.py", line 103, in _authenticate
    .format(ex)) from root_exception
ConnectionError: Couldn't connect to IBMQ server: error during login: License required. You need to accept the License from Web Platform. https://quantumexperience.ng.bluemix.net

Suggested solutions

I tested the following steps before I could solve the problem:

  1. Accept the license using the link provided by the error;
  2. Delete the accounts registered in qiskit with the command: IBMQ.delete_accounts()
  3. Create a second token in the beta version of IBMQ and try to load;

But this worked:

  1. I went back to the old version of IBM Q Experience and noticed that my token was as “NULL”. After generating a new token, everything worked again, using the following steps in python:
from qiskit import IBMQ
IBMQ.delete_accounts()
IBMQ.save_account('MY-NEW_TOKEN')
IBMQ.load_accounts()

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

3reactions
jwoehrcommented, May 26, 2019

Error when using IBMQ.load_accounts() #122 is a Qiskit documentation query.

from qiskit import IBMQ
IBMQ.save_account('MY_API_TOKEN', 'MY_URL')

These are the directions a https://qiskit.org/documentation/install.html#install-access-ibm-q-devices-label

But the typical existing free access Qiskit user never thinks about the URL.

The idea that they have to click a “Copy URL” button and explicitly choose the beta site so their authentication will match is a new concept and needs to be documented better for existing users.

The URL for IBM QE Beta can be obtained from the copy url button on https://quantum-computing.ibm.com/account

The value is set to https://api.quantum-computing.ibm.com/api/Hubs/ibm-q/Groups/open/Projects/main .

The desired result is always obtained by a full invocation of save_account('mytoken', 'https://api.quantum-computing.ibm.com/api/Hubs/ibm-q/Groups/open/Projects/main')

1reaction
jwoehrcommented, Jun 18, 2019

@big-c-note if you encounter problems you can chat on https://qiskit.slack.com in #general

Read more comments on GitHub >

github_iconTop Results From Across the Web

Access systems with your account - IBM Quantum
This is an overview of how to use your IBM Quantum account to access the systems and simulators ... load_account() : Load account...
Read more >
Error in qiskit IBMQ.load_account() - Account Credentials Not ...
I am using the ''ibmq_vigo" backend by calling IBMQ.load_account() , which is an example in qiskit documentation for NoiseModel. from qiskit import IBMQ, ......
Read more >
IBMQProvider issue - quantum computing - Stack Overflow
providers() . If there isn't anything load your account using IBMQ.load_account() . The other issue could be that there are genuinely no ...
Read more >
Installing your API key and accessing your provider
In this chapter, we used save.account() to store your account locally. ... we will use the IBMQ.load_account() and IBMQ.get_provider() classes in your ...
Read more >
AccountProvider - Qiskit
The account provider class provides access to the IBM Quantum Experience services ... To select a different provider, use the IBMQ.get_provider() method and ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found