Last modified: 2013-03-28 03:01:30 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T34549, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 32549 - Wikipedia pages freezes on Konqueror
Wikipedia pages freezes on Konqueror
Status: NEW
Product: MediaWiki
Classification: Unclassified
JavaScript (Other open bugs)
unspecified
All Linux
: Low normal (vote)
: ---
Assigned To: Nobody - You can work on this!
http://en.wikipedia.org/?debug=1
: javascript
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-11-21 16:04 UTC by Helder
Modified: 2013-03-28 03:01 UTC (History)
5 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
Call stack on Konkeror (67.11 KB, image/png)
2011-11-21 16:04 UTC, Helder
Details

Description Helder 2011-11-21 16:04:05 UTC
Created attachment 9515 [details]
Call stack on Konkeror

I'm trying to access Wikipedia articles but the only browser available in the computers of the lab I have access on my university is Konqueror 3.5.9 (Using KDE 3.5.10). On this browser, every time I open a page such as
http://en.wikipedia.org/?debug=1
http://en.wikipedia.org/wiki/Special:RecentChanges?limit=2&debug=1
I get the following message a few seconds after the page content is displayed:
----
A script on this page is causing KHTML to freeze. If it continues to run, other applications may become less responsive.
Do you want to abort the script?
----

I've enabled debugger and error reporting in the browser, to get more details about what could be the cause. When I reloaded the page, I got also this one:
----
An error occurred while attempting to run a script on this page.
http://bits.wikimedia.org/en.wikipedia.org/load.php?debug=true&lang=en&module... line 3945
[Debug] [OK]
----

and then I clicked in the "Debug" option to see the source code of the problematic script. The line mentioned contains this:
----
   results.sort( sortOrder );
----

and the call stack contains this scripts displayed in the attached screenshot. One of the scripts in the call stack is stopped in the following line:
----
    this.updateTooltipAccessKeys(
        $( '#column-one a, #mw-head a, #mw-panel a, #p-logo a' ) );
----
(which is from
http://svn.wikimedia.org/viewvc/mediawiki/branches/REL1_18/phase3/resources/mediawiki/mediawiki.util.js?view=markup#l261
)

Maybe the problem could be resolved if this jQuery selector were improved, by first selecting the elements by id and then finding "a" elements inside them. Would something like
----
    this.updateTooltipAccessKeys(
        $( '#column-one, #mw-head, #mw-panel, #p-logo' ).find( 'a' ) );
----
be more efficient?


Anyway, after I close the debugger, and go back to the article, I get the same error message again, and if I click on [Ok] or press ESC it just makes the error message to be displayed again and again whithout end.


PS: I noticed the error also on other wikis, such as
http://pt.wikipedia.org/?debug=1

On the other hand, it doesn't happens on some special pages:
http://en.wikipedia.org/wiki/Special:SpecialPages?debug=1
http://pt.wikipedia.org/wiki/Special:SpecialPages?debug=1
Comment 1 Brion Vibber 2011-11-21 18:41:37 UTC
The alternate selector that you're recommending looks like it would perform the exact same operations as the first one (in both cases, I believe it would start with getElementById lookups on the four IDs, then call getElementsByTagName('a') within each one, and combine the results into one collection).


Beware that Konqueror has a nasty history of having weird bugs in old versions that nobody does much about because they're fixed in later versions and very few people use the old ones.

Testing with an OpenSuSE LiveCD that has KDE 3.5.10 ...

No problems visible at:
* http://en.wikipedia.org/
* http://en.wikipedia.org/?debug=1
* http://en.wikipedia.org/wiki/Special:RecentChanges?limit=2&debug=1

So far, works for me on Konqueror 3.5.10.


Is this happening when logged out as well as logged in? Can you reproduce it with a fresh profile?
Comment 2 Mark A. Hershberger 2011-11-21 19:00:49 UTC
The version I had handy is 4.0.4 (20080505) which had the same problems as Bug #31945 on the recent changes page.  But it did work.
Comment 3 Helder 2011-11-21 19:04:45 UTC
(In reply to comment #1)
> Is this happening when logged out as well as logged in? Can you reproduce it
> with a fresh profile?

I don't remember. I'll check again tomorrow.
Comment 4 Helder 2011-11-22 22:50:10 UTC
The bug happens when I'm logged or unlogged and visit any of the following pages:
http://en.wikipedia.org/wiki/Blackbeard
http://en.wikipedia.org/wiki/Virginia
http://en.wikipedia.org/wiki/New_World

It do not happens on these pages:
http://en.wikipedia.org/wiki/Robert_Maynard
http://en.wikipedia.org/wiki/Cival
http://en.wikipedia.org/wiki/Spanish_conquest_of_Yucatán

The following test seems to indicate that the change I suggested above would not make things better:
http://jsperf.com/jquery-selector-for-anchor
Comment 5 Roan Kattouw 2011-11-23 11:10:27 UTC
(In reply to comment #1)
> The alternate selector that you're recommending looks like it would perform the
> exact same operations as the first one (in both cases, I believe it would start
> with getElementById lookups on the four IDs, then call
> getElementsByTagName('a') within each one, and combine the results into one
> collection).
> 
In an ideal world, that would be true, but $( '#foo' ).find( 'a' ) really is faster. See also [[mw:JSPERF]].

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links