Django. Core. Exceptions. ImproperlyConfigured: mysqlclient 1.4.0 or newer is required; You have solutions for 0.10.1
An error occurred today when replacing mysql database while learning django:
is written in _init_. Py
import pymysql
pymysql.install_as_MySQLdb()
Error: the django. Core. Exceptions. ImproperlyConfigured: mysqlclient 1.4.0 or newer is required; You have 0.10.1.
This is actually a mismatch between django and Pymysql. Python3 is not supported by mysqldb.
1. Tried to comment the python/Lib/site – packages/django/db/backends/mysql/base. Py files
' ' 'if the version & lt; (1, 4, 0): Raise ImproperlyConfigured(' mysqlClient 1.4.0 or Newer is required; You have %s.' % Database.) '
2. Updated version of Django, also useless
Final solution:
init.py is changed to
import pymysql
pymysql.version_info = (1, 4, 13, "final", 0)
pymysql.install_as_MySQLdb()
Specify the Pymysql version directly
Xiaobai learns Python, if there is a mistake, please give me more advice
Read More:
- Error: command error out with exit status 1: Python when installing mysqlclient in django2.0 setup.py egg_ info
- django.core.exceptions . improveconfigured: error loading MySQL DB module. Django configuring MySQL database
- ubuntu install mysqlclient error ERROR: Failed building wheel for mysqlclient solution
- command ‘x86_64-linux-gnu-gcc’ failed with exit status 1
- Error loading pscopg2 module: no module named pscopg2
- Install in Python 3. X web.py
- Python MAC installation mysqlclient package error “error: Command ‘clang’ failed with exit status 1” solution
- Python Mac installs mysqlclient package error “error: command’clang’ failed with exit status 1” solution
- ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full comm
- An error keyerror255 was reported when pymysql connect to MySQL
- After installing MySQL again under Linux, the solution of ‘MySQL module failed to start’ appears
- Error creating Django application: error on Python side.Exit code:1.
- Importerror of Django error: no module named**
- When Python Django creates a database, can’t open file ‘ manage.py ‘: [Errno 2] No such file or directory
- [Python] failed building wheel for MySQL Python solution
- Python: What’s Virtualenv
- ERROR: Command “python setup.py egg_info” failed with error code 1 in /tmp/pip-install-zsbbp6ce/mysq
- Magento installation error: database connect error
- An error 1064 is reported when pymysql accesses the image
- Command “python setup.py egg_info” failed with error code 1 in /private/var/folders/14/4hz051qx0wqd3