[REQUEST] Support python -m rich.traceback myscript.py
f0k opened this issue · 3 comments
How would you improve Rich?
The Python debugger pdb
supports running a script with debugging enabled by changing the command line call from python myscript.py --args
to python -m pdb myscript.py --args
. It would be great to have the same functionality for running a script with rich tracebacks installed: python -m rich.traceback myscript.py --args
. The argument-less python -m rich.traceback
could continue to display an example as before.
What problem does it solve for you?
This feature would allow using rich tracebacks occasionally for debugging without requiring to change any code or installing sitecustomize.py
(especially when frequently changing environments).
I feel this is low priority. But happy to consider a PR!
I hope we solved your problem.
If you like using Rich, you might also enjoy Textual