lhc/web/wiklou.git
4 years agoFollow-up 7960d53: Mark when the SecondaryDataUpdates and WikiPageDeletionUpdates...
James D. Forrester [Fri, 13 Sep 2019 17:59:48 +0000 (10:59 -0700)]
Follow-up 7960d53: Mark when the SecondaryDataUpdates and WikiPageDeletionUpdates hooks were deprecated

Change-Id: Id35cc5e1d21a62d0d6469b80b693bb654215db2a

4 years agoMerge "Fix a typo (yeild -> yield)"
jenkins-bot [Fri, 13 Sep 2019 17:10:14 +0000 (17:10 +0000)]
Merge "Fix a typo (yeild -> yield)"

4 years agoMerge "output: Narrow Title type hint to LinkTarget"
jenkins-bot [Fri, 13 Sep 2019 13:31:24 +0000 (13:31 +0000)]
Merge "output: Narrow Title type hint to LinkTarget"

4 years agoMerge "Reset all logging tables together"
jenkins-bot [Fri, 13 Sep 2019 12:06:20 +0000 (12:06 +0000)]
Merge "Reset all logging tables together"

4 years agoMerge "Improve MediaWikiIntegrationTestCase::resetDB()"
jenkins-bot [Fri, 13 Sep 2019 12:00:51 +0000 (12:00 +0000)]
Merge "Improve MediaWikiIntegrationTestCase::resetDB()"

4 years agoReset all logging tables together
Adam Wight [Thu, 12 Sep 2019 15:19:57 +0000 (17:19 +0200)]
Reset all logging tables together

For example, leftover cruft in `log_search` will cause spurious
associated_rev links between unrelated revisions and log entries.

Bug: T227849
Change-Id: Ie344522229e4142f2c61a267b4d693051b813236

4 years agoImprove MediaWikiIntegrationTestCase::resetDB()
Lucas Werkmeister [Thu, 12 Sep 2019 15:36:01 +0000 (17:36 +0200)]
Improve MediaWikiIntegrationTestCase::resetDB()

Test the intersection of $tablesUsed with each set of tables
separately and only update it afterwards.  Without this fix, overlaps
between the table groups would cause additional groups to be pulled in
unnecessarily.

Change-Id: I1b2a6eb47e061dee8a27fb4779809b4684c05104

4 years agooutput: Narrow Title type hint to LinkTarget
Thiemo Kreuz [Fri, 13 Sep 2019 09:34:33 +0000 (11:34 +0200)]
output: Narrow Title type hint to LinkTarget

The code never needs a full Title object, but only what the (more
narrow) interface provides.

Change-Id: I3a7aa35c7e90fffaf37f4cb444549237c20e0bd9

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Fri, 13 Sep 2019 07:30:02 +0000 (09:30 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Ieebc40ae9287950ee4ce61612e982d6e307bb2b3

4 years agoFix a typo (yeild -> yield)
DannyS712 [Fri, 13 Sep 2019 03:37:16 +0000 (03:37 +0000)]
Fix a typo (yeild -> yield)

Bug: T201491
Change-Id: I70443514d55c681e51233b6e80ac7911c5e12d5a

4 years agoMerge "filebackend: Use HTTPFileStreamer::send404Message() in caller instead"
jenkins-bot [Fri, 13 Sep 2019 02:33:15 +0000 (02:33 +0000)]
Merge "filebackend: Use HTTPFileStreamer::send404Message() in caller instead"

4 years agoMerge "Fix param docs and passed type of UserMailer::sendWithPear"
jenkins-bot [Thu, 12 Sep 2019 23:01:43 +0000 (23:01 +0000)]
Merge "Fix param docs and passed type of UserMailer::sendWithPear"

4 years agoMerge "Avoid Database::tableName in WikiExporter"
jenkins-bot [Thu, 12 Sep 2019 22:36:03 +0000 (22:36 +0000)]
Merge "Avoid Database::tableName in WikiExporter"

4 years agoMerge "Fix spaces in doc comments"
jenkins-bot [Thu, 12 Sep 2019 22:35:56 +0000 (22:35 +0000)]
Merge "Fix spaces in doc comments"

4 years agoMerge "Make DefaultPreferencesFactory depend on PermissionManager."
jenkins-bot [Thu, 12 Sep 2019 21:03:30 +0000 (21:03 +0000)]
Merge "Make DefaultPreferencesFactory depend on PermissionManager."

4 years agoFix spaces in doc comments
Umherirrender [Thu, 12 Sep 2019 19:45:18 +0000 (21:45 +0200)]
Fix spaces in doc comments

Change-Id: Ic404324003d40569d0ddb697c8b1bcf95f28e2ec

4 years agoAvoid Database::tableName in WikiExporter
Umherirrender [Wed, 4 Sep 2019 16:11:46 +0000 (18:11 +0200)]
Avoid Database::tableName in WikiExporter

Using * in select is not the prefered way.
List all needed columns to make the use visible and to avoid issues when
new fields gets added with big data.
As each column name is unique there is no need to get the table name for
prefixing the columns

The following columns no longer selected:
- log_user_text -> not used due to use of ActorMigration class
- log_actor -> Add by ActorMigration class
- log_comment_id -> Added by CommentStore
- log_page -> Unused in the writer, the ns/title pair is used instead

Move the arrays out of the loop, because there are not depending on
values changing in the loop

Change-Id: I140641b7ed75bc2b8db2e7612020d668f1be663b

4 years agoFix param docs and passed type of UserMailer::sendWithPear
Umherirrender [Wed, 11 Sep 2019 20:12:04 +0000 (22:12 +0200)]
Fix param docs and passed type of UserMailer::sendWithPear

Mail::send accepts mixed for recipients and only array for headers
The documentation for recipients allows string with comma-separated list
or a string array
https://github.com/pear/Mail/blob/master/Mail/mail.php#L115-L119

Change-Id: Ia8269e91a7dcfe09d41bd03f8830b83f28812564

4 years agoMerge "mw.ForeignApi: don’t set origin for same-origin requests"
jenkins-bot [Thu, 12 Sep 2019 17:34:37 +0000 (17:34 +0000)]
Merge "mw.ForeignApi: don’t set origin for same-origin requests"

4 years agoMerge "Resources: Consistently use base paths without trailing '/'"
jenkins-bot [Thu, 12 Sep 2019 17:34:27 +0000 (17:34 +0000)]
Merge "Resources: Consistently use base paths without trailing '/'"

4 years agoStreamFile: Merge duplicate switch cases 'jpg' and 'jpeg'
Derick Alangi [Thu, 12 Sep 2019 13:26:45 +0000 (14:26 +0100)]
StreamFile: Merge duplicate switch cases 'jpg' and 'jpeg'

Change-Id: I51d233e80c4b0cebc269b54629582d4cf76e186f

4 years agofilebackend: Use HTTPFileStreamer::send404Message() in caller instead
Derick Alangi [Tue, 10 Sep 2019 09:10:44 +0000 (10:10 +0100)]
filebackend: Use HTTPFileStreamer::send404Message() in caller instead

Replaced usage of StreamFile::STEAM_HEADLESS (now making it unused) by
HTTPFileStreamer::STREAM_HEADLESS. Also, deprecated these unused constants.
Searched around and found nothing and CS also says so too;

https://codesearch.wmflabs.org/search/?q=StreamFile%3A%3A(STREAM_ALLOW_OB%7CSTREAM_HEADLESS)&i=nope&files=&repos=

Change-Id: Ia3fc2cf072fa2fddb910c64a547d12cb243290d5

4 years agoResources: Consistently use base paths without trailing '/'
Fomafix [Thu, 12 Sep 2019 13:07:47 +0000 (15:07 +0200)]
Resources: Consistently use base paths without trailing '/'

Change-Id: Iebaf740f9367a34dc29a9312bccd54f92f0c66f2

4 years agoMerge "Replace usages of deprecated User::isAllowed. Step 2."
jenkins-bot [Thu, 12 Sep 2019 12:33:03 +0000 (12:33 +0000)]
Merge "Replace usages of deprecated User::isAllowed. Step 2."

4 years agoMerge "Make SpecialBlankPageTest independend from the language"
jenkins-bot [Thu, 12 Sep 2019 12:00:06 +0000 (12:00 +0000)]
Merge "Make SpecialBlankPageTest independend from the language"

4 years agoMake SpecialBlankPageTest independend from the language
Thiemo Kreuz [Thu, 12 Sep 2019 11:10:52 +0000 (13:10 +0200)]
Make SpecialBlankPageTest independend from the language

I would like to argue this is best practice. This also currently blocks
https://gerrit.wikimedia.org/r/521480

Change-Id: I8477f8280038c383c35bebf559ba2b5841748821

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Thu, 12 Sep 2019 06:29:35 +0000 (08:29 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Ie04c47bbaa02a23e152f48a35e62f0185054ef6b

4 years agoMerge "Cleanup File::purgeEverything() to use JobQueueGroup::lazyPush() in one batch"
jenkins-bot [Thu, 12 Sep 2019 00:11:18 +0000 (00:11 +0000)]
Merge "Cleanup File::purgeEverything() to use JobQueueGroup::lazyPush() in one batch"

4 years agoMerge "Fix XMP parser errors due to trailing nullchar"
jenkins-bot [Wed, 11 Sep 2019 23:56:51 +0000 (23:56 +0000)]
Merge "Fix XMP parser errors due to trailing nullchar"

4 years agoReplace usages of deprecated User::isAllowed. Step 2.
Petr Pchelko [Wed, 21 Aug 2019 02:01:06 +0000 (19:01 -0700)]
Replace usages of deprecated User::isAllowed. Step 2.

Bug: T220191
Depends-On: I509cd88355cfd0cc074f4135ec86399b4075f89f
Change-Id: I2341e6f1d108c92924620fba3c64ec090cb09918

4 years agoFix XMP parser errors due to trailing nullchar
Derk-Jan Hartman [Wed, 11 Sep 2019 22:12:22 +0000 (00:12 +0200)]
Fix XMP parser errors due to trailing nullchar

JPEG files can have trailing \0 chars at the end of the XMP value. Use
trim() to remove these from the string value.

Bug: T118799
Change-Id: Id4ab223ef432e5d2c0dd3b4e332320db02422700

4 years agoMake DefaultPreferencesFactory depend on PermissionManager.
Petr Pchelko [Thu, 22 Aug 2019 22:53:05 +0000 (15:53 -0700)]
Make DefaultPreferencesFactory depend on PermissionManager.

Bug: T220191
Change-Id: I3f5c4340501d59b5ca63b096364b5cc8388cff80

4 years agoCleanup File::purgeEverything() to use JobQueueGroup::lazyPush() in one batch
Aaron Schulz [Wed, 11 Sep 2019 22:09:07 +0000 (15:09 -0700)]
Cleanup File::purgeEverything() to use JobQueueGroup::lazyPush() in one batch

Change-Id: I347de55ecca4d2779eba6a8627276b9afef48905

4 years agoCleanup LinksUpdate::invalidateProperties() to use JobQueueGroup::lazyPush() in one...
Aaron Schulz [Wed, 11 Sep 2019 22:07:41 +0000 (15:07 -0700)]
Cleanup LinksUpdate::invalidateProperties() to use JobQueueGroup::lazyPush() in one batch

Change-Id: I7afaf6e6c0692aad83c017660bb8fdbb8a88597a

4 years agoCleanup field visibility and comments in CdnCacheUpdate and HTMLCacheUpdate
Aaron Schulz [Wed, 11 Sep 2019 22:00:13 +0000 (15:00 -0700)]
Cleanup field visibility and comments in CdnCacheUpdate and HTMLCacheUpdate

Change-Id: Ifbdc3e845aee9c6785c7813f6c955da4bfbe2bc8

4 years agoCleanup Title::touchLinks() to use JobQueueGroup::lazyPush() in one batch
Aaron Schulz [Wed, 11 Sep 2019 21:56:24 +0000 (14:56 -0700)]
Cleanup Title::touchLinks() to use JobQueueGroup::lazyPush() in one batch

Change-Id: I45f36a06cc333170f60162ee37b464865b6bdc37

4 years agoMerge "Add general messagebox (neutral) styling to shared.css"
jenkins-bot [Wed, 11 Sep 2019 21:07:28 +0000 (21:07 +0000)]
Merge "Add general messagebox (neutral) styling to shared.css"

4 years agoTitle: Fix case mismatch for function/method calls
Derick Alangi [Wed, 11 Sep 2019 18:05:22 +0000 (19:05 +0100)]
Title: Fix case mismatch for function/method calls

Change-Id: I278bd54818a0d143415192d17ef815d40f0c2b63

4 years agoMerge "mediawiki.util: Add debounce() function"
jenkins-bot [Wed, 11 Sep 2019 19:33:40 +0000 (19:33 +0000)]
Merge "mediawiki.util: Add debounce() function"

4 years agoMerge "deferred: Fix MW version number when hard deprecating to '1.34'"
jenkins-bot [Wed, 11 Sep 2019 19:33:33 +0000 (19:33 +0000)]
Merge "deferred: Fix MW version number when hard deprecating to '1.34'"

4 years agoMerge "jquery.color: Merge $.colorUtil back into this module"
jenkins-bot [Wed, 11 Sep 2019 19:15:22 +0000 (19:15 +0000)]
Merge "jquery.color: Merge $.colorUtil back into this module"

4 years agoMerge "Update OOUI to v0.34.1"
jenkins-bot [Wed, 11 Sep 2019 19:07:08 +0000 (19:07 +0000)]
Merge "Update OOUI to v0.34.1"

4 years agoMerge "Pass the user and request into BlockManager::getUserBlock"
jenkins-bot [Wed, 11 Sep 2019 18:58:32 +0000 (18:58 +0000)]
Merge "Pass the user and request into BlockManager::getUserBlock"

4 years agoMerge "mediawiki.special.userlogin.signup: Remove unused debounce dependency"
jenkins-bot [Wed, 11 Sep 2019 18:52:38 +0000 (18:52 +0000)]
Merge "mediawiki.special.userlogin.signup: Remove unused debounce dependency"

4 years agoMerge "mediawiki.util: Remove redundant IE8 support from addCSS()"
jenkins-bot [Wed, 11 Sep 2019 18:42:27 +0000 (18:42 +0000)]
Merge "mediawiki.util: Remove redundant IE8 support from addCSS()"

4 years agoMerge "mediawiki.util: Improve escapeId*() docs and minor optimisations"
jenkins-bot [Wed, 11 Sep 2019 18:42:21 +0000 (18:42 +0000)]
Merge "mediawiki.util: Improve escapeId*() docs and minor optimisations"

4 years agodeferred: Fix MW version number when hard deprecating to '1.34'
Derick Alangi [Wed, 11 Sep 2019 17:41:05 +0000 (18:41 +0100)]
deferred: Fix MW version number when hard deprecating to '1.34'

Should be string or bool and not a float. The reason 49bbfc7 was
not triggered is because the deprecated code path is no longer being
executed in production.

Change-Id: Ieeffb8a6cc7177c52b4c54d66152c90ded1dc248

4 years agoMerge "SpecialRunJobs: optional output stats and status."
jenkins-bot [Wed, 11 Sep 2019 16:11:08 +0000 (16:11 +0000)]
Merge "SpecialRunJobs: optional output stats and status."

4 years agomediawiki.util: Add debounce() function
Timo Tijhof [Wed, 11 Sep 2019 04:46:50 +0000 (05:46 +0100)]
mediawiki.util: Add debounce() function

Bug: T213426
Change-Id: If370b959b2617d0f506ac3ed344af8c6a667e70d

4 years agomw.ForeignApi: don’t set origin for same-origin requests
Lucas Werkmeister [Mon, 9 Sep 2019 14:55:35 +0000 (16:55 +0200)]
mw.ForeignApi: don’t set origin for same-origin requests

If the foreign API has the same host as the current page (e. g. if it’s
actually the same wiki, or multiple wikis are installed under different
paths on the same host), then the browser will not send an Origin
header, and if we still set an origin parameter, then the API will
complain that the two don’t match. Detect this and unset the origin
parameter in that case.

Bug: T208601
Change-Id: Ia006f3dc3283ce3f81d4d72cbe9676a00797c4d0

4 years agoSpecialRunJobs: optional output stats and status.
daniel [Fri, 6 Sep 2019 16:40:07 +0000 (18:40 +0200)]
SpecialRunJobs: optional output stats and status.

This adds a parameter to SpecialRunJobs that lets it output statistics
about the jobs it has run.

The 'reached' field can be used to detect when the queue is emopty,
which is essential to know for clients that want to flush the entire
job queue, to ensure that all effects of any actions they have taken
have been processed.

More specifically, this provides a way for an external testing framework
to run all jobs after an action, so it can observe and assert the
effects of that action.

Bug: T231822
Change-Id: Ibb38490afca71efeb67300b9665951c429c19a3c

4 years agoMerge "Add namespace filter to Special:PagesWithProp"
jenkins-bot [Wed, 11 Sep 2019 11:59:45 +0000 (11:59 +0000)]
Merge "Add namespace filter to Special:PagesWithProp"

4 years agoMerge "Allow users who are partially blocked to delete revisions."
jenkins-bot [Wed, 11 Sep 2019 08:24:11 +0000 (08:24 +0000)]
Merge "Allow users who are partially blocked to delete revisions."

4 years agoPass the user and request into BlockManager::getUserBlock
Thalia [Fri, 23 Aug 2019 16:11:45 +0000 (17:11 +0100)]
Pass the user and request into BlockManager::getUserBlock

Blocks are checked from the User object. Specifically,
User::getBlockedStatus instantiates a BlockManager and calls
BlockManager::getUserBlock. However, checking the block often depends
on knowing more about the state than the User should know. As a result,
the global user and request objects were passed into the block manager
on construction.

Whether the global request object should be passed into a service
constructor is still up for debate, so this moves the check for the
global state back to User::getBlockedStatus for now. (Note that it
reintroduces the problem of the User knowing more about state than it
should.)

This change also makes clearer the cases in which
BlockManager::getUserBlock is called from the User.

Different blocks may be sought, depending on the user and their
permissions. The user may be:
(1) The global user (and can be affected by IP blocks). The global
    request object is needed for checking the IP address, the XFF
    header and the cookies.
(2) The global user (and exempt from IP blocks). The global request
    object is needed for checking the cookies.
(3) Another user (not the global user). No request object is available
    or needed; just look for a block against the user account.

Cases #1 and #2 check whether the global user is blocked in practice;
the block may due to their user account being blocked or to an IP
address block or cookie block (or multiple of these). Case #3 simply
checks whether a user's account is blocked, and does not determine
whether the person using that account is affected in practice by any
IP address or cookie blocks.

Bug: T231919
Change-Id: I3f51fd3579514b83b567dfe20926df2f0930dc85

4 years agoAllow users who are partially blocked to delete revisions.
David Barratt [Thu, 18 Jul 2019 23:33:15 +0000 (19:33 -0400)]
Allow users who are partially blocked to delete revisions.

Currently, users who are partially blocked are prevented from deleting
revisions. The system should check to see if the user can edit the page.

Bug: T228486
Change-Id: Id08dfab9b0ebe9721d3552564ee9f9d1e1a4805a

4 years agoUpdate OOUI to v0.34.1
Volker E [Wed, 11 Sep 2019 05:15:37 +0000 (22:15 -0700)]
Update OOUI to v0.34.1

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

Bug: T230694
Bug: T232211
Bug: T232514
Bug: T232537
Depends-On: I00c6ecd8666d565b66af3021ecf5f339288606fe
Change-Id: Ic9b7033e3f52f415ec8aec845a65a8452d0e5d8f

4 years agomediawiki.special.userlogin.signup: Remove unused debounce dependency
Timo Tijhof [Wed, 11 Sep 2019 04:57:03 +0000 (05:57 +0100)]
mediawiki.special.userlogin.signup: Remove unused debounce dependency

The file in question does not use $.debounce() or $.throttle().
Probably a left-over from when this was factored out into
'mediawiki.htmlform.checker', which uses debounce (now mw.util).

Bug: T213426
Change-Id: Id48dc0f1119a21948ce0b93bb58c08f6e42516d7

4 years agomediawiki.util: Remove redundant IE8 support from addCSS()
Timo Tijhof [Wed, 11 Sep 2019 04:31:32 +0000 (05:31 +0100)]
mediawiki.util: Remove redundant IE8 support from addCSS()

Was added in 8eda03743c (2013) for IE8 support, but MW now
requires IE11+. The HTMLStyleElement.sheet property is available
in all supported browsers.

<https://caniuse.com/#feat=mdn-api_htmlstyleelement_sheet>

The method itself was introduced in 2010 (79618024c2 / r76324).

Change-Id: Ia6a778a6d55e9257b9e55edfedd8f17587b96c1c

4 years agomediawiki.util: Improve escapeId*() docs and minor optimisations
Timo Tijhof [Wed, 11 Sep 2019 04:30:16 +0000 (05:30 +0100)]
mediawiki.util: Improve escapeId*() docs and minor optimisations

Change-Id: Icfd8ce7e0de0041fe84a6ebcbfab97df03c18672

4 years agojquery.color: Merge $.colorUtil back into this module
Timo Tijhof [Tue, 10 Sep 2019 03:03:44 +0000 (04:03 +0100)]
jquery.color: Merge $.colorUtil back into this module

I split this out of it back in 2011 with 83a7822df7bd0c.

I don't remember why. I think it had something to do with
Special:JavaScriptTest where I wanted to do something with colors.
Having those functions is useful in theory, but that doesn't require
its own module.

Change-Id: I8815d32c7072da83ddb9fbf955534d1f954692ba

4 years agoMerge "Throw if Redis::SERIALIZER_IGBINARY is not defined"
jenkins-bot [Wed, 11 Sep 2019 04:03:14 +0000 (04:03 +0000)]
Merge "Throw if Redis::SERIALIZER_IGBINARY is not defined"

4 years agoMerge "resourceloader: Replace Xml::encodeJsCall by encodeJsonForScript"
jenkins-bot [Wed, 11 Sep 2019 03:54:06 +0000 (03:54 +0000)]
Merge "resourceloader: Replace Xml::encodeJsCall by encodeJsonForScript"

4 years agoAdd general messagebox (neutral) styling to shared.css
Volker E [Tue, 10 Sep 2019 23:38:46 +0000 (16:38 -0700)]
Add general messagebox (neutral) styling to shared.css

Bug: T232553
Change-Id: I83105bb5e30d4440284ac42d6ca6a2dc32b21704

4 years agoSpecialExpandTemplates: Add semantic 'errorbox' class to error
Volker E [Tue, 10 Sep 2019 23:16:26 +0000 (16:16 -0700)]
SpecialExpandTemplates: Add semantic 'errorbox' class to error

Bug: T232414
Change-Id: Idb493c76f0aec960afc589ce6a32736432c751e1

4 years agoMerge "Deprecate $wgContentHandlerUseDB"
jenkins-bot [Tue, 10 Sep 2019 20:09:06 +0000 (20:09 +0000)]
Merge "Deprecate $wgContentHandlerUseDB"

4 years agoMerge "api: Make ApiQuery(All)DeletedRevisions accessible to everyone"
jenkins-bot [Tue, 10 Sep 2019 19:55:28 +0000 (19:55 +0000)]
Merge "api: Make ApiQuery(All)DeletedRevisions accessible to everyone"

4 years agoMerge "Fix property filter for ApiQueryStashImageInfo::getPropertyNames"
jenkins-bot [Tue, 10 Sep 2019 19:55:22 +0000 (19:55 +0000)]
Merge "Fix property filter for ApiQueryStashImageInfo::getPropertyNames"

4 years agoDeprecate $wgContentHandlerUseDB
Brad Jorsch [Tue, 10 Sep 2019 18:22:18 +0000 (14:22 -0400)]
Deprecate $wgContentHandlerUseDB

This was a "wait for DB schema change" feature flag that stuck around
for far too long.

Also of note is that setting $wgMultiContentRevisionSchemaMigrationStage
above SCHEMA_COMPAT_OLD, which has been the default since MW 1.32, will
already raise an exception if this is false.

Bug: T148137
Change-Id: I9a234fc55336660e9f24cac81db88a945348a1a5

4 years agoMerge "Allow partially blocked users to tag unrelated revisions"
jenkins-bot [Tue, 10 Sep 2019 19:00:47 +0000 (19:00 +0000)]
Merge "Allow partially blocked users to tag unrelated revisions"

4 years agoMerge "dispatchUser() should use a 302 http status code"
jenkins-bot [Tue, 10 Sep 2019 18:53:05 +0000 (18:53 +0000)]
Merge "dispatchUser() should use a 302 http status code"

4 years agoMerge "Display error if Installer->execute() doesn't return a good status object"
jenkins-bot [Tue, 10 Sep 2019 18:42:57 +0000 (18:42 +0000)]
Merge "Display error if Installer->execute() doesn't return a good status object"

4 years agoMerge "Add filter to `Special:BlockList` to exclude indefinite blocks"
jenkins-bot [Tue, 10 Sep 2019 18:24:23 +0000 (18:24 +0000)]
Merge "Add filter to `Special:BlockList` to exclude indefinite blocks"

4 years agoMerge "Deprecate the GetBlockedStatus hook"
jenkins-bot [Tue, 10 Sep 2019 18:23:54 +0000 (18:23 +0000)]
Merge "Deprecate the GetBlockedStatus hook"

4 years agoFix property filter for ApiQueryStashImageInfo::getPropertyNames
Umherirrender [Thu, 9 May 2019 19:36:30 +0000 (21:36 +0200)]
Fix property filter for ApiQueryStashImageInfo::getPropertyNames

The property filter in ApiQueryStashImageInfo was only applied on calls
from the class itself. The call from UploadBase does not applied the
filter and than after successful upload of a stashed file the attributes
like user or mediatype are shown, but empty and not needed.

Change-Id: I89b2a935bacea81b4c8807d7ee77021377c8635c

4 years agodispatchUser() should use a 302 http status code
sbassett [Tue, 27 Aug 2019 20:55:39 +0000 (15:55 -0500)]
dispatchUser() should use a 302 http status code

dispatchUser() in SpecialRedirect.php should use a 302 http
status code instead of a 301 to avoid certain caching issues.

Bug: T231386
Change-Id: Idb0cb21cc81d73bb9f77fc211af9cfd8b4f71e7d

4 years agoMerge "resourceloader: Remove comment about XmlJsCode wrapper"
jenkins-bot [Tue, 10 Sep 2019 16:14:45 +0000 (16:14 +0000)]
Merge "resourceloader: Remove comment about XmlJsCode wrapper"

4 years agoMerge "specials: Declare dynamic properties"
jenkins-bot [Tue, 10 Sep 2019 16:06:06 +0000 (16:06 +0000)]
Merge "specials: Declare dynamic properties"

4 years agoMerge "widget: Improve properties documentation"
jenkins-bot [Tue, 10 Sep 2019 16:04:18 +0000 (16:04 +0000)]
Merge "widget: Improve properties documentation"

4 years agoAllow partially blocked users to tag unrelated revisions
David Barratt [Fri, 19 Jul 2019 01:02:54 +0000 (21:02 -0400)]
Allow partially blocked users to tag unrelated revisions

Currently, partially blocked users cannot add, modify, or remove tags from
revisions that they are not blocked from. This change allows them to modify
the tags on those pages.

Bug: T221444
Change-Id: I737ed82f9c5139b45922cb4ea9111b4fdc7c1c61

4 years agoMerge "Restore FileBackendStoreOpHandle::call"
jenkins-bot [Tue, 10 Sep 2019 15:45:17 +0000 (15:45 +0000)]
Merge "Restore FileBackendStoreOpHandle::call"

4 years agoMerge "Revert "Improve MultiHttpClient connection concurrency and reuse""
jenkins-bot [Tue, 10 Sep 2019 15:39:24 +0000 (15:39 +0000)]
Merge "Revert "Improve MultiHttpClient connection concurrency and reuse""

4 years agoRestore FileBackendStoreOpHandle::call
Daimona Eaytoy [Tue, 10 Sep 2019 13:18:25 +0000 (15:18 +0200)]
Restore FileBackendStoreOpHandle::call

Follows-up eb06fb858e8492453ddb66f9b813e.

The property is still in use, see
https://codesearch.wmflabs.org/core/?q=-%3Ecall%5Cb&i=nope&files=&repos=

and failures at
https://integration.wikimedia.org/ci/job/mediawiki-core-php72-phan-docker/5893/console.

Change-Id: Ic9e72c3ab57cef3dd16c64ce279875df10ba3a14

4 years agoRevert "Improve MultiHttpClient connection concurrency and reuse"
Reedy [Tue, 10 Sep 2019 14:56:38 +0000 (14:56 +0000)]
Revert "Improve MultiHttpClient connection concurrency and reuse"

This reverts commit 46531d62852239f620f7b7c0af1e5747a9006228.

Bug: T232487
Change-Id: I8b1b829197f0f5758a85cb1547e13448d425aed2

4 years agospecials: Declare dynamic properties
Daimona Eaytoy [Tue, 10 Sep 2019 12:30:41 +0000 (14:30 +0200)]
specials: Declare dynamic properties

And also remove a couple of unused properties.

Change-Id: I66ed64627dc475dc85da9d858a19317435d05532

4 years agowidget: Improve properties documentation
Daimona Eaytoy [Tue, 10 Sep 2019 12:05:14 +0000 (14:05 +0200)]
widget: Improve properties documentation

Explicitly declare all dynamic properties. Add docblocks for several
props. Remove the defaults when they're already set in the constructor.
Make TagMultiselectWidget use ?? like other widgets.

Change-Id: I889bf6f9e1bbe381f5bffb8ce1370c9e2e863520

4 years agoexternalstore: deprecate getLBInfo() dependency in ExternalStoreDB
Aaron Schulz [Tue, 27 Aug 2019 07:42:44 +0000 (00:42 -0700)]
externalstore: deprecate getLBInfo() dependency in ExternalStoreDB

Use the cluster and master server info array instead, when possible.

Also add initializeTable() method based on the one in addWiki.php.
This lets some internals be hidden from that script a bit more.

Bug: T231162
Change-Id: I694f12cc800684bcc13351021d9abc9a01bddfe9

4 years agoImprove MultiHttpClient connection concurrency and reuse
Aaron Schulz [Thu, 5 Sep 2019 15:30:36 +0000 (08:30 -0700)]
Improve MultiHttpClient connection concurrency and reuse

Use CURLMOPT_MAX_HOST_CONNECTIONS to enforce concurrent request limits.
This gives better concurrency than using naïve array_chunk() batches, which
were serialized and treated all URLs as pessimistically from the same host.

Allow connection reuse for multi-URL request batches. This avoids overhead
from reconnections and reduces the number of TIME_WAIT handles when many
batch operations happen in a short time frame. Previously, the use of the
CURLOPT_FORBID_REUSE flag meant that connections were cached but never
reused for multi-URL batches (only single-URL batches).

Connection limits can be verified by running large runMulti() batches
in an interactive shell and inspecting netstat for TCP connections.

Bug: T232128
Change-Id: I5c5f1eceb3fdb501a8f22f2b949756065f12379a

4 years agoresourceloader: Replace Xml::encodeJsCall by encodeJsonForScript
Fomafix [Tue, 10 Sep 2019 06:07:57 +0000 (08:07 +0200)]
resourceloader: Replace Xml::encodeJsCall by encodeJsonForScript

Also document that encodeJsonForScript can return false on invalid UTF-8
characters.

Bug: T32956
Change-Id: I9c2fd33fb2130ada67fa70ff176e5488f1a014bf

4 years agoMerge "Add a dedicated Exception for SessionOverflow"
jenkins-bot [Tue, 10 Sep 2019 09:24:45 +0000 (09:24 +0000)]
Merge "Add a dedicated Exception for SessionOverflow"

4 years agomaintenance: Fix broken userOptions maintenance script
Thiemo Kreuz [Tue, 10 Sep 2019 08:46:46 +0000 (10:46 +0200)]
maintenance: Fix broken userOptions maintenance script

Broken via I973cc60 just a few weeks ago.

Change-Id: I9e60b84acf6c2bf751e2e6cb8e97f0a7cba2764d

4 years agoMerge "Add a preference to require email for password resets"
jenkins-bot [Tue, 10 Sep 2019 08:41:00 +0000 (08:41 +0000)]
Merge "Add a preference to require email for password resets"

4 years agoAdd a dedicated Exception for SessionOverflow
Daimona Eaytoy [Sat, 7 Sep 2019 14:21:09 +0000 (16:21 +0200)]
Add a dedicated Exception for SessionOverflow

Instead of setting a custom property and checking via isset + count.

Change-Id: I087eeb2eee414218bbd6023ad1703fde22292281

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Tue, 10 Sep 2019 06:45:12 +0000 (08:45 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Ib122e0da175fc0a3c8ab85bc93c496ef4fb08ff9

4 years agoresourceloader: Remove comment about XmlJsCode wrapper
Fomafix [Tue, 10 Sep 2019 05:30:07 +0000 (07:30 +0200)]
resourceloader: Remove comment about XmlJsCode wrapper

The support for the XmlJsCode wrapper got removed in 23d066618d.

Change-Id: If14065277699aa9cca70107ff0174bd51f757c31

4 years agoMerge "filebackend: remove unneeded is_dir() call in FSFileBackend::doCleanInternal()"
jenkins-bot [Tue, 10 Sep 2019 03:37:43 +0000 (03:37 +0000)]
Merge "filebackend: remove unneeded is_dir() call in FSFileBackend::doCleanInternal()"

4 years agoMerge "filebackend: clean up some comments and remove unused FileBackendStoreOpHandle...
jenkins-bot [Tue, 10 Sep 2019 03:35:33 +0000 (03:35 +0000)]
Merge "filebackend: clean up some comments and remove unused FileBackendStoreOpHandle field"

4 years agoMerge "Cleanup and document some LCStoreDB fields"
jenkins-bot [Tue, 10 Sep 2019 03:32:45 +0000 (03:32 +0000)]
Merge "Cleanup and document some LCStoreDB fields"

4 years agoMerge "Move callers away from Title::GAID_FOR_UPDATE"
jenkins-bot [Tue, 10 Sep 2019 03:32:37 +0000 (03:32 +0000)]
Merge "Move callers away from Title::GAID_FOR_UPDATE"

4 years agofilebackend: remove unneeded is_dir() call in FSFileBackend::doCleanInternal()
Aaron Schulz [Sun, 8 Sep 2019 21:39:52 +0000 (14:39 -0700)]
filebackend: remove unneeded is_dir() call in FSFileBackend::doCleanInternal()

Change-Id: Ia630e2052edd31f0d9b6ed7068497dc4ae66d917

4 years agoDisplay error if Installer->execute() doesn't return a good status object
Reedy [Tue, 10 Sep 2019 02:19:51 +0000 (03:19 +0100)]
Display error if Installer->execute() doesn't return a good status object

Bug: T232425
Change-Id: Ic41acdfd6cdd96a393e0b2af28f69da1ff6653b7