Deleted element in inspector is incorrectly restored on Ctrl+Z, if whitespace text node is present

RESOLVED FIXED in Firefox 55

Status

P1
normal
RESOLVED FIXED
2 years ago
3 months ago

People

(Reporter: 684sigma, Assigned: jdescottes)

Tracking

({regression})

55 Branch
Firefox 55
regression
Bug Flags:
in-qa-testsuite +

Firefox Tracking Flags

(firefox-esr52 unaffected)

Details

Attachments

(1 attachment)

(Reporter)

Description

2 years ago
I decided to check how Bug 1345529 was fixed, and noticed a new bug in Nightly 55 (2017-04-11). It doesn't happen in earlier versions, but I don't know if it should be threated like a new bug, because delete operation in markup is partially broken since Bug 1304685
Here's how to reproduce the bug:

1. Navigate to this url - data:text/html,<div><p><a>test1</a> <b>test2</b></p></div>
2. Open inspector, delete node <a>
3. Press Ctrl+Z

Result: Sequence of elements in markup: <b>, then <a>
Expected: Sequence of elements in markup: <a>, then <b>
(Reporter)

Comment 1

2 years ago
Mozregression-gui generated this regression range:
https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=e2bcdd1501405f8bc8e5841a06088fd3fc179878&tochange=d508a91f09e9de268da1b7831c823c6a42f16526
->
1345529 – [Regression] Partially elements may lost when remove element in Inspector
https://bugzilla.mozilla.org/show_bug.cgi?id=1345529
Blocks: 1345529
Has Regression Range: --- → yes
Has STR: --- → yes
Keywords: regression

Updated

2 years ago
status-firefox52: --- → unaffected
status-firefox53: --- → unaffected
status-firefox54: --- → unaffected
status-firefox55: --- → affected
Assignee: nobody → jdescottes
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Priority: -- → P1
Comment hidden (mozreview-request)
try: https://treeherder.mozilla.org/#/jobs?repo=try&revision=57224f12d8e47b208abab450eeb5ed2a1fe356de 

(the eslint failure was fixed in the version submitted to mozreview)

Comment 4

2 years ago
mozreview-review
Comment on attachment 8857574 [details]
Bug 1355886 - fix regression when undoing delete node next to a whitespace sibling;

https://reviewboard.mozilla.org/r/129552/#review132900
Attachment #8857574 - Flags: review?(pbrosset) → review+

Comment 5

2 years ago
Pushed by jdescottes@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/86b5e409e093
fix regression when undoing delete node next to a whitespace sibling;r=pbro
https://hg.mozilla.org/mozilla-central/rev/86b5e409e093
Status: ASSIGNED → RESOLVED
Last Resolved: 2 years ago
status-firefox55: affected → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 55
status-firefox-esr52: --- → unaffected

Comment 7

2 years ago
I have reproduced this bug with Nightly 55.0a1 (2017-04-12) on Windows 8.1 , 64 Bit ! 

This bug's fix is Verified with latest Nightly !

Build   ID    20170419030223
User Agent    Mozilla/5.0 (Windows NT 6.3; WOW64; rv:55.0) Gecko/20100101 Firefox/55.0

[bugday-20170419]
Comment on attachment 8857574 [details]
Bug 1355886 - fix regression when undoing delete node next to a whitespace sibling;

Approval Request Comment
[Feature/Bug causing the regression]: Bug 1345529
[User impact if declined]: markup view can be broken and force the user to restart devtools
[Is this code covered by automated tests?]: yes, included here
[Has the fix been verified in Nightly?]: yes
[Needs manual test from QE? If yes, steps to reproduce]: yes, see comment 0
[List of other uplifts needed for the feature/fix]: patch from 1345529 should be uplifted first
[Is the change risky?]: no
[Why is the change risky/not risky?]: devtools-only change, making an if statement more robust
[String changes made/needed]: none
Attachment #8857574 - Flags: approval-mozilla-beta?
Comment on attachment 8857574 [details]
Bug 1355886 - fix regression when undoing delete node next to a whitespace sibling;

Fix a regression. Beta54+. Should be in 54 beta 2.
Attachment #8857574 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Comment on attachment 8857574 [details]
Bug 1355886 - fix regression when undoing delete node next to a whitespace sibling;

Sorry for putting the wrong comment. We should let this one ride the train on 55. Beta 54-.
Attachment #8857574 - Flags: approval-mozilla-beta+ → approval-mozilla-beta-
I have reproduced this bug with Nightly 55.0a1 (2017-04-12) on Ubuntu 16.04, 64 bit!
The bug's fix is now verified on latest Nightly 55.0a1 (64-bit).

Nightly 55.0a1:

Build ID 	20170606100219
User Agent 	Mozilla/5.0 (X11; Linux x86_64; rv:55.0) Gecko/20100101 Firefox/55.0

[bugday-20170531]

Comment 12

a year ago
I have reproduced this bug with Nightly 55.0a1 (2017-04-12) on Windows 10 64 bit
The bug's fix is now verified on latest Nightly 55.0a1.

Nightly 55.0a1: 
 
Build ID 	20170606030207
User Agent 	Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:55.0) Gecko/20100101 Firefox/55.0

[bugday-20170607]

Updated

4 months ago
Product: Firefox → DevTools

Updated

3 months ago
status-firefox52: unaffected → ---
status-firefox53: unaffected → ---
status-firefox54: unaffected → ---
status-firefox55: fixed → ---
Flags: in-qa-testsuite+
You need to log in before you can comment on or make changes to this bug.