Commit graph

4116 commits

Author SHA1 Message Date
This, that and the other
db3d429036 Allow change tags to be added via API action=delete
ApiDelete::delete() and ApiDelete::deleteFile() are altered from public
to protected visibility. This is not believed to affect any extensions.

Also get rid of the token variables, as they are not doing anything useful.

Bug: T108564
Change-Id: I6143043dafa6425a0df4baefe970620cbe69466c
2015-10-08 18:34:27 +11:00
Faidon Liambotis
7e20cb51fe Replace XVO with support for the Key HTTP header
MediaWiki currently has support for a header called X-Vary-Options
(XVO), used to communicate to upstream caches more granular cache
variance options than the Vary header can.

The header was envisioned by Tim Starling back in 2008 and implemented
into MediaWiki and Squid 2.0, with those patches submitted to the
squid-dev mailing list at the time:
http://www.squid-cache.org/mail-archive/squid-dev/200802/0085.html
The patches never actually made it into an upstream Squid release,
however, and Squid has since evolved in potentially significant ways.

Wikimedia has since switched to Varnish but XVO was not ported over as
it was deemed too complex at the time; custom VCL was used instead. To
our knowledge, noone else is using XVO in production and certainly not
with recent, up-to-date MediaWiki releases.

There is currently work at IETF's httpbis working group for a "Key"
header that is in concept and implementation very similar to Tim's XVO
header: https://datatracker.ietf.org/doc/draft-fielding-http-key/

Rather than rip XVO out of MediaWiki, replace it with support for the
Key header, as preliminary defined by the draft spec. This is an almost
straight search-and-replace.

No other software (caching proxy or user-agent) currently implements Key
to my knowledge, so this is essentially untested.

Change-Id: I949fc289dd5d48bd34f3b37f7739e2b9cd5db277
2015-10-07 21:26:40 -07:00
Translation updater bot
ef94ca15c8 Localisation updates from https://translatewiki.net.
Change-Id: I64e0e170899ff0395a1ae3e7979a6473f99a7c3f
2015-10-07 21:39:07 +02:00
umherirrender
fb8cc12dcb Whitelist ApiErrorFormatter_BackCompat as class not in camel case
The class name is used in extensions

Change-Id: Idd1435c5997be5b43fdeea636a453e1d675cfb27
2015-10-07 17:35:21 +00:00
Brad Jorsch
2cf39dd2e8 API: Allow generator=recentchanges to generate revids
A quick review of usage on enwiki reveals that people are currently
using generator=recentchanges with prop=revisions, so the generation of
revids is not the default to avoid breaking those clients.

Bug: T113884
Change-Id: Ia91af7099120660dc40230b76896090843985d96
2015-10-07 10:07:43 -07:00
jenkins-bot
f0b51b4200 Merge "API: Add ApiQueryAllRevisions" 2015-10-07 16:38:35 +00:00
jenkins-bot
938cdc3a59 Merge "Use ForeignFileRepo information for foreign uploads" 2015-10-07 16:05:58 +00:00
Mark Holmquist
824e53c6e8 Use ForeignFileRepo information for foreign uploads
This seems like a (slightly) cleaner system. We'll need to change
some documentation and add some configuration, but at least this will
be easier to handle.

Bug: T114765
Change-Id: If962fd3066e25e43e745efd29058eae82195bfb1
2015-10-07 10:55:24 -05:00
Translation updater bot
5654b2d600 Localisation updates from https://translatewiki.net.
Change-Id: I2ea395b34db5dde21a7c7024fe8dd3b410350a44
2015-10-06 21:45:39 +02:00
Brad Jorsch
2516ca03ed API: Add ApiQueryAllRevisions
Bug: T113885
Change-Id: I43bdc1e33945dab27466fc047d78af5e65df1740
2015-10-06 12:32:12 -04:00
Translation updater bot
7ca46c0d19 Merge "Localisation updates from https://translatewiki.net." 2015-10-05 20:03:08 +00:00
jenkins-bot
1569779421 Merge "Update various @params from DatabaseBase to IDatabase" 2015-10-05 19:59:21 +00:00
Translation updater bot
a32c4c0f6a Localisation updates from https://translatewiki.net.
Change-Id: Ic61a81aba3e8c28526a5428ff73ac41f6e1a7d34
2015-10-05 21:50:30 +02:00
Thiemo Mättig
56d2a644f7 Add null to @return tags if a method can return null
Change-Id: I420998351663d92c4a101f61842e40591eebcd5f
2015-10-05 17:53:13 +02:00
Aaron Schulz
0f7893f877 Update various @params from DatabaseBase to IDatabase
Change-Id: I98e44cdffb0fc0d729f69f702799139afb988c20
2015-10-05 05:24:29 +00:00
Translation updater bot
d21c75418d Localisation updates from https://translatewiki.net.
Change-Id: I2c6d6bb15910feb1b8da5565bc27bfe7878bc0e4
2015-10-04 22:02:58 +02:00
Amir E. Aharoni
c37d6549fd Fix Generic.Files.LineLength phpcs failure in 11 files under includes/
Bug: T102614
Change-Id: I0d759be6ef568c2c6f28606d3002484ad77a1830
2015-10-03 17:08:26 +00:00
jenkins-bot
5f71df9a35 Merge "Add page purge limiter" 2015-10-02 22:23:19 +00:00
Translation updater bot
5198ca7689 Localisation updates from https://translatewiki.net.
Change-Id: Iac862f8797a3fb3be6b7be0e2a0cab1bac88b245
2015-10-02 23:30:53 +02:00
Reedy
7fe05a9fb6 Add page purge limiter
Change-Id: I737dc77ce803432b0792f7e49323a29661bc056f
2015-10-02 20:27:44 +00:00
Aaron Schulz
b0630d1b30 Remove redundant ApiQuery::shouldCheckMaxlag
* Parent version already returns true

Change-Id: I118d59492b8dadd3c7128d2c74f6d37216206d0a
2015-10-02 19:09:24 +00:00
Translation updater bot
4e83c417e8 Localisation updates from https://translatewiki.net.
Change-Id: I4096b4a9ea51f480a79d6b07df27c0bce55aa534
2015-10-01 21:22:43 +02:00
S Page
eaa9d32462 API: mention how to get page property names
Mention action=query&list=pagepropnames to get a list of properties in
use.
Also rephrase apihelp-main-param-uselang to use active voice.

To test, visit
  api.php?action=help
  api.php?action=help&modules=query%2Bpagepropnames
  api.php?action=help&modules=query%2Bpageswithprop

Change-Id: Ic13f6c00396aed1a1c016bfcf6a39d621a4ebc06
2015-10-01 10:06:25 -04:00
jenkins-bot
833cbddc99 Merge "API: Remove warning about continuation change" 2015-09-30 21:37:58 +00:00
Brad Jorsch
847f92ca23 API: Remove warning about continuation change
Change-Id: I2a69e8ae7dc7df915ceaaeed740b74d55f9207ce
2015-09-30 19:48:52 +00:00
Translation updater bot
562b579127 Localisation updates from https://translatewiki.net.
Change-Id: I5fc58474ab4bc404a9a74d734e2fe4e61bfaa2ad
2015-09-30 21:46:52 +02:00
Translation updater bot
5f6098850a Localisation updates from https://translatewiki.net.
Change-Id: I91a42f708cd83f7dd52a91641088148add7f9a83
2015-09-29 21:45:20 +02:00
Thiemo Mättig
03f52ea063 Fix incomplete PHPDoc tags in ApiBase
Change-Id: Icb388723e51c8b07fee3900b98795cfe623942ac
2015-09-29 17:01:18 +02:00
Translation updater bot
b85e7331f3 Localisation updates from https://translatewiki.net.
Change-Id: Ibae1e9fa24a63f2465f17ca0e253957f084ddc5f
2015-09-28 22:22:33 +02:00
jenkins-bot
230f2b456b Merge "Avoid CAS errors on double post to ApiOptions" 2015-09-28 20:17:22 +00:00
Siebrand Mazeland
0fdb0ce284 Fix most PHP CodeSniffer warnings in includes/api
Change-Id: I01bb3e4c96d6034a5b6c18728bb0574c710ea9db
2015-09-28 14:24:52 +02:00
Brad Jorsch
3da605261d API: Fix some unclosed tags in en.json
Change-Id: Iaf97f17761b57ed2c202acd5f963e5be60e07730
2015-09-27 16:08:10 -04:00
Translation updater bot
5fc9d9e6f9 Localisation updates from https://translatewiki.net.
Change-Id: I07e7e7b3747d99f9b8e35a66c67962a944436f64
2015-09-27 20:36:58 +02:00
Vivek Ghaisas
c54766586a Fix issues identified by SpaceBeforeSingleLineComment sniff
Change-Id: I048ccb1fa260e4b7152ca5f09b053defdd72d8f9
2015-09-26 23:06:52 +00:00
jenkins-bot
a74baa198c Merge "API: Correct 'from_namespace' logic in ApiQueryBacklinksprop" 2015-09-26 19:04:19 +00:00
Translation updater bot
4fbc3008b4 Localisation updates from https://translatewiki.net.
Change-Id: If14c9f2c908b47b278bdcc455f024b055a9ec47c
2015-09-26 20:50:52 +02:00
Reedy
355e58da2f Re-enable Generic.CodeAnalysis.ForLoopWithTestFunctionCall.NotAllowed
Change-Id: I07b4043163e5d00709f72dbbb3e2a46b17414d1c
2015-09-26 17:45:29 +01:00
Translation updater bot
e063811c3c Localisation updates from https://translatewiki.net.
Change-Id: Ia63ccceda88256df242e36291e45c8e4db0ab0fa
2015-09-25 22:16:38 +02:00
Amir E. Aharoni
c049d9216e Improve the wording of apihelp-parse-param-section
* Change "retrieve" to "parse" (according to Anomie's comments).
* Split the first sentence for easier understanding and translation.
* Rephrase the last sentence about "new"'s validity to be more
  precise and less English-centric.

Change-Id: I71473fb186ded9e9929682d145a2381becf68767
2015-09-25 21:32:44 +03:00
Aaron Schulz
ece85dd20f Avoid CAS errors on double post to ApiOptions
Bug: T95839
Change-Id: I62f8eea31164be1ab0eacf31c494f0b296b367f2
2015-09-24 23:19:06 -07:00
Translation updater bot
25fc4eeb82 Localisation updates from https://translatewiki.net.
Change-Id: I3d916f4015f1885e3ac041c3f780209e0dee35d6
2015-09-24 21:14:52 +02:00
jenkins-bot
1dba068307 Merge "Remove dead code" 2015-09-24 17:52:50 +00:00
jeroendedauw
220e5c4482 Remove unused $pageSet var
Change-Id: Ic9c8bf9ed840703128a4c0e873ef7d70b6155494
2015-09-24 19:06:59 +02:00
jeroendedauw
8cac7794d9 Remove dead code
Change-Id: Iafcb15a8843889bf7fbfb191b64d86e9f8561185
2015-09-24 19:06:19 +02:00
umherirrender
271da88127 Some bugzilla.wikimedia.org -> phabricator.wikimedia.org changes
Changed some old bugzilla links to new phabricator links in comments,
test data and error message. This reduces the need for redirects from
old bugzilla to new phabricator from our source code.

Change-Id: Id98278e26ce31656295a23f3cadb536859c4caa5
2015-09-24 17:17:25 +02:00
Translation updater bot
b5285e26e7 Localisation updates from https://translatewiki.net.
Change-Id: I8ae3ae761cc2dd0e418bc584d8b1c0328a1a9dbb
2015-09-23 21:14:28 +02:00
jenkins-bot
70e760ee4e Merge "Add hook to allow lazy loading of import sources" 2015-09-23 16:30:36 +00:00
Brad Jorsch
462a7baa00 API: Correct 'from_namespace' logic in ApiQueryBacklinksprop
The code for the rdnamespace parameter to prop=redirects was trying to
use a nonexistent rd_from_namespace field when miser mode was not
enabled.

Bug: T113453
Change-Id: I7ef77a01c25fec34623b888f439261423cebdaef
2015-09-23 10:14:07 -04:00
This, that and the other
d3b85592ea Add hook to allow lazy loading of import sources
Currently import sources have to be set into $wgImportSources as part of
wiki startup. This is not practical for the WMF cluster, where we need some
reasonably complex logic to set up the import source structure.

This change allows the import source list to be populated from a new
"ImportSources" hook. This hook is only called when the list of import
sources is actually needed (namely, when a user with relevant permissions
loads Special:Import).

Bug: T17583
Change-Id: Ice9a19cb6dfe53ae72aa71353d0553ee9338f233
2015-09-23 17:54:31 +10:00
Translation updater bot
5ed149d76a Localisation updates from https://translatewiki.net.
Change-Id: I22fc6e0c1af4d2db3c1a7e053a1597764dce8339
2015-09-22 21:50:09 +02:00