Closed Bug 1608003 Opened 1 year ago Closed 1 year ago

touchstart Touch Simulation not working

Categories

(DevTools :: Responsive Design Mode, defect, P2)

72 Branch
defect

Tracking

(firefox-esr68 unaffected, firefox72 wontfix, firefox73 verified, firefox74 verified)

VERIFIED FIXED
Firefox 74
Tracking Status
firefox-esr68 --- unaffected
firefox72 --- wontfix
firefox73 --- verified
firefox74 --- verified

People

(Reporter: yoasif, Assigned: mtigley)

References

(Blocks 1 open bug, Regression)

Details

(Keywords: regression)

Attachments

(3 files)

Attached file touch.html

Thank you for helping make Firefox better. If you are reporting a defect, please complete the following:

From: https://www.reddit.com/r/firefox/comments/em2srk/has_v720_broken_touch_simulation_in_the_developer/

What were you doing?

Please tell us what site you were on, and what steps led to the error you are reporting

  1. Load attached test file
  2. Open RDM
  3. Enable touch simulation
  4. Reload
  5. Click on page

What happened?

Nothing happens.

What should have happened?

I should get an alert saying "hi!"

Anything else we should know?

This works if I touch the screen in RDM. It also works in Chromium.

2020-01-09T16:26:29: DEBUG : Found commit message:
Bug 1588438 - Refactor deprecated touch event APIs. r=ochameau
This revision refactors RDM's touch simulator to use modern touch web APIs where possible.
Differential Revision: https://phabricator.services.mozilla.com/D50147
2020-01-09T16:26:29: DEBUG : Did not find a branch, checking all integration branches
2020-01-09T16:26:29: INFO : The bisection is done.
2020-01-09T16:26:29: INFO : Stopped

Has Regression Range: --- → yes
Has STR: --- → yes
Regressed by: 1588438

Change the status for beta to have the same as nightly and release.
For more information, please visit auto_nag documentation.

Assignee: nobody → mtigley
Status: NEW → ASSIGNED
Priority: -- → P2
Attachment #9119935 - Attachment description: Bug 1608003 - Enable event bubbling when dispatching touch events. → Bug 1608003 - Enable event bubbling when dispatching simulated touch events.
Pushed by mtigley@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/858429dcc05d
Enable event bubbling when dispatching simulated touch events. r=bradwerth
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 74
Flags: in-testsuite+

Please nominate this for Beta approval when you get a chance.

Flags: needinfo?(mtigley)

Comment on attachment 9119935 [details]
Bug 1608003 - Enable event bubbling when dispatching simulated touch events.

Beta/Release Uplift Approval Request

  • User impact if declined: Touch events will not work for users simulating a touch-enabled device in Responsive Design Mode.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Changes only affect the touch simulator in DevTools' Responsive Design Mode.
  • String changes made/needed:
Flags: needinfo?(mtigley)
Attachment #9119935 - Flags: approval-mozilla-beta?

Comment on attachment 9119935 [details]
Bug 1608003 - Enable event bubbling when dispatching simulated touch events.

Fixes an RDM touch events regression. Approved for 73.0b6.

Attachment #9119935 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Backed out for failures on /browser_state_restore.js

backout: https://hg.mozilla.org/releases/mozilla-beta/rev/21980c8b11cca172f8d69f0e31ddfde00c98e02f

push: https://treeherder.mozilla.org/#/jobs?repo=mozilla-beta&selectedJob=285261996&revision=68842cf97fbd92247f005f10117bb2546ea0655d&searchStr=devtools

failure log: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=285261996&repo=mozilla-beta&lineNumber=33124

[task 2020-01-16T22:15:56.692Z] 22:15:56 INFO - TEST-PASS | devtools/client/responsive/test/browser/browser_state_restore.js | Value "DPR: 2" should match an existing menu item. -
[task 2020-01-16T22:15:56.693Z] 22:15:56 INFO - GECKO(2541) | console.log: "[DISPATCH] action type:" "CHANGE_PIXEL_RATIO"
[task 2020-01-16T22:15:56.696Z] 22:15:56 INFO - GECKO(2541) | [Parent 2541, Main Thread] WARNING: NS_ENSURE_TRUE(weakFrame.IsAlive()) failed: file /builds/worker/workspace/build/src/layout/xul/nsXULPopupManager.cpp, line 1056
[task 2020-01-16T22:15:56.696Z] 22:15:56 INFO - TEST-INFO | started process screentopng
[task 2020-01-16T22:15:57.229Z] 22:15:57 INFO - TEST-INFO | screentopng: exit 0
[task 2020-01-16T22:15:57.230Z] 22:15:57 INFO - TEST-UNEXPECTED-FAIL | devtools/client/responsive/test/browser/browser_state_restore.js | Got an error with usingBrowserUI false: TypeError: ui.getBrowserWindow is not a function
[task 2020-01-16T22:15:57.230Z] 22:15:57 INFO - Stack: toggleTouchSimulation@chrome://mochitests/content/browser/devtools/client/responsive/test/browser/head.js:580:27
[task 2020-01-16T22:15:57.231Z] 22:15:57 INFO - @chrome://mochitests/content/browser/devtools/client/responsive/test/browser/browser_state_restore.js:32:9
[task 2020-01-16T22:15:57.231Z] 22:15:57 INFO - Line: 580, column: 27 -
[task 2020-01-16T22:15:57.232Z] 22:15:57 INFO - Stack trace:
[task 2020-01-16T22:15:57.232Z] 22:15:57 INFO - chrome://mochikit/content/browser-test.js:test_ok:1292
[task 2020-01-16T22:15:57.232Z] 22:15:57 INFO - chrome://mochitests/content/browser/devtools/client/responsive/test/browser/head.js:addRDMTask/taskSetup/<:161
[task 2020-01-16T22:15:57.233Z] 22:15:57 INFO - Closing responsive design mode
[task 2020-01-16T22:15:57.233Z] 22:15:57 INFO - GECKO(2541) | [Child 2704, Main Thread] WARNING: NS_ENSURE_TRUE(mPresShell) failed: file /builds/worker/workspace/build/src/layout/base/nsPresContext.cpp, line 847
[task 2020-01-16T22:15:57.233Z] 22:15:57 INFO - GECKO(2541) | [Child 2617: Main Thread]: I/DocShellAndDOMWindowLeak ++DOCSHELL 0x7f7fa400a000 == 1 [pid = 2617] [id = {f238a932-5bd8-4576-ad88-508ae037933c}]
[task 2020-01-16T22:15:57.234Z] 22:15:57 INFO - GECKO(2541) | [Child 2617: Main Thread]: I/DocShellAndDOMWindowLeak ++DOMWINDOW == 8 (0x7f7fa40cf980) [pid = 2617] [serial = 24] [outer = (nil)]
[task 2020-01-16T22:15:57.234Z] 22:15:57 INFO - GECKO(2541) | [Child 2617: Main Thread]: I/DocShellAndDOMWindowLeak ++DOMWINDOW == 9 (0x7f7fa40edc00) [pid = 2617] [serial = 25] [outer = 0x7f7fa40cf980]
[task 2020-01-16T22:15:57.234Z] 22:15:57 INFO - GECKO(2541) | [Parent 2541, Main Thread] ###!!! ASSERTION: Wrong event target!: 'this == fl->GetBrowserChildMessageManager()', file /builds/worker/workspace/build/src/dom/base/InProcessBrowserChildMessageManager.cpp, line 260
[task 2020-01-16T22:15:57.235Z] 22:15:57 INFO - GECKO(2541) | #01: mozilla::EventTargetChainItem::GetEventTargetParent(mozilla::EventChainPreVisitor&) [dom/events/EventDispatcher.cpp:425]

Flags: needinfo?(mtigley)
Flags: qe-verify+
QA Whiteboard: [qa-triaged]

This issue is Verified as Fixed in our latest Nightly build 74.0a1 (2020-01-16) on Ubuntu 16.04, Mac 10.14 and Windows 10.

(In reply to Natalia Csoregi [:nataliaCs] from comment #9)

Backed out for failures on /browser_state_restore.js

backout: https://hg.mozilla.org/releases/mozilla-beta/rev/21980c8b11cca172f8d69f0e31ddfde00c98e02f

push: https://treeherder.mozilla.org/#/jobs?repo=mozilla-beta&selectedJob=285261996&revision=68842cf97fbd92247f005f10117bb2546ea0655d&searchStr=devtools

failure log: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=285261996&repo=mozilla-beta&lineNumber=33124

[task 2020-01-16T22:15:56.692Z] 22:15:56 INFO - TEST-PASS | devtools/client/responsive/test/browser/browser_state_restore.js | Value "DPR: 2" should match an existing menu item. -
[task 2020-01-16T22:15:56.693Z] 22:15:56 INFO - GECKO(2541) | console.log: "[DISPATCH] action type:" "CHANGE_PIXEL_RATIO"
[task 2020-01-16T22:15:56.696Z] 22:15:56 INFO - GECKO(2541) | [Parent 2541, Main Thread] WARNING: NS_ENSURE_TRUE(weakFrame.IsAlive()) failed: file /builds/worker/workspace/build/src/layout/xul/nsXULPopupManager.cpp, line 1056
[task 2020-01-16T22:15:56.696Z] 22:15:56 INFO - TEST-INFO | started process screentopng
[task 2020-01-16T22:15:57.229Z] 22:15:57 INFO - TEST-INFO | screentopng: exit 0
[task 2020-01-16T22:15:57.230Z] 22:15:57 INFO - TEST-UNEXPECTED-FAIL | devtools/client/responsive/test/browser/browser_state_restore.js | Got an error with usingBrowserUI false: TypeError: ui.getBrowserWindow is not a function
[task 2020-01-16T22:15:57.230Z] 22:15:57 INFO - Stack: toggleTouchSimulation@chrome://mochitests/content/browser/devtools/client/responsive/test/browser/head.js:580:27
[task 2020-01-16T22:15:57.231Z] 22:15:57 INFO - @chrome://mochitests/content/browser/devtools/client/responsive/test/browser/browser_state_restore.js:32:9
[task 2020-01-16T22:15:57.231Z] 22:15:57 INFO - Line: 580, column: 27 -
[task 2020-01-16T22:15:57.232Z] 22:15:57 INFO - Stack trace:
[task 2020-01-16T22:15:57.232Z] 22:15:57 INFO - chrome://mochikit/content/browser-test.js:test_ok:1292
[task 2020-01-16T22:15:57.232Z] 22:15:57 INFO - chrome://mochitests/content/browser/devtools/client/responsive/test/browser/head.js:addRDMTask/taskSetup/<:161
[task 2020-01-16T22:15:57.233Z] 22:15:57 INFO - Closing responsive design mode
[task 2020-01-16T22:15:57.233Z] 22:15:57 INFO - GECKO(2541) | [Child 2704, Main Thread] WARNING: NS_ENSURE_TRUE(mPresShell) failed: file /builds/worker/workspace/build/src/layout/base/nsPresContext.cpp, line 847
[task 2020-01-16T22:15:57.233Z] 22:15:57 INFO - GECKO(2541) | [Child 2617: Main Thread]: I/DocShellAndDOMWindowLeak ++DOCSHELL 0x7f7fa400a000 == 1 [pid = 2617] [id = {f238a932-5bd8-4576-ad88-508ae037933c}]
[task 2020-01-16T22:15:57.234Z] 22:15:57 INFO - GECKO(2541) | [Child 2617: Main Thread]: I/DocShellAndDOMWindowLeak ++DOMWINDOW == 8 (0x7f7fa40cf980) [pid = 2617] [serial = 24] [outer = (nil)]
[task 2020-01-16T22:15:57.234Z] 22:15:57 INFO - GECKO(2541) | [Child 2617: Main Thread]: I/DocShellAndDOMWindowLeak ++DOMWINDOW == 9 (0x7f7fa40edc00) [pid = 2617] [serial = 25] [outer = 0x7f7fa40cf980]
[task 2020-01-16T22:15:57.234Z] 22:15:57 INFO - GECKO(2541) | [Parent 2541, Main Thread] ###!!! ASSERTION: Wrong event target!: 'this == fl->GetBrowserChildMessageManager()', file /builds/worker/workspace/build/src/dom/base/InProcessBrowserChildMessageManager.cpp, line 260
[task 2020-01-16T22:15:57.235Z] 22:15:57 INFO - GECKO(2541) | #01: mozilla::EventTargetChainItem::GetEventTargetParent(mozilla::EventChainPreVisitor&) [dom/events/EventDispatcher.cpp:425]

Ah, ui.getBrowserWindow was something that landed as part of Bug 1585008, which is only in Nightly. I'm not confident about uplifting the patch in that issue as well, so I think for now let's remove that call and in the tests we'll just use ui.toolWindow.

Flags: needinfo?(mtigley)

Hi Micah, any updates on the revised patch for this bug?

Flags: needinfo?(mtigley)

We want to uplift the fix for touch events done in D59439. However, the test added there relies on a method landed in Nightly. So for now, let's have this test only assume old RDM UI.

Flags: needinfo?(mtigley)

This issue is Verified as Fixed in our latest Beta Build 73.0b11 on Windows 10, Mac OsX 10.14 and Ubuntu 18.04.

Status: RESOLVED → VERIFIED
QA Whiteboard: [qa-triaged]
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.