我已经很好地配置了OSQA Django,但是当我尝试这个网址时如何解决这个问题:
http://localhost/questions/ask/
在debog mod中:
TypeError at /questions/ask/
'NoneType' object is not iterable
Request Method: GET
Request URL: http://localhost/questions/ask/
Django Version: 1.6
Exception Type: TypeError
Exception Value:
'NoneType' object is not iterable
Exception Location: /home/mm/osqa/osqa-server/forum/markdownext/mdx_settingsparser.py in __init__, line 13 :
Python Executable: /usr/bin/python
Python Version: 2.7.6
Python Path:
['/usr/local/lib/python2.7/dist-packages/South-1.0-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/django_debug_toolbar-1.2.1-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/sqlparse-0.1.12-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/Markdown-2.5-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/html5lib-1.0b3-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/python_openid-2.2.5-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/Django-1.6-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/elementtree-1.2.7_20070827_preview-py2.7.egg',
'/usr/local/lib/python2.7/dist-packages/ipython-2.2.0-py2.7.egg',
'/usr/lib/python2.7',
'/usr/lib/python2.7/plat-x86_64-linux-gnu',
'/usr/lib/python2.7/lib-tk',
'/usr/lib/python2.7/lib-old',
'/usr/lib/python2.7/lib-dynload',
'/usr/local/lib/python2.7/dist-packages',
'/usr/lib/python2.7/dist-packages',
'/usr/lib/python2.7/dist-packages/PILcompat',
'/usr/lib/python2.7/dist-packages/gst-0.10',
'/usr/lib/python2.7/dist-packages/gtk-2.0',
'/usr/lib/pymodules/python2.7',
'/usr/lib/python2.7/dist-packages/ubuntu-sso-client',
'/home/marwen/osqa',
'/home/marwen/osqa/osqa-server',
'/home/marwen/osqa/osqa-server/forum/markdownext']
Server time: Fri, 26 Sep 2014 11:17:48 -0400
使用代码第13行编辑:
for key, value in configs:
self.config[key] = value
答案 0 :(得分:3)
很难说没有错误的堆栈跟踪,但我认为我最近遇到了与OSQA类似的问题。问题是Markdown插件的v2.5发生了重大变化。如果将安装恢复为使用v2.4.1,则可能会解决此错误。