mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
5a7dd0d331
commit
ce61de9ae1
@ -19,9 +19,13 @@ class Boss:
|
|||||||
document.title = 'calibre :: ' + self.current_library_name
|
document.title = 'calibre :: ' + self.current_library_name
|
||||||
|
|
||||||
def onerror(self, msg, script_url, line_number, column_number, error_object):
|
def onerror(self, msg, script_url, line_number, column_number, error_object):
|
||||||
fname = str.rpartition(script_url, '/')[-1] or script_url
|
try:
|
||||||
msg = msg + '<br><span style="font-size:smaller">' + str.format('Error at {}:{}:{}', fname, line_number, column_number or '') + '</span>'
|
fname = str.rpartition(script_url, '/')[-1] or script_url
|
||||||
details = ''
|
msg = msg + '<br><span style="font-size:smaller">' + str.format('Error at {}:{}:{}', fname, line_number, column_number or '') + '</span>'
|
||||||
if error_object and error_object.stack:
|
details = ''
|
||||||
details = error_object.stack
|
if error_object and error_object.stack:
|
||||||
error_dialog(_('Unhandled error'), msg, details)
|
details = error_object.stack
|
||||||
|
error_dialog(_('Unhandled error'), msg, details)
|
||||||
|
return True
|
||||||
|
except:
|
||||||
|
console.error('There was an error in the unhandled exception handler')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user