New issue
Advanced search Search tips

Issue 837863 link

Starred by 2 users

Issue metadata

Status: WontFix
Owner:
Closed: Nov 16
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 3
Type: Bug



Sign in to add a comment

Emoji with combining characters are truncated oddly in performance user timing pane

Reported by joe.lenc...@airbnb.com, Apr 28 2018

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.117 Safari/537.36

Steps to reproduce the problem:
1. Create a user timing with performance.mark and performance.measure that has an emoji with combining character in it. (e.g. \ud83d\udc69\u200d\ud83c\udfa8)
2. Record a performance profile
3. Zoom in and out of the user timing pane so the text is truncated

What is the expected behavior?
Emoji is stable

What went wrong?
Emoji changes based on text truncation

Did this work before? No 

Chrome version: 68.0.3410.0  Channel: canary
OS Version: OS X 10.13.4
Flash Version: 

I believe the truncation logic probably uses basic string length, which is 5 for the single emoji character I used above.
 
emojibug.gif
628 KB View Download
Depending on how this tool works under the hood, this problem might also exist outside of devtools
Labels: Needs-Triage-M68
Labels: Triaged-ET Needs-Feedback
Thanks for filing the issue!

@Reporter: Could you please provide sample test file/URL that reproduces the issue which help in further triaging it.

Thanks!
Project Member

Comment 5 by sheriffbot@chromium.org, May 2 2018

Cc: viswa.karala@chromium.org
Labels: -Needs-Feedback
Thank you for providing more feedback. Adding the requester to the cc list.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Owner: l...@chromium.org
Status: Assigned (was: Unconfirmed)
The truncation logic is here: https://cs.chromium.org/chromium/src/third_party/blink/renderer/devtools/front_end/platform/utilities.js?sq=package:chromium&l=180


Comment 7 by l...@chromium.org, May 21 2018

Labels: -Pri-2 Pri-3
It looks like our trimming logic is too simple.  We just truncate at the nearest whole codepoint.  The example in the JSFiddle uses '\u200d', the zero-width joiner to make a modifier sequence.

By spec [1], there are a lot of sequence types: modifier sequences, tag sequences, regional modifier sequences.  A full solution involves implementing checks for all of these + a way to detect support for Emojis on the display.

[1] https://www.unicode.org/reports/tr51/tr51-9.html
Status: WontFix (was: Assigned)
Fixing this is a lot of effort for a corner case.  Since there is an easy workaround (resizing), closing.

Sign in to add a comment