Я сталкиваюсь с этой проблемой на моей странице about в шаблонах django, если я удаляю свой css, тогда он работает хорошо, иначе он выдает мне ошибку всякий раз, когда я использую для отображения изображений, ответьте как можно скорее, пожалуйста, ответьте быстро для этот вопрос, если кто-нибудь может
Django Version: 3.0.5
Python Version: 3.7.6
Installed Applications:
['django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'mysiteapp']
Installed Middleware:
['django.middleware.security.SecurityMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware']
Traceback (most recent call last):
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
response = get_response(request)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\core\handlers\base.py", line 115, in _get_response
response = self.process_exception_by_middleware(e, request)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\core\handlers\base.py", line 113, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "F:\newproject\mysite\mysiteapp\views.py", line 27, in about
return render(request,'about.html')
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\shortcuts.py", line 19, in render
content = loader.render_to_string(template_name, context, request, using=using)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\template\loader.py", line 61, in render_to_string
template = get_template(template_name, using=using)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\template\loader.py", line 15, in get_template
return engine.get_template(template_name)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\template\backends\django.py", line 34, in get_template
return Template(self.engine.get_template(template_name), self)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\template\engine.py", line 143, in get_template
template, origin = self.find_template(template_name)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\template\engine.py", line 125, in find_template
template = loader.get_template(name, skip=skip)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\template\loaders\base.py", line 24, in get_template
contents = self.get_contents(origin)
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\site-packages\django\template\loaders\filesystem.py", line 24, in get_contents
return fp.read()
File "C:\Users\Rishabh\AppData\Local\Programs\Python\Python37-32\lib\codecs.py", line 322, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
Exception Type: UnicodeDecodeError at /about
Exception Value: 'utf-8' codec can't decode byte 0x92 in position 1394: invalid start byte