Page MenuHomePhabricator

Prepare mobile language button for deployment
Closed, ResolvedPublic5 Estimated Story Points

Description

In order to deploy the mobile language button at the top, we need to do some preparations.

Old bottom language button will be live with the new action bar and button at the same time for some time, so...

AC

  • Feature flag bottom language button (T140872)
  • Feature flag action bar (stable HTML when disabled, beta action bar with language button at the top when enabled)
  • Make sure the both JS & CSS related to this features will work when enabled but having old cached HTML
    • Create followup task to remove cached HTML considerations (add FIXMEs with the task number) if necessary

Event Timeline

The approach with the cached HTML can be either hack it to work regardless or just detect it is the old html and fall back to the disabled config flag, whatever it is we should be clear and don't break the features :p

dr0ptp4kt set the point value for this task to 5.Jul 14 2016, 5:21 PM

I've split flagging the language button T140872

Feel free to do the same with the other AC

Change 301102 had a related patch set uploaded (by Phuedx):
Extract page action creators

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

Change 301103 had a related patch set uploaded (by Phuedx):
[Hygiene] Test SkinMinerva#isAllowedPageAction

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

Change 301104 had a related patch set uploaded (by Phuedx):
[Hygiene] Extend SkinMinerva#isAllowedPageAction

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

Change 301102 merged by jenkins-bot:
Extract page action creators

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

Change 301103 merged by jenkins-bot:
[Hygiene] Test SkinMinerva#isAllowedPageAction

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

Change 301104 merged by jenkins-bot:
[Hygiene] Extend SkinMinerva#isAllowedPageAction

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

Change 301351 had a related patch set uploaded (by Phuedx):
Promote "switch-language" page action to stable

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

Change 301352 had a related patch set uploaded (by Phuedx):
Promote and flag the new action bar styles

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

phuedx updated the task description. (Show Details)

The patches aren't split quite right, which is causing a browser test failure.

From IRC, with @Jhernandez's permission:

1:01:16 PM <joakino> yo, fyi i'm seeing the page action language switcher in stable and out of order https://i.imgur.com/yACglR7.png
1:01:44 PM <joakino> works fine in beta
1:04:33 PM <joakino> i've -1d it
5:20:09 PM <phuedx> that's with old styles applying to the addition of the new page action, right?
5:20:45 PM <joakino> that was just with the first patch
5:20:57 PM <phuedx> yeah, that's what i'd expect from that patch
5:21:05 PM <phuedx> the first patch simply adds the language switcher action
5:21:25 PM <phuedx> the page action bar styles are distinct from the addition of the language switcher
5:21:44 PM <phuedx> or have i misunderstood the whole thing?
5:21:49 PM <joakino> so one shouldn't be merged without the other?
5:22:12 PM <phuedx> i thought we were promoting the language switcher and flagging the new styles
5:22:22 PM <phuedx> but are we flagging both at the same time?
5:23:14 PM <joakino> i think we're supposed to make it ready to publish with a config variable, but keep it disabled for now (both beta action bar and top language button)
5:23:34 PM <joakino> then we'll enable top action bar with language button in stable, + bottom language button
5:23:47 PM <joakino> and after a month, disable bottom language button
5:24:18 PM <phuedx> oh ok -- that's a relatively trivial thing to do: we'll just have the language switcher visibility depend on the action bar flag
5:24:21 PM <phuedx> no worries

@phuedx I've merged 1/2. I've made a slight adjustment to the README so hopefully if you're okay with that you can also merge that change.

Note to aid testing I needed to fix a regression T141571 would be great if @Jhernandez or yourself can merge!

As always, thanks for your help @Jdlrobson. I've slightly reworded the README, updated the DocBlock for SkinMinerva#isAllowedPageAction per @jhobs's review, and rebased atop your change for T141571. I'd appreciate a re-test of both of my changes.

Change 301352 merged by jenkins-bot:
Promote and flag the new action bar styles

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

Change 301351 merged by jenkins-bot:
Promote "switch-language" page action to stable

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

Technically this allows us to switch to the new top language button with just a config variable.

So I'd consider that part signed off ^.

The remaining sign off is verifying everything works as it is now in prod before the next train cut.

  • Stable shows old action bar without language buttons
  • Beta shows new action bar with language button
  • Language button at the bottom is present
  • Stable, clicking bottom button opens language overlay
  • Beta, clicking on the bottom one scrolls to top and shows toast
  • Beta, clicking top language button opens language overlay

@Jhernandez, does that mean we should, for example, check on a group 0 server on Tuesday, 2-August-2016?

The functionality on en.m.wikipedia.org/wiki/Lang on iPhone 5c iOS 9.3 Safari seems to work as you describe, although I don't recall what level of edge caching is in play there.

@Jhernandez we can verify the cached HTML issue locally. I just verified this works as expected myself.

The verification step is as follows:

You can also do similar tests by checking out older revisions e.g.

Given we have not enabled this I see this as an additional sign off step for https://phabricator.wikimedia.org/T138961 not this patch. @dr0ptp4kt from what I see this card can be signed off and resolved.