1
$\begingroup$

When I try IBMQ.load_account or IBMQ.delete_account gives an error in the ubuntu machine and the error is,

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/anaconda3/lib/python3.7/site-packages/qiskit/providers/ibmq/ibmqfactory.py", line 291, in delete_account
    stored_credentials, _ = read_credentials_from_qiskitrc()
  File "/home/anaconda3/lib/python3.7/site-packages/qiskit/providers/ibmq/credentials/configrc.py", line 86, in read_credentials_from_qiskitrc
    new_credentials = Credentials(**single_credentials)  # type: ignore[arg-type]
TypeError: __init__() got an unexpected keyword argument 'efault_provider'

The qiskit version I used is

{'qiskit-terra': '0.17.4',
 'qiskit-aer': '0.8.2',
 'qiskit-ignis': '0.6.0',
 'qiskit-ibmq-provider': '0.14.0',
 'qiskit-aqua': '0.9.2',
 'qiskit': '0.27.0', 
 'qiskit-nature': None,
 'qiskit-finance': None,
 'qiskit-optimization': None,
 'qiskit-machine-learning': None}
$\endgroup$
7
  • $\begingroup$ Are you just calling that function or something else? $\endgroup$
    – epelaaez
    Jun 20 at 22:45
  • $\begingroup$ Hi @epelaaez , I tried first to save the account it gave me the same error. So I tried deleting the account again I ended up with the same error. I'm calling the function by importing IBMQ from qiskit along with my credential. $\endgroup$
    – Monica
    Jun 20 at 23:00
  • $\begingroup$ In the last line of the error message, the parameter efault_provider is mentioned. Is this a typo from your side or is that the actual error message? $\endgroup$
    – epelaaez
    Jun 20 at 23:30
  • $\begingroup$ It is the actual error message right. Because we save the account using ibmq.save_account('Key', overwrite = True) which means it is an actual error message and not a typo. $\endgroup$
    – Monica
    Jun 20 at 23:51
  • $\begingroup$ @Monica could you post contents of your ~/.qiskit/qiskitrc file here? (hide the token before posting) $\endgroup$ Jun 21 at 10:47
2
$\begingroup$

Based on the error message

TypeError: __init__() got an unexpected keyword argument 'efault_provider'

Your qiskitrc file contains an invalid keyword efault_provider (it should be default_provider). You'll need to delete your $HOME/.qiskit/qiskitrc file and do save_account() again.

$\endgroup$
1
  • $\begingroup$ Thank you @jyu00, I deleted the file and it worked for me. $\endgroup$
    – Monica
    Jun 21 at 15:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.