fix cgitb
This commit is contained in:
parent
393402df60
commit
e8c092a351
14 changed files with 14 additions and 14 deletions
|
@ -163,7 +163,7 @@ class OpencvWidget(QLabel):
|
|||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
app = QApplication(sys.argv)
|
||||
w = OpencvWidget()
|
||||
w.show()
|
||||
|
|
|
@ -38,7 +38,7 @@ class Window(QWidget, QCursorGif):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
|
|
|
@ -141,7 +141,7 @@ class Window(QWidget):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
|
|
|
@ -91,7 +91,7 @@ class Window(QWidget):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, 'text')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
|
|
|
@ -79,7 +79,7 @@ class Window(QListWidget):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
# 通过qss改变按钮的高度
|
||||
|
|
|
@ -70,7 +70,7 @@ class Window(QWidget):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, 'text')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
|
|
|
@ -220,7 +220,7 @@ class Window(QWidget):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
|
|
|
@ -139,7 +139,7 @@ class Window(QWidget, Ui_FormSerialPort):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
|
|
|
@ -78,7 +78,7 @@ class DemoWindow(QWidget):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
w = DemoWindow()
|
||||
|
|
|
@ -75,7 +75,7 @@ class Window(QWidget):
|
|||
if __name__ == '__main__':
|
||||
import sys
|
||||
import cgitb
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
from PyQt5.QtWidgets import QApplication
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
|
|
|
@ -185,7 +185,7 @@ if __name__ == "__main__":
|
|||
# 开启F12 控制台功能,需要单独通过浏览器打开这个页面
|
||||
# 这里可以做个保护, 发布软件,启动时把这个环境变量删掉。防止他人通过环境变量开启
|
||||
os.environ['QTWEBENGINE_REMOTE_DEBUGGING'] = '9966'
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
w.show()
|
||||
|
|
|
@ -68,7 +68,7 @@ class WebView(QWebView):
|
|||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
app = QApplication(sys.argv)
|
||||
w = WebView()
|
||||
w.show()
|
||||
|
|
|
@ -165,7 +165,7 @@ class Window(QWidget):
|
|||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.excepthook = cgitb.enable(1, None, 5, '')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
app = QApplication(sys.argv)
|
||||
w = Window()
|
||||
w.show()
|
||||
|
|
|
@ -132,7 +132,7 @@ if __name__ == '__main__':
|
|||
import cgitb
|
||||
import os
|
||||
os.makedirs('tmp', exist_ok=True)
|
||||
sys.excepthook = cgitb.enable(1, None, 5, 'text')
|
||||
cgitb.enable(1, None, 5, '')
|
||||
app = QApplication(sys.argv)
|
||||
loop = QEventLoop(app)
|
||||
asyncio.set_event_loop(loop)
|
||||
|
|
Loading…
Reference in a new issue