Page MenuHomePhabricator

Regression: AMC Outreach Drawer doesn't open when user is eligible
Closed, ResolvedPublic3 Estimated Story PointsBUG REPORT

Description

Steps to reproduce

  1. Open up a new window in incognito mode (assuming you are using chrome)
  2. Login to https://en.m.wikipedia.beta.wmflabs.org/wiki/Dog with AMC off
  3. Click the "Desktop" link in the footer
  • This also affects the history link, the talk button (not tab), and the add talk button since amc outreach was setup to work with those

Expected results

  • AMC Outreach drawer opens

Actual results

  • AMC Outreach drawer does not open. Nothing happens.

Check any additional observations

Dev Notes

QA steps

This is now on the beta cluster and enables all logged in users with >= 0 edits to see the drawer (the # of edits is configurable and was set to 0 to make testing easier).

This is a bit of a pain to test multiple times because the drawer should only show once per browser/action/device combo. A way to get around this is to use a new incognito mode window in chrome (iOS Safari has their own version of that at https://support.apple.com/en-us/HT203036) every time you want to see the drawer:

  1. If you have enabled AMC at https://en.m.wikipedia.beta.wmflabs.org, turn it off
  2. Close all previous incognito windows, launch a new incognito window, and login to https://en.m.wikipedia.beta.wmflabs.org/wiki/Spain

Alternatively, if you are on a laptop on chrome, you can open up dev tools and in the console execute localStorage.clear(). This saves you from having to open/close tabs and log in/log out.

When user is logged in with AMC turned off, user clicks desktop link, and then dismisses it

  • Follow steps 1 - 2 and assert you see the drawer when you click on "Desktop" link in the footer
  • Assert that the drawer remains visible when attempting to scroll.
  • Dismiss the drawer by tapping the "No thanks" link or by tapping the black part of the overlay. Assert that the desktop page loads.
  • Go back to the mobile site by clicking the "Mobile view" link in the footer. Click the desktop link in the footer again and assert that the drawer does NOT show but the desktop page loads. Click the mobile view link again to go back to the mobile site.

When user is logged in with AMC turned off, user clicks desktop link, and then enables it

  • Follow steps 1 - 2 and assert you see the drawer when you click on "Desktop" link in the footer
  • Enable amc mode by tapping "Enable advanced mode" button. Assert that the page reloads. The desktop site should NOT load.
  • Click the desktop link in the footer again and assert that the drawer does NOT show but the desktop page loads. Click the mobile view link again to go back to the mobile site.

When user is logged in with AMC turned off, user clicks history link, and then dismisses it

  • Follow steps 1 - 2 and assert you see the drawer when you click on "Last edited ...." link at bottom of page
  • Assert that the drawer remains visible when attempting to scroll.
  • Dismiss the drawer by tapping the "No thanks" link or by tapping the black part of the overlay. Assert that the non-amc history page loads.
  • Go back to previous page and click history link again. Assert that the drawer does NOT show but the history page loads again.

When user is logged in with AMC turned off, user clicks history link, and then enables it

  • Follow steps 1 - 2 and assert you see the drawer when you click on "Last edited ...." link at bottom of page
  • Enable amc mode by tapping "Enable advanced mode" button. Assert that the amc history page loads
  • Go back to previous page and click history link again. Assert that the drawer does NOT show but the amc history page loads.

QA Results

Event Timeline

Change 563622 had a related patch set uploaded (by Nray; owner: Nray):
[mediawiki/skins/MinervaNeue@master] Update amcOutreach to reflect new drawer changes

https://gerrit.wikimedia.org/r/563622

Change 563623 had a related patch set uploaded (by Nray; owner: Nray):
[mediawiki/extensions/MobileFrontend@master] Update AmcOutreachDrawer to reflect new drawer changes

https://gerrit.wikimedia.org/r/563623

ovasileva triaged this task as Medium priority.Jan 13 2020, 11:39 AM
Jdlrobson renamed this task from [Bug] AMC Outreach Drawer doesn't open when user is eligible to Regression: AMC Outreach Drawer doesn't open when user is eligible.Jan 13 2020, 7:18 PM
Jdlrobson added a project: Regression.

Change 563623 abandoned by Nray:
Update AmcOutreachDrawer to reflect new drawer changes

Reason:
https://gerrit.wikimedia.org/r/#/c/mediawiki/extensions/MobileFrontend/ /564113 is better way of handling this although I think "showIfEligible" should be renamed to something like "executeIfEligible" as it would not longer show anything

https://gerrit.wikimedia.org/r/563623

Change 564153 had a related patch set uploaded (by Nray; owner: Nray):
[mediawiki/skins/MinervaNeue@master] Update amc outreach code to reflect new drawer changes

https://gerrit.wikimedia.org/r/564153

Change 563622 abandoned by Nray:
Update amcOutreach to reflect new drawer changes

Reason:
Please look at https://gerrit.wikimedia.org/r/#/c/mediawiki/skins/MinervaNeue/ /564153/ instead

https://gerrit.wikimedia.org/r/563622

Change 564157 had a related patch set uploaded (by Nray; owner: Nray):
[operations/mediawiki-config@master] Temporarily turn off AmcOutreach until T242491 regression is resolved

https://gerrit.wikimedia.org/r/564157

Change 564157 abandoned by Nray:
Temporarily turn off AmcOutreach until T242491 regression is resolved

Reason:
We might have time to fix this after all

https://gerrit.wikimedia.org/r/564157

Change 564153 merged by jenkins-bot:
[mediawiki/skins/MinervaNeue@master] Update amc outreach code to reflect new drawer changes

https://gerrit.wikimedia.org/r/564153

Found a regression on talk page that needs a fix:

  1. Go to talk page
  2. Click on Add talk button
  3. Drawer opens
  4. Click outside drawer
  5. TalkSectionAddOverlay appears
  6. Exit overlay
  7. User can't scroll. Viewport is locked
ovasileva set the point value for this task to 3.Jan 14 2020, 6:22 PM

Change 564755 had a related patch set uploaded (by Nray; owner: Nray):
[mediawiki/skins/MinervaNeue@master] Remove amc outreach from talk page

https://gerrit.wikimedia.org/r/564755

nray updated the task description. (Show Details)

Change 564755 merged by jenkins-bot:
[mediawiki/skins/MinervaNeue@master] Remove amc outreach from talk page

https://gerrit.wikimedia.org/r/564755

@ovasileva What would you like the updated copy on the amc outreach drawer to be? It is currently:

"Advanced mode makes it easier to access Talk pages, History pages, Recent changes, and other editor tools on mobile."

@nray How about "Advanced mode provides expanded functionality on Talk pages, History pages, Recent changes, and other editor tools on mobile."?

expanded functionality on Talk pages

Just wanted to check. Talk experience on AMC is identical to logged in. I think the only change to AMC talk pages is the addition of the more menu. Is this what we mean by expanded functionality?

Good point. How about "Advanced mode provides expanded functionality of History pages, Watchlist pages, Recent changes, and other editor tools on mobile". Still not perfect, so open to suggestions

Change 565382 had a related patch set uploaded (by Nray; owner: Nray):
[mediawiki/extensions/MobileFrontend@master] Edit AMC Outreach Drawer Description

https://gerrit.wikimedia.org/r/565382

Good point. How about "Advanced mode provides expanded functionality of History pages, Watchlist pages, Recent changes, and other editor tools on mobile". Still not perfect, so open to suggestions

Sounds good to me; I made a patch to update this at https://gerrit.wikimedia.org/r/#/c/mediawiki/extensions/MobileFrontend/+/565382/

Change 565382 merged by jenkins-bot:
[mediawiki/extensions/MobileFrontend@master] Edit AMC Outreach Drawer Description

https://gerrit.wikimedia.org/r/565382

Edtadros added a subscriber: Edtadros.

Test Result

Status: ✅ PASS
OS: macOS Catalina
Browser: Chrome
Device: MBP
Emulated Device: iPhoneX

Test Artifact(s):

QA steps

This is now on the beta cluster and enables all logged in users with >= 0 edits to see the drawer (the # of edits is configurable and was set to 0 to make testing easier).

This is a bit of a pain to test multiple times because the drawer should only show once per browser/action/device combo. A way to get around this is to use a new incognito mode window in chrome (iOS Safari has their own version of that at https://support.apple.com/en-us/HT203036) every time you want to see the drawer:

If you have enabled AMC at https://en.m.wikipedia.beta.wmflabs.org, turn it off
Close all previous incognito windows, launch a new incognito window, and login to https://en.m.wikipedia.beta.wmflabs.org/wiki/Spain
Alternatively, if you are on a laptop on chrome, you can open up dev tools and in the console execute localStorage.clear(). This saves you from having to open/close tabs and log in/log out.

AC1: When user is logged in with AMC turned off, user clicks desktop link, and then dismisses it
Follow steps 1 - 2 and assert you see the drawer when you click on "Desktop" link in the footer
Assert that the drawer remains visible when attempting to scroll.
Dismiss the drawer by tapping the "No thanks" link or by tapping the black part of the overlay. Assert that the desktop page loads.
Go back to the mobile site by clicking the "Mobile view" link in the footer. Click the desktop link in the footer again and assert that the drawer does NOT show but the desktop page loads. Click the mobile view link again to go back to the mobile site.

T238364-1.gif (812×374 px, 882 KB)

AC2: When user is logged in with AMC turned off, user clicks desktop link, and then enables it
Follow steps 1 - 2 and assert you see the drawer when you click on "Desktop" link in the footer
Enable amc mode by tapping "Enable advanced mode" button. Assert that the page reloads. The desktop site should NOT load.
Click the desktop link in the footer again and assert that the drawer does NOT show but the desktop page loads. Click the mobile view link again to go back to the mobile site.

T238364-1.gif (812×374 px, 814 KB)

AC3: When user is logged in with AMC turned off, user clicks history link, and then dismisses it
Follow steps 1 - 2 and assert you see the drawer when you click on "Last edited ...." link at bottom of page
Assert that the drawer remains visible when attempting to scroll.
Dismiss the drawer by tapping the "No thanks" link or by tapping the black part of the overlay. Assert that the non-amc history page loads.
Go back to previous page and click history link again. Assert that the drawer does NOT show but the history page loads again.

T238364-1.gif (812×374 px, 828 KB)

AC4: When user is logged in with AMC turned off, user clicks history link, and then enables it
Follow steps 1 - 2 and assert you see the drawer when you click on "Last edited ...." link at bottom of page
Enable amc mode by tapping "Enable advanced mode" button. Assert that the amc history page loads
Go back to previous page and click history link again. Assert that the drawer does NOT show but the amc history page loads.

T238364-1.gif (480×222 px, 3 MB)

Looks good - banner is appearing as expected. Resolving