diff --git a/pyqode/python/widgets/interactive.py b/pyqode/python/widgets/interactive.py
index <HASH>..<HASH> 100644
--- a/pyqode/python/widgets/interactive.py
+++ b/pyqode/python/widgets/interactive.py
@@ -30,9 +30,8 @@ class PyInteractiveConsole(InteractiveConsole):
         self.set_writer(self._write)
         self.setMouseTracking(True)
         self.PROG = QtCore.QRegExp(
-            r'\s*File "[a-zA-Z\/_\d:\\\.]*((.\.[a-zA-Z\/_\d:\\]*")|(")), '
-            r'line [0-9]*.*')
-        self.FILENAME_PROG = QtCore.QRegExp(r'"[a-zA-Z\/_\.\d:\\]*"')
+            r'\s*File ".*", line [0-9]*, in ')
+        self.FILENAME_PROG = QtCore.QRegExp(r'".*"')
         self.LINE_PROG = QtCore.QRegExp(r'line [0-9]*')
         self.setLineWrapMode(self.NoWrap)
         self._module_color = QtGui.QColor('blue')
Simplify PyInteractiveConsole file regex

and fix bug if exception occur in dist-packages (there was an issue with the previous regex which did not take '-' into account)