lhc/web/wiklou.git
7 years agoMerge "Replaced Linker::link() usage with LinkRenderer in some special pages"
jenkins-bot [Sun, 4 Dec 2016 06:19:39 +0000 (06:19 +0000)]
Merge "Replaced Linker::link() usage with LinkRenderer in some special pages"

7 years agoReplaced Linker::link() usage with LinkRenderer in some special pages
Subin Siby [Sat, 3 Dec 2016 08:01:49 +0000 (13:31 +0530)]
Replaced Linker::link() usage with LinkRenderer in some special pages

Bug: T149346
Change-Id: I73c2b7402012a49e4419b6214f1d03f2e819220b

7 years agoMerge "Add $magicWords translation for Bengali (bn)"
jenkins-bot [Sun, 4 Dec 2016 01:27:18 +0000 (01:27 +0000)]
Merge "Add $magicWords translation for Bengali (bn)"

7 years agoMerge "Clarify in emailuserfooter that by responding one reveals their email address"
jenkins-bot [Sat, 3 Dec 2016 22:56:05 +0000 (22:56 +0000)]
Merge "Clarify in emailuserfooter that by responding one reveals their email address"

7 years agoClarify in emailuserfooter that by responding one reveals their email address
Huji Lee [Fri, 2 Dec 2016 21:25:23 +0000 (16:25 -0500)]
Clarify in emailuserfooter that by responding one reveals their email address

Bug: T152242
Change-Id: I686f7bb8dd1d225620266ac9cbecadcf06bd7705

7 years agoAdd $magicWords translation for Bengali (bn)
Pmlineditor [Mon, 21 Nov 2016 07:35:41 +0000 (13:05 +0530)]
Add $magicWords translation for Bengali (bn)

Bug: T151134
Change-Id: I81ce473668e3712ea575dc38f5eb76abb45498ac

7 years agoArticleViewCustom, EditPageGetDiffText and ShowRawCssJs were removed
Reedy [Thu, 1 Dec 2016 13:12:55 +0000 (13:12 +0000)]
ArticleViewCustom, EditPageGetDiffText and ShowRawCssJs were removed

Bug: T145728
Change-Id: Iddf29005abbaceaa1e3cc2c79e4becfb46294414

7 years agoArticle::getAutosummary() and WikiPage::getAutosummary() were removed
Reedy [Thu, 1 Dec 2016 12:45:36 +0000 (12:45 +0000)]
Article::getAutosummary() and WikiPage::getAutosummary() were removed

Bug: T145728
Change-Id: I233571658b902c93a148a992ea99eb159551e732

7 years agoRemove ContentHandler functions with no usages at all
Reedy [Thu, 1 Dec 2016 12:40:05 +0000 (12:40 +0000)]
Remove ContentHandler functions with no usages at all

Bug: T145728
Change-Id: Ia0d7a5eb7e79b586c3b30688c80bb8b4b723fff6

7 years agoMerge "Localisation updates from https://translatewiki.net."
L10n-bot [Fri, 2 Dec 2016 20:56:05 +0000 (20:56 +0000)]
Merge "Localisation updates from https://translatewiki.net."

7 years agoMerge "Avoid use of DatabaseBase in /includes"
jenkins-bot [Fri, 2 Dec 2016 20:54:26 +0000 (20:54 +0000)]
Merge "Avoid use of DatabaseBase in /includes"

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Fri, 2 Dec 2016 20:53:57 +0000 (21:53 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Ifb9f00278f2dc7589efa501dd4ee8fba3087ea60

7 years agoAvoid use of DatabaseBase in /includes
Aaron Schulz [Fri, 2 Dec 2016 19:18:27 +0000 (11:18 -0800)]
Avoid use of DatabaseBase in /includes

Change-Id: Ia3b7f9cb7d40f4ec9f19c924904e8a096880ec6a

7 years agoMerge "Ignore query cache in LoadMonitorMySQL"
jenkins-bot [Fri, 2 Dec 2016 19:59:21 +0000 (19:59 +0000)]
Merge "Ignore query cache in LoadMonitorMySQL"

7 years agoMerge "Set token properly when creating in User::newSystemUser()"
jenkins-bot [Fri, 2 Dec 2016 19:47:47 +0000 (19:47 +0000)]
Merge "Set token properly when creating in User::newSystemUser()"

7 years agoMove link-underline user preference rule to body class
Ed Sanders [Wed, 7 Sep 2016 22:51:48 +0000 (15:51 -0700)]
Move link-underline user preference rule to body class

ResourceLoaderUserCSSPrefsModule is now empty and can be removed.

Change-Id: I806e117131765b859e990c14735bb9494db9a37e

7 years agoReplace Linker::link() usage with LinkRenderer
rlot [Fri, 2 Dec 2016 15:43:12 +0000 (16:43 +0100)]
Replace Linker::link() usage with LinkRenderer

Replaced deprecated Linker:link() with LinkRenderer

Bug: T149346
Change-Id: Iab158d49b186835a14c357c91a1c5c4f78986238

7 years agoSet token properly when creating in User::newSystemUser()
Brad Jorsch [Sat, 19 Nov 2016 00:54:58 +0000 (19:54 -0500)]
Set token properly when creating in User::newSystemUser()

Otherwise callers that don't use 'steal' is going to break because it'll
think it needs to steal the user.

If such a user exists on a wiki, it can be fixed by setting the token to
the invalid token. The easiest way is probably to just call
User::newSystemUser( $name, [ 'steal' => true ] ) with eval.php.

Note there's no way for anyone to use these users unless they steal the
token from the DB, since they still don't have a password, email, or any
other method of authentication or account recovery set up.

Change-Id: I9efd2d2f5fffb4e4411a894f9514cdf2c66663a9

7 years agoMerge "mediawiki.notification: Improve scroll performance"
jenkins-bot [Fri, 2 Dec 2016 13:00:22 +0000 (13:00 +0000)]
Merge "mediawiki.notification: Improve scroll performance"

7 years agoslave -> replica in SessionConsistentConnectionManager
Amir Sarabadani [Fri, 2 Dec 2016 10:42:40 +0000 (14:12 +0330)]
slave -> replica in SessionConsistentConnectionManager

Change-Id: Ie59c90fa5f4b18d4321f7924a4facd7ea9049f4a

7 years agoIgnore query cache in LoadMonitorMySQL
Aaron Schulz [Fri, 2 Dec 2016 09:09:44 +0000 (01:09 -0800)]
Ignore query cache in LoadMonitorMySQL

Change-Id: I0b3c27ca6d2f8805297d91557cc40bd4bbc1a677

7 years agoRemoved Xml::escapeJsString()
Reedy [Wed, 30 Nov 2016 00:38:00 +0000 (00:38 +0000)]
Removed Xml::escapeJsString()

Change-Id: Iead8385a72a79632a90594a8828080a6d572e039

7 years agoUser::edits() was removed
Reedy [Wed, 30 Nov 2016 00:41:47 +0000 (00:41 +0000)]
User::edits() was removed

Change-Id: I3ebe2cceb94a0d61a9e0ab5bb0599e8a03146046

7 years agoMerge "SpecialActiveUsers: escape group names"
jenkins-bot [Fri, 2 Dec 2016 06:09:37 +0000 (06:09 +0000)]
Merge "SpecialActiveUsers: escape group names"

7 years agoMerge "Remove Atomic methods from ConnectionManagers"
jenkins-bot [Fri, 2 Dec 2016 05:07:53 +0000 (05:07 +0000)]
Merge "Remove Atomic methods from ConnectionManagers"

7 years agoRemove Atomic methods from ConnectionManagers
addshore [Thu, 1 Dec 2016 00:13:16 +0000 (00:13 +0000)]
Remove Atomic methods from ConnectionManagers

Change-Id: I697f63f45975b13af52bc22fced6e4d07e35115f
Depends-On: I4341a1b4ff6a67e4c1770faae38e9b126f1bf0bf

7 years agoresourceloader: Add test coverage for ResourceLoaderContext::msg()
Timo Tijhof [Fri, 2 Dec 2016 04:47:05 +0000 (20:47 -0800)]
resourceloader: Add test coverage for ResourceLoaderContext::msg()

Brings ResourceLoaderContext coverage to 100%.

Change-Id: I3ccc6aa87c89f69158b8d8684be565403afb4036

7 years agoDon't hard fail when we couldn't find an entry point for an extension
Chad Horohoe [Mon, 28 Nov 2016 22:53:40 +0000 (14:53 -0800)]
Don't hard fail when we couldn't find an entry point for an extension

It doesn't make a ton of sense, it's just pointing out that we have
a weird extension for which we cannot detect a standard entry point
for. These (unfortunately) exist, but they're easily worked around
using --list-file

Removing the hard failure allows you to use the two options in
tandem... --extension-dir for the initial pass and then --list-file
for the weirdo outstanding ones

Change-Id: I3d9cf1d614dacaa91fb2092019ccf1d14d61ccab

7 years agoMerge "SpecialFewestrevisions: Allow pages with only 1 revision to be shown"
jenkins-bot [Fri, 2 Dec 2016 00:10:26 +0000 (00:10 +0000)]
Merge "SpecialFewestrevisions: Allow pages with only 1 revision to be shown"

7 years agoRemove $purpose parameter from password validity check
Brad Jorsch [Thu, 1 Dec 2016 23:30:23 +0000 (18:30 -0500)]
Remove $purpose parameter from password validity check

This was added in I56b6600 in an attempt to work around a bug in
CentralAuth, but the bug has since been fixed in a better way. No hook
functions in Gerrit use the parameter (or ever have, as far as I can
tell), and anything that was passing a value other than the default
'login' has since been removed. So let's just get rid of it instead of
keeping it around doing nothing.

Change-Id: Ie604e03d268706221161ac93eb866f477e466fb4

7 years agoinstaller: Restore link text in default main page content
Kunal Mehta [Thu, 1 Dec 2016 22:55:49 +0000 (14:55 -0800)]
installer: Restore link text in default main page content

Accidentally got dropped in b85a17b7543.

Change-Id: I30b7a8d42877a54749792e97e49670087a85ca2b

7 years agoMerge "ApiSandbox: Better handling of parsed messages"
jenkins-bot [Thu, 1 Dec 2016 22:17:02 +0000 (22:17 +0000)]
Merge "ApiSandbox: Better handling of parsed messages"

7 years agoIDatabase::delete() table name parameter should be a string
Reedy [Thu, 1 Dec 2016 21:32:09 +0000 (21:32 +0000)]
IDatabase::delete() table name parameter should be a string

Change-Id: I7ba2cdb6cdddf04819ff80e27814f704f41d15f1

7 years agoMerge "Replace Linker::link() usage with LinkRenderer"
jenkins-bot [Thu, 1 Dec 2016 20:24:51 +0000 (20:24 +0000)]
Merge "Replace Linker::link() usage with LinkRenderer"

7 years agoMerge "http: Support HTTP Basic Authentication"
jenkins-bot [Thu, 1 Dec 2016 20:09:02 +0000 (20:09 +0000)]
Merge "http: Support HTTP Basic Authentication"

7 years agoReplace Linker::link() usage with LinkRenderer
Haikal Izzuddin [Wed, 30 Nov 2016 01:07:37 +0000 (09:07 +0800)]
Replace Linker::link() usage with LinkRenderer

Bug: T149346
Change-Id: Ie384566617f18ad6c3bf836b39702365d59f714d

7 years agoMerge "Replace Linker::link() with LinkRenderer in some special pages"
jenkins-bot [Thu, 1 Dec 2016 19:56:18 +0000 (19:56 +0000)]
Merge "Replace Linker::link() with LinkRenderer in some special pages"

7 years agohttp: Support HTTP Basic Authentication
Chrisludt [Tue, 8 Nov 2016 13:22:50 +0000 (13:22 +0000)]
http: Support HTTP Basic Authentication

Adds two new options (username and password) to the
MWHttpRequest (and HTTP helper class) to enable
support for HTTP Basic Authentication on outgoing HTTP
connections.

Change-Id: If83f025bbe63769ba7bb4a824c5f12d5f1ec640a

7 years agoMerge "Replace Linker::link() with LinkRenderer in includes directory"
jenkins-bot [Thu, 1 Dec 2016 19:45:09 +0000 (19:45 +0000)]
Merge "Replace Linker::link() with LinkRenderer in includes directory"

7 years agoMerge "mediawiki.storage: Provide a wrapper for sessionStorage too"
jenkins-bot [Thu, 1 Dec 2016 17:13:25 +0000 (17:13 +0000)]
Merge "mediawiki.storage: Provide a wrapper for sessionStorage too"

7 years agoMerge "Fix typo in $fallback so Russian fallback is applied"
jenkins-bot [Thu, 1 Dec 2016 13:29:39 +0000 (13:29 +0000)]
Merge "Fix typo in $fallback so Russian fallback is applied"

7 years agoFix typo in $fallback so Russian fallback is applied
Siebrand Mazeland [Thu, 1 Dec 2016 13:00:53 +0000 (14:00 +0100)]
Fix typo in $fallback so Russian fallback is applied

Change-Id: I25ab7b58dedff895b60737d45b6fcf48f9484001

7 years agoMerge "Align search result CSS with Wikimedia UI color palette"
jenkins-bot [Thu, 1 Dec 2016 10:49:35 +0000 (10:49 +0000)]
Merge "Align search result CSS with Wikimedia UI color palette"

7 years agoMerge "Rank aliases in search in order they appear in the messages file."
jenkins-bot [Thu, 1 Dec 2016 09:54:21 +0000 (09:54 +0000)]
Merge "Rank aliases in search in order they appear in the messages file."

7 years agoReplace Linker::link() with LinkRenderer in some special pages
Yuriy Shnitkovskiy [Wed, 30 Nov 2016 22:56:33 +0000 (00:56 +0200)]
Replace Linker::link() with LinkRenderer in some special pages

* SpecialEditTags
* SpecialEmailuser
* SpecialFewestrevisions
* SpecialImport
* SpecialListgrouprights
* SpecialMediaStatistics
* SpecialMergeHistory
* SpecialMIMEsearch
* SpecialMostcategories
* SpecialMostinerwikis
* SpecialMostlinked

Bug: T149346
Change-Id: Idee566dbff87f2e8bf909ba8371d551aaf0dd08b

7 years agoReplace Linker::link() with LinkRenderer in includes directory
Yuriy Shnitkovskiy [Wed, 30 Nov 2016 21:28:55 +0000 (23:28 +0200)]
Replace Linker::link() with LinkRenderer in includes directory

* CategoryViewer
* OutputPage
* Preferences

Bug: T149346
Change-Id: I9f9bcd9b461884817e8ceefbc6757c436221e331

7 years agomediawiki.storage: Provide a wrapper for sessionStorage too
Ori Livneh [Mon, 30 Nov 2015 20:41:43 +0000 (12:41 -0800)]
mediawiki.storage: Provide a wrapper for sessionStorage too

T119146 provides a use-case for using sessionStorage. So far mw.storage
was localStorage-specific. With a small modification, we can allow the
Storage object to passed to the constructor, which allows us to create a
wrapper around sessionStorage (mw.storage.session) with minimal code duplication.

Bug: T121646
Change-Id: I73bc82d9fa2359148fe1e50b6535bfa0dbe8bd3e

7 years agoMerge "Clean up http classes a bit"
jenkins-bot [Thu, 1 Dec 2016 03:32:47 +0000 (03:32 +0000)]
Merge "Clean up http classes a bit"

7 years agoClean up http classes a bit
Gergő Tisza [Wed, 26 Oct 2016 04:08:14 +0000 (21:08 -0700)]
Clean up http classes a bit

* added integration tests. We probably don't want automated tests
  to make external requests but these make manual testing more
  convenient. Documented some oddities discovered by testing.
* made ::$status, ::proxySetup() and ::getHeaderList()
  protected; they were not referenced in any gerrit-hosted extension
  and they provide no useful functionality to external callers.
  Similarly, marked ::read() and ::errorHandler() as internal
  (these are used as callbacks so can't be protected)
* removed inheritance abuse in ::execute()
* documented ::execute() as returning a StatusValue (but
  keep returning a Status for now)
* changed setCookie argument defaults to ones that make sense
* replaced MWException
* moved unit tests to the correct location
* fixed some code style issues

Change-Id: I5852fc75badc5d475ae30ec2c9376bde7024bd95

7 years agoMerge "SpecialBrokenRedirects: fix up LinkRenderer conversion"
jenkins-bot [Thu, 1 Dec 2016 01:48:33 +0000 (01:48 +0000)]
Merge "SpecialBrokenRedirects: fix up LinkRenderer conversion"

7 years agoSpecialBrokenRedirects: fix up LinkRenderer conversion
MtDu [Wed, 30 Nov 2016 22:51:41 +0000 (16:51 -0600)]
SpecialBrokenRedirects: fix up LinkRenderer conversion

$options is no longer supported, use makeBrokenLink() instead.

Follows-up d8c56ec84f.

Change-Id: If2025232a2e09ab99b1bdc6d58a77f347f3dbf5e

7 years agoMerge "ExtensionRegistryTest: Illustrate priority in array_replace_recursive test...
jenkins-bot [Thu, 1 Dec 2016 00:41:10 +0000 (00:41 +0000)]
Merge "ExtensionRegistryTest: Illustrate priority in array_replace_recursive test case"

7 years agoExtensionRegistryTest: Illustrate priority in array_replace_recursive test case
Roan Kattouw [Wed, 30 Nov 2016 23:54:15 +0000 (18:54 -0500)]
ExtensionRegistryTest: Illustrate priority in array_replace_recursive test case

When two keys have conflicting values, the value from extension.json wins
when using this merge strategy.

Change-Id: I0222682f3b3fb08f80afc7dda677da7bbfe8e5d1

7 years agoFix SessionConsistentConnectionManagerTest class and file name
addshore [Thu, 1 Dec 2016 00:15:38 +0000 (00:15 +0000)]
Fix SessionConsistentConnectionManagerTest class and file name

Change-Id: If60f081946b8f3bb564f2bb17fd1261af0cb7e3a

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Wed, 30 Nov 2016 21:57:58 +0000 (22:57 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I028c1cb92a6b14cc4ca72f6cff0b75f74bc68058

7 years agoRevert "Localisation updates from https://translatewiki.net."
Raimond Spekking [Wed, 30 Nov 2016 20:57:45 +0000 (20:57 +0000)]
Revert "Localisation updates from https://translatewiki.net."

Local twn repo seem outdated

This reverts commit 683e05d4413a9727ec882b4b15d04edcc562f93f.

Change-Id: I3e38317ef0ef2a7e9080ee7a50c2101a921d632c

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Wed, 30 Nov 2016 20:53:44 +0000 (21:53 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I83a9c227bab5b29162367eed71ccabf513ac5423

7 years agoAlign search result CSS with Wikimedia UI color palette
Amir Sarabadani [Wed, 30 Nov 2016 20:30:41 +0000 (00:00 +0330)]
Align search result CSS with Wikimedia UI color palette

Bug: T152025
Change-Id: Idc58deca48327d82372f5136a2fb07146ab1f371

7 years agoMerge "DatabaseUpdater: Stop inserting junk into 'updatelog' every time the updater...
jenkins-bot [Wed, 30 Nov 2016 20:26:49 +0000 (20:26 +0000)]
Merge "DatabaseUpdater: Stop inserting junk into 'updatelog' every time the updater runs"

7 years agoDatabaseUpdater: Stop inserting junk into 'updatelog' every time the updater runs
Bartosz Dziewoński [Wed, 30 Nov 2016 19:49:31 +0000 (20:49 +0100)]
DatabaseUpdater: Stop inserting junk into 'updatelog' every time the updater runs

Nothing ever looks at these rows, and if you have update.php in a Cron
job or a Git hook or something, they can accumulate in huge numbers.

Also remove a test which verified that the rows get inserted.

If you reached this place while trying to find out what the weird
"updatelist-1.28.0-14628929450" rows in your database are, rest
assured they are useless. If they're causing disk space problems,
you can delete them:

  DELETE FROM updatelog WHERE ul_key LIKE 'updatelist-%';

Change-Id: If94f243810e82ea3724cbd47b301bb96ba9a49d9

7 years agoMerge "Almost invisible change on UI colors to align with Wikimedia color palette"
jenkins-bot [Wed, 30 Nov 2016 19:57:49 +0000 (19:57 +0000)]
Merge "Almost invisible change on UI colors to align with Wikimedia color palette"

7 years agoAlmost invisible change on UI colors to align with Wikimedia color palette
Amir Sarabadani [Wed, 30 Nov 2016 19:00:24 +0000 (22:30 +0330)]
Almost invisible change on UI colors to align with Wikimedia color palette

 - wikitable
 - thumbnails
 - gallery
 - TOC
 - catlinks

Bug: T152025
Change-Id: I8ca0f94ad66a5d6cec649f65e87b145a9a9aba78

7 years agoMerge "CategoryPager: Allow categories with no members to be shown"
jenkins-bot [Wed, 30 Nov 2016 19:32:23 +0000 (19:32 +0000)]
Merge "CategoryPager: Allow categories with no members to be shown"

7 years agoMerge "ImageHistoryPseudoPager: Only display 10 revisions at once by default"
jenkins-bot [Wed, 30 Nov 2016 19:27:26 +0000 (19:27 +0000)]
Merge "ImageHistoryPseudoPager: Only display 10 revisions at once by default"

7 years agoMerge "Throw an exception if password hash would be truncated by DB"
jenkins-bot [Wed, 30 Nov 2016 19:10:47 +0000 (19:10 +0000)]
Merge "Throw an exception if password hash would be truncated by DB"

7 years agoMerge "mediawiki.language: fix convertNumber( ..., true )"
jenkins-bot [Wed, 30 Nov 2016 19:04:48 +0000 (19:04 +0000)]
Merge "mediawiki.language: fix convertNumber( ..., true )"

7 years agoMerge "Update OOjs UI to v0.18.1"
jenkins-bot [Wed, 30 Nov 2016 18:43:25 +0000 (18:43 +0000)]
Merge "Update OOjs UI to v0.18.1"

7 years agoMerge "Add DB ConnectionManagers"
jenkins-bot [Wed, 30 Nov 2016 18:43:21 +0000 (18:43 +0000)]
Merge "Add DB ConnectionManagers"

7 years agoMerge "SpecialUserrights: Make new fetchUser() parameter optional"
jenkins-bot [Wed, 30 Nov 2016 18:27:07 +0000 (18:27 +0000)]
Merge "SpecialUserrights: Make new fetchUser() parameter optional"

7 years agoSpecialUserrights: Make new fetchUser() parameter optional
Bartosz Dziewoński [Wed, 30 Nov 2016 18:04:45 +0000 (19:04 +0100)]
SpecialUserrights: Make new fetchUser() parameter optional

This in, unfortunately, a public API, apparently.
Follow-up to d87a4eaa19aad80e109307eb0088fd6a25dd5f51.

Bug: T151961
Change-Id: Ia0e583a5cbb9ed143bf5dff9b513b76ca2790d72

7 years agoMerge "Fix MediaTransformError message handling"
jenkins-bot [Wed, 30 Nov 2016 17:00:54 +0000 (17:00 +0000)]
Merge "Fix MediaTransformError message handling"

7 years agoCategoryPager: Allow categories with no members to be shown
Bartosz Dziewoński [Wed, 30 Nov 2016 16:41:17 +0000 (17:41 +0100)]
CategoryPager: Allow categories with no members to be shown

This affects the listing on Special:Categories.

Bug: T12915
Change-Id: I6265d20b8afd199832de6dd3b2e126a1c45d4b11

7 years agoMerge "Prevent login-only local password provider from removing passwords"
jenkins-bot [Wed, 30 Nov 2016 16:39:12 +0000 (16:39 +0000)]
Merge "Prevent login-only local password provider from removing passwords"

7 years agoFix MediaTransformError message handling
Brad Jorsch [Tue, 1 Nov 2016 19:08:38 +0000 (15:08 -0400)]
Fix MediaTransformError message handling

Give access to the raw Message instead of only to the HTML or text in
the RequestContext language.

Pass Message objects instead of strings from calling ->text() as the
parameters of Messages so if the outer Message's language is changed
things get parsed sensibly.

Change-Id: Ibd6c1217b6fed839c888b66e02900f8e21ed3e6b

7 years agoAdd Message::listParam()
Brad Jorsch [Wed, 2 Nov 2016 16:53:19 +0000 (12:53 -0400)]
Add Message::listParam()

This allows for passing a list of values that will be turned into a list
in the context of the language for which the Message is being processed.

For example, currently you'd have to do

 $msg = new Message( 'something', [ $language->commaList( $list ) ] );

which isn't going to give correct results if the message is later
changed to a different language with a different value for
'comma-separator'.

Now, you can do this instead

 $msg = new Message( 'something', [ Message::listParam( $list, 'comma' ) ] );

and it will be listified properly no matter what language is later used to
parse $msg.

Change-Id: I66868c61832260870449998fef14c842f17753ee

7 years agoMerge "Added warning for improper ending of a token"
jenkins-bot [Wed, 30 Nov 2016 14:43:04 +0000 (14:43 +0000)]
Merge "Added warning for improper ending of a token"

7 years agoMerge "Accept 'OK' status results from search engine"
jenkins-bot [Wed, 30 Nov 2016 13:59:36 +0000 (13:59 +0000)]
Merge "Accept 'OK' status results from search engine"

7 years agoSpecialActiveUsers: escape group names
Niklas Laxström [Wed, 30 Nov 2016 13:53:11 +0000 (14:53 +0100)]
SpecialActiveUsers: escape group names

Change-Id: I1a4d1501b8481d9f670916818fe7f75e983c2800

7 years agomediawiki.language: fix convertNumber( ..., true )
Niklas Laxström [Wed, 30 Nov 2016 08:35:20 +0000 (09:35 +0100)]
mediawiki.language: fix convertNumber( ..., true )

It was not handling separator unformatting.

In mediawiki.jqueryMsg.test.js fix broken test case:
* Hindi does not use comma as decimal separator!
* The number was not formatted as it would be by the
  formatting code. By definition back-conversion is
  only defined for input that we generate. For other
  input the output is undefined. There are other tests
  with same issue, but I did not touch them now.

Bug: T151198
Change-Id: Icc9bc09675151645055c7e7f706472a15cc81b0f

7 years agoAdd DB ConnectionManagers
addshore [Mon, 21 Nov 2016 13:26:07 +0000 (13:26 +0000)]
Add DB ConnectionManagers

This moves and refactors the ConsistentReadConnectionManager
from Wikibase into the core rdbms lib.
The refactoring also creates a generic ConnectionManager.

This relates to Iff20a22f9f2bc7ceefd6defc0ed9a494a6fe62c0
which introduced a DB factory / connection manager in
an extension revealing the need for this in multiple places.

Change-Id: I0c58e15aed5bed88323d18cb95e5008f8d3381c5

7 years agoMerge "Replace Linker::link() with LinkRenderer in some special pages"
jenkins-bot [Wed, 30 Nov 2016 10:04:09 +0000 (10:04 +0000)]
Merge "Replace Linker::link() with LinkRenderer in some special pages"

7 years agoReplace Linker::link() with LinkRenderer in some special pages
MtDu [Wed, 30 Nov 2016 00:05:22 +0000 (18:05 -0600)]
Replace Linker::link() with LinkRenderer in some special pages

* SpecialAllPages
* SpecialAncientpage
* SpecialBlock
* SpecialBrokenRedirects
* SpecialDoubleRedirects

Bug: T149346
Change-Id: Ib9997ec29b5c0079acb79dc2772196b38665145d

7 years agoMessageCache: some inline comments
Andrew Green [Mon, 17 Oct 2016 15:00:47 +0000 (10:00 -0500)]
MessageCache: some inline comments

Change-Id: I42427eef73d86c1a2e99dfa22b5dae159542e243

7 years agoAdded warning for improper ending of a token
georggi [Mon, 28 Nov 2016 20:22:56 +0000 (22:22 +0200)]
Added warning for improper ending of a token

Added warning if token ends with Token::SUFFIX by comparing result of substr to Token::SUFFIX.
Simplified Token class calls.

Bug: T122280
Change-Id: Id405dcc7b5e4d28995edf334aa6e183efdb749de

7 years agoqunit: Don't assume synchronous Deferred.resolve
Timo Tijhof [Wed, 23 Nov 2016 17:53:28 +0000 (09:53 -0800)]
qunit: Don't assume synchronous Deferred.resolve

* mw.loader.test: Most test did this correctly already by returning
  a Promise to QUnit.test, or by using assert.async().
  However two tests did not.

* mediawiki.jqueryMsg.test: Previously the async() handles were
  obtained within the task execution loop. Before jQuery 3.0,
  simple .then() operations when they are already resolved happen
  synchronously, so the current handle was resolved and the next
  handle obtained in the same go and QUnit never saw the state
  as having no unresolved async handles.

  With jQuery 3.0 the test fails because QUnit would end the test
  after the first iteration.

  Fix by simply obtaining all the async() handles when creating the
  list of tasks, instead of within the individual task execution.
  This way they're all reserved and they'll count down as we go.

* mediawiki.api.test: Consistently use 'respondImmediately' for
  the tests that were missing it, and return promise to QUnit.test()

  Also update hardcoded API urls that encoded space as '+', which may
  now be encoded as '%20'.

Bug: T124742
Change-Id: If7ee1c6025be70fecc0a93d4ac155da4db6571ab

7 years agoMerge "mediawiki.api: Fix getToken() incompat with jQuery 3.0"
jenkins-bot [Wed, 30 Nov 2016 02:03:14 +0000 (02:03 +0000)]
Merge "mediawiki.api: Fix getToken() incompat with jQuery 3.0"

7 years agoMerge "Remove $wgSessionsInMemcached"
jenkins-bot [Wed, 30 Nov 2016 00:55:17 +0000 (00:55 +0000)]
Merge "Remove $wgSessionsInMemcached"

7 years agoUpdate OOjs UI to v0.18.1
James D. Forrester [Wed, 30 Nov 2016 00:12:08 +0000 (16:12 -0800)]
Update OOjs UI to v0.18.1

Release notes:
 https://phabricator.wikimedia.org/diffusion/GOJU/browse/master/History.md;v0.18.1

Change-Id: I5fe3129c9ccf3fa20494b5934bca7487d8d36879

7 years agoRemove $wgSessionsInMemcached
Reedy [Wed, 30 Nov 2016 00:07:19 +0000 (00:07 +0000)]
Remove $wgSessionsInMemcached

Change-Id: Ia2b4d62ea504a3cb04f4c2bec49b16f155c8b0c9

7 years agoMerge "Make protect.php maintenance script not ignore --user and --reason parameters"
jenkins-bot [Wed, 30 Nov 2016 00:05:06 +0000 (00:05 +0000)]
Merge "Make protect.php maintenance script not ignore --user and --reason parameters"

7 years agoAccept 'OK' status results from search engine
Erik Bernhardson [Wed, 9 Nov 2016 00:41:11 +0000 (16:41 -0800)]
Accept 'OK' status results from search engine

Historically code that talks to the SearchEngine has been treating
anything other than a 'Good' result, such as results but with a warning
(perhaps the query timed out and only gave partial results) as a
complete failure. Adjust the handling to report results from an 'OK'
status response while attaching any warnings to the api response, or
in a notiable red box on Special:Search.

Bug: T134157
Change-Id: Ic5e0db727790f4fd189caa54ea5f01672d6a8ea4

7 years agoRank aliases in search in order they appear in the messages file.
Stanislav Malyshev [Tue, 29 Nov 2016 21:54:15 +0000 (13:54 -0800)]
Rank aliases in search in order they appear in the messages file.

This will ensure the local page name (which is the first alias) is prioritized.

Bug: T151660
Change-Id: I3cc266024f5e052d20ff55c4b2c6cbd2945e3dd3

7 years agoMerge "Use isDisabled() instead of isBlank() in getGrantName in User.php"
jenkins-bot [Tue, 29 Nov 2016 23:03:55 +0000 (23:03 +0000)]
Merge "Use isDisabled() instead of isBlank() in getGrantName in User.php"

7 years agoMerge "Allow API endpoint customization for mw.widgets.TitleWidget"
jenkins-bot [Tue, 29 Nov 2016 22:57:48 +0000 (22:57 +0000)]
Merge "Allow API endpoint customization for mw.widgets.TitleWidget"

7 years agoMerge "Rewrite logstash key conflict warning from I6677dbf6"
jenkins-bot [Tue, 29 Nov 2016 22:53:10 +0000 (22:53 +0000)]
Merge "Rewrite logstash key conflict warning from I6677dbf6"

7 years agoMerge "List grant codenames next to grants on Special:ListGrants"
jenkins-bot [Tue, 29 Nov 2016 22:49:21 +0000 (22:49 +0000)]
Merge "List grant codenames next to grants on Special:ListGrants"

7 years agoUse isDisabled() instead of isBlank() in getGrantName in User.php
Justin Du [Tue, 29 Nov 2016 22:36:21 +0000 (16:36 -0600)]
Use isDisabled() instead of isBlank() in getGrantName in User.php

Bug: T151956
Change-Id: Ic23c75b784c725f8f73eb1cf98d2bdb3763ab09d

7 years agoList grant codenames next to grants on Special:ListGrants
MtDu [Mon, 28 Nov 2016 23:46:44 +0000 (17:46 -0600)]
List grant codenames next to grants on Special:ListGrants

Bug: T145351
Change-Id: Ia07de6269fa6192071aaea5d750362685389001c

7 years agomediawiki.notification: Improve scroll performance
Timo Tijhof [Tue, 29 Nov 2016 21:48:15 +0000 (13:48 -0800)]
mediawiki.notification: Improve scroll performance

This fixes the problem with random scroll lag when on a page that had
1 or more notifications at some point. The scroll handler was fairly
expensive and kept being called on every scroll event.

The actual frame where a frame is detected does take more than 16ms to
paint but that's unavoidable. It only happens for 1 or 2 frames, which
is perfectly within the response guidelines for RAIL.

https://developers.google.com/web/fundamentals/performance/rail

(MacBook Pro, Latest Chrome, CPU throttle 5x)

1. Before
* Duration of no-change scroll event
  (not crossing offset.top in ither direction) ~5ms
* Duration of changed scroll event
  (crossing the offset.top and swapping classes) ~10ms
* Paint:
  - 16ms for no-change frames (50-60fps)
  - 40ms for frames that paint a change. (25-30fps)

2. After storing isFloating as boolean and not checking
   className if nothing changed.
* no-change scroll event: ~0.13ms
* changed scroll event: ~2ms
* Paint:
  - 15ms for no-change frame (60fps)
  - 33ms for no-change frame (30fps)

3. After changing $window.scrollTop() to window.pageYOffset.
* no-change scroll event: 15μs (0.015ms)
* changed scroll event: ~1ms
* Paint:
  - 11ms for no-change frame (60fps)
  - 20ms for no-change frame (48fps)

Change-Id: Ia48b00cd0834700ce79e72d4599c51ff8c6179b5

7 years agoMerge "Localisation updates from https://translatewiki.net."
L10n-bot [Tue, 29 Nov 2016 20:59:14 +0000 (20:59 +0000)]
Merge "Localisation updates from https://translatewiki.net."