Closed Bug 850421 Opened 8 years ago Closed 8 years ago
app:// urls aren't shortened when displayed in the debugger side menu
This is because app:// urls can't be turned into a Ci.nsIURL for some reason. Because we rely on this service for trimming, they show up like in the attached screenshot, which is less than optimal. We can (and should IMHO) hack our way out of this for now.
Huh, this seems fixed in the latest fx-team.
Test it in a scratchpad like this: let url = "app://system.gaiamobile.org/js/test.js"; let uri = Services.io.newURI(url, null, null).QueryInterface(Ci.nsIURL); This throws in Nightly but works in fx-team, so I guess It's going to go away in a few days time. However, it'd be nice if we had some tests written for this.
Huh... this *still* happens in Nightly.
I don't understand why creating a newURI with "app://foo.js" works in fx-team tip, but throws a "Exception: Component returned failure code: 0x80004002 (NS_NOINTERFACE) [nsISupports.QueryInterface]" in Nightly… Those repos should've been in sync by now. Clean profiles in both builds didn't change anything. Am I doing something incredibly dumb or can anyone else reproduce this behavior? Fwiw, this happens in Aurora too..
I can reproduce this and it is working in both debug and optimized builds in fx-team tip, while failing in Nightly. I wonder what else is different there.
fabrice/bsmedberg, do you have any idea why this is happening? I don't see the AppProtocolHandler being packaged in browser/installer/package-manifest.in, whereas it is included in b2g/installer/package-manifest.in. Could that explain why the protocol handler is present when run from a symlinked build and not from a Nightly? If the plan is to not include the AppProtocolHandler in desktop Firefox, how should the debugger treat such URLs?
Panos, indeed AppProtocolHandler is not packaged with firefox desktop since we have no support for packaged apps there, so indeed you are probably just "lucky" with the symlink. This protocol handler is only available on b2g and android so far, but that should be harmless to package it in fx also if you need it.
Thanks Fabrice. I had to fix bug 855223 and bug 855227 first, in order to be able to test the fix, but it does indeed fix the problem when debugging Firefox OS.
Assignee: nobody → past
Status: NEW → ASSIGNED
Attachment #730075 - Flags: review?(benjamin)
Priority: -- → P2
Whiteboard: [b2g] → [b2g][fixed-in-fx-team]
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Whiteboard: [b2g][fixed-in-fx-team] → [b2g]
Target Milestone: --- → Firefox 22
You need to log in before you can comment on or make changes to this bug.