Improve error toast readability#2371
Conversation
Error toasts could grow taller than the screen and sometimes showed the
same message in both the title and the description. Cap the title height,
split .NET error strings at the inner-exception marker (" ---> ") as well
as the first stack frame so the title stays short, and de-duplicate JS
errors whose stack already repeats the message. Also fix the copy-button
checkmark, which rendered white (invisible) in light mode.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
📝 WalkthroughWalkthroughUpdates ChangesError parsing improvements and toast icon scoping
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Caution Failed to replace (edit) comment. This is likely due to insufficient permissions or the comment being deleted. Error details |
|
The latest updates on your projects. Learn more about Argos notifications ↗︎
|
Derive the display title once in unifyErrorEvent — Error.toString(), which keeps the error type (e.g. "TypeError: …") and drops the browser's "Uncaught" prefix — instead of re-deriving it in processErrorIntoDetails. Consistent across thrown Errors, ErrorEvents, and promise rejections, and it keeps the type visible (the earlier event.error.message dropped it entirely once the stack header was stripped from the detail). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
bc09d18 to
cb190f2
Compare
Error toasts could grow taller than the screen and sometimes showed the same message in both the title and the description. This caps the title height, splits .NET error strings at the inner-exception marker (` ---> `) as well as at the first stack frame so the title stays short, and de-duplicates JS errors whose stack already repeats the message. Also fixes the copy-button checkmark, which rendered white (invisible) in light mode.
Frontend-only; unit tests cover the error-string parsing. Not yet visually verified on a device.
Before:

After:

Before:

After:

🤖 Generated with Claude Code