[Buildbot-commits] [Buildbot] #951: UTF-8 data in logs causes web rss feed exception
Buildbot trac
trac at buildbot.net
Wed Jan 29 15:24:34 UTC 2014
#951: UTF-8 data in logs causes web rss feed exception
--------------------+----------------------
Reporter: AHowell | Owner: AHowell
Type: defect | Status: closed
Priority: major | Milestone: 0.8.2
Version: 0.8.1 | Resolution: fixed
Keywords: web |
--------------------+----------------------
Changes (by dustin):
* status: reopened => closed
* resolution: => fixed
Old description:
> Traceback (most recent call last):
> File "/usr/lib/python2.7/site-
> packages/twisted/protocols/basic.py", line 251, in dataReceived
> why = self.lineReceived(line)
> File "/usr/lib/python2.7/site-packages/twisted/web/http.py",
> line 1573, in lineReceived
> self.allContentReceived()
> File "/usr/lib/python2.7/site-packages/twisted/web/http.py",
> line 1641, in allContentReceived
> req.requestReceived(command, path, version)
> File "/usr/lib/python2.7/site-packages/twisted/web/http.py",
> line 807, in requestReceived
> self.process()
> --- <exception caught here> ---
> File "/usr/lib/python2.7/site-packages/twisted/web/server.py",
> line 125, in process
> self.render(resrc)
> File "/usr/lib/python2.7/site-packages/twisted/web/server.py",
> line 132, in render
> body = resrc.render(self)
> File "/usr/lib/python2.7/site-
> packages/buildbot/status/web/feeds.py", line 40, in render
> data = self.content(request)
> File "/usr/lib/python2.7/site-
> packages/buildbot/status/web/feeds.py", line 202, in content
> log_lines.extend(unicode(logdata.split('
> ')[-30:],'utf-8'))
> exceptions.TypeError: coercing to Unicode: need string or buffer,
> list found
New description:
Traceback (most recent call last):
File "/usr/lib/python2.7/site-
packages/twisted/protocols/basic.py", line 251, in dataReceived
why = self.lineReceived(line)
File "/usr/lib/python2.7/site-packages/twisted/web/http.py",
line 1573, in lineReceived
self.allContentReceived()
File "/usr/lib/python2.7/site-packages/twisted/web/http.py",
line 1641, in allContentReceived
req.requestReceived(command, path, version)
File "/usr/lib/python2.7/site-packages/twisted/web/http.py",
line 807, in requestReceived
self.process()
--- <exception caught here> ---
File "/usr/lib/python2.7/site-packages/twisted/web/server.py",
line 125, in process
self.render(resrc)
File "/usr/lib/python2.7/site-packages/twisted/web/server.py",
line 132, in render
body = resrc.render(self)
File "/usr/lib/python2.7/site-
packages/buildbot/status/web/feeds.py", line 40, in render
data = self.content(request)
File "/usr/lib/python2.7/site-
packages/buildbot/status/web/feeds.py", line 202, in content
log_lines.extend(unicode(logdata.split('
')[-30:],'utf-8'))
exceptions.TypeError: coercing to Unicode: need string or buffer,
list found
--
Comment:
There's a much better fix in nine (logs are stored in unicode), but this
fix is fine for 0.8.x.
{{{
commit fdf1f2fdd731403ed96517777429e59531c41a37
Author: Dustin J. Mitchell <dustin at mozilla.com>
Date: Wed Jan 29 10:23:42 2014 -0500
Ignore decoding errors in atom/rss feeds; fixes #951
}}}
--
Ticket URL: <http://trac.buildbot.net/ticket/951#comment:6>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation
More information about the Commits
mailing list