mirror of
https://github.com/moparisthebest/SickRage
synced 2025-01-07 03:48:02 -05:00
Added code to check if title present when error report being submitted to GH is present.
This commit is contained in:
parent
422f0935d8
commit
ca0c98c913
@ -272,7 +272,9 @@ class UIError():
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
def __init__(self, message):
|
def __init__(self, message):
|
||||||
self.title = sys.exc_info()[1].message or None
|
try:self.title = sys.exc_info()[1].message
|
||||||
|
except:self.title = None
|
||||||
self.message = message
|
self.message = message
|
||||||
self.time = datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')
|
self.time = datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S')
|
||||||
self.exc_info = sys.exc_info() or None
|
try:self.exc_info = sys.exc_info()
|
||||||
|
except:self.exc_info = None
|
||||||
|
@ -157,6 +157,9 @@ class Logger(object):
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
for curError in sorted(classes.ErrorViewer.errors, key=lambda error: error.time, reverse=True)[:500]:
|
for curError in sorted(classes.ErrorViewer.errors, key=lambda error: error.time, reverse=True)[:500]:
|
||||||
|
if not curError.title:
|
||||||
|
continue
|
||||||
|
|
||||||
message = u"### INFO\n"
|
message = u"### INFO\n"
|
||||||
message += u"Python Version: **" + sys.version[:120] + "**\n"
|
message += u"Python Version: **" + sys.version[:120] + "**\n"
|
||||||
message += u"Operating System: **" + platform.platform() + "**\n"
|
message += u"Operating System: **" + platform.platform() + "**\n"
|
||||||
|
Loading…
Reference in New Issue
Block a user