Textualize/rich

[REQUEST] Support python -m rich.traceback myscript.py

f0k opened this issue · 3 comments

f0k commented

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).

We found the following entry in the FAQ which you may find helpful:

Feel free to close this issue if you found an answer in the FAQ. Otherwise, please give us a little time to review.

This is an automated reply, generated by FAQtory

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