how to solve this error after running python manage.py migrate

Traceback (most recent call last):
File “C:\Users\Gairick\Desktop\gitrepo\django\venv\Scripts\django1\manage.py”, line 22, in
main()
File “C:\Users\Gairick\Desktop\gitrepo\django\venv\Scripts\django1\manage.py”, line 18, in main
execute_from_command_line(sys.argv)
File “C:\Users\Gairick\AppData\Roaming\Python\Python311\site-packages\django\core\management_init_.py”,
line 401, in execute_from_command_line
utility.execute()
File “C:\Users\Gairick\AppData\Roaming\Python\Python311\site-packages\django\core\management_init_.py”,
line 395, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File “C:\Users\Gairick\AppData\Roaming\Python\Python311\site-packages\django\core\management\base.py”, lin
e 341, in run_from_argv
connections.close_all()
File “C:\Users\Gairick\AppData\Roaming\Python\Python311\site-packages\django\db\utils.py”, line 230, in cl
ose_all
connection.close()
File “C:\Users\Gairick\AppData\Roaming\Python\Python311\site-packages\django\utils\asyncio.py”, line 26, i
n inner
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File “C:\Users\Gairick\AppData\Roaming\Python\Python311\site-packages\django\db\backends\sqlite3\base.py”,
line 261, in close
if not self.is_in_memory_db():
^^^^^^^^^^^^^^^^^^^^^^
File “C:\Users\Gairick\AppData\Roaming\Python\Python311\site-packages\django\db\backends\sqlite3\base.py”,
line 380, in is_in_memory_db
return self.creation.is_in_memory_db(self.settings_dict[‘NAME’])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “C:\Users\Gairick\AppData\Roaming\Python\Python311\site-packages\django\db\backends\sqlite3\creation.
py”, line 12, in is_in_memory_db
return database_name == ‘:memory:’ or ‘mode=memory’ in database_name
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: argument of type ‘WindowsPath’ is not iterable

What’s your DATABASES setting is like?

issue resolved thanks by the way

Could you explain what you did to make it work? For learning purposes

1 Like

I got this same error , Can you please share the workaround

I had similar issue

(crud) PS C:\dframework\myproject> py manage.py makemigrations webapp
Traceback (most recent call last):
File “C:\dframework\myproject\manage.py”, line 22, in
main()
File “C:\dframework\myproject\manage.py”, line 18, in main
execute_from_command_line(sys.argv)
File “C:\dframework\crud\Lib\site-packages\django\core\management_init_.py”, line 442, in execute_from_command_line
utility.execute()
File “C:\dframework\crud\Lib\site-packages\django\core\management_init_.py”, line 416, in execute
django.setup()
File “C:\dframework\crud\Lib\site-packages\django_init_.py”, line 24, in setup
apps.populate(settings.INSTALLED_APPS)
File “C:\dframework\crud\Lib\site-packages\django\apps\config.py”, line 193, in create
import_module(entry)
File “C:\Users\Owner\AppData\Local\Programs\Python\Python311\Lib\importlib_init_.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “”, line 1204, in _gcd_import
File “”, line 1176, in _find_and_load
File “”, line 1140, in _find_and_load_unlocked
ModuleNotFoundError: No module named ‘rest_frameworkwebapp’

After I do my models I get this error when I try to makemigrations

Ok Guys, resolved thank you, for the purpose of learning I forgot to put a comma in the INSTALLED_APPS after my application name