HeadersAlreadySentException
emit_http_headers called multiple (2) times! Headers: ['Content-Type: text/html; charset=utf-8', 'Status: 200 OK']
If you want to report a bug, please save this page and attach it to your bug report.
Traceback
A problem occurred in a Python script. Here is the
sequence of function calls leading up to the error, in the
order they occurred.
/home/user/workspace/moin-1.7/MoinMoin/request/__init__.py
in run
(self=<MoinMoin.request.request_standalone.Request object>)
- 1266 self.page.send_page(msg=msg)
- 1267 else:
- 1268 handler(self.page.page_name, self)
- 1269
- 1270 # every action that didn't use to raise MoinMoinFinish must call this now:
- handler
= <function execute>
- self
= <MoinMoin.request.request_standalone.Request object>
- self.page
= <MoinMoin.Page.Page object>
- self.page.page_name
= u'Example1'
/home/user/workspace/moin-1.7/MoinMoin/action/edit.py
in execute
(pagename=u'Example1', request=<MoinMoin.request.request_standalone.Request object>)
- 73 # is invoked without savetext start editing
- 74 if savetext is None or 'button_load_draft' in request.form:
- 75 pg.sendEditor()
- 76 return
- 77
- pg
= <MoinMoin.PageEditor.PageEditor object>
- pg.sendEditor
= <bound method PageEditor.sendEditor of <MoinMoin.PageEditor.PageEditor object>>
/home/user/workspace/moin-1.7/MoinMoin/PageEditor.py
in sendEditor
(self=<MoinMoin.PageEditor.PageEditor object>, **kw={})
- 198 # Did one of the prechecks fail?
- 199 if msg:
- 200 self.send_page(msg=msg)
- 201 return
- 202
- self
= <MoinMoin.PageEditor.PageEditor object>
- self.send_page
= <bound method PageEditor.send_page of <MoinMoin.PageEditor.PageEditor object>>
- msg
= u'This page is currently <em>locked</em> for editi... until 2007-07-23 14:17:38, i.e. for 1 minute(s).'
/home/user/workspace/moin-1.7/MoinMoin/Page.py
in send_page
(self=<MoinMoin.PageEditor.PageEditor object>, msg=u'This page is currently <em>locked</em> for editi... until 2007-07-23 14:17:38, i.e. for 1 minute(s).', **keywords={})
- 1094 else:
- 1095 request.setHttpHeader('Status: 404 NOTFOUND')
- 1096 request.emit_http_headers()
- 1097
- 1098 request.write(self.formatter.startDocument(self.page_name))
- request
= <MoinMoin.request.request_standalone.Request object>
- request.emit_http_headers
= <bound method Request.emit_http_headers of <MoinMoin.request.request_standalone.Request object>>
/home/user/workspace/moin-1.7/MoinMoin/request/__init__.py
in emit_http_headers
(self=<MoinMoin.request.request_standalone.Request object>, more_headers=[])
- 1312 self.sent_headers = sent_headers
- 1313 if sent_headers > 1:
- 1314 raise HeadersAlreadySentException("emit_http_headers called multiple (%d) times! Headers: %r" % (sent_headers, all_headers))
- 1315 #else:
- 1316 # self.log("Notice: emit_http_headers called first time. Headers: %r" % all_headers)
- global
HeadersAlreadySentException
= <class MoinMoin.request.HeadersAlreadySentException>
- sent_headers
= 2
- all_headers
= ['Content-Type: text/html; charset=utf-8', 'Status: 200 OK']
HeadersAlreadySentException
emit_http_headers called multiple (2) times! Headers: ['Content-Type: text/html; charset=utf-8', 'Status: 200 OK']
- args = ("emit_http_headers called multiple (2) times! Hea...ype: text/html; charset=utf-8', 'Status: 200 OK']",)
System Details
- Date: Mon, 23 Jul 2007 14:17:54 +0000
- Platform: Linux noname 2.6.18-2-k7 #1 SMP Wed Nov 8 20:38:36 UTC 2006 i686
- Python: Python 2.4.4 (/usr/bin/python)
- MoinMoin: Release 1.7.0alpha (release)