یلدا ادامه داره... ❤️ ۴۰ درصد تخفیف همه دورهها
استفاده از تخفیفهاهر دستوری که در منیج میزنم و شامل دستور زیر هم میشه
python3 manage.py check
این ارور رو میده
System check identified no issues (0 silenced).
Traceback (most recent call last):
File "manage.py", line 22, in <module>
main()
File "manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "/home/mmj/.local/lib/python3.8/site-packages/django/core/management/__init__.py", line 401, in execute_from_command_line
utility.execute()
File "/home/mmj/.local/lib/python3.8/site-packages/django/core/management/__init__.py", line 395, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/home/mmj/.local/lib/python3.8/site-packages/django/core/management/base.py", line 341, in run_from_argv
connections.close_all()
File "/home/mmj/.local/lib/python3.8/site-packages/django/db/utils.py", line 230, in close_all
connection.close()
File "/home/mmj/.local/lib/python3.8/site-packages/django/utils/asyncio.py", line 26, in inner
return func(*args, **kwargs)
File "/home/mmj/.local/lib/python3.8/site-packages/django/db/backends/sqlite3/base.py", line 261, in close
if not self.is_in_memory_db():
File "/home/mmj/.local/lib/python3.8/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 "/home/mmj/.local/lib/python3.8/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 'PosixPath' is not iterable
اگه از Django 3.1 استفاده میکنین، توی فایل settings.py، قسمت دیتابیس ها، از str()
استفاده کنین، مثل کد زیر:
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': str(BASE_DIR / 'db.sqlite3'),
}
}
https://stackoverflow.com/questions/64634674/django-typeerror-argument-of-type-posixpath-is-not-iterable
https://forum.djangoproject.com/t/django-tutorial-python-manage-py-startapp-polls-fails/2718/5
آیا مایل به ارسال نوتیفیکیشن و اخبار از طرف راکت هستید ؟