Closed Bug 827034 Opened 12 years ago Closed 12 years ago

Simultaneous downloading of a hosted app preloading appcache and a packaged app - hosted app fails to install, can't be launched, and can't be used ever again

Categories

(Core Graveyard :: DOM: Apps, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: jsmith, Assigned: etienne)

Details

(Keywords: dataloss)

Build: B2G 18 1/5/2013 Device: Unagi Steps: 1. Start installing the hosted app with appcache preloading test case 4 from http://mozqa.com/webapi-permissions-tests/ 2. Start installing the packaged app test case 5 from http://mozqa.com/webapi-permissions-tests/ 3. Wait until both apps finish installing 4. Try launching the app that preloaded the appcache Expected: The app should launch. Actual: The app fails to launch. And this gets worse - if I try uninstall the app, it won't get removed from the homescreen until a restart. If I try to install the app again, it won't install. So something fatal happened here.
Component: Gaia::Homescreen → DOM: Apps
Product: Boot2Gecko → Core
Version: unspecified → Trunk
blocking-basecamp: --- → ?
Keywords: dataloss
Consistently reproducible too.
Apparently this happens even if the packaged app is valid.
Summary: Try to install a valid hosted app that preloads a large appcache and packaged app with a mini-manifest to manifest mismatch - hosted app installs, can't be launched, and can't be used ever again → Try to install a valid hosted app that preloads a large appcache and a large packaged app - hosted app silently fails install, can't be launched, and can't be used ever again
Assignee: nobody → fabrice
blocking-basecamp: ? → +
Turns out there's other repo steps that can reproduce this behavior quite easily. I just reproduced this same bug when trying to restart a download for a packaged app and a hosted app preloading appcache at the same time. Same issue reoccurs. I got a feeling that the problem going on here is that *bad* things are happening when we try download resources for a hosted app preloading appcache and a packaged app at the same time.
Summary: Try to install a valid hosted app that preloads a large appcache and a large packaged app - hosted app silently fails install, can't be launched, and can't be used ever again → Simultaneous downloading of a hosted app preloading appcache and a packaged app - hosted app fails to install, can't be launched, and can't be used ever again
Here's what's happening: * We start the AppCache app install - there are no application with a "mozqa.com" manifest's origin - we generate an ID for this app - we save the app in the app registry * We start the packaged app install - we lookup and find an app with "mozqa.com" as a manifest's origin - we assign the same ID to this app - we override the appacache app entry in the registry with the packaged app one -- once the 2 installations are done -- * When trying to launch the packaged app no problem * When trying to launch the AppCache app we find that the manifestURL doesn't match the app id, we bailout -- after a phone restart -- * The AppCache app isn't there anymore (since it got overwritten in the app registry by the packaged app) -- note -- Once the packaged app is installed its origin is changed to an "app://" one, that's why when you install the packaged app first, then the appcache one, it works. Talked with Fabrice, this is a WONTFIX since we don't plan to fully support multiple apps by origin for v1.
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → WONTFIX
Packaged apps have no concept of an app origin. Reopening.
Status: RESOLVED → REOPENED
Resolution: WONTFIX → ---
Status: REOPENED → RESOLVED
Closed: 12 years ago12 years ago
Resolution: --- → WONTFIX
Fabrice clarified this to me what's going wrong here - we don't support a packaged app mini-manifest and a webapp manifest on the same origin due to the multiple apps per origin rule. I need to check that marketplace is serving mini-manifests on a different origin than the webapp origin.
blocking-basecamp: + → ---
No longer blocks: b2g-app-updates
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.