Python论坛  - 讨论区

标题:[python-chinese] 同一程序在Django自带的webserver和apache2上运行结果不同

2006年09月14日 星期四 23:17

WANG Zhen zhenwang0115在gmail.com
星期四 九月 14 23:17:46 HKT 2006

6§‚‰bš‡h¸8ڞ
µê[É+^¦m§ÿðÃ(¡Ú^rG«¢¸Ÿú§÷cjx(ýØڞ
,µê[ÊË^§ùÞÂ׬·÷hsûn·Na¶iC©à£›±êïz¸m¶Ÿÿ–‡–,·Í4Óù²²+^þZ ŠÔnéí»­:j–œ…í´çŸ¦¡Úr¶'ß^!¶ÚþZjXh²ßæÊÈ­{ùh‚)ÿ2‡iÊØhê뢳ò¶'©Ý•êݍ©à¡Ê+z§vW«²j§+a¢tëiǛiÉ&¢ËkyǧµÆ¥–V¬´X¥{û¬¯ùboúr¶'ۏìŠ×©iɁë?š‡iÊØhŸö©iÈ^§)bí½ö)Çjwez°â²–­rÞ²ém¡¸ÞrÚÞ¨X¥{û¬¯ùboúr¶'ۏìŠ×©iɁë?6§‚=朶áè ýØڞ
?rŠÞþ§vW«³ù¨vœ­†‰éÊX§{^·ŠxZÙ^®·­º¹Ì¡Óò¶'©Ý•êëz¡b•ï剿éÊØhŸn?²+^¥§$j¬ü8ڞ
4÷šrۇ ƒ÷cjx(ýÊ+{øZÙ^®Ïæ¡Úr¶'§)bíxÞ)ÜjY]ŠÊZµÈ^®Ç§vÈ ©

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

2006年09月15日 星期五 23:02

kongkongxiangbo 孔祥波 py.konger在gmail.com
星期五 九月 15 23:02:47 HKT 2006

may be sqlite config error
DATABASE_NAME = './data.db'
should 'path/to/your/project/data.db'
0.95-py2.4.egg/django/db/backends/sqlite3/base.py", line 66, in close
  self.connection.close()OperationalError: Unable to close due to
unfinalised statements


2006/9/14, WANG Zhen <zhenwang0115在gmail.com>:
> 正在学习Django框架,照做limodou兄的Django Step by Step上的例子中。今天做到第五讲
> http://www.woodpecker.org.cn/obp/django/django-stepbystep/newtest/doc/tut05.html
>
> 的程序,但是遇到了奇怪的问题:
> 如果按照教程中使用Django自带的web server通过http://localhost:8000/mysite/login/来运行程序,一切正常;
> 但是使用自己在Ubuntu 6.06上配置的apache 2.0.55 + mod_python 3.1
> .4通过http://localhost/mysite/login/来运行该程序,则在单击"登录"按钮之后报错:
>
> Mod_python error: "PythonHandler django.core.handlers.modpython"
>
> Traceback (most recent call last):
>
>   File "/usr/lib/python2.4/site-packages/mod_python/apache.py", line
> 299, in HandlerDispatch
>
>     result = object(req)
>
>   File
> "/usr/lib/python2.4/site-packages/Django-0.95-py2.4.egg/django/core/handlers/modpython.py",
> line 163, in handler
>     return ModPythonHandler()(req)
>
>   File "/usr/lib/python2.4/site-packages/Django-
> 0.95-py2.4.egg/django/core/handlers/modpython.py", line 143, in __call__
>     dispatcher.send(signal=signals.request_finished)
>
>   File
> "/usr/lib/python2.4/site-packages/Django-0.95-py2.4.egg/django/dispatch/dispatcher.py",
> line 347, in send
>
>     sender=sender,
>
>   File
> "/usr/lib/python2.4/site-packages/Django-0.95-py2.4.egg/django/dispatch/robustapply.py",
> line 47, in robustApply
>     return receiver(*arguments, **named)
>
>   File "/usr/lib/python2.4/site-packages/Django-
> 0.95-py2.4.egg/django/db/backends/sqlite3/base.py", line 66, in close
>     self.connection.close()
>
> OperationalError: Unable to close due to unfinalised statements
> 目前还看不太懂这些错误信息,还请大家指点,谢谢先!
> P. S. 之前四讲的程序都可以在Django自带的web server和我自己配置的apache2上面跑起来。
>
>
> --
> Only the paranoid survive.
>

[导入自Mailman归档:http://www.zeuux.org/pipermail/zeuux-python]

如下红色区域有误,请重新填写。

    你的回复:

    请 登录 后回复。还没有在Zeuux哲思注册吗?现在 注册 !

    Zeuux © 2025

    京ICP备05028076号