Closed
Bug 826940
Opened 12 years ago
Closed 12 years ago
after updating packaged app, starting app shows old version
Categories
(Firefox OS Graveyard :: General, defect)
Tracking
(blocking-basecamp:+, firefox19 wontfix, firefox20 wontfix, firefox21 fixed, b2g18 fixed)
People
(Reporter: myk, Assigned: fabrice)
References
Details
Attachments
(1 file)
1.21 KB,
patch
|
myk
:
review+
|
Details | Diff | Splinter Review |
When updating a preloaded packaged app, after the update has been downloaded and applied, and its application.zip file has been placed in the appropriate location in the filesystem (i.e. in path-to-Gaia-profile/webapps/APPID/), overwriting the old application.zip file at that location, starting the app should show you the new version of the application; but instead it shows you the old version.
I'm seeing this on recently nightly builds of B2G Desktop, and it's a regression from older builds like 12-13, where this didn't happen. jsmith suggested it might be a duplicate of bug 823189.
Note that I do start the app before checking for an update; but I quit the app before actually applying the update. And confirm that it isn't running by checking the task list. After a B2G restart, however, starting the app shows you the new version.
I'm encountering this while developing stub apps for preloaded third-party apps that check for and download an update and then quit themselves to allow the system to install it. The stubs will be ineffective if the updates, once applied, cannot be used until B2G is restarted, since the whole point is to get users an updated app as soon as they start the stub for the first time.
And we want to ship some of these stubs on Basecamp devices, so requesting blocking-basecamp.
Comment 1•12 years ago
|
||
Hmm. Actually now that I read this bug it isn't probably a dupe of the issue seen in bug 823189 after hearing about the "restart" workaround.
It actually sounds like the preloaded packaged app equivalent of bug 822870. We currently don't update the app's representation until a restart of the respective app process. That bug was blocking- mainly cause hosted app manifest changes are rare. This is a different case to consider, however.
I do wonder if this is a core bug or a Gaia bug. It could potentially be a bug in Gaia.
Reporter | ||
Updated•12 years ago
|
Blocks: market-packaged-apps
Updated•12 years ago
|
Summary: after updating preloaded packaged app, starting app shows old version → after updating preloaded packaged app, starting app shows old version until the phone is restarted
Updated•12 years ago
|
Assignee: nobody → fabrice
blocking-basecamp: ? → +
Comment 3•12 years ago
|
||
So apparently this now happens instead of bug 823189 with a regular packaged app update.
Restart didn't fix the problem for me, however.
Summary: after updating preloaded packaged app, starting app shows old version until the phone is restarted → after updating preloaded or non preloaded packaged app, starting app shows old version
Blocks: b2g-app-updates
Reporter | ||
Comment 4•12 years ago
|
||
Note: Fabrice asked me to try the patch in this pastebin <http://pastebin.mozilla.org/2043986>, and it does indeed solve the problem!
(In reply to Jason Smith [:jsmith] from comment #3)
> So apparently this now happens instead of bug 823189 with a regular packaged
> app update.
>
> Restart didn't fix the problem for me, however.
That might be a different bug, as a quick skim of the nsIZipReaderCache code suggests it's an in-memory cache, so it wouldn't survive a restart.
Perhaps you're experiencing a side-effect of bug 826935, which causes DOMApplicationRegistry to try to update the app, overwriting application.zip, while the app is still running. That's the kind of thing that fails on Windows systems, where you can't overwrite an open file; but it usually works on *nix systems, so I'm not sure why it would fail on B2G.
In any case, try retesting after this bug and that one have been merged to the b2g18 branch, and see if you can still reproduce!
Assignee | ||
Comment 5•12 years ago
|
||
I wrote the patch while offline, and it works.
Assignee: amarchesini → fabrice
Attachment #698779 -
Flags: review?(myk)
Reporter | ||
Updated•12 years ago
|
Attachment #698779 -
Flags: review?(myk) → review+
Assignee | ||
Comment 6•12 years ago
|
||
Comment 7•12 years ago
|
||
Ed - Can you land this on b2g18 as soon as you can? This fixes a very important change that fixes a smoketest for a feature, so I'd like to get this patch in a build as soon as possible.
Flags: needinfo?(emorley)
status-b2g18:
--- → fixed
Flags: needinfo?(emorley)
Reporter | ||
Updated•12 years ago
|
Summary: after updating preloaded or non preloaded packaged app, starting app shows old version → after updating packaged app, starting app shows old version
Updated•12 years ago
|
Comment 9•12 years ago
|
||
Comment 10•12 years ago
|
||
Verified - I managed to get an update on Thursday that did update the packaged app to the new version successfully.
Updated•12 years ago
|
status-firefox19:
--- → wontfix
status-firefox20:
--- → wontfix
status-firefox21:
--- → fixed
Target Milestone: --- → B2G C4 (2jan on)
Updated•12 years ago
|
No longer blocks: market-packaged-apps
You need to log in
before you can comment on or make changes to this bug.
Description
•