Re: [sage-devel] strange error message when raising an Error in cython()

2019-02-13 Thread Jeroen Demeyer
You can ignore that "An unexpected error occurred while tokenizing input" message. It's IPython having trouble with the traceback, it has nothing to do with your Cython code. -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from th

Re: [sage-devel] strange error message when raising an Error in cython()

2019-02-13 Thread jonathan.kliem via sage-devel
Is this normal behaviour? ERROR:root:An unexpected error occurred while tokenizing input The following traceback may be corrupted or invalid The error message is: ('EOF in multi-line string', (1, 0)) I guess I can just do sage: cython(''' : c = 2 : try: : if c == 2: :

Re: [sage-devel] strange error message when raising an Error in cython()

2019-02-13 Thread Jeroen Demeyer
On 2019-02-13 11:02, jonathan.kliem via sage-devel wrote: I'm getting a strange error when raising an error in cython(), example: I don't really understand your problem. You ask Cython to raise an exception and the exception is raised. It seems like Cython is doing exactly what it's supposed

[sage-devel] strange error message when raising an Error in cython()

2019-02-13 Thread jonathan.kliem via sage-devel
I'm getting a strange error when raising an error in cython(), example: sage: cython(''' : c = 2 : if c == 2: : raise IndexError() : ''') ERROR:root:An unexpected error occurred while tokenizing input The following traceback may be corrupted or invalid The error message is: ('E