black screen fix

This commit is contained in:
Neythen Treloar 2022-04-07 18:37:29 +01:00
commit 1e7dca59f2

View File

@ -972,6 +972,7 @@ class StockTicker():
image_list.append(self.blank)
except Exception as e:
logf = open('log.txt', "a")
exc_type, exc_obj, exc_tb = sys.exc_info()
fname = os.path.split(exc_tb.tb_frame.f_code.co_filename)[1]
@ -982,6 +983,7 @@ class StockTicker():
logf.write('\n ' + "".join(traceback.format_exception(sys.exc_info()[0], sys.exc_info()[1], sys.exc_info()[2])))
logf.close()
finalDisplayImage = self.stitchImage(image_list)
return finalDisplayImage
@ -1305,6 +1307,7 @@ class StockTicker():
image_list.append(self.blank)
except Exception as e:
logf = open('log.txt', "a")
exc_type, exc_obj, exc_tb = sys.exc_info()
fname = os.path.split(exc_tb.tb_frame.f_code.co_filename)[1]
@ -1314,6 +1317,7 @@ class StockTicker():
logf.write('. type: ' + str(exc_type))
logf.write('\n ' + "".join(traceback.format_exception(sys.exc_info()[0], sys.exc_info()[1], sys.exc_info()[2])))
logf.close()
finalDisplayImage = self.stitchImage(image_list)
@ -2801,6 +2805,7 @@ if __name__ == '__main__':
stock_ticker = StockTicker()
stock_ticker.process_msg('A')
while True:
msg = getInput()
stock_ticker.process_msg(msg)
@ -2814,6 +2819,7 @@ if __name__ == '__main__':
logf.write('. type: ' + str(exc_type))
logf.write('\n ' + "".join(traceback.format_exception(sys.exc_info()[0], sys.exc_info()[1], sys.exc_info()[2])))
logf.close()