Skip to content

Conversation

@reteps
Copy link

@reteps reteps commented Feb 10, 2026

Summary

  • Adds a show_border parameter to Traceback, Traceback.from_exception(), install(), and Console.print_exception()
  • When show_border=False, tracebacks render without the Panel border, using a plain text title instead
  • Useful for embedding tracebacks in contexts where the Panel border adds unwanted visual noise

Test plan

  • test_show_border_true: Verifies default rendering includes box-drawing characters
  • test_show_border_false: Verifies borderless rendering has no box-drawing chars but preserves content
  • All existing traceback tests pass
  • mypy strict mode passes
  • black formatting clean

🤖 Generated with Claude Code

When show_border=False, tracebacks render without the Panel border,
using a plain text title instead. This is useful for embedding tracebacks
in contexts where the Panel border adds unwanted visual noise.

The parameter is added to Traceback.__init__(), Traceback.from_exception(),
install(), and Console.print_exception().

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@reteps reteps marked this pull request as ready for review February 10, 2026 19:49
@reteps
Copy link
Author

reteps commented Feb 10, 2026

I did not see any policy for AI-assisted contributions, but please let me know if I should close this. This is a feature I monkey-patched for my own needs I thought might be useful to others, so I am upstreaming it. Thanks!

@reteps
Copy link
Author

reteps commented Feb 10, 2026

In my case, I wanted to use Rich primarily for syntax highlighting, and I don't want the panel behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant