Fixed a few issues in the PEP-8 checker for Python 2.

Mon, 26 Sep 2011 18:07:55 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Mon, 26 Sep 2011 18:07:55 +0200
changeset 1339
913182fdc3dd
parent 1338
4d0b50ef28cb
child 1341
6104ae9ceb55

Fixed a few issues in the PEP-8 checker for Python 2.

Plugins/CheckerPlugins/Pep8/Pep8Checker.py file | annotate | diff | comparison | revisions
diff -r 4d0b50ef28cb -r 913182fdc3dd Plugins/CheckerPlugins/Pep8/Pep8Checker.py
--- a/Plugins/CheckerPlugins/Pep8/Pep8Checker.py	Mon Sep 19 18:41:19 2011 +0200
+++ b/Plugins/CheckerPlugins/Pep8/Pep8Checker.py	Mon Sep 26 18:07:55 2011 +0200
@@ -138,9 +138,9 @@
         
         interpreter = Preferences.getDebugger("PythonInterpreter")
         if interpreter == "" or not Utilities.isExecutable(interpreter):
-            self.messages.append(filename, "1", "1",
+            self.messages.append((filename, 1, 1,
                 QCoreApplication.translate("Pep8Py2Checker",
-                    "Python2 interpreter not configured."))
+                    "Python2 interpreter not configured.")))
             return
         
         checker = os.path.join(getConfig('ericDir'),
@@ -168,7 +168,7 @@
                         Preferences.getSystem("IOEncoding"),
                         'replace').splitlines()
             if output[0] == "ERROR":
-                self.messages.append(filename, "1", "1", output[2])
+                self.messages.append((filename, 1, 1, output[2]))
                 return
             
             if output[0] == "NO_PEP8":
@@ -199,6 +199,6 @@
                 self.statistics[code] = int(countStr)
                 index += 1
         else:
-            self.messages.append(filename, "1", "1",
+            self.messages.append((filename, 1, 1,
                 QCoreApplication.translate("Pep8Py2Checker",
-                    "Python2 interpreter did not finish within 15s."))
+                    "Python2 interpreter did not finish within 15s.")))

eric ide

mercurial