Home > other >  Execute python manage. Py makemigrations always prompt mysqlclient version problem
Execute python manage. Py makemigrations always prompt mysqlclient version problem

Time:09-22

I am a beginner, there is really no solution of this problem, please help each master advice:
Pymysql installed, to install mysqlclient also 1.4.6 version, is to prompt the following error, collapsed, watching video and no interpretation in this area, as if the problem doesn't exist,
I use the python is 3.8, the django is 3.0.5, pycharm is 2018.3
Don't know where is wrong, debugging countless times, also not make,

C: \ Windows \ System32 & gt; Python manage. Py makemigrations
Python: can 't open the file' manage. Py ': [2] Errno No to the file or directory

C: \ Windows \ System32 & gt; D:

D: \ & gt; CD django01/testdb01

D: \ django01 \ testdb01 & gt; Python manage. Py makemigrations
Traceback (the most recent call last) :
The File "is the manage. Py", line 21, in & lt; module>
The main ()
The File "is the manage. Py", line 17, in the main
Execute_from_command_line (sys. Argv)
File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django/core/management/set py", line 401, in exe
Cute_from_command_line
The utility. The execute ()
File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django/core/management/set py", line 377, in exe
Express
Django. The setup ()
File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ set py", line 24, setup in
Apps. The populate (Settings. The INSTALLED_APPS)
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ apps \ registry py", line 114, in the populate
App_config. Import_models ()
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ apps \ config py", line 211, in import_models
Self. Models_module=import_module (models_module_name)
File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ importlib \ set py", line 127, in import_module
Return _bootstrap. _gcd_import (name [level:], package, level)
The File "& lt; Frozen importlib. _bootstrap & gt;" , line 1014, in _gcd_import
The File "& lt; Frozen importlib. _bootstrap & gt;" , line 991, in _find_and_load
The File "& lt; Frozen importlib. _bootstrap & gt;" , line 975, in _find_and_load_unlocked
The File "& lt; Frozen importlib. _bootstrap & gt;" , line 671, in _load_unlocked
The File "& lt; Frozen importlib. _bootstrap_external & gt;" , line 783, in exec_module
The File "& lt; Frozen importlib. _bootstrap & gt;" , line 219, in _call_with_frames_removed
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ contrib \ auth \ models py", line 2, the in & lt; module>
The from the django. Contrib. Auth. Base_user import AbstractBaseUser, BaseUserManager
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ contrib \ auth \ base_user py", line 47, in & lt; Modul
E>
The class AbstractBaseUser (models. Model) :
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ db \ models \ base py", line 121, in __new__
New_class. Add_to_class (' _meta 'Options (meta, app_label))
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ db \ models \ base py", line 325, in add_to_class
Value. Contribute_to_class (CLS, name)
File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ db \ models \ options py", line 208, contribute in
_to_class
Self. Db_table=truncate_name (self. Db_table, connection. Ops. Max_name_length ())
File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ db \ set py", 28, the line in __getattr__
Return getattr (connections [DEFAULT_DB_ALIAS], item)
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ db \ utils py", line 207, in the __getitem__
Backend=load_backend (db [' ENGINE '])
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ db \ utils py", line 111, in load_backend
S.b ase return import_module (' % '% backend_name)
File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ importlib \ set py", line 127, in import_module
Return _bootstrap. _gcd_import (name [level:], package, level)
The File "C: \ Users \ \ Administrator \ \ AppData \ Local \ designed \ Python Python38-32 \ lib \ site - packages \ django \ db \ backends \ mysql \ base py", line 37, in & lt; Modul
E>
Raise ImproperlyConfigured (' mysqlclient 1.3.13 or newer is required; You have % s. % Database. The __version__)
Django. Core. Exceptions. ImproperlyConfigured: mysqlclient 1.3.13 or newer is required; You have 0.9.3.
  • Related