You can control what the traceback of exceptions you are emitting: 

"raise e.with_traceback(None)" should clear everything before the current 
frame. 

Or you can get clever and construct a traceback with only the frames you want.


On Saturday, May 29, 2021, 08:27:18 PM GMT+1, André Roberge 
<andre.robe...@gmail.com> wrote:

What I am interested in is having a project-agnostic standardised Python way to 
specify what to show to an end-user when an exception is raised.

  
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/RMA5Y567KY7LYP3BFWGBR57NGD6JBBOJ/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to