Last Comment Bug 700201 - Addons that haven't been updated for an extremely long time should not be compatible by default
: Addons that haven't been updated for an extremely long time should not be com...
Status: VERIFIED FIXED
qa!
: dev-doc-complete, verified-aurora
Product: Toolkit
Classification: Components
Component: Add-ons Manager (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla11
Assigned To: Blair McBride [:Unfocused] (UNAVAILABLE)
:
Mentors:
https://groups.google.com/forum/#!top...
Depends on:
Blocks: 692664 702792 706796
  Show dependency treegraph
 
Reported: 2011-11-06 18:31 PST by Blair McBride [:Unfocused] (UNAVAILABLE)
Modified: 2012-03-24 09:28 PDT (History)
11 users (show)
bmcbride: in‑testsuite+
bmcbride: in‑litmus-
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
fixed


Attachments
Patch v1 (16.27 KB, patch)
2011-11-07 15:49 PST, Blair McBride [:Unfocused] (UNAVAILABLE)
dtownsend: review+
asa: approval‑mozilla‑aurora+
Details | Diff | Splinter Review

Description Blair McBride [:Unfocused] (UNAVAILABLE) 2011-11-06 18:31:10 PST
It is possible to obtain addons that haven't been updated since (for instance) Firefox 1.0. These are unlikely to work correctly (if at all) on modern versions of the application, and so shouldn't be compatible by default.

One solution is to have AMO blacklist these addons in the new <addon_compatibility> elements of the metadata ping. However, that only solves it for addons AMO has any data on.

A more generic solution is to have the application specify a minimum version that addons should be compatible by default with. This would't need to be changed very often.
Comment 1 Blair McBride [:Unfocused] (UNAVAILABLE) 2011-11-07 15:49:43 PST
Created attachment 572660 [details] [diff] [review]
Patch v1
Comment 2 Dave Townsend [:mossop] 2011-11-09 11:46:30 PST
Comment on attachment 572660 [details] [diff] [review]
Patch v1

Review of attachment 572660 [details] [diff] [review]:
-----------------------------------------------------------------

::: browser/app/profile/firefox.js
@@ +59,5 @@
>  pref("extensions.strictCompatibility", true);
>  
> +// Specifies a minimum maxVersion an addon needs to say it's compatible with
> +// for it to be compatible by default.
> +pref("extensions.minCompatibleAppVersion", "3.0");

We should have a newsgroup thread or something to decide what this should be.

::: toolkit/mozapps/extensions/XPIProvider.jsm
@@ +6975,5 @@
> +      else if (app.id == TOOLKIT_ID)
> +        minCompatVersion = XPIProvider.minCompatiblePlatformVersion;
> +
> +      if (minCompatVersion &&
> +          Services.vc.compare(minCompatVersion, app.maxVersion) > 0)

Shouldn't this compare against version rather than app.maxVersion?
Comment 3 Dave Townsend [:mossop] 2011-11-09 16:23:36 PST
Comment on attachment 572660 [details] [diff] [review]
Patch v1

Review of attachment 572660 [details] [diff] [review]:
-----------------------------------------------------------------

::: toolkit/mozapps/extensions/XPIProvider.jsm
@@ +6970,5 @@
> +
> +      // Extremely old extensions should not be compatible by default.
> +      let minCompatVersion;
> +      if (app.id == Services.appinfo.ID)
> +          minCompatVersion = XPIProvider.minCompatibleAppVersion;

Too much indentation
Comment 4 Blair McBride [:Unfocused] (UNAVAILABLE) 2011-11-09 16:29:39 PST
(In reply to Dave Townsend (:Mossop) from comment #2)
> We should have a newsgroup thread or something to decide what this should be.

Indeed. Posted: https://groups.google.com/forum/#!topic/mozilla.dev.platform/Wkuc1W9TS9c
(Was also cross-posted to dev-apps-firefox.)
Comment 5 Alex Limi (:limi) — Firefox UX Team 2011-11-09 20:09:08 PST
Toolkit 2.0 and Firefox 4.0 seem like reasonable defaults. Add-ons that say they were compatible with 3.5 or 3.6 and haven't been updated since then are unlikely to be in good shape.
Comment 6 Dave Townsend [:mossop] 2011-11-13 17:08:47 PST
(In reply to Alex Limi (:limi) — Firefox UX Team from comment #5)
> Toolkit 2.0 and Firefox 4.0 seem like reasonable defaults. Add-ons that say
> they were compatible with 3.5 or 3.6 and haven't been updated since then are
> unlikely to be in good shape.

Sounds good to me!
Comment 7 Blair McBride [:Unfocused] (UNAVAILABLE) 2011-11-13 17:35:10 PST
https://hg.mozilla.org/integration/fx-team/rev/9591426bab8e
Comment 8 Blair McBride [:Unfocused] (UNAVAILABLE) 2011-11-13 17:35:47 PST
Comment on attachment 572660 [details] [diff] [review]
Patch v1

Tested, no string changes, an important part of the big addons-compatible-by-default push.
Comment 9 Blair McBride [:Unfocused] (UNAVAILABLE) 2011-11-13 17:47:02 PST
I should probably note that this feature is not currently enabled on Aurora (or Central, for that matter). Assuming we do decide to enable it for Fx10 (see bug 698653), it would be good to have this patch in now rather than later, so it can go through QA's scrutiny (and not suffer bitrot).
Comment 10 Rob Campbell [:rc] (:robcee) 2011-11-15 14:12:41 PST
https://hg.mozilla.org/mozilla-central/rev/9591426bab8e
Comment 11 christian 2011-11-16 11:39:29 PST
This doesn't transplant to aurora cleanly, sad.
Comment 12 Blair McBride [:Unfocused] (UNAVAILABLE) 2011-11-16 19:39:07 PST
https://hg.mozilla.org/releases/mozilla-aurora/rev/6ff7fdaed43f
Comment 13 Virgil Dicu [:virgil] [QA] 2011-11-28 07:44:16 PST
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:11.0a1) Gecko/20111127 Firefox/11.0a1
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:10.0a2) Gecko/20111127 Firefox/10.0a2
Mozilla/5.0 (Windows NT 5.1; rv:11.0a1) Gecko/20111127 Firefox/11.0a1
Mozilla/5.0 (Windows NT 5.1; rv:10.0a2) Gecko/20111127 Firefox/10.0a2
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:10.0a2) Gecko/20111127 Firefox/10.0a2
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:11.0a1) Gecko/20111128 Firefox/11.0a1
Mozilla/5.0 (X11; Linux i686; rv:11.0a1) Gecko/20111128 Firefox/11.0a1
Mozilla/5.0 (X11; Linux i686; rv:10.0a2) Gecko/20111128 Firefox/10.0a2

Verified Aurora and Nightly on Ubuntu 11.04, Mac OS 10.6, Windows XP, 7. Add-ons with max version smaller than 4.* are displayed as incompatible after the upgrade. Add-on with max version equal to 4.* is displayed as compatible after the upgrade.

1. Start Firefox 3.6.24 with clean profile.
2. Install following add-ons: 
https://addons.mozilla.org/en-US/firefox/addon/close-other-tabs/?src=ss
https://addons.mozilla.org/en-US/firefox/addon/go-classic/?src=ss
https://addons.mozilla.org/en-US/firefox/addon/replacetabs-extension/?src=ss
3. Upgrade to Firefox 11 (Firefox 10)
4. Open Add-ons manager

Replacetabs Extension is displayed as compatible (max version=4.*) as normal.
The other two extensions (max version smaller than 4.*) are displayed as incompatible after the upgrade.
Comment 14 Eric Shepherd [:sheppy] 2012-03-24 09:28:51 PDT
Docs revised:

https://developer.mozilla.org/en/Install_Manifests
https://developer.mozilla.org/en/Building_an_Extension

Mentioned on Firefox 11 for developers.

Note You need to log in before you can comment on or make changes to this bug.