摘要: 报错截图: 解决方案: 打开django/views下的debug.py文件,转到line331行: with Path(CURRENT_DIR, 'templates', 'technical_500.html').open() as fh 将其改成: with Path(CURRENT_DIR, 阅读全文
posted @ 2020-12-11 12:48 胸怀丶若谷 阅读(99) 评论(0) 推荐(0)
摘要: # 自定义日志输出信息 LOGGING = { 'version': 1, 'disable_existing_loggers': True, 'formatters': { 'standard': { 'format': '%(asctime)s [%(threadName)s:%(thread) 阅读全文
posted @ 2020-12-11 12:02 胸怀丶若谷 阅读(103) 评论(0) 推荐(0)
摘要: 报错的原因是因为我们的STATICFILES_DIRS赋值时,形式不对,其应该赋数组对象,具体如下: 找到settings.py文件, 把 STATICFILES_DIRS=(os.path.join(BASE_DIR,'static')) 改为 STATICFILES_DIRS=[(os.path 阅读全文
posted @ 2020-12-11 11:32 胸怀丶若谷 阅读(462) 评论(0) 推荐(0)