Skip to content

RUM-16087: Catch Throwable.loggableStackTrace() throws#3458

Merged
kikoveiga merged 1 commit into
developfrom
kikoveiga/rum-16087/catch-loggable-stacktrace-throws
May 20, 2026
Merged

RUM-16087: Catch Throwable.loggableStackTrace() throws#3458
kikoveiga merged 1 commit into
developfrom
kikoveiga/rum-16087/catch-loggable-stacktrace-throws

Conversation

@kikoveiga

@kikoveiga kikoveiga commented May 20, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

  • Wrap Throwable.loggableStackTrace() in a try - catch block.

Motivation

Throwable.printStackTrace() can throw, as seen here, which would silently drop the entire crash report. According to my quick investigation, it might be due to older versions of kotlinx.coroutines that had an internal bug in how they handle state.

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Make sure you discussed the feature or bugfix with the maintaining team in an Issue
  • Make sure each commit and the PR mention the Issue number (cf the CONTRIBUTING doc)

@kikoveiga
kikoveiga force-pushed the kikoveiga/rum-16087/catch-loggable-stacktrace-throws branch 3 times, most recently from 4fb0038 to 13d6aea Compare May 20, 2026 15:19
@kikoveiga kikoveiga changed the title RUM-16087: Catch loggableStackTrace throws RUM-16087: Catch Throwable#loggableStackTrace throws May 20, 2026
@kikoveiga kikoveiga changed the title RUM-16087: Catch Throwable#loggableStackTrace throws RUM-16087: Catch Throwable.loggableStackTrace() throws May 20, 2026
@kikoveiga
kikoveiga marked this pull request as ready for review May 20, 2026 15:40
@kikoveiga
kikoveiga requested review from a team as code owners May 20, 2026 15:40

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 13d6aea655

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@kikoveiga
kikoveiga force-pushed the kikoveiga/rum-16087/catch-loggable-stacktrace-throws branch 2 times, most recently from 5293d29 to a0e66fa Compare May 20, 2026 16:03
@kikoveiga kikoveiga self-assigned this May 20, 2026
@datadog-prod-us1-5

This comment has been minimized.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
@kikoveiga
kikoveiga force-pushed the kikoveiga/rum-16087/catch-loggable-stacktrace-throws branch from a0e66fa to 2576337 Compare May 20, 2026 16:09
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 72.19%. Comparing base (057365c) to head (2576337).

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #3458      +/-   ##
===========================================
- Coverage    72.31%   72.19%   -0.12%     
===========================================
  Files          964      964              
  Lines        35500    35503       +3     
  Branches      5897     5898       +1     
===========================================
- Hits         25670    25629      -41     
- Misses        8237     8263      +26     
- Partials      1593     1611      +18     
Files with missing lines Coverage Δ
...com/datadog/android/internal/utils/ThrowableExt.kt 100.00% <100.00%> (ø)

... and 36 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@kikoveiga
kikoveiga merged commit 1c3f8e7 into develop May 20, 2026
27 checks passed
@kikoveiga
kikoveiga deleted the kikoveiga/rum-16087/catch-loggable-stacktrace-throws branch May 20, 2026 19:34
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.

3 participants