开发者

Garbled output on Django development server with Jython

I'm running Django (1.2.5) on Jython (2.5.2) on Windows 7 (have also tried this on XP with the same results). The problem I'm running into is with the Django development server. The output from the server is garbled in the first few characters of every line.

jython manage.py runserver

Validating models...

0 errors found

Django version 1.2.5, using settings 'Polls.settings'

Development server is running at http://127.0.0.1:8000/

Quit the server with CONTROL-C.

←[35;1m[09/Mar/2011 16:33:09] "GET / HTTP/1.1" 500 64949

←[0m←[32m[开发者_JAVA技巧09/Mar/2011 16:33:16] "GET /admin HTTP/1.1" 301 0

←[0m←[m[09/Mar/2011 16:33:17] "GET /admin/ HTTP/1.1" 200 1882

←[0m

The problem is I can't actually stop the server using Ctrl-C (or Ctrl-Z, etc.). If I try Ctrl-Break, I get what looks to be a very long stack trace, but the server is still running. The only way to stop it, is to close the terminal window entirely.

This only happens when running Django on Jython. On CPython, it's fine.

This also causes problems when entering data like setting the admin super user, etc. The data gets corrupted and is not entered correctly. So it seems to be a character encoding issue. I've googled all over the place and have not been able to find the answer. What am I doing wrong, or what do I need to do? Thanks.


Set the DJANGO_COLORS environment variable to nocolor in order to disable Django's attempts to colorize the output.

And then log a bug in the Django bug tracker.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜