Python Forum
Python 3.8 -- mysql-connector error
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Python 3.8 -- mysql-connector error
#1
In my earlier post, it was reported that pip install of some packages fails in case of python 3.8, while there is no such problem for python 3.7.4

It is further observed that in case of mysql-connector, though pip install is successful in both versions, python 3.8 throws error on running relevant code, while the execution is smooth on python 3.7.4

Sample code:
import mysql.connector

mydb = mysql.connector.connect(
    host="localhost",
    user="adt",
    passwd="adt-MSQR"
)

print(mydb)
Output (Python-3.7.4):
Output:
<mysql.connector.connection_cext.CMySQLConnection object at 0x00000299018E8548>
On the other hand, if same code is run on python 3.8, following error is encountered:
Error:
Traceback (most recent call last): File "J:\AdtPython-Practice\MySQL\msqTest.py", line 12, in <module> mydb = mysql.connector.connect( File "C:\Program Files\Python38\lib\site-packages\mysql\connector\__init__.py", line 179, in connect return MySQLConnection(*args, **kwargs) File "C:\Program Files\Python38\lib\site-packages\mysql\connector\connection.py", line 95, in __init__ self.connect(**kwargs) File "C:\Program Files\Python38\lib\site-packages\mysql\connector\abstracts.py", line 716, in connect self._open_connection() File "C:\Program Files\Python38\lib\site-packages\mysql\connector\connection.py", line 208, in _open_connection self._do_auth(self._user, self._password, File "C:\Program Files\Python38\lib\site-packages\mysql\connector\connection.py", line 137, in _do_auth packet = self._protocol.make_auth( File "C:\Program Files\Python38\lib\site-packages\mysql\connector\protocol.py", line 99, in make_auth packet += self._auth_response(client_flags, username, password, File "C:\Program Files\Python38\lib\site-packages\mysql\connector\protocol.py", line 58, in _auth_response auth = get_auth_plugin(auth_plugin)( File "C:\Program Files\Python38\lib\site-packages\mysql\connector\authentication.py", line 190, in get_auth_plugin raise errors.NotSupportedError( mysql.connector.errors.NotSupportedError: Authentication plugin 'caching_sha2_password' is not supported
Any Clue?
A.D.Tejpal
Reply


Messages In This Thread
Python 3.8 -- mysql-connector error - by adt - Oct-26-2019, 01:55 PM
RE: Python 3.8 -- mysql-connector error - by buran - Oct-26-2019, 02:57 PM
RE: Python 3.8 -- mysql-connector error - by adt - Oct-26-2019, 03:17 PM
RE: Python 3.8 -- mysql-connector error - by buran - Oct-26-2019, 04:19 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020