1 Star 0 Fork 14

vitocor131/哔哩BCM_1

forked from Oops404/哔哩BCM 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
executor.pyw 1.40 KB
一键复制 编辑 原始数据 按行查看 历史
Oops404 提交于 2022-07-18 10:16 . fix cache title parse exception
# -*- coding: UTF-8-*-
# author: cheneyjin@outlook.com
# update 20220718
import traceback
import _thread
import json
import logging
import os
import re
import sys
import uuid
import time
from subprocess import Popen, PIPE
from PyQt5 import QtCore, QtWidgets, QtGui
from PyQt5.QtGui import QIcon, QTextCursor
from PyQt5.QtWidgets import QMainWindow, QApplication
import cgitb
from cm import UiMainWindow
# import qdarkstyle
cgitb.enable(format='text')
logging.basicConfig(
level=logging.INFO,
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s',
filename='log.md'
)
logger = logging.getLogger(__name__)
logger.addHandler(logging.StreamHandler(stream=sys.stdout))
def handle_exception(exc_type, exc_value, exc_traceback):
if issubclass(exc_type, KeyboardInterrupt):
sys.__excepthook__(exc_type, exc_value, exc_traceback)
return
logger.error("Uncaught exception", exc_info=(exc_type, exc_value, exc_traceback))
sys.excepthook = handle_exception
if __name__ == '__main__':
try:
app = QApplication(sys.argv)
MainWindow = QMainWindow()
# app.setStyleSheet(qdarkstyle.load_stylesheet_pyqt5())
# app.setStyleSheet(qdarkstyle.load_stylesheet(qt_api='pyqt5'))
ui = UiMainWindow(logger)
ui.setup_ui(MainWindow)
MainWindow.show()
sys.exit(app.exec_())
except Exception as e:
logger.error(traceback.format_exc())
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Python
1
https://gitee.com/ericw131/bcm_1.git
git@gitee.com:ericw131/bcm_1.git
ericw131
bcm_1
哔哩BCM_1
master

搜索帮助