Commit graph

87008 commits

Author SHA1 Message Date
Bill Pirkle
d993f499ee 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
2019-02-15 17:48:01 +00:00
Translation updater bot
ff75ea4f05 Localisation updates from https://translatewiki.net.
Change-Id: Ic40eaf0cedbbf6a81585f4f0d686f4aa3ae7d160
2019-02-14 22:05:28 +01:00
jenkins-bot
d298eecd5e Merge "objectcache: refactor and simplify some WANObjectCache code" 2019-02-14 20:58:56 +00:00
jenkins-bot
39836fea2b Merge "Update required PHP version to 7.0.13" 2019-02-14 20:40:35 +00:00
jenkins-bot
2e9c34c562 Merge "Use "try-catch" block instead of "if" block to prevent interruption of new installation" 2019-02-14 19:31:57 +00:00
James D. Forrester
60a172aaea Update required PHP version to 7.0.13
Bug: T209423
Change-Id: I66e563adb062bc132a1092d78bfd06e2210f382e
2019-02-14 11:29:48 -08:00
jenkins-bot
1d84a0e24d Merge "jquery.makeCollapsible.styles: Avoid FOUC for collapse button" 2019-02-14 13:26:12 +00:00
jenkins-bot
d56233299d Merge "EnhancedChangesList: Load style module via addModuleStyles()" 2019-02-14 13:24:55 +00:00
jenkins-bot
504543b4f7 Merge "Add missing dependency on module 'mediawiki.notify'" 2019-02-14 13:17:55 +00:00
jenkins-bot
043ab6393c Merge "mediawiki.special.changeslist.enhanced: Convert CSS to LESS" 2019-02-14 13:09:13 +00:00
Fomafix
d871643d05 Add missing dependency on module 'mediawiki.notify'
watchlist.js uses mw.notify.

Change-Id: Iff59e01d96f3d8ffddd9ddaf9d3b4463c8cac8d1
2019-02-14 09:59:23 +01:00
jenkins-bot
37ef56fadd Merge "registration: Allow @-prefixed keys in manifest_version 2" 2019-02-14 06:38:04 +00:00
jenkins-bot
38af39658d Merge "Update AtEase calls to use Wikimedia namespace" 2019-02-14 06:18:57 +00:00
Aaron Schulz
999ff6097d 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
2019-02-13 19:48:44 -08:00
jenkins-bot
dc24eba870 Merge "objectcache: cleanup tombstone/mutex logic in doGetWithSetCallback()" 2019-02-14 01:25:11 +00:00
jenkins-bot
4d5a6ab951 Merge "resourceloader: Restore the comment about <script> vs XHR loading" 2019-02-14 00:49:21 +00:00
Bartosz Dziewoński
3d38db2a65 resourceloader: Restore the comment about <script> vs XHR loading
Removed in 42956b99b5.

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
2019-02-14 00:35:30 +00:00
Aaron Schulz
fdb00bf4e2 objectcache: cleanup tombstone/mutex logic in doGetWithSetCallback()
This largely follows-up 6b2f13b055.

* 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
2019-02-13 22:57:38 +00:00
Fomafix
628cb2e32d mediawiki.special.changeslist.enhanced: Convert CSS to LESS
Change-Id: Ic71a6bce99fd6417f90b5abdd52dcfa10e62029d
2019-02-13 22:30:12 +01:00
Translation updater bot
eb4e194185 Localisation updates from https://translatewiki.net.
Change-Id: I377eb66bceaf7e946bbcdb51cf767d96be3e24c9
2019-02-13 22:01:42 +01:00
jenkins-bot
5853b3584c Merge "Add missing documentation to ProtectedTitlesPager" 2019-02-13 20:36:32 +00:00
jenkins-bot
b6c7c057d2 Merge "rdbms: Use more narrow type hints in LBFactoryTest" 2019-02-13 18:47:02 +00:00
Thiemo Kreuz
eee735a176 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
2019-02-13 18:27:26 +00:00
Fomafix
82182ec0e2 mediawiki.special.changeslist.legend: Convert CSS to LESS
Change-Id: I543cb50958689af6b32d3cd462a8f77f31724a03
2019-02-13 18:45:16 +01:00
jenkins-bot
b7b7111c83 Merge "rdbms: avoid duplicate spammy logging in LoadBalancer::getRandomNonLagged" 2019-02-13 17:52:30 +00:00
Lucas Werkmeister
d5ed0163f2 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
2019-02-13 11:17:10 -05:00
jenkins-bot
4091905d5b Merge "resourceloader: Ignore warnings in JSMinPlus parser" 2019-02-13 05:36:11 +00:00
Stanislav Malyshev
341bd5d6e9 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
2019-02-12 18:50:14 -08:00
Timo Tijhof
7a72b16e0f 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
2019-02-13 02:11:37 +00:00
Reedy
daf15e14ab Update AtEase calls to use Wikimedia namespace
Helps ease migration (stops vendor patch failing)

Change-Id: I9a985b341e1c3664c4ced6f793b19149067a580a
2019-02-12 23:48:31 +00:00
Translation updater bot
e36ef661d9 Localisation updates from https://translatewiki.net.
Change-Id: Ia27cd1dfe1e1fecdff6431841c9e26a2daf3a865
2019-02-12 21:54:12 +01:00
Aaron Schulz
f0f3e77dd3 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
2019-02-12 10:52:31 -08:00
jenkins-bot
9eafd89011 Merge "Prevent fatal PHP errors when PageRestriction::getTitle() returns null." 2019-02-12 16:27:04 +00:00
Thiemo Kreuz
22f5babf4d 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
2019-02-12 13:05:03 +01:00
Thiemo Kreuz
a1bb593efb 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
2019-02-12 12:58:43 +01:00
RazeSoldier
56d2fc8081 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
2019-02-12 13:38:32 +08:00
Reedy
f51c9e889f Update wikimedia/xmp-reader from 0.6.1 to 0.6.2
Change-Id: Ie396666aae2122dc552f6f1a7f6fe6ff96387fd1
Depends-On: Ia5dcf97548ed1c1f17cce9701df5cf13eea814dd
2019-02-12 01:25:25 +00:00
Reedy
20a5054172 Update wikimedia/php-session-serializer from v1.0.6 to v1.0.7
Change-Id: Id30bb862bec42e508b3551d39f5980d900ade206
Depends-On: Ia19d237198fd2a0a15db467ec9dd97e98a857e33
2019-02-12 01:25:25 +00:00
Fomafix
4c9822afff 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
2019-02-12 02:22:47 +01:00
jenkins-bot
7099937b42 Merge "Revert "RCFilters: Export config vars in the RL modules where possible"" 2019-02-12 01:16:50 +00:00
Catrope
492969e12b Revert "RCFilters: Export config vars in the RL modules where possible"
This reverts commit bf4f9d0313.

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
2019-02-12 01:02:27 +00:00
Fomafix
2f9a6581b7 EnhancedChangesList: Load style module via addModuleStyles()
This change avoids a flash of missing collapsible toggle icons while
loading.

Change-Id: I090b1622868f2e5a01ca783dfce3be16b7d6b525
2019-02-12 01:29:36 +01:00
Reedy
ec46d1e8a5 Update wikimedia/ip-set 2.0.0 to 2.0.1
Change-Id: I154a677bac28a451be4f203ff05ea4620260b54e
Depends-On: I1090817a5ff1e406cf51596a8b1558c7bd3ca7d7
2019-02-12 00:28:49 +00:00
jenkins-bot
272afcab46 Merge "ChangesList: Remove spaces from <td> in EnhancedChangesListGroup.mustache" 2019-02-12 00:26:42 +00:00
jenkins-bot
b39f1946c4 Merge "ProtectionForm: Move JS config var to RL packageFiles" 2019-02-12 00:14:25 +00:00
Fomafix
9c5a477395 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
2019-02-12 00:06:48 +00:00
jenkins-bot
de383fe4e4 Merge "Job::factory should throw an InvalidArgumentException, not MWException" 2019-02-11 23:50:13 +00:00
Derick Alangi
f8337198ce Job::factory should throw an InvalidArgumentException, not MWException
Change-Id: I9a85562b205db604d2746ec5db0e72dacdb93c6d
2019-02-11 23:35:47 +00:00
jenkins-bot
34c498088e Merge "mw.widgets: Use CSS grid for the calendar in supporting browsers" 2019-02-11 22:21:45 +00:00
Bartosz Dziewoński
377dcabeaa mw.widgets: Use CSS grid for the calendar in supporting browsers
Bug: T214997
Change-Id: I05dca01585f3de86580e7ae94ceeae1716f56ba3
2019-02-11 13:58:34 -08:00