Since a few days ago I started noticing the following message on error
console (on Google Chrome 17.0.963.79, on Ubuntu):
Failed to load resource: the server responded with a status of 404 (Not Found)
https://pt.wikibooks.org/function%20(selector,context)%7Breturn%20new%20jQuery.fn.init(selector,context,rootjQuery);%7D
When I asked on IRC, Roan said it was as if "someone used
mw.wikiScript( $ ) or something", and that "the part after /w/ is
equal to $.toString()" (which is indeed the case, except for the URL
encoding)
After some debugging, I found the error was being caused by one of my
user scripts:
https://pt.wikibooks.org/?oldid=234535
and then I tried to reduce the code as much as I could, to isolate the
problem, and the simplified version can be found here:
https://pt.wikibooks.org/?oldid=234559&action=edit
When I'm using it, with all gadgets disabled, I get the error on that
page itself, right after my debug message is shown:
"$( addButton )" was executed inside of mw.loader.using( 'ext.wikiEditor.toolbar'...
In debug mode,
https://pt.wikibooks.org/?oldid=234540&action=edit&debug=1
The "URL" in the error message is a little different:
GET https://pt.wikibooks.org/function%20(%20selector,%20context%20)%20%7B//%20The%20jQuery%20object%20is%20actually%20just%20the%20init%20constructor%20'enhanced'return%20new%20jQuery.fn.init(%20selector,%20context,%20rootjQuery%20);%7D
404 (Not Found)
(and it also happens right after "$( addButton )" was executed inside
of mw.loader.using( 'ext.wikiEditor.toolbar'...), which is the encoded
form of
"function ( selector, context ) {// The jQuery object is actually just
the init constructor 'enhanced'return new jQuery.fn.init( selector,
context, rootjQuery );}"
The error also happens on pages such as these:
https://pt.wikibooks.org/wiki/Special:Random?action=edit&debug=1
https://pt.wikibooks.org/wiki/JustAnEmptyPage?action=edit&debug=1
and also on Firefox 9.0.1 on Windows XP:
GET https://pt.wikibooks.org/w/function%20(selector,%20context)%20%7B%20%20%20%20return%20new%20jQuery.fn.init(selector,%20context,%20rootjQuery);%7D
[HTTP/1.1 404 Not Found 578ms]
What could be causing this?
Did I do something wrong on that script, or there is a bug in some of the functions used?
Version: 1.19
Severity: normal