mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-04-12 10:30:58 +00:00
Use new get_encoded_writer() function.
This commit is contained in:
parent
ec8e529406
commit
b81fdd9b60
1 changed files with 2 additions and 2 deletions
|
|
@ -21,14 +21,14 @@ Check HTML pages for broken links. This is the GUI client.
|
|||
import sys
|
||||
from PyQt4.QtGui import QApplication, QStyleFactory, QErrorMessage
|
||||
from linkcheck.gui import LinkCheckerMain
|
||||
from linkcheck import configuration, drop_privileges
|
||||
from linkcheck import configuration, drop_privileges, i18n
|
||||
|
||||
def excepthook (debugwidget, etype, evalue, tb):
|
||||
"""Catch unhandled exceptions."""
|
||||
from cStringIO import StringIO
|
||||
from PyQt4.QtCore import qWarning
|
||||
from linkcheck.director.console import internal_error
|
||||
out = StringIO()
|
||||
out = i18n.get_encoded_writer(out=StringIO())
|
||||
internal_error(out=out, etype=etype, evalue=evalue, tb=tb)
|
||||
print >> out, debugwidget.getText()
|
||||
qWarning(out.getvalue())
|
||||
|
|
|
|||
Loading…
Reference in a new issue