lhc/web/wiklou.git
5 years agoFix grammar in UserPasswordPolicy documentation
Thalia [Wed, 20 Feb 2019 19:47:39 +0000 (19:47 +0000)]
Fix grammar in UserPasswordPolicy documentation

Change-Id: I423d5ce9f9a778ee21381ba433a52b8bd3e154fc

5 years agopagers: Fix and add missing @param documentation
Thiemo Kreuz [Tue, 19 Feb 2019 14:27:25 +0000 (15:27 +0100)]
pagers: Fix and add missing @param documentation

Sometimes the code expects a specific subclass as it calls a specific
method that only exists in this subclass. If this is not the case, all
the code needs to know is that it got some special page.

Some of these constructors should be changed to expect a IContextSource
instead of a special page. But this is for another patch. Here in this
patch I intentionally touch documentation only.

Change-Id: I33bae9641a8871f359edccacf88f09cfe8e83139

5 years agoMerge "resourceloader: Make $rl parameter mandatory for MessageBlobStore"
jenkins-bot [Tue, 19 Feb 2019 17:49:17 +0000 (17:49 +0000)]
Merge "resourceloader: Make $rl parameter mandatory for MessageBlobStore"

5 years agoresourceloader: Make $rl parameter mandatory for MessageBlobStore
Timo Tijhof [Sat, 16 Feb 2019 23:46:30 +0000 (23:46 +0000)]
resourceloader: Make $rl parameter mandatory for MessageBlobStore

Change-Id: I851b2417b7e495a1d0c7ee1aa8be2b2e970840bb

5 years agobuild: Add initial version of Fresnel config
Timo Tijhof [Tue, 5 Feb 2019 20:57:11 +0000 (20:57 +0000)]
build: Add initial version of Fresnel config

Copied from fresnel.git (removed there with I742c56122).

Bug: T133646
Change-Id: I23e7e9bc6343cf9e14dbfe275c1cdbb4cc5bd76d

5 years agoFollow-up 262fd58: Correctly apply the ORDER BY in ActiveUsersPager
mainframe98 [Tue, 19 Feb 2019 15:01:59 +0000 (16:01 +0100)]
Follow-up 262fd58: Correctly apply the ORDER BY in ActiveUsersPager

In 262fd58, an ORDER BY clause was added, but the direction it
is supposed to use was not loaded correctly from the $data array.
It is available under the key 'order', not 'dir'.

Bug: T216200
Change-Id: I5e675c98820813cd9107865e11e82ae57828a974

5 years agoMerge "Remove deprecated method insertArticleLink() from class ChangeList"
jenkins-bot [Tue, 19 Feb 2019 12:49:46 +0000 (12:49 +0000)]
Merge "Remove deprecated method insertArticleLink() from class ChangeList"

5 years agoMerge "Follow-up 77276ce: Clarify i18n message key/values and div class"
jenkins-bot [Tue, 19 Feb 2019 12:48:13 +0000 (12:48 +0000)]
Merge "Follow-up 77276ce: Clarify i18n message key/values and div class"

5 years agoRemove deprecated method insertArticleLink() from class ChangeList
Derick Alangi [Sun, 10 Feb 2019 23:49:13 +0000 (00:49 +0100)]
Remove deprecated method insertArticleLink() from class ChangeList

This method was deprecated in MediaWiki 1.27 and in MW 1.26, an alternative
method was introduced (getArticleLink). Per the code search tool here:
https://codesearch.wmflabs.org/search/?q=insertArticleLink%5C(&i=nope&files=&repos=,
only SimpleChanges and RecentActivityFeed extensions still use this method and
patches have been made to stop the use of these deprecated methods, see;
~ Ia80496c02ee5d0cb7bf9bdb1b336ea2699325d4c (RecentActivityFeed extension)
~ I5a9359f107da6a92b5f52e58879b540480ed2443 (SimpleChanges extension)

Once the above patches are merged, this patch can be reviewed and merged
as there will no longer be any usage of the deprecated method per code search
tool.

Change-Id: I166a7e5af7d8d3df60208583b6ce002bf65305a6

5 years agoMerge "Changed the name of the (gcr) language from "Kreyol Gwiyanè" to "Kriyòl Gwiyan...
jenkins-bot [Tue, 19 Feb 2019 11:21:52 +0000 (11:21 +0000)]
Merge "Changed the name of the (gcr) language from "Kreyol Gwiyanè" to "Kriyòl Gwiyannen""

5 years agoFollow-up 77276ce: Clarify i18n message key/values and div class
Derick Alangi [Tue, 19 Feb 2019 08:59:20 +0000 (09:59 +0100)]
Follow-up 77276ce: Clarify i18n message key/values and div class

Bug: T150324
Change-Id: I5bbaf2030e07f27d64bf18109f198ff4cc04a7ff

5 years agoMerge "specials: Fix fatal MWNamespace exception on Special:Contributions"
jenkins-bot [Tue, 19 Feb 2019 00:44:21 +0000 (00:44 +0000)]
Merge "specials: Fix fatal MWNamespace exception on Special:Contributions"

5 years agospecials: Fix fatal MWNamespace exception on Special:Contributions
Derick Alangi [Sun, 17 Feb 2019 11:38:12 +0000 (12:38 +0100)]
specials: Fix fatal MWNamespace exception on Special:Contributions

Namespaces with negative values (valid like -1 and -2 or invalid like
less than -2), should not be processed as they do not have associated
namespaces. Rather than throwing an exception, nicely tell the user
the namespace is a negative value and doesn't have an associated
namespace to it.

Also, don't show any results, just load the form again so user can do
another request but show reason for this behavior atop of form.

Bug: T150324
Change-Id: I525d305a4dabb040110894d3230eeb5e04ff8336

5 years agoMerge "Cache redirects from Special:Redirect"
jenkins-bot [Mon, 18 Feb 2019 21:41:52 +0000 (21:41 +0000)]
Merge "Cache redirects from Special:Redirect"

5 years agoMerge "MigrateActors: Don't delete log_search rows when migrating"
jenkins-bot [Mon, 18 Feb 2019 21:19:51 +0000 (21:19 +0000)]
Merge "MigrateActors: Don't delete log_search rows when migrating"

5 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Mon, 18 Feb 2019 21:04:55 +0000 (22:04 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Ibb9f46d77e8fc63163bd1f7792beb7a7bde12be7

5 years agoMerge "mediawiki.api: Prevent misusing #saveOptions"
jenkins-bot [Mon, 18 Feb 2019 19:53:40 +0000 (19:53 +0000)]
Merge "mediawiki.api: Prevent misusing #saveOptions"

5 years agoresourceloader: Require $context parameter for FileModule::readStyleFiles()
Timo Tijhof [Sat, 16 Feb 2019 23:30:46 +0000 (23:30 +0000)]
resourceloader: Require $context parameter for FileModule::readStyleFiles()

Deprecated since MW 1.27.

Also update ResourcesTest to use TestingAccessWrapper instead of long-form
object reflection, and also apply it to its call for this method given
its meant to be private.

Change-Id: I9cc1af93730f632e4f8bf3a16d514a51ee73cb03

5 years agoMerge "resourceloader: Instantiate main class via ServiceWiring"
jenkins-bot [Mon, 18 Feb 2019 18:44:44 +0000 (18:44 +0000)]
Merge "resourceloader: Instantiate main class via ServiceWiring"

5 years agoresourceloader: Instantiate main class via ServiceWiring
Timo Tijhof [Sat, 16 Feb 2019 23:16:09 +0000 (23:16 +0000)]
resourceloader: Instantiate main class via ServiceWiring

It also removes some code duplication which is nice.

This unlocks various future changes, including:

* Making the `$config` parameter mandatory for the ResourceLoader class
  constructor, which currently falls back to global state.
  This should be deprecated and removed.

* Making it possible to instantiate the ResourceLoader class
  without all the default MW modules being registered from
  global state. E.g. move MW module registration from main class
  constructor to ServiceWiring, and remove the 'EmptyResourceLoader'
  class hack from unit tests, and use regular 'new ResourceLoader'
  instead.

* Making ResourceLoader a standalone library (some day),
  e.g. allowing it to be instantiated from a basic PHP script,
  in a way that is still useful and perhaps able to serve
  (most) RL modules without MW itself.

Bug: T32956
Change-Id: I4939f296c705b268e9cf8de635e923a739410470

5 years agomediawiki.api: Prevent misusing #saveOptions
Bartosz Dziewoński [Fri, 1 Feb 2019 22:23:30 +0000 (14:23 -0800)]
mediawiki.api: Prevent misusing #saveOptions

Task T214963 is about how we misused #saveOptions in VisualEditor and
made MediaWiki sad. I'm not sure whether we should fix the issues
there or here, but it seems like the mistakes would be easy to make in
other software, so let's try here first and see what folks think about
it.

* Do not send action=options API requests for IP users
* Wait for the previous request to finish before sending another

Bug: T214963
Change-Id: I85cfc6b5829bcd96e6245431cd979c24630a8fd8

5 years agoMerge "mediawiki.Title: Avoid 'this' in static method"
jenkins-bot [Mon, 18 Feb 2019 17:35:57 +0000 (17:35 +0000)]
Merge "mediawiki.Title: Avoid 'this' in static method"

5 years agoMerge "objectcache: remove dangling WAN cache EventRelayer references"
jenkins-bot [Mon, 18 Feb 2019 17:07:20 +0000 (17:07 +0000)]
Merge "objectcache: remove dangling WAN cache EventRelayer references"

5 years agoMerge "Do not use raw html for Special:ProtectedPages drop-down messages"
jenkins-bot [Mon, 18 Feb 2019 11:39:30 +0000 (11:39 +0000)]
Merge "Do not use raw html for Special:ProtectedPages drop-down messages"

5 years agoDo not use raw html for Special:ProtectedPages drop-down messages
Brian Wolff [Sun, 17 Feb 2019 11:14:18 +0000 (11:14 +0000)]
Do not use raw html for Special:ProtectedPages drop-down messages

The following messages are affected: protectedpages-indef,
protectedpages-cascade, protectedpages-noredirect.

This appear to be accidental. AFAIK nobody is using these messages
in a raw html fashion.

This change is to make phan-taint-check happier.

Bug: T216348
Change-Id: I0e038c2e01e2252be288b86950208510741efc67

5 years agoMerge "import: Remove deprecated WikiRevision::$importer property"
jenkins-bot [Mon, 18 Feb 2019 07:48:00 +0000 (07:48 +0000)]
Merge "import: Remove deprecated WikiRevision::$importer property"

5 years agoFix 'expliciit' typo at resources/Resources.php
zoranzoki21 [Sun, 17 Feb 2019 22:45:10 +0000 (23:45 +0100)]
Fix 'expliciit' typo at resources/Resources.php

Bug: T201491
Change-Id: Ic6c60aad037df3599572f7248093d7dc1509819d

5 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sun, 17 Feb 2019 20:55:23 +0000 (21:55 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I2316460e88bc758daa875638518105524f97ea1d

5 years agoMerge "Escape messages ipb-sitewide and ipb-partial."
jenkins-bot [Sun, 17 Feb 2019 14:58:29 +0000 (14:58 +0000)]
Merge "Escape messages ipb-sitewide and ipb-partial."

5 years agoEscape messages ipb-sitewide and ipb-partial.
Brian Wolff [Sun, 17 Feb 2019 12:49:03 +0000 (12:49 +0000)]
Escape messages ipb-sitewide and ipb-partial.

Radio button htmlform treats options as being raw html

Change-Id: Ia25ed5b88e937414ea7993a1cf29fe44ed8e22d4

5 years agoCache redirects from Special:Redirect
Brian Wolff [Fri, 1 Feb 2019 01:54:08 +0000 (01:54 +0000)]
Cache redirects from Special:Redirect

People sometimes link these from high traffic places, so it is
important to cache in varnish.

File's with height can change so only cache that for 10 seconds.

Also change from 302 to 301.

Change-Id: I87a60c812cd1aa78a36359090c0cb8390be7183f

5 years agoAvoid rawParams() in Special:Emailuser
Brian Wolff [Wed, 26 Sep 2018 01:00:25 +0000 (01:00 +0000)]
Avoid rawParams() in Special:Emailuser

Bug: T216348
Change-Id: I6b543c508260f5889f1236dd43022a6a0fe963a9

5 years agoobjectcache: remove dangling WAN cache EventRelayer references
Aaron Schulz [Sun, 17 Feb 2019 03:44:36 +0000 (19:44 -0800)]
objectcache: remove dangling WAN cache EventRelayer references

* Remove 'channels' field references from config/setup
* Remove 'relayer'/'channels' field reference in unit tests
* Remove unused DEFAULT_PURGE_CHANNEL class constant
* Also remove long-since bogus 'pool' field references

Follow-up to 4753b0a4ed4b6b8abb

Change-Id: If6670ff4e1dccc8ae253a08b46d205601da10024

5 years agomediawiki.Title: Avoid 'this' in static method
Timo Tijhof [Sun, 17 Feb 2019 00:48:41 +0000 (00:48 +0000)]
mediawiki.Title: Avoid 'this' in static method

Follows-up 144103b0293.

Also remove use of private mw.config.values, and remove redundant
manual restoration.

Change-Id: I3570dbfa2d2f524ade6b467821e493e950f2a605

5 years agoresources: Document why mw.user has two seemingly unused deps
Fomafix [Fri, 7 Dec 2018 09:55:03 +0000 (10:55 +0100)]
resources: Document why mw.user has two seemingly unused deps

The code in the module 'mediawiki.user' does not depend on the modules
'user.options' and 'user.tokens' so the ResourceLoader dependency is
not necessary.

Change-Id: I22b9175f7623dbdf1c08826904b76dee5d56ea40

5 years agoMerge "widgets: Remove redundant equality check in SelectWithInputWidget"
jenkins-bot [Sun, 17 Feb 2019 00:35:34 +0000 (00:35 +0000)]
Merge "widgets: Remove redundant equality check in SelectWithInputWidget"

5 years agoMerge "objectcache: remove EventRelayer dependency from WANObjectCache"
jenkins-bot [Sat, 16 Feb 2019 19:49:22 +0000 (19:49 +0000)]
Merge "objectcache: remove EventRelayer dependency from WANObjectCache"

5 years agoMerge "Fix documentation for Revision::getComment and WikiPage::getComment"
jenkins-bot [Sat, 16 Feb 2019 10:59:48 +0000 (10:59 +0000)]
Merge "Fix documentation for Revision::getComment and WikiPage::getComment"

5 years agoobjectcache: remove EventRelayer dependency from WANObjectCache
Aaron Schulz [Sat, 16 Feb 2019 07:17:23 +0000 (23:17 -0800)]
objectcache: remove EventRelayer dependency from WANObjectCache

The use of that class for WAN cache by third parties is extremely unlikely
and the approach was abandoned at WMF in favor of mcrouter (dynomite was
also considered preferable).

Change-Id: I328eb74f21c23db80acc5178bc3c9cf9f823da13

5 years agoChangeTags: Deprecate ChangeTags::purgeTagUsageCache()
Roan Kattouw [Sat, 16 Feb 2019 01:00:49 +0000 (17:00 -0800)]
ChangeTags: Deprecate ChangeTags::purgeTagUsageCache()

The cache key that it purges is no longer used anywhere.

Change-Id: I2c255936451cde09579594cc4524c8fe38cf3e7c

5 years agoMerge "Improve documentation for different block types"
jenkins-bot [Fri, 15 Feb 2019 22:23:54 +0000 (22:23 +0000)]
Merge "Improve documentation for different block types"

5 years agoMerge "Remove double check of $oldRevision"
jenkins-bot [Fri, 15 Feb 2019 20:15:47 +0000 (20:15 +0000)]
Merge "Remove double check of $oldRevision"

5 years agoMigrateActors: Don't delete log_search rows when migrating
Brad Jorsch [Thu, 7 Feb 2019 15:27:06 +0000 (10:27 -0500)]
MigrateActors: Don't delete log_search rows when migrating

When I4764c1c78 switched from being run during read-both/write-new to
write-both/read-old, we should have also removed the code that
blanked/deleted the old rows. That was done for the main migration, but
was overlooked for log_search.

Bug: T215464
Change-Id: Icbba54dbd57fe0fa07ea0f6dcdde30089f067ace

5 years agoImprove documentation for different block types
Thalia [Fri, 15 Feb 2019 19:24:58 +0000 (19:24 +0000)]
Improve documentation for different block types

Clarify the purposes of Block::type and Block::getType

Change-Id: I64a2695f430c7718c504edb1fa6531a529c115cf

5 years agoPrevent PHP notice on SpecialDeletedContributions
Matěj Suchánek [Thu, 14 Feb 2019 09:47:54 +0000 (10:47 +0100)]
Prevent PHP notice on SpecialDeletedContributions

Bug: T208544
Change-Id: Ie8d5c3d7257134857713853eec8e0eb42890366a

5 years agoRefactor calls to deprecated function Content::getNativeData()
Bill Pirkle [Thu, 7 Feb 2019 00:14:23 +0000 (18:14 -0600)]
Refactor calls to deprecated function Content::getNativeData()

Function Content::getNativeData() was deprecated.  Replace with
calls to new function TextContent::getText() in most places.

Bug: T155582
Change-Id: I2bd508c72aac4faf474ba45ab1f92e2e8d2eb9be

5 years agoimport: Remove deprecated WikiRevision::$importer property
Derick Alangi [Thu, 14 Feb 2019 12:30:49 +0000 (13:30 +0100)]
import: Remove deprecated WikiRevision::$importer property

This property was introduced since 1.17 and was unused, then following
the deprecation policy, it was deprecated in 1.29. Removing this now
as it's been long enough and has been for several MW versions. Also,
updated release notes to mention this removal.

Change-Id: Ib6353dd37079bcfe7cd15600e8af1f67b245f4a3

5 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Thu, 14 Feb 2019 21:05:27 +0000 (22:05 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Ic40eaf0cedbbf6a81585f4f0d686f4aa3ae7d160

5 years agoMerge "objectcache: refactor and simplify some WANObjectCache code"
jenkins-bot [Thu, 14 Feb 2019 20:58:56 +0000 (20:58 +0000)]
Merge "objectcache: refactor and simplify some WANObjectCache code"

5 years agoMerge "Update required PHP version to 7.0.13"
jenkins-bot [Thu, 14 Feb 2019 20:40:35 +0000 (20:40 +0000)]
Merge "Update required PHP version to 7.0.13"

5 years agoMerge "Use "try-catch" block instead of "if" block to prevent interruption of new...
jenkins-bot [Thu, 14 Feb 2019 19:31:57 +0000 (19:31 +0000)]
Merge "Use "try-catch" block instead of "if" block to prevent interruption of new installation"

5 years agoUpdate required PHP version to 7.0.13
James D. Forrester [Thu, 14 Feb 2019 19:29:48 +0000 (11:29 -0800)]
Update required PHP version to 7.0.13

Bug: T209423
Change-Id: I66e563adb062bc132a1092d78bfd06e2210f382e

5 years agoMerge "jquery.makeCollapsible.styles: Avoid FOUC for collapse button"
jenkins-bot [Thu, 14 Feb 2019 13:26:12 +0000 (13:26 +0000)]
Merge "jquery.makeCollapsible.styles: Avoid FOUC for collapse button"

5 years agoMerge "EnhancedChangesList: Load style module via addModuleStyles()"
jenkins-bot [Thu, 14 Feb 2019 13:24:55 +0000 (13:24 +0000)]
Merge "EnhancedChangesList: Load style module via addModuleStyles()"

5 years agoMerge "Add missing dependency on module 'mediawiki.notify'"
jenkins-bot [Thu, 14 Feb 2019 13:17:55 +0000 (13:17 +0000)]
Merge "Add missing dependency on module 'mediawiki.notify'"

5 years agoMerge "mediawiki.special.changeslist.enhanced: Convert CSS to LESS"
jenkins-bot [Thu, 14 Feb 2019 13:09:13 +0000 (13:09 +0000)]
Merge "mediawiki.special.changeslist.enhanced: Convert CSS to LESS"

5 years agoAdd missing dependency on module 'mediawiki.notify'
Fomafix [Thu, 14 Feb 2019 08:59:23 +0000 (09:59 +0100)]
Add missing dependency on module 'mediawiki.notify'

watchlist.js uses mw.notify.

Change-Id: Iff59e01d96f3d8ffddd9ddaf9d3b4463c8cac8d1

5 years agoMerge "registration: Allow @-prefixed keys in manifest_version 2"
jenkins-bot [Thu, 14 Feb 2019 06:38:04 +0000 (06:38 +0000)]
Merge "registration: Allow @-prefixed keys in manifest_version 2"

5 years agoMerge "Update AtEase calls to use Wikimedia namespace"
jenkins-bot [Thu, 14 Feb 2019 06:18:57 +0000 (06:18 +0000)]
Merge "Update AtEase calls to use Wikimedia namespace"

5 years agoobjectcache: refactor and simplify some WANObjectCache code
Aaron Schulz [Wed, 13 Feb 2019 20:24:27 +0000 (12:24 -0800)]
objectcache: refactor and simplify some WANObjectCache code

* Move $value === false checks to isValid()
* Rename $isTombstone variable to avoid confusion with the new value
* Reorganize conditionals around set() calls in doGetWithSetCallback()
* Skip getInterimValue() check when there is no reason to assume anything
  might even be there (e.g. the key is not tombstoned)
* Fold the tombstone case for $useMutex into the ternary

Change-Id: I257110097cffe7fe87c6a9896e875f09d5c936d9

5 years agoMerge "objectcache: cleanup tombstone/mutex logic in doGetWithSetCallback()"
jenkins-bot [Thu, 14 Feb 2019 01:25:11 +0000 (01:25 +0000)]
Merge "objectcache: cleanup tombstone/mutex logic in doGetWithSetCallback()"

5 years agoMerge "resourceloader: Restore the comment about <script> vs XHR loading"
jenkins-bot [Thu, 14 Feb 2019 00:49:21 +0000 (00:49 +0000)]
Merge "resourceloader: Restore the comment about <script> vs XHR loading"

5 years agoresourceloader: Restore the comment about <script> vs XHR loading
Bartosz Dziewoński [Wed, 13 Feb 2019 13:21:04 +0000 (14:21 +0100)]
resourceloader: Restore the comment about <script> vs XHR loading

Removed in 42956b99b558294e5aa8c6c0e2a8f18513478022.

I think it's useful to know this rationale (even more so because
the arguments about caching seem no longer correct these days).

Also, add the line about loading progress not being known when
using this method.

(Slightly related to T216034)

Change-Id: I81fa90483c0c85fecc5cb620196521ce8bdd33a7

5 years agoobjectcache: cleanup tombstone/mutex logic in doGetWithSetCallback()
Aaron Schulz [Wed, 13 Feb 2019 18:54:39 +0000 (10:54 -0800)]
objectcache: cleanup tombstone/mutex logic in doGetWithSetCallback()

This largely follows-up 6b2f13b055c84d.

* Make the comments and use of temporary variables easier to follow.
* Simplified some conditionals by remove redundant checks.
* Bypass the final set() call if $isTombstone is true. It will almost
  always be rejected due to the tombstone still being there anyway, so
  there is no point in the roundtrips. Also, the most likely case where
  it would succeed is due to the callback taking a long time to run, in
  which case data from the replication lag uncertainty period that the
  tombstone represents would be getting saved to cache with the full
  nominal TTL, which is wrong.

Change-Id: Ic28e15b24f39e128bd72ad4d905edb852bc907aa

5 years agomediawiki.special.changeslist.enhanced: Convert CSS to LESS
Fomafix [Wed, 13 Feb 2019 13:07:26 +0000 (14:07 +0100)]
mediawiki.special.changeslist.enhanced: Convert CSS to LESS

Change-Id: Ic71a6bce99fd6417f90b5abdd52dcfa10e62029d

5 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Wed, 13 Feb 2019 21:01:42 +0000 (22:01 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I377eb66bceaf7e946bbcdb51cf767d96be3e24c9

5 years agoMerge "Add missing documentation to ProtectedTitlesPager"
jenkins-bot [Wed, 13 Feb 2019 20:36:32 +0000 (20:36 +0000)]
Merge "Add missing documentation to ProtectedTitlesPager"

5 years agoMerge "rdbms: Use more narrow type hints in LBFactoryTest"
jenkins-bot [Wed, 13 Feb 2019 18:47:02 +0000 (18:47 +0000)]
Merge "rdbms: Use more narrow type hints in LBFactoryTest"

5 years agordbms: Use more narrow type hints in LBFactoryTest
Thiemo Kreuz [Tue, 12 Feb 2019 12:01:26 +0000 (13:01 +0100)]
rdbms: Use more narrow type hints in LBFactoryTest

Originally I wanted to fix the broken type hint for the `Database`
class. But I ended limiting the scope as much as possible and only
type hint at the interfaces that contain the methods the code actually
needs.

Change-Id: I450a55e80612f6e676f7c803dc904b4b653426d8

5 years agomediawiki.special.changeslist.legend: Convert CSS to LESS
Fomafix [Wed, 13 Feb 2019 11:27:20 +0000 (12:27 +0100)]
mediawiki.special.changeslist.legend: Convert CSS to LESS

Change-Id: I543cb50958689af6b32d3cd462a8f77f31724a03

5 years agoMerge "rdbms: avoid duplicate spammy logging in LoadBalancer::getRandomNonLagged"
jenkins-bot [Wed, 13 Feb 2019 17:52:30 +0000 (17:52 +0000)]
Merge "rdbms: avoid duplicate spammy logging in LoadBalancer::getRandomNonLagged"

5 years agoFix CommentStoreComment RawMessage construction
Lucas Werkmeister [Wed, 13 Feb 2019 10:44:06 +0000 (11:44 +0100)]
Fix CommentStoreComment RawMessage construction

If a CommentStoreComment is constructed without a Message argument, then
the RawMessage it uses instead should specify the comment text as a
plain-text parameter, not as a regular parameter: we don’t want any
syntax in the text to be interpreted at the Message level.

Change-Id: If14debde2bceae695c8955604ee96bd5005d8b66

5 years agoMerge "resourceloader: Ignore warnings in JSMinPlus parser"
jenkins-bot [Wed, 13 Feb 2019 05:36:11 +0000 (05:36 +0000)]
Merge "resourceloader: Ignore warnings in JSMinPlus parser"

5 years agoregistration: Allow @-prefixed keys in manifest_version 2
Stanislav Malyshev [Fri, 8 Feb 2019 20:13:49 +0000 (12:13 -0800)]
registration: Allow @-prefixed keys in manifest_version 2

As specified in
<https://www.mediawiki.org/wiki/Manual:Extension_registration#Retaining_documentation>.

Bug: T215650
Change-Id: I2ff523828389fbec39cdf7c55046e7da901a2ecb

5 years agoresourceloader: Ignore warnings in JSMinPlus parser
Timo Tijhof [Wed, 13 Feb 2019 01:45:56 +0000 (01:45 +0000)]
resourceloader: Ignore warnings in JSMinPlus parser

It's old and unmaintained. The only thing we care about is if it
was able to parse the script and if not, what its error is. Its
return value or broken inner workings are insignificant at this
point and only cause noise.

Bug: T77169
Change-Id: Ie357ccfcc6141f894b452eb3996e168c1526990f

5 years agoUpdate AtEase calls to use Wikimedia namespace
Reedy [Tue, 12 Feb 2019 23:48:31 +0000 (23:48 +0000)]
Update AtEase calls to use Wikimedia namespace

Helps ease migration (stops vendor patch failing)

Change-Id: I9a985b341e1c3664c4ced6f793b19149067a580a

5 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Tue, 12 Feb 2019 20:54:12 +0000 (21:54 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Ia27cd1dfe1e1fecdff6431841c9e26a2daf3a865

5 years agordbms: avoid duplicate spammy logging in LoadBalancer::getRandomNonLagged
Aaron Schulz [Tue, 12 Feb 2019 18:52:31 +0000 (10:52 -0800)]
rdbms: avoid duplicate spammy logging in LoadBalancer::getRandomNonLagged

This is already logged in LoadMonitor in getServerStates() in a less spammy way
(due to APC caching of server states).

Bug: T215611
Change-Id: Id70fdfa62eff9cb6446deea5e197f4c0af4928aa

5 years agoMerge "Prevent fatal PHP errors when PageRestriction::getTitle() returns null."
jenkins-bot [Tue, 12 Feb 2019 16:27:04 +0000 (16:27 +0000)]
Merge "Prevent fatal PHP errors when PageRestriction::getTitle() returns null."

5 years agoUpdate @deprecated comment for the DB_SLAVE constant
Thiemo Kreuz [Tue, 12 Feb 2019 12:03:38 +0000 (13:03 +0100)]
Update @deprecated comment for the DB_SLAVE constant

I keep searching for the proper replacement for this deprecated
constant. It's much easier to find when the @deprecated comment
just mentions it.

Change-Id: I199b876ecfb6e146848b395bc7bfad80742f000d

5 years agoAdd missing documentation to ProtectedTitlesPager
Thiemo Kreuz [Tue, 12 Feb 2019 11:57:05 +0000 (12:57 +0100)]
Add missing documentation to ProtectedTitlesPager

This was discussed in I2b5c95d. The reason no IDE was able to find this
usage of the deprecated SpecialPage::getTitle method was the missing
type hinting.

TODO:
* A lot of properties this class uses are not declared.
* A lot of stuff in here must be private, but is public at the moment.
But this is for later patches.

Change-Id: I12fd6e517e5bd3507032ee3aafcb1de96733985b

5 years agoUse "try-catch" block instead of "if" block to prevent interruption of new installation
RazeSoldier [Mon, 11 Feb 2019 11:49:38 +0000 (19:49 +0800)]
Use "try-catch" block instead of "if" block to prevent interruption of new installation

New installation blocked when checking if the DB exists,
because when select DB, if it fails, it will throw an exception.

So I modify the checking logic to determine if there is an exception
thrown instead of detecting the return value.

Bug: T215566
Change-Id: I6817997434df7adc79fbc1b224b77c0daa8cc11d

5 years agowidgets: Remove redundant equality check in SelectWithInputWidget
Derick Alangi [Mon, 11 Feb 2019 14:59:36 +0000 (15:59 +0100)]
widgets: Remove redundant equality check in SelectWithInputWidget

The check `if ( $config['disabled'] == true )` is the same as the
check `if ( $config['disabled'] )`. Was this intentional or was it
supposed to be a test for equality and type (===)? If not, then I
think this patch removes the irrelevancy.

Clearly, if the $config['disabled'] is set to false, the isset()
check will return true but the second check will fail even with
this patch as it does the same thing.

Change-Id: Ibbe5b4949590f8ac954f613236056dd2e6dd18ba

5 years agoUpdate wikimedia/xmp-reader from 0.6.1 to 0.6.2
Reedy [Tue, 12 Feb 2019 01:24:17 +0000 (01:24 +0000)]
Update wikimedia/xmp-reader from 0.6.1 to 0.6.2

Change-Id: Ie396666aae2122dc552f6f1a7f6fe6ff96387fd1
Depends-On: Ia5dcf97548ed1c1f17cce9701df5cf13eea814dd

5 years agoUpdate wikimedia/php-session-serializer from v1.0.6 to v1.0.7
Reedy [Tue, 12 Feb 2019 00:40:12 +0000 (00:40 +0000)]
Update wikimedia/php-session-serializer from v1.0.6 to v1.0.7

Change-Id: Id30bb862bec42e508b3551d39f5980d900ade206
Depends-On: Ia19d237198fd2a0a15db467ec9dd97e98a857e33

5 years agojquery.makeCollapsible.styles: Avoid FOUC for collapse button
Fomafix [Tue, 12 Feb 2019 01:22:47 +0000 (02:22 +0100)]
jquery.makeCollapsible.styles: Avoid FOUC for collapse button

The expand button on a <div> element has already a pseudo-class with the
expand text as content. For the collapse button this pseudo-class is
missing.

This change adds the missing pseudo-class for the collapse button to
prevent a missing button while loading.

The missing collapse button while loading is visible on
Special:RecentChanges. The expand button is always there.

Change-Id: I7fa80238d54ac43a96bf1d70bd42a0cccf90a73a

5 years agoMerge "Revert "RCFilters: Export config vars in the RL modules where possible""
jenkins-bot [Tue, 12 Feb 2019 01:16:50 +0000 (01:16 +0000)]
Merge "Revert "RCFilters: Export config vars in the RL modules where possible""

5 years agoRevert "RCFilters: Export config vars in the RL modules where possible"
Catrope [Tue, 12 Feb 2019 00:54:39 +0000 (00:54 +0000)]
Revert "RCFilters: Export config vars in the RL modules where possible"

This reverts commit bf4f9d0313495dd67a53b9925edf9a3cc6ef36fe.

Reason for revert: causes issues with OAuth extension

The OAuth extension uses a hook to override certain tag messages, and
that hook uses RequestContext::getMain()->msg(), which tries to load
the current user. That's not allowed in load.php requests, so we get a
"Sessions are disabled for this entry point" error.

Change-Id: If58b7edfca116cd7a11f38556f74bed82609d96a

5 years agoEnhancedChangesList: Load style module via addModuleStyles()
Fomafix [Sun, 10 Feb 2019 15:04:57 +0000 (16:04 +0100)]
EnhancedChangesList: Load style module via addModuleStyles()

This change avoids a flash of missing collapsible toggle icons while
loading.

Change-Id: I090b1622868f2e5a01ca783dfce3be16b7d6b525

5 years agoUpdate wikimedia/ip-set 2.0.0 to 2.0.1
Reedy [Tue, 12 Feb 2019 00:28:49 +0000 (00:28 +0000)]
Update wikimedia/ip-set 2.0.0 to 2.0.1

Change-Id: I154a677bac28a451be4f203ff05ea4620260b54e
Depends-On: I1090817a5ff1e406cf51596a8b1558c7bd3ca7d7

5 years agoMerge "ChangesList: Remove spaces from <td> in EnhancedChangesListGroup.mustache"
jenkins-bot [Tue, 12 Feb 2019 00:26:42 +0000 (00:26 +0000)]
Merge "ChangesList: Remove spaces from <td> in EnhancedChangesListGroup.mustache"

5 years agoMerge "ProtectionForm: Move JS config var to RL packageFiles"
jenkins-bot [Tue, 12 Feb 2019 00:14:25 +0000 (00:14 +0000)]
Merge "ProtectionForm: Move JS config var to RL packageFiles"

5 years agoChangesList: Remove spaces from <td> in EnhancedChangesListGroup.mustache
Fomafix [Sun, 10 Feb 2019 20:01:25 +0000 (21:01 +0100)]
ChangesList: Remove spaces from <td> in EnhancedChangesListGroup.mustache

The special page RecentChanges can included in wiki content via

  {{Special:RecentChanges}}

In this case the generated content is parsed by a wikitext parser. The
wikitext parser converts

  <td>
    <span>Foo</span>
  </td>

to the HTML

  <td><p><span>Foo</span></p></td>

But the wikitext

  <td><span>Foo</span></td>

is converted to the HTML

  <td><span>Foo</span></td>

The module 'jquery.makeCollapsible' supports custom collapsible toggle
buttons but only when they are a direct child of the <td> element. When
the module does not find a custom collapsible toggle button it adds the
default button [Expand].

Because of the additional <p> element when including the recent changes
the module 'jquery.makeCollapsible' adds a default collapsible toggle
button.

This change removes the spaces between <td> and <span> to prevent the
<p> elements when including the recent changes.

Bug: T215737
Change-Id: Ida46956fc7f9ab923c542751ac13411380c02ab0

5 years agoMerge "Job::factory should throw an InvalidArgumentException, not MWException"
jenkins-bot [Mon, 11 Feb 2019 23:50:13 +0000 (23:50 +0000)]
Merge "Job::factory should throw an InvalidArgumentException, not MWException"

5 years agoJob::factory should throw an InvalidArgumentException, not MWException
Derick Alangi [Wed, 30 Jan 2019 19:40:46 +0000 (20:40 +0100)]
Job::factory should throw an InvalidArgumentException, not MWException

Change-Id: I9a85562b205db604d2746ec5db0e72dacdb93c6d

5 years agoMerge "mw.widgets: Use CSS grid for the calendar in supporting browsers"
jenkins-bot [Mon, 11 Feb 2019 22:21:45 +0000 (22:21 +0000)]
Merge "mw.widgets: Use CSS grid for the calendar in supporting browsers"

5 years agomw.widgets: Use CSS grid for the calendar in supporting browsers
Bartosz Dziewoński [Wed, 30 Jan 2019 23:54:42 +0000 (15:54 -0800)]
mw.widgets: Use CSS grid for the calendar in supporting browsers

Bug: T214997
Change-Id: I05dca01585f3de86580e7ae94ceeae1716f56ba3

5 years agoMerge "parser: Add new pcache metrics, split by page content model"
jenkins-bot [Mon, 11 Feb 2019 21:05:48 +0000 (21:05 +0000)]
Merge "parser: Add new pcache metrics, split by page content model"

5 years agoMerge "registration: Define packageFiles for v1 extension schema"
jenkins-bot [Mon, 11 Feb 2019 21:05:42 +0000 (21:05 +0000)]
Merge "registration: Define packageFiles for v1 extension schema"

5 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Mon, 11 Feb 2019 20:54:25 +0000 (21:54 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Id809e80a46547f7bf042eb6073efd7a519666ce7