Closed
Bug 1146132
Opened 10 years ago
Closed 10 years ago
content scripts don't attach to intercepted frame on firefox nightly with e10s
Categories
(Add-on SDK Graveyard :: General, defect, P1)
Add-on SDK Graveyard
General
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 707624
People
(Reporter: winhowes, Unassigned)
References
Details
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:36.0) Gecko/20100101 Firefox/36.0
Build ID: 20150320202338
Steps to reproduce:
I'm writing a FF addon where when a particular url is loaded in an iframe I intercept the request and load my own content instead by redirecting to a data URI and attaching a content script to the intercepted iframe. This works brilliantly on every version of FF except nightly with e10s enabled (it works with e10s disabled).
Interception Code:
function requestListener(event){
event.subject.QueryInterface(Ci.nsIHttpChannel);
let url = event.subject.URI.spec;
if(url == particularURL) {
event.subject.redirectTo(Services.io.newURI("data:text/html,CONTENT",null, null));
}
}
Page Mod code:
pageMod.PageMod({
include: ["data:*"],
contentScriptFile: [data.url("myScript.js")],
contentScriptWhen: "ready",
attachTo: ["frame"],
onAttach: function(worker){
console.log("Attached"); //doesn't run with e10s
}
});
Actual results:
In FF nightly with e10s enabled, the content script doesn't attach to the newly loaded frame.
Expected results:
The content script should attach to the newly loaded frame (this works with e10s disabled)
Updated•10 years ago
|
Flags: needinfo?(dtownsend)
Updated•10 years ago
|
Blocks: sdk/page-mod, e10s-sdk
Priority: -- → P1
Comment 1•10 years ago
|
||
Can you give a fuller testcase here, how is requestListener being called for example?
Flags: needinfo?(winhowes)
requestListener is being called like this:
var events = require("sdk/system/events");
events.on("http-on-modify-request", requestListener);
Flags: needinfo?(winhowes)
Updated•10 years ago
|
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Flags: needinfo?(dtownsend)
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•