Closed
Bug 1152330
Opened 10 years ago
Closed 10 years ago
Avoid to add listener from rulers highlighter to content window
Categories
(DevTools :: Inspector, defect)
DevTools
Inspector
Tracking
(firefox40 affected, firefox43 fixed)
RESOLVED
FIXED
Firefox 43
People
(Reporter: zer0, Assigned: zer0)
References
(Blocks 1 open bug)
Details
Attachments
(1 file, 2 obsolete files)
4.76 KB,
patch
|
zer0
:
review+
pbro
:
feedback+
|
Details | Diff | Splinter Review |
Currently the rulers adds a couple of listeners to the content window; that should be avoided.
Assignee | ||
Updated•10 years ago
|
OS: Mac OS X → All
Hardware: x86 → All
Assignee | ||
Comment 1•10 years ago
|
||
Assignee | ||
Updated•10 years ago
|
Attachment #8639333 -
Flags: review?(pbrosset)
Assignee | ||
Comment 2•10 years ago
|
||
Comment on attachment 8639333 [details] [diff] [review]
Avoid to add listener from rulers highlighter to content window
Changing reviewer 'cause Patrick will be on PTO for a while.
Mike, can you have a look at that? If you don't feel comfortable to review this, just let me know! Thanks!
Attachment #8639333 -
Flags: review?(pbrosset) → review?(mratcliffe)
Updated•10 years ago
|
Attachment #8639333 -
Flags: review?(mratcliffe) → review+
Assignee | ||
Comment 3•10 years ago
|
||
Assignee | ||
Updated•10 years ago
|
Attachment #8639333 -
Attachment is obsolete: true
Assignee | ||
Comment 4•10 years ago
|
||
Comment on attachment 8646765 [details] [diff] [review]
Avoid to add listener from rulers highlighter to content window
Comparing to the previous patch, I just added the try / catch block I mentioned on vidyo. My mistake was that I was using a `finally` initially instead of a `catch`; without realizing that it was a nested `try` statement – therefore the enclosing try statement's catch clause was entered.
Where this patch will indeed solve the issue when we leave the tests – at least locally, I'm running on try too – we should probably understand what is happening with the highlighter environment, and why is destroyed before the highlighter.
Attachment #8646765 -
Flags: review+
Attachment #8646765 -
Flags: feedback?(pbrosset)
Assignee | ||
Comment 5•10 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=d7174c6e46fb
There is an exception, but it doesn't seems related to this bug.
Comment 6•10 years ago
|
||
What about if in CustomHighlighterActor.prototype.finalize you reverse the environment and highlighter destroys?
finalize: method(function() {
if (this._highlighter) {
this._highlighter.destroy();
this._highlighter = null;
}
if (this._highlighterEnv) {
this._highlighterEnv.destroy();
this._highlighterEnv = null;
}
}, {
oneway: true
})
Tried this quickly locally, and the exception seems to be gone.
Updated•10 years ago
|
Attachment #8646765 -
Flags: feedback?(pbrosset)
Assignee | ||
Comment 7•10 years ago
|
||
(In reply to Patrick Brosset [:pbrosset] [:pbro] from comment #6)
> What about if in CustomHighlighterActor.prototype.finalize you reverse the
> environment and highlighter destroys?
This is definitely the culprit then; I was looking at `HighlighterActor`, where the order is correct (the highlighter is destroyed before the environment).
> Tried this quickly locally, and the exception seems to be gone.
Should we remove the try / catch then, and invert the order in `CustomHighlighterActor`?
Comment 8•10 years ago
|
||
(In reply to Matteo Ferretti [:matteo] [:zer0] from comment #7)
> Should we remove the try / catch then, and invert the order in
> `CustomHighlighterActor`?
Yes, that's the right thing to do.
Assignee | ||
Comment 9•10 years ago
|
||
Assignee | ||
Comment 10•10 years ago
|
||
Comment on attachment 8649318 [details] [diff] [review]
Avoid to add listener from rulers highlighter to content window
I thought I've already updated this patch, but apparently I didn't.
Here also the try result:
https://treeherder.mozilla.org/#/jobs?repo=try&revision=3d780dde0c02
Attachment #8649318 -
Flags: review+
Attachment #8649318 -
Flags: feedback?(pbrosset)
Comment 11•10 years ago
|
||
Comment on attachment 8649318 [details] [diff] [review]
Avoid to add listener from rulers highlighter to content window
Review of attachment 8649318 [details] [diff] [review]:
-----------------------------------------------------------------
Looks good!
Attachment #8649318 -
Flags: feedback?(pbrosset) → feedback+
Assignee | ||
Updated•10 years ago
|
Attachment #8646765 -
Attachment is obsolete: true
Assignee | ||
Updated•10 years ago
|
Keywords: checkin-needed
Comment 12•10 years ago
|
||
Keywords: checkin-needed
Status: NEW → RESOLVED
Closed: 10 years ago
status-firefox43:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 43
Updated•7 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•