Closed Bug 1175991 Opened 10 years ago Closed 10 years ago

cset IDs on treeherder are inconsistently ellipsized (some are, some aren't), when browser chooses a wider font than we expect (e.g. due to bug 1173826)

Categories

(Tree Management :: Treeherder, defect, P4)

defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: dholbert, Assigned: jfrench)

Details

(Keywords: regression)

Attachments

(4 files)

STR: 1. Visit this URL: https://treeherder.mozilla.org/#/jobs?repo=mozilla-inbound&revision=3562a09b2bf3 or just visit the main m-i treeherder page and scroll down. ACTUAL RESULTS: csets IDs are inconsistently ellipsized. Screenshot coming up. It looks like they all *nearly* fit, but in most cases they're barely too wide and trigger an ellipsis. EXPECTED RESULTS: No ellipses. Or: consistent ellipses. (Maybe these should be rendered in a monospace font, so they're all the same width? At least then, if they're ellipsized, they'll all be ellipsized in the same way.)
Attached image screenshot
Here's a screenshot. Note that the last cset has no ellipsis (and _barely_ fits). The others have an ellipsis starting an an inconsistent x-position, which looks awkward. (They may have different numbers of characters being ellipsized, too; not sure.)
I think this is a recent regression; adding 'regression' keyword. These elements all have an explicit fixed width -- "width: 7.5em" -- which clearly may or may not be wide enough, depending on the width of the text (since we're using a variable-width font). If I remove that fixed-width, and instead substitute in "font-family: monospace; margin-right: 2px", then I get EXPECTED RESULTS, pretty much. (Alternately, if we don't want to use a monospace font, I think there may also be some CSS property that lets you ask for equal character spacing/positioning, without having to use a monospace font. I can't remember the name, but jfkthame probably does.)
Keywords: regression
This layout change occurred ~7 months ago to align resultset header bar contents when the job tables are collapsed. https://github.com/mozilla/treeherder-ui-deprecated/pull/282 We no longer have a job collapse button, so we could possibly revert the layout change and let them be ragged again. Curious Daniel are you running with non-default browser/OS font size? I don't think other folks have seen this on Ubuntu since the change a half year ago, per your screen grab. I could be wrong though. I haven't seen it on Win or OSX after the change. Trying right now altering my browser font or OS font sizes, I can't yet reproduce it.
Flags: needinfo?(dholbert)
(In reply to Jonathan French (:jfrench) from comment #3) > Curious Daniel are you running with non-default browser/OS font size? Nope. Also, I can't repro in current Firefox release, so there may be a recent browser regression (or behavior-change) involved here.
Flags: needinfo?(dholbert)
Interesting, thank you for the update! I wonder if Chrome looks the same as Firefox release, or if it looks the same as Nightly on your system? I had tried: OSX 10.10.3 Firefox Nightly, Release Chrome Opera* Safari* *unsupported on Treeherder I checked anyway for the clipping and it was fine also Win Firefox Release
There is indeed a recent browser regression here -- mozregression directed me to the patch for bug 1165693, which indeed seems to have caused us to sometimes pick the wrong font on linux (bug 1173826). Anyway -- I think it may still make sense to leave this bug open & fix TreeHerder to be more resilient here. In particular: - seems like we shouldn't be depending on precise assumptions about how many characters will fit into how many em's of width. If we intend to show the full 12-character csetID (and I think we do), we should size this element to its intrinsic size. - seems like we should be making these characters equally spaced, either via a monospace font or via whatever that CSS feature I'm remembering was, at the end of comment 2.
For reference, here's a screenshot from before the gecko regression (bug 1173826). As you can see, there's no ellipsizing here, but the cset IDs are still different widths, which IMO makes them a little hard to read. [and can cause issues/inconsistencies if a different font is chosen, as described above]
Summary: cset IDs on treeherder are inconsistently ellipsized (some are, some aren't) → cset IDs on treeherder are inconsistently ellipsized (some are, some aren't), when browser chooses a wider font than we expect (e.g. due to bug 1173826)
Assignee: nobody → tojonmz
Status: NEW → ASSIGNED
OS: Unspecified → All
Priority: -- → P4
Hardware: Unspecified → All
Attached file treeherder-PR662
Please see above PR for status and review.
Attachment #8624471 - Flags: review?(cdawson)
Attachment #8624471 - Flags: review?(cdawson) → review+
Marking fixed per above merge. Will verify on the next push to stage/prod.
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
I have a small nit to fix, the baseline text alignment is a bit out. So I will fix that.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Supplemental tweak PR. It's so tiny I just checked with camd over irc rather than flagging for review.
Status: REOPENED → RESOLVED
Closed: 10 years ago10 years ago
Resolution: --- → FIXED
Verified fixed on production.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: