Commit graph

52767 commits

Author SHA1 Message Date
Fomafix
512aa4e551 Use PHP 7 '??' operator instead of if-then-else
Change-Id: Ia86f8433f30a166d38ee63d0d1745b26740767b9
2018-10-27 23:46:13 +02:00
jenkins-bot
3c25fc54a0 Merge "API: Set robots noindex,nofollow on HTML output" 2018-10-27 05:27:15 +00:00
GeoffreyT2000
19dd287981 Increment edit count for all page moves
The user_editcount field should be incremented for all page moves, not just those done using Special:MovePage. Also, if talk pages and/or subpages are moved along with the base page, they will all be included in the edit count.

Bug: T195550
Change-Id: If75a45e4404ca7162b59bf85fa62a996383658b9
2018-10-26 23:35:01 +00:00
jenkins-bot
03157c14a9 Merge "Localisation updates from https://translatewiki.net." 2018-10-26 20:48:49 +00:00
jenkins-bot
cb4d4c4d8f Merge "Move user_editcount updates to a mergeable deferred update" 2018-10-26 20:32:24 +00:00
jenkins-bot
8e744f6f48 Merge "rdbms: add transaction comment to IDatabase::masterPosWait()" 2018-10-26 20:20:37 +00:00
jenkins-bot
a14a638d41 Merge "rdbms: fix connection reuse logic in LoadBalancer for postgres" 2018-10-26 20:20:32 +00:00
Translation updater bot
529ccd9e02 Localisation updates from https://translatewiki.net.
Change-Id: If9e3c1bf47afc4ee0f0c0afacebf3e32df62fb8c
2018-10-26 21:55:34 +02:00
Tim Starling
a6a017cea4 Fix use of non-existent variable Parser::$config
Fix bug from Ib4394f370cb561ccf195338a1c2e9e465dcb3dc3

Add test.

Bug: T208000
Change-Id: Ia81cca1b64afef2af3cb8dff19719a7f0de9d306
2018-10-25 16:27:55 -07:00
Aaron Schulz
390fce6db1 Move user_editcount updates to a mergeable deferred update
This should reduce excess contention and lock timeouts.
Previously, it used a pre-commit hook which ran just before the
end of the DB transaction round.

Also removed unused User::incEditCountImmediate() method.

Bug: T202715
Depends-on: I6d239a5ea286afb10d9e317b2ee1436de60f7e4f
Depends-on: I0ad3d17107efc7b0e59f1dd54d5733cd1572a2b7
Change-Id: I0d6d7ddd91bbb21995142808248d162e05696d47
2018-10-25 15:32:18 -07:00
Aaron Schulz
a58a9d5fce rdbms: add transaction comment to IDatabase::masterPosWait()
Change-Id: I95aa3b678b76cd06439d1feaba7f09a9c13f8931
2018-10-25 22:07:02 +00:00
jenkins-bot
839e0d6768 Merge "Move timing code out of the try/catch in doPostOutputShutdown()" 2018-10-25 21:45:27 +00:00
jenkins-bot
28aebf8e06 Merge "Silence transaction profiler master queries notices for rollback" 2018-10-25 21:27:08 +00:00
jenkins-bot
14e0c6af83 Merge "rdbms: remove duplicate @params in IDatabase::select()" 2018-10-25 21:17:19 +00:00
jenkins-bot
07bb67286b Merge "filerepo: Inject the WAN cache info FileRepo instances" 2018-10-25 21:17:09 +00:00
jenkins-bot
e3cfa25e71 Merge "Remove unused fields in ForeignDBViaLBRepo" 2018-10-25 21:17:04 +00:00
jenkins-bot
d31ec23f2a Merge "rdbms: Use "mixed" type for $profiler field in LoadBalancer" 2018-10-25 21:16:59 +00:00
Aaron Schulz
8baffeae4f filerepo: Inject the WAN cache info FileRepo instances
Also fixed some intellij IDEA warnings.

Change-Id: I667ed7ef9b49c1da1c8c7c9914daadb7c74b3c79
2018-10-25 20:57:40 +00:00
Aaron Schulz
5ad3a32361 rdbms: Use "mixed" type for $profiler field in LoadBalancer
Change-Id: I8d110d0420a155bb62f4212933d9de2562dc7661
2018-10-25 20:47:28 +00:00
Translation updater bot
d75ac255ad Localisation updates from https://translatewiki.net.
Change-Id: I67923401760c77676ed4e674170335333ac15d15
2018-10-25 22:16:19 +02:00
jenkins-bot
995afd709d Merge "Fix code style in EmailNotification.php" 2018-10-25 19:30:22 +00:00
Alangi Derick
eb251abc62 Fix code style in EmailNotification.php
Code style fix for namespace "use" statement.

Change-Id: I0755481f640aae535c8328824812e25db467e528
2018-10-25 18:57:22 +00:00
jenkins-bot
b00021f0e7 Merge "MailAddress->toString(): Reduce complexity by inverting ifs" 2018-10-25 17:49:09 +00:00
Reedy
da9c742af0 MailAddress->toString(): Reduce complexity by inverting ifs
Change-Id: I5185c0231a0944f36d960211e78cf36273c94d52
2018-10-25 10:30:11 -07:00
Aaron Schulz
0ee8b1652b Move timing code out of the try/catch in doPostOutputShutdown()
Change-Id: Idc24fdaff5bbcb98445cc4dee8c94cc75cd00573
2018-10-25 09:22:30 -07:00
Aaron Schulz
59573879f1 rdbms: avoid transaction status errors from ping() in rollback()
Change-Id: I38658cbf90518d9818824674da371637db15e156
2018-10-25 08:34:39 -07:00
Brad Jorsch
46875ad861 API: Set robots noindex,nofollow on HTML output
There's probably not much benefit in search engines indexing the API
auto-generated help or various random "format=jsonfm" outputs.

On Wikimedia wikis we already have a robots.txt entry denying indexing
of everything under /w/, which includes api.php.

Bug: T207818
Change-Id: I196d401eeb5fcf49844265df41ad3cce83ffdcdf
2018-10-25 09:37:30 -04:00
Roan Kattouw
13a1d8957b WikiPage: Truncate redirect fragments before inserting them into the DB
The rd_fragment field is 255 bytes wide, but there is no limit on how
long title fragments can be. We don't want to let the database silently
truncate the fragment for us, because that can result in invalid UTF-8.
Instead, truncate it before insertion in a UTF-8-aware way.

Bug: T207876
Change-Id: I12745f3f4c174eaced56d80f3661a71d0e5637e6
2018-10-24 17:33:56 -07:00
Kunal Mehta
d47e2822bc Disable $wgEnableImageWhitelist by default
This opens up a hole for administrators to load images from external resources,
potentially leaking user's private information to external servers (IP address,
User-Agent, etc.).

Change-Id: Ie780637b292493e664e4d54671a5bb81046106f4
2018-10-24 15:39:53 -07:00
jenkins-bot
2ce2935c06 Merge "Use a pre-commit hook for change_tag_def count updates" 2018-10-24 22:14:03 +00:00
jenkins-bot
0d2dd9cf37 Merge "Hard deprecate functionality replaced with random_bytes()" 2018-10-24 22:13:06 +00:00
jenkins-bot
23b8bd2ad0 Merge "Hard deprecate non-tidy OutputPage::addWikiText() method" 2018-10-24 22:13:00 +00:00
jenkins-bot
ecee5cd7c7 Merge "Use PHP 7 '??' operator instead of if-then-else" 2018-10-24 21:58:04 +00:00
jenkins-bot
13dba84b6f Merge "Fix PHPDoc type for instance variables and methods" 2018-10-24 21:17:02 +00:00
Aaron Schulz
30d0c54950 Use a pre-commit hook for change_tag_def count updates
Bug: T207881
Change-Id: I3000f14d0e49482b0c90ffcfc494211fbc198a20
2018-10-24 14:09:41 -07:00
jenkins-bot
f57c8f9da0 Merge "Tidy Message::parseAsBlock() by enabling tidy in MessageCache" 2018-10-24 20:35:06 +00:00
C. Scott Ananian
45305de579 Hard deprecate non-tidy OutputPage::addWikiText() method
Tidy will always be enabled with our future parsers.  Hard-deprecate
this method which doesn't tidy the output.

Users of `OutputPage::addWikiText()` will be converted one-by-one to
`OutputPage::addWikiTextAsInterface()` so that any unexpected issues
(deliberately untidy wikitext added, which should be rare) can be
addressed.

Bug: T198214
Depends-On: I778ba9e6efed576605f492c9a073c7203b6c0477
Depends-On: I16529879a3b3aed960c5dc006e2af513d7e91fcd
Change-Id: If8353c37245d9d233d589f82c198668ccb3fce05
2018-10-24 20:05:58 +00:00
jenkins-bot
6605509b81 Merge "Remove deprecated "Parsoid v1 API" compatibility thunks" 2018-10-24 17:45:34 +00:00
jenkins-bot
e044600d9d Merge "HTMLForm: Remove parameters 'notice', 'notice-messages', 'notice-message'" 2018-10-24 17:14:34 +00:00
C. Scott Ananian
518ddd8121 Remove deprecated "Parsoid v1 API" compatibility thunks
These have been deprecated since MW 1.26, and were hard deprecated
in MW 1.32.

Bug: T205029
Change-Id: I387794ecceec8aec1bd01923a71673aa2ddf4282
2018-10-24 09:48:12 -07:00
David Barratt
b3014df3b6 List Partial Block details in ApiQueryBlocks and ApiQueryUserinfo.
The ApiQueryBlocks and ApiQueryUserinfo endpoints will now return whether or not the block is
sitewide or partial. Partial block restrictions can be returned with ApiQueryBlocks.

Bug: T197141
Change-Id: I76eb4cac4dc989c621a00a39996faebd0eb9892c
2018-10-24 16:26:32 +00:00
David Barratt
170c49d61c Update Special:BlockList to present Partial Block details from the database
The Special:BlockList page will be updated to show details from the Partial
Block within the "Block parameters" column. The format of the column will
change to make the details more readable.

Bug: T197143
Change-Id: Ibd79b049d93e427c2d541f8ef93005847482ef59
2018-10-24 16:26:06 +00:00
James D. Forrester
9c32d7bcf4 Follow-up cfa70ea6d0: Fix rebase artefact, also remove preference listing
Change-Id: Ia146f013beba2c82a8f76355b49a4192fbd0ed3b
2018-10-24 07:58:47 -07:00
Aaron Schulz
7f1a2fcd6b rdbms: fix connection reuse logic in LoadBalancer for postgres
Change-Id: Ic4b7af156fbed54aae0a34a0bbba76490cd505e0
2018-10-24 04:35:14 -07:00
Aaron Schulz
935dfc307c Silence transaction profiler master queries notices for rollback
Change-Id: I53f0149cbf69ee2e57fe556668dd6cbfadd79823
2018-10-24 02:51:44 -07:00
jenkins-bot
954b695a85 Merge "Remove old "bulletin board style toolbar" from core" 2018-10-24 05:30:14 +00:00
jenkins-bot
aff39bd7c9 Merge "Enforce partial blocks" 2018-10-24 03:15:39 +00:00
jenkins-bot
728d6e918c Merge "Add partial block details to block-log entries." 2018-10-24 01:45:25 +00:00
jenkins-bot
8da9405898 Merge "Update Special:Block to set Partial Blocks" 2018-10-24 01:45:18 +00:00
jenkins-bot
295ed872b1 Merge "TitlesMultiselectWidget: Add a widget that allows selection of multiple titles" 2018-10-24 01:35:54 +00:00