Chad Horohoe [Wed, 20 Jul 2011 23:06:24 +0000 (23:06 +0000)]
Revert r85034, r81186, r77638: per CR on r77638: XMLReader and XMLWriter are memory-hungry beasts and this script OOMs constantly.
This was already reverted in 1.17wmf1 (r82930) by Ariel. Doing the same in trunk now. I'm not opposed to using the new pretty XML* classes, but somebody needs to debug why they eat memory for breakfast, lunch and dinner.
Chad Horohoe [Wed, 20 Jul 2011 22:32:30 +0000 (22:32 +0000)]
(bug 25355) Parser generates edit section links for special pages
Per Tim on r58362: disable edit section links on all text parsed via $wgOut. Article already handles setting this to true for page content, so this shouldn't really hurt anything. Could use some tests to confirm the behavior, however. Should resolve the last problems with r70498 and friends.
Robin Pepermans [Wed, 20 Jul 2011 22:31:47 +0000 (22:31 +0000)]
Use $this->getLang() per Nikerabbit on r91648.
Ryan Schmidt [Wed, 20 Jul 2011 20:12:48 +0000 (20:12 +0000)]
* $wgDnsBlacklistUrls now accepts an array with url and key as the elements to work with DNSBLs that require keys, such as Project Honeypot.
Alexandre Emsenhuber [Wed, 20 Jul 2011 19:49:15 +0000 (19:49 +0000)]
* Use local context instead of global variables
* Call Linker methods statically
* Throw exceptions directly instead of calling OutputPage's methods that will throw them
* Use Title::getUserPermissionsErrors() instead of Title::userCan() so that the User object can be passed to them
Raimond Spekking [Wed, 20 Jul 2011 19:26:59 +0000 (19:26 +0000)]
Localisation updates for core and extension messages from translatewiki.net (2011-07-20 19:00:00 UTC)
Ian Baker [Wed, 20 Jul 2011 17:08:37 +0000 (17:08 +0000)]
Documenting new parser hook, re r92506.
This refers to an extension that's not checked in quite yet, FYI
Alexandre Emsenhuber [Wed, 20 Jul 2011 16:49:02 +0000 (16:49 +0000)]
Make Title::isNamespaceProtected() require the $user parameter, the only call to it is in the file itself
Platonides [Wed, 20 Jul 2011 15:38:13 +0000 (15:38 +0000)]
Commit a list of unimplemented tests.
Platonides [Wed, 20 Jul 2011 15:35:48 +0000 (15:35 +0000)]
Follow up r92635
Platonides [Wed, 20 Jul 2011 15:33:46 +0000 (15:33 +0000)]
Fix for r91885.
These tests were added in r91885.
Platonides [Wed, 20 Jul 2011 15:30:57 +0000 (15:30 +0000)]
Follow up r92635.
Platonides [Wed, 20 Jul 2011 15:24:21 +0000 (15:24 +0000)]
I like better checking for the actual extension, loading if needed (and able).
Platonides [Wed, 20 Jul 2011 15:13:58 +0000 (15:13 +0000)]
Fixup r89029. You don't include the brackets in the method name!
--ta línea y las que están debajo serán ignoradas--
M includes/media/SVGMetadataExtractor.php
M tests/phpunit/includes/media/SVGMetadataExtractorTest.php
Niklas Laxström [Wed, 20 Jul 2011 12:59:11 +0000 (12:59 +0000)]
Removed todos, not useful
Moved separators to separatorTransformTable
Sam Reed [Wed, 20 Jul 2011 11:46:27 +0000 (11:46 +0000)]
Remove @return void documentation
Add missing error to getPossibleErrors
Aryeh Gregor [Wed, 20 Jul 2011 02:34:25 +0000 (02:34 +0000)]
Allow blocked sysops to view Special:Unblock
Previously, trying to visit [[Special:Unblock]] while blocked would give
an error, even if the user has the unblockself permission. I moved the
permission check from execute() to right before the code that does the
actual unblocking. This should probably be examined closely for
security, since I'm not familiar with this code, although the impact of
a bug would be small. I tested some simple cases manually and they all
worked as expected:
* Unblocking self works (as before)
* Submitting the form fails unless you're trying to unblock yourself (as
before)
* GETting the page with any parameters works (previously failed unless
the target was your own username)
Aryeh Gregor [Wed, 20 Jul 2011 02:34:17 +0000 (02:34 +0000)]
Fix inaccurate return type in comment
Owen Davis [Wed, 20 Jul 2011 00:15:05 +0000 (00:15 +0000)]
added missing null checks in callers of Revision::newNullRevision
Robin Pepermans [Tue, 19 Jul 2011 23:09:55 +0000 (23:09 +0000)]
$wgUploadNavigationUrl should be used for file redlinks if $wgUploadMissingFileUrl is not set. The first was used for this until the second was introduced in r69997 (1.17). According to the comments there it was broken in 1.16 but as far as I tested it worked in 1.16. In any case, the old behavior should be restored as most WMF wikis have set wgUploadNavigationUrl but not wgUploadMissingFileUrl.
Platonides [Tue, 19 Jul 2011 22:10:05 +0000 (22:10 +0000)]
Follow-up r92588. Make it work regardless of $wgHtml5
Platonides [Tue, 19 Jul 2011 21:41:25 +0000 (21:41 +0000)]
Since r92364 UserTest.php needs a database
Platonides [Tue, 19 Jul 2011 21:38:28 +0000 (21:38 +0000)]
Follow up r91419. A boolean attribute can be both the empty string and its name [whatwg.org/specs/web-apps/current-work/multipage/common-microsyntaxes.html#boolean-attributes]
We use the later since that's what xhtml1 required [http://www.w3.org/TR/xhtml1/#h-4.5].
Alexandre Emsenhuber [Tue, 19 Jul 2011 21:35:37 +0000 (21:35 +0000)]
* Use local context instead of global variables
* Call Linker methods statically
Platonides [Tue, 19 Jul 2011 21:22:51 +0000 (21:22 +0000)]
Spacing, removed unneded global.
Roan Kattouw [Tue, 19 Jul 2011 21:19:50 +0000 (21:19 +0000)]
Fixes for URL expanding in CSSMin: adjust the offset correctly (this could've theoretically resulted in very strange bugs) and only call wfExpandUrl() if available (the file is in includes/libs so it should work outside of MediaWiki)
Platonides [Tue, 19 Jul 2011 21:05:17 +0000 (21:05 +0000)]
Remove the globals. r91570 was wrong saying that parent::setUp()
would initialise those vars (this class parent is MediaWikiTestCase,
not MediaWikiLangTestCase) but the language doesn't seem to matter.
Platonides [Tue, 19 Jul 2011 20:36:09 +0000 (20:36 +0000)]
Follow-up r91518
Platonides [Tue, 19 Jul 2011 20:31:48 +0000 (20:31 +0000)]
Follow up r92036. The global is not needed now.
Platonides [Tue, 19 Jul 2011 20:28:02 +0000 (20:28 +0000)]
Follow-up r91246. The global is no longer needed.
Platonides [Tue, 19 Jul 2011 20:21:11 +0000 (20:21 +0000)]
r91784 forgot to change one instance of $wgUser to $user
Raimond Spekking [Tue, 19 Jul 2011 20:10:05 +0000 (20:10 +0000)]
Localisation updates for core and extension messages from translatewiki.net (2011-07-19 19:45:00 UTC)
Platonides [Tue, 19 Jul 2011 20:06:01 +0000 (20:06 +0000)]
Follow up r91561. Use canonical class names.
Platonides [Tue, 19 Jul 2011 20:03:41 +0000 (20:03 +0000)]
Expand the defines from JSTokenizer::__construct() placing them at the top of the file.
This fixes the Notices that would be produced if several JSTokenizer were instantiated.
jsminplus was added in r91591.
Defines code was generated with:
$js = new JSTokenizer();
foreach ($js->opTypeNames as $operand => $name) echo "define('OP_$name', '$operand');\n";
foreach ($js->keywords as $keyword) echo "define('KEYWORD_" . strtoupper($keyword) . "', '$keyword');\n";
Platonides [Tue, 19 Jul 2011 19:53:00 +0000 (19:53 +0000)]
Remove double ; and final ?> from jsminplus (imported in r91591).
This should be uncontroversial.
Platonides [Tue, 19 Jul 2011 19:05:23 +0000 (19:05 +0000)]
Profiling errors. r92106 missed a wfProfileOut
r92118 added a wfProfileIn but not all returns were covered. Also changed its spaces to tabs.
Platonides [Tue, 19 Jul 2011 19:00:09 +0000 (19:00 +0000)]
Follow up to r91561: Use the canonical class names.
Robin Pepermans [Tue, 19 Jul 2011 15:52:38 +0000 (15:52 +0000)]
Follow-up r92528:
* remove @static
* return database result directly (no need for while())
* getAllPrefixesDb() -> getAllPrefixesDB()
Robin Pepermans [Tue, 19 Jul 2011 13:30:38 +0000 (13:30 +0000)]
Follow-up r92528: probably better to put it in the API & new features sections
Robin Pepermans [Tue, 19 Jul 2011 12:30:18 +0000 (12:30 +0000)]
(bug 19838) API does not use interwiki cache.
Patch by Beau; modified to work with current code.
Russ Nelson [Tue, 19 Jul 2011 03:44:28 +0000 (03:44 +0000)]
mark a non-API function private; rename it to reflect what it does; call getPath() rather than accessing object variable directly
Jeroen De Dauw [Tue, 19 Jul 2011 00:43:20 +0000 (00:43 +0000)]
style fix
Ian Baker [Mon, 18 Jul 2011 23:23:14 +0000 (23:23 +0000)]
Refactored section assembly code to be more readable
Added a hook that's called for each section. This allows sections to be addressed separately at the document level, for example by wrapping each in a div (as in the reverted r50769). This in-turn enables richer section-specific UI, like highlighting or in-line editing.
Sam Reed [Mon, 18 Jul 2011 23:04:09 +0000 (23:04 +0000)]
Revert 2 from r92498
Sam Reed [Mon, 18 Jul 2011 23:01:08 +0000 (23:01 +0000)]
Update code comments that point to 1.18 to point to 1.19
Sam Reed [Mon, 18 Jul 2011 22:53:52 +0000 (22:53 +0000)]
Add RELEASE-NOTES-1.18.old into RELEASE-NOTES-1.18
Needs svn copy in REL1_18
Aaron Schulz [Mon, 18 Jul 2011 22:30:38 +0000 (22:30 +0000)]
Removed testBug29116LoadWithEmptyIp. Fails due to wfDeprecated() call in load() and nothing uses that so it's not worth it.
Sam Reed [Mon, 18 Jul 2011 22:27:25 +0000 (22:27 +0000)]
Move current RELEASE-NOTES-1.18 to RELEASE-NOTES-1.18.old
Moved RELEASE-NOTES-1.19 to RELEASE-NOTES-1.18
Wipe RELEASE-NOTES-1.19
Updating text where necessary
Keeping RELEASE-NOTES-1.18.old till we've established there's nothing that just went into that changelog
Sam Reed [Mon, 18 Jul 2011 22:23:42 +0000 (22:23 +0000)]
Add comment
Remove unused wfGetDb()
Andrew Garrett [Mon, 18 Jul 2011 22:02:11 +0000 (22:02 +0000)]
Fix autoblocks in r92480 r92482 -- modified the wrong half
Sam Reed [Mon, 18 Jul 2011 22:01:40 +0000 (22:01 +0000)]
It seems people don't either pay attention to code comments, or those comments lie
r92461
Andrew Garrett [Mon, 18 Jul 2011 21:56:59 +0000 (21:56 +0000)]
Fix autoblocks in r92480
Chad Horohoe [Mon, 18 Jul 2011 21:56:10 +0000 (21:56 +0000)]
(bug 29959) Installer fatal when cURL and allow_url_fopen is disabled and user tries to subsribe to mediawiki-announce
Really, I'm not sure about the usefulness of exploding with a MWException anytime we can't do an external request, but at least we can stop the installer from exploding :)
Andrew Garrett [Mon, 18 Jul 2011 21:48:56 +0000 (21:48 +0000)]
Block.php fixes: Always store mExpiry as a TS_MW or "infinity". Convert as appropriate.
Sam Reed [Mon, 18 Jul 2011 21:26:33 +0000 (21:26 +0000)]
* (bug 29938) list=users&usprop=rights shows rights the user doesn't have
Alexandre Emsenhuber [Mon, 18 Jul 2011 20:52:22 +0000 (20:52 +0000)]
Let Skin extend ContextSource instead of reinventing the wheel
Aaron Schulz [Mon, 18 Jul 2011 20:44:51 +0000 (20:44 +0000)]
Refactored new getAutomaticGroups() function out of getEffectiveGroups()
Sam Reed [Mon, 18 Jul 2011 20:11:53 +0000 (20:11 +0000)]
Documentation updates
Add a couple of missing explicit class variables
Raimond Spekking [Mon, 18 Jul 2011 20:05:52 +0000 (20:05 +0000)]
Localisation updates for core and extension messages from translatewiki.net (2011-07-18 19:50:00 UTC)
Sam Reed [Mon, 18 Jul 2011 19:56:16 +0000 (19:56 +0000)]
Set explicit public modifier
Swap @private to private
Ian Baker [Mon, 18 Jul 2011 19:31:38 +0000 (19:31 +0000)]
changed sessionkey to filekey to keep consistent with the rest of UploadStash (while retaining sessionkey for backwards compatibility)
Neil Kandalgaonkar [Mon, 18 Jul 2011 18:59:56 +0000 (18:59 +0000)]
removing xdebug call
Mark A. Hershberger [Mon, 18 Jul 2011 18:05:45 +0000 (18:05 +0000)]
Bug #29874 - Image extension strict whitelist handling is inconsistent
Patch from Dan Collins
Aaron Schulz [Mon, 18 Jul 2011 17:23:56 +0000 (17:23 +0000)]
Updated doMaintenance since wmf-config/ was moved up a dir
Sam Reed [Mon, 18 Jul 2011 16:09:50 +0000 (16:09 +0000)]
Remove call to User::getImplicitGroups() from ApiQueryAllUsers
Per the below, as User::getGroupsWithPermission() will return */autoconfirmed, etc if applicable
> var_dump( User::getGroupsWithPermission( 'createtalk' ) );
array(2) {
[0]=>
string(1) "*"
[1]=>
string(4) "user"
}
> var_dump( User::getGroupsWithPermission( 'autoconfirmed' ) );
array(5) {
[0]=>
string(13) "autoconfirmed"
[1]=>
string(3) "bot"
[2]=>
string(5) "sysop"
[3]=>
string(8) "reviewer"
[4]=>
string(9) "confirmed"
}
Alexandre Emsenhuber [Mon, 18 Jul 2011 15:41:09 +0000 (15:41 +0000)]
* Use local context instead of global variables
* Call Linker methods statically
* Use Linker::linkKnown() instead of Linker::link() where possible
Sam Reed [Mon, 18 Jul 2011 13:19:46 +0000 (13:19 +0000)]
* (bug 29935) Improve formatting of examples in ApiParamInfo
Old example string with newlines left for the moment, pending discussion on bug...
Sam Reed [Mon, 18 Jul 2011 13:14:05 +0000 (13:14 +0000)]
Kill unused globals
Remove unreachable return;
Sam Reed [Mon, 18 Jul 2011 13:10:29 +0000 (13:10 +0000)]
-rakkaus/#mediawiki-i18n- (1 lines skipped) [18-Jul-2011 12:54:37] PHP Fatal error: Call to a member function addHTML() on a non-object in /www/w/includes/specials/SpecialWatchlist.php on line 65
Swap $out for $output
Aaron Schulz [Mon, 18 Jul 2011 03:30:03 +0000 (03:30 +0000)]
Disallow given options twice (instead of letting the newest one take precedence). This property may be useful for a Het Deploy wrapper.
Robin Pepermans [Sun, 17 Jul 2011 23:18:06 +0000 (23:18 +0000)]
Fix r92418: 'fr', of course
Robin Pepermans [Sun, 17 Jul 2011 23:16:56 +0000 (23:16 +0000)]
Add fallback 'frc' -> 'fr'. Main translator agreed ( translatewiki.net/wiki/Thread:User_talk:Ebe123/Fallback_for_'frc' ).
Raimond Spekking [Sun, 17 Jul 2011 19:50:15 +0000 (19:50 +0000)]
Localisation updates for core and extension messages from translatewiki.net (2011-07-17 19:25:00 UTC)
Sam Reed [Sun, 17 Jul 2011 17:23:51 +0000 (17:23 +0000)]
Add a couple more useful URL's to the API help banner
Add help url for ApiQueryDeletedrevs
Sam Reed [Sun, 17 Jul 2011 17:09:51 +0000 (17:09 +0000)]
Followup r92396
Using action=paraminfo to give help urls (and examples for that matter!!) look awful as a string with an encoded \n in the middle of it
Sam Reed [Sun, 17 Jul 2011 17:02:06 +0000 (17:02 +0000)]
* (bug 28817) Add reference help page link to API Modules
Last followup of r92396
Should be all modules with documentation pages in core now documented...
Sam Reed [Sun, 17 Jul 2011 16:51:11 +0000 (16:51 +0000)]
Followup r92396
More modules documented, pretty much only action=query&list= to be done (ie links added where documentation pages exist already)
Sam Reed [Sun, 17 Jul 2011 16:38:24 +0000 (16:38 +0000)]
Followup r92396, add help urls for most of the core (non query) modules
Sam Reed [Sun, 17 Jul 2011 16:23:29 +0000 (16:23 +0000)]
Followup r92396 rename method, fix boolean comparison that was supposed to be inverted when de-indenting
Sam Reed [Sun, 17 Jul 2011 16:18:09 +0000 (16:18 +0000)]
* (bug 28817) Add reference help page link to API Modules
Start of this bug, fleshed out base code implemented, plus a few key modules (will finish rest up soon)
Tweaked/improved/updated some documentation as I went through also
Sam Reed [Sun, 17 Jul 2011 15:48:51 +0000 (15:48 +0000)]
Flesh out some TODO documentation from onwiki pages
Alexandre Emsenhuber [Sun, 17 Jul 2011 09:33:34 +0000 (09:33 +0000)]
Fix for r92388: that was the wrong method
Alexandre Emsenhuber [Sun, 17 Jul 2011 09:25:50 +0000 (09:25 +0000)]
* Changed Special:RecentChanges and Special:RecentChangesLinked to use the local context instead of global variables
* Added context to ChangesList
* Added new factory for ChangesList and subclasses in ChangesList::newFromContext() and modified ChangesList::newFromUser() to call it with the main context since anyway User::getSkin() return the Skin from the main context, so this won't change anything but the User::getOption() call
* Updates Special:RecentChanges and Special:Watchlist to use that new function
* Call Linker methods statically
* Use Linker::linkKnown() instead of Linker::link() where possible
* In Special:Watchlist: Use wfMessage() instead of OutputPage::addWikiMsgArray() with the third parameter
Alexandre Emsenhuber [Sun, 17 Jul 2011 07:47:13 +0000 (07:47 +0000)]
* Expanded documentation, added GPL header and changed the @author tag to use my real name
* Made RequestContext implement IContextSource
* Added ContextSource::msg()
* Made ContextSource fall back to RequestContext::getMain() when there's no context set
Raimond Spekking [Sat, 16 Jul 2011 20:06:00 +0000 (20:06 +0000)]
Localisation updates for core and extension messages from translatewiki.net (2011-07-16 19:52:00 UTC)
Ping r92057: Full export of core and ext-installer
Alexandre Emsenhuber [Sat, 16 Jul 2011 19:31:18 +0000 (19:31 +0000)]
* Use standard method to check user permissions
* Directly throw an ReadOnlyError instead of calling OutputPage::readOnlyPage()
* In Special:Block: don't let user think the error is temporary if he doesn't have right and the database is locked, instead check permissions first and then the database lock
Alexandre Emsenhuber [Sat, 16 Jul 2011 19:19:01 +0000 (19:19 +0000)]
* Use wfMessage() instead of OutputPage::addWikiMsgArray() with the third parameter
* In EditPage.php: call Linker methods statically
Bryan Tong Minh [Sat, 16 Jul 2011 16:09:00 +0000 (16:09 +0000)]
First steps for bug 14801: add backend support for per-namespace permissions to core. This extends $wgGroupPermissions syntax from $wgGroupPermissions[$group][$right] = bool to $wgGroupPermissions[$group][$right] = array( NS_X => bool ). This is safely backwards compatible; the booleans are still fully supported, and any unset namespace will default to false.
* User::getRights(), User::isAllowed() and User::getGroupPermissions now optionally accept a namespace parameter. If not set, it will check whether the user has the right for all namespaces.
* Anything that uses Title::getUserPermissionsErrorsInternal() automatically supports per-namespace permissions. This includes Title::getUserPermissionsErrors and Title::(quick)UserCan.
* Fix tests that set User::mRights
The next step would be to change all User::isAllowed() to Title::quickUserCan or pass the namespace to User::isAllowed().
Alexandre Emsenhuber [Sat, 16 Jul 2011 13:36:37 +0000 (13:36 +0000)]
* Use local context instead of global variables
* Call Linker methods statically
* Changed some messages to replace parameters before parsing where possible
* Changed usage of OutputPage::addWikiMsgArray() with third parameter to wfMessage()
Niklas Laxström [Sat, 16 Jul 2011 11:40:28 +0000 (11:40 +0000)]
Array indexes start from zero
Robin Pepermans [Sat, 16 Jul 2011 00:14:33 +0000 (00:14 +0000)]
Remove 'dk' from dummy language codes, it was removed in r71693.
Robin Pepermans [Fri, 15 Jul 2011 23:28:30 +0000 (23:28 +0000)]
Split MessagesKs into ks-arab and ks-deva, as Kashmiri is written in two scripts. The MessagesKs file contained rtl = true, which is only for the Arab script, and the digit transform table which was for the Devanagari script.
Added one lonely message from kswiki.
Also specified comment of Quechua to Southern Quechua, as it is the variety used in MessagesQu and on quwiki.
Sam Reed [Fri, 15 Jul 2011 23:18:38 +0000 (23:18 +0000)]
sync up RELEASE-NOTES
Krinkle [Fri, 15 Jul 2011 22:57:57 +0000 (22:57 +0000)]
html:key should be self-closing in jquery.localize unit tests.
More IE6, 7 and 8 fixes for jquery.localize unit tests.
html:key should be self-closing. This was in most tests, but accidentally forgotten in a few. Other browsers are looser on this, but IE is very strict about it.
Krinkle [Fri, 15 Jul 2011 22:54:28 +0000 (22:54 +0000)]
Removing deprecated <msg /> support in jquery.localize. Maintaing it is a PITA and it doesn't work properly in IE6, 7 and 8.
<html:msg /> has been the new format for a while.
Krinkle [Fri, 15 Jul 2011 22:43:32 +0000 (22:43 +0000)]
Increasing timeout duration. Some TestSwarm participants appear to have slower virtual machines and/or may have network slowness. 1.5 second was a bit too short anyway. This will reduce false positives.
Alexandre Emsenhuber [Fri, 15 Jul 2011 20:56:46 +0000 (20:56 +0000)]
* Use local context instead of global variables
* Call Linker methods satically
* Use wfMessage() instead of OutputPage::addWikiMsgArray() with a third parameter
Aaron Schulz [Fri, 15 Jul 2011 20:47:37 +0000 (20:47 +0000)]
Removed unused function
Leo Koppelkamm [Fri, 15 Jul 2011 20:24:00 +0000 (20:24 +0000)]
r92288 : Missed second arg to inArray
Krinkle [Fri, 15 Jul 2011 19:25:16 +0000 (19:25 +0000)]
ajaxCategories fixes:
* Partial revert of r92264. mw.ajaxCategories has nothing to do with mediawiki.util.init, moved into separate initiation module, only loaded when ajax categories is enabled.
* Removing instantiation from the script. mw.ajaxCategories is now a public accessible constructor
* Fix Uncaught ReferenceError: wgUserGroups is not defined
($wgLegacyJavaScriptGlobals = false;)
* Renamimng stripIllegals() to clean(), adding '#' to the regex as those are not allowed either.
* Combining var statements by separating them with comma's ( var foo, bar, baz; ) instead of "var foo; var bar; var baz;"svn up
* Using dot.notation for objects instead of array-like['string'] keys
* Whitespace conventions
* Using inArray utility instead of indexOf (cross-browser support, mostly IE6)
** $.inArray uses Array.prototype.indexOf if available, otherwise fallback to a loop. mw.util.inArray is a wrapper around $.inArray to return a boolean value (since inArray/indexOf may return 0)
* Don't use $( '#bodyContent' ) (skin specific) but mw.util.$content
* Using mw.Title
* Re-using helper functions from the outer-closure instead of re-declaring them privately for every instance again (performance!)
Follows-up: r92112, r92151, r92264