Closed Bug 777121 Opened 12 years ago Closed 6 years ago

When an app fails to launch via the browser, send an error up to JS to indicate to web content that the app failed to launch and why

Categories

(Core Graveyard :: DOM: Apps, defect)

16 Branch
defect
Not set
normal

Tracking

(firefox16 wontfix)

RESOLVED WONTFIX
Tracking Status
firefox16 --- wontfix

People

(Reporter: jsmith, Unassigned)

Details

When an app fails to launch via the browser, we currently do not report any error back either through returning an error code or throwing an exception to indicate to web content that the app failed to launch and why. We should provide a way to indicate to web content that when an app fails to launch, indicate why it failed in JS so that web content can handle it accordingly.
Keywords: dev-doc-needed
Priority: -- → P1
I agree that we should fix this. And the fix does have a desktop-specific component. But it also requires us to fix an underlying issue in the mozApps API, which unconditionally calls the success callback for a "launch" request after sending a webapps-launch notification: https://github.com/mozilla/mozilla-central/blob/2c83384d5ad30903d97014c5320ab2e0e5666f18/dom/apps/src/Webapps.jsm#L1020-L1021 We might want to track the API and runtime-specific parts of the fix in separate bugs, but let's use this bug to track both for the moment, since we might end up fixing them together. Thus moving this to the appropriate product/component for the underlying issue with the API.
Component: Web Apps → DOM: Apps
Priority: P1 → --
Product: Firefox → Core
This would be easily fixable for the desktop runtime as we don't need to call notifyObserver but could directly call WebappOSUtils.launch. But I guess we want to keep the same behavior between platforms, so we could create an observer in Webapps.jsm that waits for a "webapps-launched" event.
(In reply to Marco Castelluccio [:marco] from comment #2) > This would be easily fixable for the desktop runtime as we don't need to > call notifyObserver but could directly call WebappOSUtils.launch. But I > guess we want to keep the same behavior between platforms, so we could > create an observer in Webapps.jsm that waits for a "webapps-launched" event. We also need to associate that event with the launch request that triggered it.
Product: Core → Core Graveyard
Core Graveyard / DOM: Apps is inactive. Closing all bugs in this component.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.