【发布时间】:2011-03-16 12:06:59
【问题描述】:
我无法弄清楚为什么会出现此错误。请帮忙。
Traceback(最近一次通话最后一次):
文件“C:\Python26\lib\site-packages\django\core\servers\basehttp.py”,第 280 行,运行中 self.result = application(self.environ, self.start_response)
调用中的文件“C:\Python26\lib\site-packages\django\core\servers\basehttp.py”,第 674 行 return self.application(environ, start_response)
调用中的文件“C:\Python26\lib\site-packages\django\core\handlers\wsgi.py”,第 241 行 response = self.get_response(request)
文件“C:\Python26\lib\site-packages\django\core\handlers\base.py”,第 142 行,在 get_response return self.handle_uncaught_exception(request, resolver, exc_info)
文件“C:\Python26\lib\site-packages\django\core\handlers\base.py”,第 166 行,在 handle_uncaught_exception 中 return debug.technical_500_response(request, *exc_info)
文件“C:\Python26\lib\site-packages\django\views\debug.py”,第 58 行,位于 Technical_500_response html = 记者.get_traceback_html()
文件“C:\Python26\lib\site-packages\django\views\debug.py”,第 109 行,在 get_traceback_html 帧 = self.get_traceback_frames()
文件“C:\Python26\lib\site-packages\django\views\debug.py”,第 228 行,在 get_traceback_frames pre_context_lineno, pre_context, context_line, post_context = self._get_lines_from_file(filename, lineno, 7, loader, module_name)
文件“C:\Python26\lib\site-packages\django\views\debug.py”,第 209 行,在 _get_lines_from_file context_line = source[lineno].strip('\n')
IndexError: 列表索引超出范围
会不会是因为使用了notepad++?
【问题讨论】:
标签: django