0
import mysql.connector

mydb = mysql.connector.connect(

    host="localhost",
    user="root",
    password="henry123test",
    )

This was the error returned

mysql.connector.errors.NotSupportedError: Authentication plugin 'caching_sha2_password' is not supported.

Can anyone help me, been googling for some time now.

Timus
  • 7,225
  • 5
  • 10
  • 24
  • Does this answer your question? [Authentication plugin 'caching\_sha2\_password' cannot be loaded](https://stackoverflow.com/questions/49194719/authentication-plugin-caching-sha2-password-cannot-be-loaded) – sushanth Nov 03 '20 at 11:00
  • 1
    This error is typical if you installed the deprecated `mysql-connector` and not `mysql-connector-python`. – Klaus D. Nov 03 '20 at 11:01
  • @KlausD. Thanks for clarifying, I just installed mysql-connector-python and it worked! – Jamike Michel Ohia Nov 03 '20 at 11:10

1 Answers1

-1

use pip3 install mysql-connector-python.