1、报错:

UnicodeDecodeError: 'gbk' codec can't decode byte 0xa6 in position 9737: illegal multibyte sequence

  

2、解决:

  打开django/views下的debug.py文件,转到line331行:
   with Path(CURRENT_DIR, 'templates', 'technical_500.html').open() as fh
  将其改成:
    with Path(CURRENT_DIR, 'templates', 'technical_500.html').open(encoding="utf-8") as fh
就成功了。

  

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-10-26
  • 2021-04-19
  • 2021-12-27
  • 2021-11-19
  • 2021-06-07
  • 2021-12-15
猜你喜欢
  • 2021-09-12
  • 2022-12-23
  • 2021-07-22
  • 2021-11-21
  • 2021-09-14
  • 2022-01-22
  • 2022-12-23
相关资源
相似解决方案