Closed Bug 1571517 Opened 5 years ago Closed 5 years ago

Whitespace-only table cell breaks copy to clipboard

Categories

(Core :: Layout: Tables, defect, P3)

68 Branch
Desktop
All
defect

Tracking

()

RESOLVED FIXED
mozilla70
Tracking Status
firefox-esr60 --- wontfix
firefox-esr68 --- wontfix
firefox68 --- wontfix
firefox69 --- wontfix
firefox70 --- fixed

People

(Reporter: abbeyj+bugzilla, Assigned: emilio)

References

(Regression)

Details

(Keywords: regression, testcase)

Attachments

(2 files)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Firefox/68.0

Steps to reproduce:

Having a table cell that is whitespace-only can break trying to copy to the clipboard from an adjacent table cell.

  1. Load attached test case
  2. Click and hold on the right part of the blue border. Drag-select to the left part of the green border.
  3. Press Ctrl+C

Actual results:

Nothing. The clipboard contents are unchanged. No error messages appear in either the web console or the browser console.

Expected results:

The clipboard contents should have been changed to "Hello" (or "\tHello" or similar)

Attached file table_cell.html

Using mozregression-gui I've narrowed this down. It was not able to finish successfully but it did narrow it down to a one day window.

Last known good:
app_name: firefox
build_date: 2018-01-31
build_file: C:\Users\jabbatiello.mozilla\mozregression\persist\2018-01-31--mozilla-central--firefox-60.0a1.en-US.win64.zip
build_type: nightly
build_url: https://archive.mozilla.org/pub/firefox/nightly/2018/01/2018-01-31-22-03-03-mozilla-central/firefox-60.0a1.en-US.win64.zip
changeset: 3804441e575c9f46fcb03894de3c780eeae7197f
pushlog_url: https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=3804441e575c9f46fcb03894de3c780eeae7197f&tochange=9207588939fdb5355f12c9b48efe733daaa3725e
repo_name: mozilla-central
repo_url: https://hg.mozilla.org/mozilla-central

First known bad:
app_name: firefox
build_date: 2018-02-01
build_file: C:\Users\jabbatiello.mozilla\mozregression\persist\2018-02-01--mozilla-central--firefox-60.0a1.en-US.win64.zip
build_type: nightly
build_url: https://archive.mozilla.org/pub/firefox/nightly/2018/02/2018-02-01-22-02-25-mozilla-central/firefox-60.0a1.en-US.win64.zip
changeset: ee7f64d0764961e9663c681efc8d2b3759af79d6
pushlog_url: https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=3804441e575c9f46fcb03894de3c780eeae7197f&tochange=ee7f64d0764961e9663c681efc8d2b3759af79d6
repo_name: mozilla-central
repo_url: https://hg.mozilla.org/mozilla-central

Errors from the mozregression-gui log:
2019-08-05T15:01:19: CRITICAL : First build 3804441e575c is missing, but mozregression can't find a build before - so it is excluded, but it could contain the regression!
2019-08-05T15:01:24: CRITICAL : Last build ee7f64d07649 is missing, but mozregression can't find a build after - so it is excluded, but it could contain the regression!

Status: UNCONFIRMED → NEW
Has Regression Range: --- → yes
Has STR: --- → yes
Component: Untriaged → Layout: Tables
Ever confirmed: true
Keywords: regression, testcase
OS: Unspecified → All
Product: Firefox → Core
Hardware: Unspecified → Desktop

I narrowed this down to https://hg.mozilla.org/mozilla-central/rev/c41e1dcbc77afd39f79fa34f7b1c6baa4fc29713. At 402091 things work and at 402127 it is broken.

Flags: needinfo?(emilio)
Regressed by: 1423331

Huh, that's quite bizarre... I'll look into it.

Assignee: nobody → emilio
Flags: needinfo?(emilio)

We have a range that starts at the end of a cell, and ends somewhere else.

We were bailing out recursively from the beginning, causing the serialization to
be the empty string rather than the actually selected text.

Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/5bf902f7f64c
Don't bail out when serializing a range starting at the end of an element. r=mbrodesser

The priority flag is not set for this bug.
:dholbert, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(dholbert)
Flags: needinfo?(dholbert)
Priority: -- → P3
Upstream web-platform-tests status checks passed, PR will merge once commit reaches central.
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla70
Upstream PR merged by moz-wptsync-bot
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: