Firefox hangs on a page with slow running script




8 years ago
6 years ago


(Reporter: nizamov.shawkat, Unassigned)



Windows XP

Firefox Tracking Flags

(Not tracked)


(Whiteboard: [testday-20120831], URL)


(1 attachment)



8 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20100611 Firefox/3.6.4
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20100611 Firefox/3.6.4

Just try that link - Firefox 3.6.4 hangs on that page!
I tried to disable Flash plugin - firefox still hangs. 

Reproducible: Always

Steps to Reproduce:
1. open link
2. see firefox hanging 
Actual Results:  
firefox hangs

Expected Results:  
see what is actually written on that web page

Comment 1

8 years ago
Oops! Firefox hangs not exactly on opening that URL, but on clicking that URL from Google. So, to reproduce this big :

1) open google
2) search for "python find program directory"
3) look for the 4th or 5th link, pointing to
4) exact link by google is
5) click on that link  
6) see how Firefox hangs

Comment 2

8 years ago
Firefox in Safe mode also hangs.

Comment 3

8 years ago
That's not a hang - there's a script running that consumes a lot of cpu (searchhi.js), which tries to highlight the search words that you used on Google. But after 10 seconds, the warning dialog comes up, and you can stop it.

Comment 4

8 years ago
Sorry, in my case this is exactly a hang, I can wait more than 10 minutes and there is no any dialogs. But this may be already another problem.


7 years ago
Version: unspecified → 3.6 Branch
Jo, so is this a bug with us or their script?

Comment 6

7 years ago
Note that it never hanged for me, I'm not sure why experienced that.

With Mozilla 4.0.1, there's no slow-script warning either. Either the changed something in their script, or Firefox 4.0 is now faster, and doesn't complain anymore. I guess the former. : it's it ok for you to close this bug ? Do you still see the problem ?

Comment 7

7 years ago
Yes, I still observe erratic behaviour with Firefox 4.0.1, on 2 PC's on both Windows XP 32-bit and Ubuntu 64-bit. On both systems after opening the redirection URL (from Comment #1, step 4, not from the original bugreport!) firefox shows up a part of activestate page, then it freezes for a few seconds, then it become responsive for a few seconds again and then freezes forever. Monitoring system resource I noticed that it uses 100% CPU and steadily grows up in memory till several gigabytes. On Linux then it would be killed by OOM-killer. On Windows it shows a window with message like "Firefox crashed, send a bug report back to Mozilla?". I answered "Yes", so another bugreport should be registered somewhere on Mozilla's servers. After then Firefox restarts, restores windows and guess what  - it still hangs on both systems! I do not know why others can not reproduce it while I can on both computers that are available for me right now. Just followed the link from Comment#1.

Comment 8

7 years ago
You never said that it crashed, only that it was hung. In that case, can you tell us the crash-id ? You can find it back in <about:crashes>.

Comment 9

7 years ago
Here it is:

Hungs were occuring with 3.6.4, now I am using 4.0.1. 
On Linux it really hungs, but gets silently killed by OS. On Windows it now generates a crash report. 

My environment is quite generic, the only thing that I could suspect is that we have to use a squid based proxy to access internet. Unfortunately, I can not check the case without proxy. Anyway I hardly believe that this could cause such problems.

Comment 10

7 years ago
That crash signature doesn't contain any useful information. Any other crash id's listed?

On Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20110420 Firefox/3.6.17 ID:20110420140830 I get the slow running script dialog after ~10 seconds.

On Mozilla/5.0 (Windows NT 5.1; rv:7.0a1) Gecko/20110610 Firefox/7.0a1 ID:20110610030736 I am getting a fairly long hang (>30 seconds) and then finally get the slow running script warning:

A script on this page may be busy, or it may have stopped responding. You can stop the script now, or you can continue to see if the script will complete.


Comment 11

7 years ago
Do you observe a memory consumption increase too? In my case Firefox eats all the memory before being killed.

Comment 12

7 years ago
I do see a spike to over 400 Mb.

Nizamov -> That crash signature doesn't contain any useful information. Any other crash id's listed in about:crashes?

Comment 13

7 years ago
Nizamov -> That crash signature doesn't contain any useful information. Any other crash id's listed in about:crashes?

Comment 14

7 years ago

I tried to reproduce the crashes, but Firefox silently upgraded from version 4.0 to version 5.0 on both PC's that I use. Now I also observe the same behavior with Firefox 5.0 as you - after a hang for a few seconds (5-15) I see the slow running script warning, on both Linux and WinXp. 

So, the bottom line is that bug was present in Firefox versions including 4.0 and have gone in Firefox 5.0. Probably, bugreport could be now closed, it is not relevant anymore.

Comment 16

7 years ago
Neither crash ID has any usable stack data. Do you have any others?

I always get the slow running script dialog, but no crash.

If no other crash ids, the best bet is to get a stacktrace with WinDGB ->
Version: 3.6 Branch → 5 Branch

Comment 17

7 years ago
Created attachment 548009 [details]

Comment 18

7 years ago
I noticed that crash generally occurs on the second attempt to open that page. Can you try opening it twice, closing the corresponding tab before second attempt?

Comment 19

7 years ago
Still getting a ~30 second hang with Mozilla/5.0 (Windows NT 5.1; rv:8.0a1) Gecko/20110723 Firefox/8.0a1 ID:20110723030814 and then get the slow running script dialog.

Same results with closing the tab, opening a new tab, and revisiting the URL.
Summary: Firefox 3.6.4 hangs on this page → Firefox hangs on a page with slow running script
Version: 5 Branch → Trunk
        if (pn.className != "searchword") {
          // word has not already been highlighted!
          var nv = node.nodeValue;
          var ni = tempNodeVal.indexOf(tempWordVal);
          // Create a load of replacement nodes
          var before = document.createTextNode(nv.substr(0, ni));
          var docWordVal = nv.substr(ni, word.length);
          var after = document.createTextNode(nv.substr(ni + word.length));
          var hiwordtext = document.createTextNode(docWordVal);
          var hiword = document.createElement("span");
          hiword.className = "searchword";
          pn.insertBefore(before, node);
          pn.insertBefore(hiword, node);
          pn.insertBefore(after, node);
          pn.removeChild(node); <================== Line 44 with the slow Script Warning
          searchhi.found += 1;

The Crashes - when happening - would be just OOMs, no?
Btw, the URL is killing Opera Next/GC 14 too (CPU-wise).
Component: General → General
Keywords: hang
Product: Firefox → Core
QA Contact: general → general
I cannot reproduce the bug using today's Nightly and Windows 7.

Could you please try again with a newer Firefox version? Thanks!
Whiteboard: [testday-20120831]

Comment 22

6 years ago
hi @Gabriela.
I am having windows 7 and firefox version is 14.0.1
Facebook ticker problem is resolved.
but, still there is some random error.
It occurs after continuous usage for hours, I can't track the exact event when the hang occurs.
Hi, many thanks for your update!
Whenever it hangs, please obtain the Crash ID from about:crashes and paste it here.

Comment 24

6 years ago

I can not reproduce this bug anymore (FF 14 on WinXP and Linux). There is even no slow script warning, url/page is opened and rendered as fast as it could be generally expected. Probably, the bug is fixed meanwhile, however, it can be attributed to the changes in my systems too.
Hi, many thanks for the update!

I will close this bug as works for me, please reopen should you have more issues.
Last Resolved: 6 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.