[IPython-dev] fix_frame_records_filenames() messes up Cython tracebacks
Matthias BUSSONNIER
bussonniermatthias at gmail.com
Thu Nov 20 10:55:41 EST 2014
Le 20 nov. 2014 à 16:04, Jeroen Demeyer a écrit :
> In IPython/core/ultratb.py, the fix_frame_records_filenames() tries to
> "correct" filenames in tracebacks. However, for tracebacks coming from
> Cython, this actually replaces the perfectly fine .pyx source filename
> by the compiled .so filename.
>
> So here is a suggestion: in fix_frame_records_filenames(), check that
> the better_fn() is not a binary file(*) and only then do the
> replacement. This would be easy to implement, any objections?
>
> I am asking this because Sage heavily uses Cython and this is annoying.
I don't see any reason not to improve current logic.
From your description, I suppose we could also whitelist extensions ?
--
M
>
>
> (*) the standard way of doing this is to check for \x00 bytes.
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev
More information about the IPython-dev
mailing list