Skip to content
This repository has been archived by the owner on Jan 17, 2023. It is now read-only.

Notify user of missing mozAddonManager #2364

Closed
chuckharmston opened this issue Apr 5, 2017 · 9 comments
Closed

Notify user of missing mozAddonManager #2364

chuckharmston opened this issue Apr 5, 2017 · 9 comments
Assignees
Labels
Milestone

Comments

@chuckharmston
Copy link

chuckharmston commented Apr 5, 2017

@fzzzy will be removing the non-mozAddonManager paths with this release. Since those APIs have specific prerequisites, including an about:config pref, we may see some mysteriously broken behavior like that experienced this morning if any of those prerequisites are not hit.

To remediate, we should check for the existence (!!navigator.mozAddonManager should suffice) on startup, notify the user if any of them are not met, and suggest steps for fixing it.

I'd suggest the following logic to determine messaging.

  1. window.location.protocol === 'https'
    • If not, tell the user to make sure they are accessing on that protocol.
  2. Firefox version is >= 49 47 (double-checking that that's when mozAddonManager shipped.
    • If not, tell the user to update.
  3. !['example.com', 'testpilot.dev.mozaws.net', 'testpilot.stage.mozaws.net'].includes(window.location.host)
    • If not, tell the user that they need to set extensions.webapi.testing.
  4. window.location.host !== 'testpilot.firefox.com'
    • If not, tell the user that they must access Test Pilot on an approved hostname.
  5. Tell the user that they should file a bug because we have no idea what's going on.

It is very likely that this is only seen on dev or stage, but there's no reason to not build this to be something that we're comfortable shipping on production. When bug 1359837 lands, there's a very reasonable way production users may run into this. To accommodate, we should also disable the install button with appropriate messaging.

@fzzzy
Copy link
Contributor

fzzzy commented Apr 6, 2017

Not this release -- the old code is still in place for now. But I will remove the old path fairly soon.

@fzzzy
Copy link
Contributor

fzzzy commented Apr 7, 2017

@chuckharmston If you have some time this sprint, do you feel like doing this? It should be really straightforward.

@chuckharmston
Copy link
Author

See this bug for another place where mozAddonManager may be prevented in the future: https://bugzilla.mozilla.org/show_bug.cgi?id=1359837

@ghost ghost added the needs:UX label May 1, 2017
@ghost
Copy link

ghost commented May 1, 2017

If a user has the pref mentioned in bug 1359837 flipped, they'll see an install dialog followed by an error message here. The biggest use case for that pref is managed workstations who have admins who flip it.

marking needs UX for how we want to communicate to the user and cc @johngruen . This feels like a pretty slim audience (@chuckharmston is asking about how many people were talking about) but this issue is blocking landing the patch in the bug.

edit: didn't mean to close

@ghost ghost closed this as completed May 1, 2017
@ghost ghost reopened this May 1, 2017
@ghost ghost added status:insprint and removed status:insprint labels May 1, 2017
@fzzzy
Copy link
Contributor

fzzzy commented May 2, 2017

Time to get going on this soon.

@johngruen
Copy link
Contributor

Will bring it up in the UX meeting; no reason we can't crank something out ASAP

@fzzzy fzzzy self-assigned this May 25, 2017
fzzzy added a commit to fzzzy/testpilot that referenced this issue May 25, 2017
@fzzzy
Copy link
Contributor

fzzzy commented May 25, 2017

@johngruen Since this will only be seen by a small number of users that try to test Test Pilot locally, on stage, or on dev, but have something misconfigured, I don't think much UX is required. I did a simple implementation, here are examples of what it looks like in various error cases:

screen shot 2017-05-25 at 2 25 07 pm

screen shot 2017-05-25 at 2 25 36 pm

fzzzy added a commit to fzzzy/testpilot that referenced this issue May 31, 2017
fzzzy added a commit to fzzzy/testpilot that referenced this issue Jun 8, 2017
@fzzzy fzzzy assigned johngruen and unassigned fzzzy Jun 8, 2017
fzzzy added a commit to fzzzy/testpilot that referenced this issue Jun 19, 2017
@flodolo
Copy link
Collaborator

flodolo commented Jun 20, 2017

As asked in the past, please ping when there are pull requests with strings (plus #2532)

@fzzzy
Copy link
Contributor

fzzzy commented Jun 20, 2017

@flodolo Sorry about that. We will work on setting up a localization branch next quarter so this process is more formalized.

@ghost ghost added this to the Sprint 27 milestone Jul 10, 2017
@ghost ghost added this to the Sprint 27 milestone Jul 10, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

5 participants