Commit graph

42438 commits

Author SHA1 Message Date
Siebrand Mazeland
8a02a4b4fd Call static functions statically in API
Change-Id: I5952acb932c1e7337dc85226a898da3472e799e9
2016-03-08 16:11:02 +00:00
Siebrand Mazeland
33ba3bea02 Use Elvis operator where possible in API
Change-Id: I0a26c04cf2ded2c1bd74d8dabd131ae8e20117f3
2016-03-08 16:10:23 +00:00
Siebrand Mazeland
94afc567d6 Remove unused local variables in API
Change-Id: Ia94ae232308ad47ee88dbd30675cfcbdb6b371ed
2016-03-08 16:52:00 +01:00
Translation updater bot
adaf3d221f Localisation updates from https://translatewiki.net.
Change-Id: I11fb4866b2fc0c5daf9ee639d42feef2cdafe768
2016-03-07 21:59:57 +01:00
jenkins-bot
76c39c6f2c Merge "Improve change content model log entry for page creations" 2016-03-07 19:15:41 +00:00
Kunal Mehta
2b72964015 Improve change content model log entry for page creations
There really isn't a previous content model because the page didn't
exist beforehand, so say the page was created with a non-default
content model.

Bug: T128645
Change-Id: Ibe0b124e3f3ceaaf3775f82e2646b7639a146a42
2016-03-07 10:29:45 -08:00
Translation updater bot
ee683c821e Localisation updates from https://translatewiki.net.
Change-Id: I683765945022afc8b9b4a839ab28f47f79d86f69
2016-03-06 21:51:01 +01:00
jenkins-bot
a3363b95de Merge "Instrument diff timing" 2016-03-05 23:31:25 +00:00
Translation updater bot
7ab19abd82 Localisation updates from https://translatewiki.net.
Change-Id: Ib49bf89dcc309086e521635db1198fe39e46b995
2016-03-05 22:41:56 +01:00
jenkins-bot
448bd26da8 Merge "Don't treat configured but absent engine as executable" 2016-03-05 00:20:43 +00:00
Max Semenik
f4ad20c1d4 Instrument diff timing
Bug: T128697
Change-Id: I748286abac025092abc33b3b7b8a0d3dabafdd25
2016-03-04 15:06:48 -08:00
Max Semenik
44ed77c07e Don't treat configured but absent engine as executable
E.g. if you have $wgExternalDiffEngine = 'wikidiff2' but after
a PHP update you no longer have the module you still shouldn't attempt
to shell out to some nonexistent wikidiff2.

Bug: T74030
Change-Id: I745cd1cb2e152f4fbb95c8f782d70117f8c844f1
2016-03-04 15:06:39 -08:00
jenkins-bot
2f2b4a6849 Merge "SpecialUserlogin: Update main RequestContext in addition to globals" 2016-03-04 21:26:29 +00:00
Translation updater bot
0fcde80db7 Localisation updates from https://translatewiki.net.
Change-Id: I62572d292497e21e7ffcaf6b8ab2524f469360a6
2016-03-04 22:11:18 +01:00
jenkins-bot
e1a5cd121f Merge "Ditch support for original wikidiff" 2016-03-04 21:01:58 +00:00
Max Semenik
356aea3ab6 Ditch support for original wikidiff
It's been unmaintained for a while and does not support
various languages adequately.
Also, document $wgExternalDiffEngine.

Change-Id: Ia8aeffd79d550fb7a1a7121456940446eea8bd4f
2016-03-04 12:47:59 -08:00
jenkins-bot
be619b8386 Merge "Add additional tracking information to mediawiki.searchSuggest" 2016-03-04 20:10:17 +00:00
Erik Bernhardson
c1159337a9 Add additional tracking information to mediawiki.searchSuggest
Adds a few pieces of information to improve tracking of autocomplete
usage.

* When using Special:Search 'go' feature forward wprov parameter to redirect
* Include a data attribute indicating autocomplete location to
  differentiate usage of the header and Special:Search content autocompletes
* Report exact query string that was used for impression-results
* Add handling to allow searchSuggest subscribers to append tracking
  information to generated article links
* Add a new hook, SpecialSearchGoResult, that can either change the url
  redirected to in the 'go' feature or cancel it entirely.

Bug: T125915
Change-Id: Iec7171fcf301f1659d852afa87ce271f468177c1
2016-03-04 11:53:39 -08:00
Timo Tijhof
92ed2104e9 SpecialUserlogin: Update main RequestContext in addition to globals
Change-Id: I835bb77938f7e02c862563ea38341cf5840aa367
2016-03-04 18:52:18 +00:00
jenkins-bot
b3ffeea139 Merge "Follow-up e33d6f45a. Fix some mistakes w/ limit on QueryPage" 2016-03-04 17:59:03 +00:00
jenkins-bot
541b2e7e5b Merge "Revert "Allow auto suggestion for subpages of Special:BotPasswords"" 2016-03-04 16:42:18 +00:00
Anomie
f73cfcc051 Revert "Allow auto suggestion for subpages of Special:BotPasswords"
This is completely wrong. If you're going to auto-complete anything here (which is probably not really necessary), you need to auto-complete the "bot names" for the current user rather than every user name on the wiki.

This reverts commit aa8823ac4b.

Change-Id: I5d477198827c107f947d25dddc2513f12d2bfd62
2016-03-04 16:27:58 +00:00
jenkins-bot
98e0474714 Merge "Revert "Templatize Special:Contributions lines"" 2016-03-04 15:29:30 +00:00
Krinkle
ae42161c84 Revert "Templatize Special:Contributions lines"
Breaks RevisionDelete.

This reverts commit 1bce6db10e.

Change-Id: I8f63e002e34a9d13e2597a27e3dd918a687d1e7c
2016-03-04 15:14:58 +00:00
Arlo Breault
09be5db2b3 Fix parserTests.php script
* Follow up to 60e4f3fd

Change-Id: If1370a720da21c3662fda4100c96b1758ddc1dc0
2016-03-03 16:52:39 -08:00
Brian Wolff
b89e3dd182 Follow-up e33d6f45a. Fix some mistakes w/ limit on QueryPage
Fix some rather embarrassing mistakes. See comments on e33d6f45a.

Also change the behaviour when someone sets an offset higher than
max allowed. Returning a page with 0 results and broken prev/next
links is poor UI imo.

Change-Id: Ibfc983675ae0c600eeccd5e361550e9b5f96f5fd
2016-03-03 15:53:55 -05:00
jenkins-bot
7546dd9490 Merge "Templatize Special:Contributions lines" 2016-03-03 20:30:54 +00:00
jenkins-bot
e5977f6dee Merge "MediaWiki Widgets: Add new SearchInputWidget" 2016-03-03 20:30:49 +00:00
Adam Roses Wight
1bce6db10e Templatize Special:Contributions lines
Bug: T122537
Change-Id: I11aac43de495881e10e393d075a231bd346ea547
2016-03-03 20:11:20 +00:00
jenkins-bot
379bffe905 Merge "Prevent "Failed to create..." warnings when session loading fails" 2016-03-03 17:11:05 +00:00
Florian
18c6615d01 MediaWiki Widgets: Add new SearchInputWidget
SearchInputWidget is similar to a TitleInputWidget, but doesn't has
a visible loading indication, doesn't highlight the first result and
uses the opensearch api endpoint for suggestions, instead of
prefixsearch.

Extra points:
 * Improve documentation of mw.widgets.TitleInputWidget's configuration
   option validateTitle

Bug: T118443
Change-Id: I8b8098041fe2971389fa908d007d2e77255829ec
2016-03-03 16:29:40 +00:00
jenkins-bot
996b7350f3 Merge "Add tags support to patrol, protect, unblock, and undelete" 2016-03-03 16:28:45 +00:00
Timo Tijhof
f58eea9bbd installer: Update main RequestContext when updating $wgLang
Change-Id: I1e3b76b2358a90a551616dc84eb6f2be6bb41c0a
2016-03-03 01:40:01 +00:00
jenkins-bot
7e6a9ce4ad Merge "filebackend: Clean up TempFSFile and fix IDEA errors" 2016-03-03 01:38:05 +00:00
Aaron Schulz
b3c80a0ff5 filebackend: Clean up TempFSFile and fix IDEA errors
Change-Id: I4e25e3bf906fa3a918f4462fac1a6be5e85696aa
2016-03-03 01:25:37 +00:00
Timo Tijhof
98911418c2 CSSMin: Remove file-existance filter in getLocalFileReferences()
Follows-up 8f5cd11d82.

The old getLocalFileReferences() method is no longer used anywhere.
Remove it and rename getAllLocalFileReferences back to it.

Change-Id: I864258aad128ba9b54464c7bc854543f2937f977
2016-03-03 00:16:13 +00:00
Timo Tijhof
570cff1168 resourceloader: Don't cache CSSMin::remap() calls
The output of this function is not deterministic. This function
is what tranforms urls to include content hashes and also embeds
content as data URI. The calls to this function are expected to be
up to date and matching the version hash as constructed by the
current web request.

Previously, the content hash as constructed based on the collective
file hash of all references images was accurate but the generated
css associated with it could be stale.

Unless we abuse MemoizedCallable to take a separate cache buster
(with $localFileRefs?), it's best to remove this as it isn't
a deterministic function and shouldn't be memoized.

Bug: T128668
Change-Id: Icb87ddc585d7320ac48619446bb8b9cbe5f4780e
2016-03-03 00:10:14 +00:00
Gergő Tisza
664ba620e9 Prevent "Failed to create..." warnings when session loading fails
If there is an existing session for a given ID but loading it fails,
there is no point in trying to create a new empty session with that
ID. Just fail silently (the reason for not loading the session
should be logged elsewhere), don't spam the logs and don't slow
down execution by throwing and catching an exception.

Change-Id: I8299872cc29c32cb245686ed0bca6b9a5902cdc1
2016-03-02 15:36:02 -08:00
This, that and the other
c99e3d537e Linker: Avoid passing false to Title::newFromText
This is needed because the call to substr() returns false when the string
is only 1 character long, which occurs when parsing degenerate links like
[[:]] and [[::|foo]].

The seemingly unnecessary test for $match[1] !== '' is for forwards
compatibility with PHP 7.

Bug: T121706
Change-Id: Icc19ee990d01958d64b938d298e9a7e1df7181b5
2016-03-02 23:10:28 +00:00
Timo Tijhof
ee1d97b3cc api: Fix "PHP Notice: Undefined variable: config"
Follows-up 362c220aa1, which split the method up but didn't
re-create a local $config variable.

Change-Id: Ic32ac3c600d0b4d69e8129fa50ea47d9a6a54b20
2016-03-02 21:54:43 +00:00
jenkins-bot
ee6e8ab1bb Merge "Add ContentHandler::supportsCategories method" 2016-03-02 21:24:28 +00:00
jenkins-bot
51fb0db61b Merge "AutoloadGenerator: Account for PHP 5.5 syntax like "self::static"" 2016-03-02 20:22:37 +00:00
Bartosz Dziewoński
667522795b Fix trivial PHPCS violations in */skins/* directories
Due to T127238, files in various */skins/* directories are not checked
by PHPCS. Temporarily removed the exclude rule from phpcs.xml and ran:

  composer fix includes/skins/* tests/phpunit/includes/skins/* tests/phpunit/skins/*

Change-Id: I9240c1cee825920b6634903282be6252cce55686
2016-03-02 21:02:15 +01:00
jenkins-bot
d9898761d0 Merge "Add help link for Special:ChangeContentModel" 2016-03-02 19:25:15 +00:00
Timo Tijhof
d1b4d97a3e AutoloadGenerator: Account for PHP 5.5 syntax like "self::static"
Bug: T128625
Change-Id: I905b549a738b76c07c56ec92f500553c1d48f558
2016-03-02 19:17:42 +00:00
jenkins-bot
315b516cf1 Merge "Allow FSFile objects for src in FileBackend::do*Operations" 2016-03-02 19:14:25 +00:00
Aaron Schulz
a5d903860a Allow FSFile objects for src in FileBackend::do*Operations
Convenience aside, this lets multiwrite backends do async replication for
"store" operations safely, buy keeping a handle to the source file that
prevents it from getting prematurely deleted before the post-send writes
to the secondary backends can happen.

Bug: T91869
Change-Id: I1254de527c47835c35fed6e526b42953c1b2b2ca
2016-03-02 18:49:56 +00:00
Kunal Mehta
b51daafa5b Add help link for Special:ChangeContentModel
Bug: T128556
Change-Id: Id55a463cf6eac4f20e800ae49448e6007f68a3c4
2016-03-02 10:31:01 -08:00
Brad Jorsch
ca4bba6a98 Fix use of RawMessage in Status::getMessage()
RawMessage::__construct() takes a single array of params, it's not
varargs-style like wfMessage().

Change-Id: I63950ee16e359aa2627228350e27d9e94bb6e8ce
2016-03-02 12:36:22 -05:00
aude
437f60f358 Add ContentHandler::supportsCategories method
and check for this in WikiPage::doEditUpdates before
inserting a new CategoryMembershipChangeJob.

Some content models like the Wikibase ones do not
have categories and it's wasteful to add these jobs
for all Wikibase edits.

Bug: T126977
Change-Id: I2c54a4ba1546445dc41101e15cb83a2c6cc2b1c9
2016-03-02 15:20:56 +01:00