参考https://blog.csdn.net/xiaoyaosheng19/article/details/82643729

原因: 最新的mysql8.0对用户密码的加密方式为caching_sha2_password, django暂时还不支持这种新增的加密方式。只需要将用户加密方式改为老的加密方式即可。

use mysql;
alter user 'root'@'localhost' identified with mysql_native_password by 'yourpassword';
flush privileges;