Skip to content

Conversation

@jonathanmos
Copy link
Member

@jonathanmos jonathanmos commented Nov 3, 2025

What does this PR do?

The wireframe schema has been updated to allow sending text truncation mode. Possible modes are:

head
middle
tail
clip

This pr:
• Updates the session replay schema
• Captures and sends truncation mode for native
• Captures and sends truncation mode for compose
• Fixes a small issue with the sample application where it wasn't respecting system windows bounds

Depends on DataDog/rum-events-format#318
Related to DataDog/dd-sdk-ios#2550

Motivation

• Align with iOS on sending text truncation
• More accurate presentation of text when it overflows the bounds of the container.

Additional Notes

Anything else we should know when reviewing?

Review checklist (to be filled by reviewers)

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

@datadog-official
Copy link

datadog-official bot commented Nov 3, 2025

🎯 Code Coverage
Patch Coverage: 100.00%
Total Coverage: 70.96% (+0.11%)

View detailed report

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 53d2a45 | Docs | Datadog PR Page | Was this helpful? Give us feedback!

@codecov-commenter
Copy link

codecov-commenter commented Nov 3, 2025

Codecov Report

❌ Patch coverage is 78.48101% with 17 lines in your changes missing coverage. Please review.
✅ Project coverage is 70.87%. Comparing base (ee38a9a) to head (53d2a45).
⚠️ Report is 247 commits behind head on develop.

Files with missing lines Patch % Lines
...ionreplay/compose/internal/utils/SemanticsUtils.kt 77.78% 6 Missing and 8 partials ⚠️
...l/mappers/semantics/AbstractSemanticsNodeMapper.kt 50.00% 1 Missing ⚠️
...y/compose/internal/reflection/ComposeReflection.kt 0.00% 1 Missing ⚠️
...onreplay/compose/internal/utils/ReflectionUtils.kt 0.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2978      +/-   ##
===========================================
- Coverage    70.91%   70.87%   -0.04%     
===========================================
  Files          829      829              
  Lines        30381    30452      +71     
  Branches      5184     5201      +17     
===========================================
+ Hits         21543    21581      +38     
- Misses        7373     7390      +17     
- Partials      1465     1481      +16     
Files with missing lines Coverage Δ
...mpose/internal/mappers/semantics/TextLayoutInfo.kt 85.71% <100.00%> (+2.38%) ⬆️
...id/sessionreplay/recorder/mapper/TextViewMapper.kt 91.23% <100.00%> (+0.57%) ⬆️
...l/mappers/semantics/AbstractSemanticsNodeMapper.kt 75.47% <50.00%> (+0.47%) ⬆️
...y/compose/internal/reflection/ComposeReflection.kt 0.00% <0.00%> (ø)
...onreplay/compose/internal/utils/ReflectionUtils.kt 1.35% <0.00%> (-0.02%) ⬇️
...ionreplay/compose/internal/utils/SemanticsUtils.kt 68.13% <77.78%> (+3.21%) ⬆️

... and 27 files with indirect coverage changes

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

@jonathanmos jonathanmos marked this pull request as ready for review November 13, 2025 09:36
@jonathanmos jonathanmos requested review from a team as code owners November 13, 2025 09:36
0xnm
0xnm previously approved these changes Nov 13, 2025
@jonathanmos jonathanmos dismissed stale reviews from 0xnm and ambushwork via 53d2a45 November 13, 2025 13:14
whenever(mockResult.action) doReturn mockAction
whenever(textLayoutResult.layoutInput) doReturn mockTextLayoutInput
doAnswer { invocation ->
@Suppress("UNCHECKED_CAST")
Copy link
Member

Choose a reason for hiding this comment

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

very nit: to avoid this Suppress, you can use invocation.getArgument<MutableList<TextLayoutResult>(0) API

@jonathanmos jonathanmos merged commit 5cec742 into develop Nov 20, 2025
26 checks passed
@jonathanmos jonathanmos deleted the jmoskovich/pana-4799/text-truncation branch November 20, 2025 09:13
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.

5 participants