1. Ronny Pfannschmidt
  2. py-hacks

Commits

holger krekel  committed 02d1c65

improve error message, fix changelog

  • Participants
  • Parent commits 0f5a580
  • Branches default

Comments (0)

Files changed (2)

File CHANGELOG

View file
+Changes between 1.4.1 and 1.4.2
+==================================================
+
+- fix (pytest) issue23 - tmpdir argument now works on Python3.2 and WindowsXP
+  (which apparently starts to offer os.symlink now)
+
+- better error message for syntax errors from compiled code
+
 Changes between 1.4.0 and 1.4.1
 ==================================================
 

File py/_code/source.py

View file
             msglines = self.lines[:ex.lineno]
             if ex.offset:
                 msglines.append(" "*ex.offset + '^')
-            msglines.append("syntax error probably generated here: %s" % filename)
+            msglines.append("(code was compiled probably from here: %s)" % filename)
             newex = SyntaxError('\n'.join(msglines))
             newex.offset = ex.offset
             newex.lineno = ex.lineno