Closed Bug 933587 Opened 11 years ago Closed 11 years ago

content-sessionStore.js:179 - ReferenceError: Ci is not defined


(Firefox :: Session Restore, defect)

Not set



Firefox 28
Tracking Status
firefox28 + verified


(Reporter: jruderman, Assigned: billm)


(Depends on 1 open bug)


(Keywords: regression)

1. Create a new profile
2. Launch debug Firefox
3. Press Cmd+N

Result: on stdout or stderr, and in the Browser Console,

System JS : ERROR chrome://browser/content/content-sessionStore.js:179 - ReferenceError: Ci is not defined

I'm guessing this is a regression from
Assignee: nobody → wmccloskey
Am I right in assuming that this error could be the cause of intermittent tab restore failures?  About 5% of my tabs fail to reload properly (typically the most recently used ones), and it started in the last few days of Nightlies.  Or should I file this issue separately?
(In reply to J. Ryan Stinnett [:jryans] from comment #2)
> ...should I file this issue separately?

See bug #934212
These sorts of problems are extremely annoying. We really need to fix bug 673569 somehow.
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 28
It concerns me when things like this can break without our test suite noticing at all. Can we please find a way to test this more?
Flags: in-testsuite?
Yes, I was thinking the exact same thing and it's on my todo list. I'll look into that and will file a bug to do that. Thanks for following up, I was a little surprised as well that we didn't catch that.
I should explain the problem some more, since the bug is not as straightforward as it looks. Content scripts all share the same global. So if we have two content scripts, A and B, and A defines Ci, then B doesn't need to define Ci as long as it's loaded after A.

The problem here is that somehow content-sessionStore.js was getting loaded before any other script that defines it. Felipe and I were talking about why the ordering might be different at different times, but we don't know. Anyway, the nondeterminism here is why we didn't catch this in testing. Usually it works fine. We might be able to make a test for this by figuring out what causes the ordering to be different and then triggering that, but I'm not sure it's worth it.

Bug 673569 will fix the problem by effectively wrapping each content script in (function(){...})(). That way, if one doesn't define Ci, it will fail no matter what.
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:28.0) Gecko/20100101 Firefox/28.0
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:28.0) Gecko/20100101 Firefox/28.0

Tested this on latest Aurora (Build ID: 20131211004000) using the scenarios from 934212#c2 and 934212#c10 and the sessions were properly restored each time.

Tim, do you want me to cover anything else for this issue?
Flags: needinfo?(ttaubert)
(In reply to Cornel Ionce [QA] from comment #12)
> Tim, do you want me to cover anything else for this issue?

No, thank you. This issue should be fixed and Bill is working on bug 673569 to prevent future failures like that.
Flags: needinfo?(ttaubert)
Ok, marking this issue as verified in this case. Thank you!
You need to log in before you can comment on or make changes to this bug.