#71: Preparsing causes confusing error messages
-------------------------------------------+----------------------------
Reporter: Justin Walker (justin@… | Owner: cwitty
Type: enhancement | Status: new
Priority: minor | Milestone: sage-feature
Component: misc | Resolution:
Keywords: | Merged in:
Authors: Jeroen Demeyer | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
Dependencies: | Stopgaps:
-------------------------------------------+----------------------------
Changes (by {'newvalue': u'Jeroen Demeyer', 'oldvalue': ''}):
* author: => Jeroen Demeyer
Old description:
> When a .sage file is "load"ed or "attach"ed, it gets translated to a .py
> file before being processed; the result is a file with different
> structure than the original. Any errors are described in terms of the
> .py file, not the .sage file.
>
> One possible solution would be to add a custom `excepthook` which
> translates the exception traceback from the `.py` file to the `.sage`
> file.
New description:
When a .sage file is "load"ed or "attach"ed, it gets translated to a .py
file before being processed; the result is a file with different structure
than the original. Any errors are described in terms of the .py file, not
the .sage file.
One working solution is to monkey-patch `traceback.extract_tb()` to undo
preparsing.
--
--
Ticket URL: <http://trac.sagemath.org/ticket/71#comment:10>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.