Firefox fails to detect updates for unpacked extension installed through Windows Registry

The extension is installed in C:\Program Files (x86)\AppName\firefox\addonName
I followed the instructions from here: https://developer.mozilla.org/en-US/docs/Adding_Extensions_using_the_Windows_Registry

The latest application updater also updates our add-on for Firefox so we can deploy the Mozilla signed add-on that works with FF 43. However, Firefox fails to detect that the add-on has changed/updated even though the documentation states that “You can force Firefox to notice changes by deleting and recreating the directory, or by touching the modification time of the directory.”

The C:\Program Files (x86)\AppName\firefox\addonName has the “modified” date updated; I also tried to manually update it by renaming the folder to addonName1 then making a copy and renaming the copy to addonName. Both dir and File Explorer confirm that the folder create/modified dates are updated yet Firefox still refuses to see the changes and, as a result, the addon is still listed with the old version number and disabled because it “could not be verified for use in Firefox and has been disabled.”

What’s the proper way to update an unpacked add-on installed through Windows Registry? Is there any other way to force Firefox to “re-scan” the add-ons and detect that install.rdf has changed?

Are you saying that Firefox doesn’t load the add-on again even after it restarts? Or is this a restartless add-on and you’re trying to make Firefox reload it right away?

I’m referring to the exact same update scenario from https://developer.mozilla.org/en-US/docs/Adding_Extensions_using_the_Windows_Registry:

Updating

Firefox doesn’t automatically notice changes to install.rdf at restart. This is because it checks the modification time of the add-on directory before checking install.rdf. You can force Firefox to notice changes by deleting and recreating the directory, or by touching the modification time of the directory.

Maybe it’s easier if I give you the steps we use to reproduce the issue:

  1. install Firefox 43 on a clean machine
  2. install old version of our product which includes an unpacked Firefox extension (not signed); the installer will register the extension in Windows Registry
  3. launch Firefox - the extension is disabled because it’s not signed; it shows as version 1.0.0 (just an example)
  4. close Firefox and update the product; the updater will replace the extension located in c:\program files (x86)\product\firefox\extensionFolder with a newer version that is signed (version 2.0.0)
  5. launch Firefox again
  6. the extension is still disabled and the Add-ons page still lists it as version 1.0.0 even though install.rdf now says it’s version 2.0.0

It doesn’t matter how many times I restart Firefox, reboot the computer or manually update the extension folder (so the timestamp changes) - Firefox still insists that the extension could not be verified.

Resetting the Firefox profile or going through a sequence of removing the extension from registry, starting Firefox (so it no longer ‘sees’ the extension), closing Firefox, adding the extension to registry and restarting Firefox fixes the issue.

Is there any update on this from Mozilla? We have similar issues with our plug-in, and even after we signed it, and copied the signed plug-in, firefox does not pick it up. We got to have this fixed or have some way for Firefox to reload the plug-in.

It’s odd that version 1.0.0 is still being reported in the Add-ons Manager. It sounds like it isn’t checking the installation directory again for some reason. I think in this case you should file a bug here with all the details.

Never mind, it looks like the bug already exists. It’d be good that you comment on it, especially if you have any additional information to provide.

I’ve updated the docs on that page and made some notes in the bug report. The best method for ensuring that Firefox picks up your updates is to set the modification time of your new install.rdf file to something very new, ideally the time you install the extension to the user’s computer. That should ensure Firefox picks up the changes.