{{{
Performing system checks...
Traceback (most recent call last):
File "manage.py", line 33, in <module>
main()
File "manage.py", line 29, in main
execute_from_command_line(sys.argv)
File "/usr/local/lib/python3.8/site-
packages/django/core/management/__init__.py", line 419, in
execute_from_command_line
utility.execute()
File "/usr/local/lib/python3.8/site-
packages/django/core/management/__init__.py", line 413, in execute
System check identified no issues (0 silenced).
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/lib/python3.8/site-
packages/django/core/management/base.py", line 354, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/local/lib/python3.8/site-
packages/django/core/management/commands/runserver.py", line 61, in
execute
super().execute(*args, **options)
File "/usr/local/lib/python3.8/site-
packages/django/core/management/base.py", line 398, in execute
output = self.handle(*args, **options)
File "/usr/local/lib/python3.8/site-
packages/channels/management/commands/runserver.py", line 65, in handle
super().handle(*args, **options)
File "/usr/local/lib/python3.8/site-
packages/django/core/management/commands/runserver.py", line 96, in handle
self.run(**options)
File "/usr/local/lib/python3.8/site-
packages/django/core/management/commands/runserver.py", line 103, in run
autoreload.run_with_reloader(self.inner_run, **options)
File "/usr/local/lib/python3.8/site-
packages/django/utils/autoreload.py", line 638, in run_with_reloader
start_django(reloader, main_func, *args, **kwargs)
File "/usr/local/lib/python3.8/site-
packages/django/utils/autoreload.py", line 623, in start_django
reloader.run(django_main_thread)
File "/usr/local/lib/python3.8/site-
packages/django/utils/autoreload.py", line 328, in run
autoreload_started.send(sender=self)
File "/usr/local/lib/python3.8/site-
packages/django/dispatch/dispatcher.py", line 180, in send
return [
File "/usr/local/lib/python3.8/site-
packages/django/dispatch/dispatcher.py", line 181, in <listcomp>
(receiver, receiver(signal=self, sender=sender, **named))
File "/usr/local/lib/python3.8/site-
packages/django/template/autoreload.py", line 44, in
watch_for_template_changes
for directory in get_template_directories():
File "/usr/local/lib/python3.8/site-
packages/django/template/autoreload.py", line 21, in
get_template_directories
items.update(Path.cwd() / to_path(dir) for dir in backend.engine.dirs)
File "/usr/local/lib/python3.8/site-
packages/django/template/autoreload.py", line 21, in <genexpr>
items.update(Path.cwd() / to_path(dir) for dir in backend.engine.dirs)
File "/usr/local/lib/python3.8/site-packages/django/utils/_os.py", line
58, in to_path
raise TypeError('Invalid path type: %s' % type(value).__name__)
TypeError: Invalid path type: PurePosixPath
}}}
----
Our Django is being run in a docker container (base image `python:3.8.6
-slim-buster`) with WSL2 which could be related to funky path issues.
Reverting to v3.2.3 resolves the issue.
--
Ticket URL: <https://code.djangoproject.com/ticket/32887>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* status: new => closed
* resolution: => needsinfo
Comment:
Thanks for the report. Is there a reason why you use `pathlib.PurePath()`
(POSIX paths) instead of `Path()` (cross-OS paths) in your settings? This
looks like a misconfiguration to me 🤔
--
Ticket URL: <https://code.djangoproject.com/ticket/32887#comment:1>
Comment (by Damien Allen):
We used a cookie-cutter template for our docker setup:
https://github.com/wemake-services/wemake-django-
template/blob/master/%7B%7Bcookiecutter.project_name%7D%7D/server/settings/components/__init__.py
I will put in a PR over there, thanks for prompt reply!
--
Ticket URL: <https://code.djangoproject.com/ticket/32887#comment:2>
* resolution: needsinfo => invalid
--
Ticket URL: <https://code.djangoproject.com/ticket/32887#comment:3>