解决方法

vi /home/zhangtq/.local/lib/python3.6/site-packages/django/db/backends/mysql/operations.py

将decode改为encode 

或直接注释掉如下图

django报错query = query.decode(errors='replace') AttributeError: 'str' object has no attribute 'decode'

 

相关文章: