src/eric7/UI/ErrorLogDialog.py

branch
eric7
changeset 9221
bf71ee032bb4
parent 9209
b99e7fd55fd3
child 9473
3f23dbf37dbe
--- a/src/eric7/UI/ErrorLogDialog.py	Wed Jul 13 11:16:20 2022 +0200
+++ b/src/eric7/UI/ErrorLogDialog.py	Wed Jul 13 14:55:47 2022 +0200
@@ -20,10 +20,11 @@
     """
     Class implementing a dialog to display an error log.
     """
+
     def __init__(self, logFile, showMode, parent=None):
         """
         Constructor
-        
+
         @param logFile name of the log file containing the error info (string)
         @param showMode flag indicating to just show the error log message
             (boolean)
@@ -32,29 +33,29 @@
         super().__init__(parent)
         self.setupUi(self)
         self.setWindowFlags(Qt.WindowType.Window)
-        
+
         pixmap = (
-            self.style().standardIcon(
-                QStyle.StandardPixmap.SP_MessageBoxQuestion)
+            self.style()
+            .standardIcon(QStyle.StandardPixmap.SP_MessageBoxQuestion)
             .pixmap(32, 32)
         )
         self.icon.setPixmap(pixmap)
-        
+
         if showMode:
             self.icon.hide()
             self.label.hide()
             self.deleteButton.setText(self.tr("Delete"))
             self.keepButton.setText(self.tr("Close"))
             self.setWindowTitle(self.tr("Error Log"))
-        
+
         self.__ui = parent
         self.__logFile = logFile
-        
+
         with contextlib.suppress(OSError):
             with open(logFile, "r", encoding="utf-8") as f:
                 txt = f.read()
             self.logEdit.setPlainText(txt)
-    
+
     @pyqtSlot()
     def on_emailButton_clicked(self):
         """
@@ -62,8 +63,9 @@
         """
         self.accept()
         self.__ui.showEmailDialog(
-            "bug", attachFile=self.__logFile, deleteAttachFile=True)
-    
+            "bug", attachFile=self.__logFile, deleteAttachFile=True
+        )
+
     @pyqtSlot()
     def on_deleteButton_clicked(self):
         """
@@ -72,7 +74,7 @@
         if os.path.exists(self.__logFile):
             os.remove(self.__logFile)
         self.accept()
-    
+
     @pyqtSlot()
     def on_keepButton_clicked(self):
         """

eric ide

mercurial