lhc/web/wiklou.git
7 years agoRemove WebRequest::checkSessionCookie() method as being deprecated
Victor Barbu [Wed, 28 Dec 2016 21:41:30 +0000 (23:41 +0200)]
Remove WebRequest::checkSessionCookie() method as being deprecated

Bug: T61113
Change-Id: I5285dbfc47d6429e16b7e7839bf55d48320d0bf0

7 years agoFix wrong class name for ImageGalleryBase in comments
divadsn [Sat, 31 Dec 2016 13:37:59 +0000 (13:37 +0000)]
Fix wrong class name for ImageGalleryBase in comments

This change is part of change 329773.

Change-Id: I2766e2ff3e64a84f52a5d7fa065bbc38280866c1

7 years agoMerge "TitleValue: Include the invalid DB key in the message when throwing"
jenkins-bot [Sat, 31 Dec 2016 11:10:46 +0000 (11:10 +0000)]
Merge "TitleValue: Include the invalid DB key in the message when throwing"

7 years agoRemove doubled title on Special:MIMESearch
Florian [Tue, 24 May 2016 16:56:12 +0000 (18:56 +0200)]
Remove doubled title on Special:MIMESearch

Having a page title (from skin) and the same text in the first
form on that page (directly after the page title) is doubled
and doesn't look very good. This change removes the form title
completely, as it is obvious enough what the form does (the input
has it's own label and the page title is clearly visible).

Follow up: I6c8b0f3be92bc455fe62846508d0b21c778b993d

Change-Id: I56c2f05ebe5b15f50eba6297c39326e1504b8229

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sat, 31 Dec 2016 08:34:10 +0000 (09:34 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I4d073c77288bda2ee9310aa43108a89b87d546cb

7 years agoTitleValue: Include the invalid DB key in the message when throwing
This, that and the other [Sat, 31 Dec 2016 05:30:32 +0000 (16:30 +1100)]
TitleValue: Include the invalid DB key in the message when throwing

The current output "Bad value for parameter $dbkey: invalid DB key" is
useless for actually working out which DB key is to blame.

Bug: T146778
Change-Id: Iaf57e25ab27b5065469c5dc5de0a1b881c48210c

7 years agoImprove strings for the contentmodel log
This, that and the other [Sat, 31 Dec 2016 04:38:47 +0000 (15:38 +1100)]
Improve strings for the contentmodel log

Consistent terminology ("content model" not "contentmodel" or
"Contentmodel"; "change" not "modification"; "non-default" not
"non-standard") and clearer wording.

Change-Id: Ia24f30713588a35d077f52e6b25f59cd8b1c7c2f

7 years agoAdd a 'ChangeUserGroups' hook in Special:Userrights
Justin Du [Sat, 31 Dec 2016 02:39:44 +0000 (20:39 -0600)]
Add a 'ChangeUserGroups' hook in Special:Userrights

Currently, there is no hook that runs before a user's groups are changed. Adding a hook here will allow for action before the groups are changed.

Bug: T49338
Change-Id: I87dbb6a8eb897f4a40215d33d1a0b24af7efa871

7 years agoAdd 'UnblockUser' and 'UnblockUserComplete' hooks to Special:Unblock
Justin Du [Sat, 31 Dec 2016 01:29:34 +0000 (19:29 -0600)]
Add 'UnblockUser' and 'UnblockUserComplete' hooks to Special:Unblock

Currently, there are two hooks ('BlockIP' and 'BlockIPComplete') that run when a user or IP is blocked in Special:Block, but no similar hooks when a user is unblocked in Special:Unblock. Adding these two hooks allows an extension to add and remove criteria about a user/IP unblock before it occurs and for possible action after an unblock is completed.

Bug: T50546
Change-Id: I9d9888dc5f1bb6a8bc62e90e6a423bf56b05173b

7 years agoReplaced &$this with $this
awu42 [Fri, 30 Dec 2016 16:55:28 +0000 (11:55 -0500)]
Replaced &$this with $this

Replaced &$this in includes/Title.php to avoid error in PHP 7.1

Bug: T153505
Change-Id: I76eaae609a817af42687d87bcf0d13da7ba01c05

7 years agoMerge "Make SpecialPage::getLinkRenderer() public"
jenkins-bot [Fri, 30 Dec 2016 15:47:39 +0000 (15:47 +0000)]
Merge "Make SpecialPage::getLinkRenderer() public"

7 years agoAdd ->text() to prevent double HTML escaping
Fomafix [Fri, 30 Dec 2016 15:01:03 +0000 (16:01 +0100)]
Add ->text() to prevent double HTML escaping

wfMessage() without ->text() makes an automatic HTML escaping.
Html::element() makes also a HTML escaping of the content.
This leads to a double escaping and raw HTML in shown on the rendered page.

Change-Id: I68165492c828837f842e7885f557644ca1bb0a8c

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Fri, 30 Dec 2016 09:03:31 +0000 (10:03 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I93d8f62640eb192034ac0caf523f1efa820caefe

7 years agoChange the punctuation of apierror-baddiff
Amire80 [Fri, 30 Dec 2016 06:46:56 +0000 (08:46 +0200)]
Change the punctuation of apierror-baddiff

A comma implies that one of three different things happened.
A full stop makes it clear that one thing happened, and one of
the two reasons in the next sentence was the reason for it.

Change-Id: I79aa8222dd0f6f1af74bc2017c4e058a559ef719

7 years agoMerge "Database: Avoid internal use of ignoreErrors()"
jenkins-bot [Thu, 29 Dec 2016 20:38:26 +0000 (20:38 +0000)]
Merge "Database: Avoid internal use of ignoreErrors()"

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Thu, 29 Dec 2016 08:47:32 +0000 (09:47 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I09da6dbd70b11f52646813bd78e2e42ab61706cb

7 years agoMerge "Replace some usages of &$this in hook parameters"
jenkins-bot [Wed, 28 Dec 2016 21:30:23 +0000 (21:30 +0000)]
Merge "Replace some usages of &$this in hook parameters"

7 years agoReplace some usages of &$this in hook parameters
Victor Barbu [Sun, 25 Dec 2016 19:32:22 +0000 (21:32 +0200)]
Replace some usages of &$this in hook parameters

Affected classes:
- ApiBase
- ApiPageSet
- HistoryPager
- RawAction

Bug: T153505
Change-Id: I0862476a39a1c3206a84f79c1b8f7db41bc47959

7 years agoMerge "Add release notes for recent language fallback additions"
jenkins-bot [Wed, 28 Dec 2016 10:26:04 +0000 (10:26 +0000)]
Merge "Add release notes for recent language fallback additions"

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Wed, 28 Dec 2016 09:19:21 +0000 (10:19 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Ic17ad3e58b95bee1275374e01d1e3dead7662320

7 years agoAdd release notes for recent language fallback additions
Federico Leva [Wed, 28 Dec 2016 08:19:55 +0000 (09:19 +0100)]
Add release notes for recent language fallback additions

Change-Id: Iead6f9160eb19b413104f65bbb9f23b4e65d9865

7 years agoMerge "EditPage: Avoid use of &$this in hooks"
jenkins-bot [Wed, 28 Dec 2016 07:47:35 +0000 (07:47 +0000)]
Merge "EditPage: Avoid use of &$this in hooks"

7 years agoEditPage: Avoid use of &$this in hooks
Justin Du [Tue, 27 Dec 2016 14:36:04 +0000 (08:36 -0600)]
EditPage: Avoid use of &$this in hooks

* This triggers warnings in PHP 7.1

Bug: T153505
Change-Id: I5324a6bfe9e8ed255975104c5de7e7a7011cb741

7 years agoFallback io (Ido) to eo (Esperanto)
Federico Leva [Thu, 1 Dec 2016 13:13:06 +0000 (14:13 +0100)]
Fallback io (Ido) to eo (Esperanto)

Ido is a variant of Esperanto and all its speakers are supposed
to also know Esperanto. Either way, all translators were notified.

https://translatewiki.net/wiki/Thread:Portal_talk:Ido/Use_Esperanto_when_no_translation

From eo, io will inherit the date format, usage of space as digit separator
(consistent with most European languages), hundreds of translations for
magic words and special pages. The namespace gender alias for eo is adapted
to match the io format.

All the io.wiki and io.wiktionary users as listed by WikiStats have been
notified of the discussion individually.

Change-Id: Ia85d2e4b007b523027891bf2c2bccde55916510c

7 years agoLanguage fallback from Pontic (pnt) to Greek (el)
Federico Leva [Tue, 6 Dec 2016 22:35:55 +0000 (23:35 +0100)]
Language fallback from Pontic (pnt) to Greek (el)

The (relative) majority of speakers is estimated to live in Greece
and know Greek; for the others, intelligibility seems assured.
The language fallback was probably forgotten for a mere oversight.

https://translatewiki.net/wiki/Thread:Portal_talk:Pnt/Use_Greek_when_no_translation

In addition to the discussion between translators, every pnt.wiki
user has been alerted individually.

From el, pnt will inherit hundreds of translations for magic words,
namespaces and special page names. $linkTrail, $separatorTransformTable
and $fallback8bitEncoding are currently defined in el but not pnt.
The "ISO 8601" date format will also change definition, but the default
date format is "pnt" which is defined only for pnt.

Change-Id: I0377fff9300a8314cb9172f3be710be5dbce6825

7 years agoReciprocal language fallback for Upper/Lower Sorbian (hsb, dsb)
Federico Leva [Tue, 6 Dec 2016 22:32:05 +0000 (23:32 +0100)]
Reciprocal language fallback for Upper/Lower Sorbian (hsb, dsb)

The two are closely related and are estimated to be 86 % mutually
intelligible in written form.

https://translatewiki.net/wiki/Thread:Portal_talk:Hsb/Fallback_to_dsb
https://translatewiki.net/wiki/Thread:Portal_talk:Dsb/Fallback_to_hsb

The two locales already have identical $dateFormats and largely
overlapping $namespaceGenderAliases and translations of namespaces,
magic words and special pages (often they differ only for diacritics
and only about a dozen of them are defined in one but not the other).

All the users with some edits on dsb.wiki, hsb.wiki, hsb.wiktionary
(as listed by WikiStats) have been notified individually.

Change-Id: Ib806387c875c1bbef180f2b85eae45c050824cb7

7 years agoMerge "mediawiki.ui: Explicitly define input text color"
jenkins-bot [Tue, 27 Dec 2016 12:47:44 +0000 (12:47 +0000)]
Merge "mediawiki.ui: Explicitly define input text color"

7 years agoMerge "Edit stash: Simplify with postWithToken"
jenkins-bot [Tue, 27 Dec 2016 12:30:28 +0000 (12:30 +0000)]
Merge "Edit stash: Simplify with postWithToken"

7 years agoMerge "Adding white background color to thumbimages (i.e. framed images)"
jenkins-bot [Tue, 27 Dec 2016 12:02:14 +0000 (12:02 +0000)]
Merge "Adding white background color to thumbimages (i.e. framed images)"

7 years agoDatabase: Avoid internal use of ignoreErrors()
Kevin Israel [Tue, 27 Dec 2016 10:20:30 +0000 (05:20 -0500)]
Database: Avoid internal use of ignoreErrors()

* Use $tempIgnore in DatabaseBase::tableExists() instead of ignoreErrors().
* DatabasePostgres::reportQueryError(), since 419221e4a71b, calls
  ignoreErrors() before and after rollback(). This is probably not effective
  as a recursion guard (reportQueryError() would be called regardless), and
  for suppressing any log entry or exception, it is redundant (doRollback()
  already sets $tempIgnore when calling query()).
* ignoreErrors(), now unused, can be removed in a separate change set.

Change-Id: Iee768abf996ece213146ab8f64a15a2b407a2e5e

7 years agoRemove incorrect deprecated notice from function WikiRevision::getText()
Subin Siby [Tue, 27 Dec 2016 06:57:06 +0000 (12:27 +0530)]
Remove incorrect deprecated notice from function WikiRevision::getText()

WikiRevision::getText() was wrongly marked deprecated in 1.21.
This has been fixed.

Bug: T152282
Bug: T61113
Change-Id: I3f0e0f7fe38bd4e2001efbe17cdba6bcc90b036f

7 years agomediawiki.ui: Explicitly define input text color
jo12bar [Mon, 26 Dec 2016 18:48:49 +0000 (10:48 -0800)]
mediawiki.ui: Explicitly define input text color

This fixes an issue where certain system themes (i.e. custom Gnome
themes) would set a default & often unreadable text color for any
.mw-ui-input's. The text color is now explicity set to
`@colorGray1`, fixing this issue.

Bug: T148457
Change-Id: I5b31fab317948d231bce5c242af65d6cc7d3f4aa

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Mon, 26 Dec 2016 21:05:43 +0000 (22:05 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I6ba2a0605d635d14f0ab659cd0931ecebffb91f2

7 years agoMerge "moved Exception classes from ContentHandler.php"
jenkins-bot [Mon, 26 Dec 2016 14:40:19 +0000 (14:40 +0000)]
Merge "moved Exception classes from ContentHandler.php"

7 years agomoved Exception classes from ContentHandler.php
mynk-96 [Sat, 24 Dec 2016 11:58:38 +0000 (17:28 +0530)]
moved Exception classes from ContentHandler.php

Bug: T153243
Change-Id: Ieb37b34e76441c5f68ec565c43421c50ac9be7e7

7 years agoReplace &$this with $this in MediaWiki/core hook system
divadsn [Sun, 25 Dec 2016 23:55:27 +0000 (23:55 +0000)]
Replace &$this with $this in MediaWiki/core hook system

Bug: T153505
Change-Id: Ie287adf8b1d384aa651c659a9d385877379a0f11

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sun, 25 Dec 2016 21:02:13 +0000 (22:02 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I32d9a7aec18502403d80f5c48393c5d3abf6c5a9

7 years agoMerge "Add id attribute to error message "mw-error-cannotundelete""
jenkins-bot [Sun, 25 Dec 2016 19:17:20 +0000 (19:17 +0000)]
Merge "Add id attribute to error message "mw-error-cannotundelete""

7 years agoMerge "Fix rendering issues on RecentChanges Special page"
jenkins-bot [Sun, 25 Dec 2016 17:49:52 +0000 (17:49 +0000)]
Merge "Fix rendering issues on RecentChanges Special page"

7 years agoEdit stash: Simplify with postWithToken
Matt Russell [Mon, 27 Jun 2016 08:14:30 +0000 (18:14 +1000)]
Edit stash: Simplify with postWithToken

The original aborting issue in T102863 was fixed in 4a61bb8fb318.

Also moved early return to the top and added early return if the form is
missing, as well as moving code from the useless `onFormLoaded` function into
the main body.

Change-Id: Ie05d267f19ac2801754860fca1cec677167cd5d8

7 years agoMerge "Add populateInterwiki maintenance script"
jenkins-bot [Sun, 25 Dec 2016 11:13:30 +0000 (11:13 +0000)]
Merge "Add populateInterwiki maintenance script"

7 years agoAdd populateInterwiki maintenance script
aude [Thu, 28 Apr 2016 21:22:12 +0000 (17:22 -0400)]
Add populateInterwiki maintenance script

This has been in Wikibase since 2012, but is not at all
specific to Wikibase, and doesn't even require Wikibase
to be enabled.

Having this in core will make it available to more people
and without the hassle of having to clone Wikibase to
use the script.

Bug: T114577
Change-Id: Ib521a65e616bdc4b81206a084289cb4750f0d1f5

7 years agoMerge "Allow PHAN location to be read from PATH"
jenkins-bot [Sun, 25 Dec 2016 01:20:37 +0000 (01:20 +0000)]
Merge "Allow PHAN location to be read from PATH"

7 years agoMerge "Add missing properties to MailAddress class"
jenkins-bot [Sun, 25 Dec 2016 01:15:51 +0000 (01:15 +0000)]
Merge "Add missing properties to MailAddress class"

7 years agoAdd id attribute to error message "mw-error-cannotundelete"
divadsn [Fri, 23 Dec 2016 20:14:05 +0000 (20:14 +0000)]
Add id attribute to error message "mw-error-cannotundelete"

Bug: T20819
Change-Id: I65c241506d53ced2e714f3f6d431c2005263a1c0

7 years agoFix rendering issues on RecentChanges Special page
Phantom42 [Sat, 24 Dec 2016 22:23:23 +0000 (00:23 +0200)]
Fix rendering issues on RecentChanges Special page

Legend is rendered correctly now, fixed namespace checkboxes
behaviour, fixed styles of the changes list.

Bug: T112693
Change-Id: If2c5701587eee50a6d578459f6b38b6f16cd5fe9

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sat, 24 Dec 2016 20:59:52 +0000 (21:59 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Iebe696fe47becb1a8171efb29ed59d2afc35b748

7 years agoAdding white background color to thumbimages (i.e. framed images)
Kaldari [Sat, 24 Dec 2016 06:08:57 +0000 (22:08 -0800)]
Adding white background color to thumbimages (i.e. framed images)

Bug: T154077
Change-Id: I96d2225a9cab05f5e427bdb6a5ee11198af34ff5

7 years agoMake SpecialPage::getLinkRenderer() public
Kunal Mehta [Sat, 24 Dec 2016 01:14:05 +0000 (17:14 -0800)]
Make SpecialPage::getLinkRenderer() public

This makes it easier to be dependency injected and used in areas that
get SpecialPage instances like hooks.

Change-Id: I5cf823695cdc18c5dd9390244af5f3c6bc4f63c0

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Fri, 23 Dec 2016 21:00:18 +0000 (22:00 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: If0fcd4dfa00d5ef0d23155f66dddd7df8d563826

7 years agoAdd missing properties to MailAddress class
addshore [Fri, 23 Dec 2016 15:42:47 +0000 (15:42 +0000)]
Add missing properties to MailAddress class

Change-Id: I6f199cee22678391938637685a1a81771528eac4

7 years agoAllow PHAN location to be read from PATH
addshore [Fri, 23 Dec 2016 14:42:19 +0000 (14:42 +0000)]
Allow PHAN location to be read from PATH

Change-Id: I4ea64eab12f299a13559178c80fe6797d07a5f85

7 years agoRemove &$this usage
Subin Siby [Thu, 22 Dec 2016 10:31:10 +0000 (16:01 +0530)]
Remove &$this usage

Replaced &$this to avoid PHP 7.1 warning of passing $this by reference

Bug: T153505
Change-Id: I3e9bc59dc8cefac0108482afeb9cc9a274e2e54b

7 years agoMerge "Avoid pointless use of isset() in LBFactoryMulti()"
jenkins-bot [Fri, 23 Dec 2016 06:22:12 +0000 (06:22 +0000)]
Merge "Avoid pointless use of isset() in LBFactoryMulti()"

7 years agoRemove duplicate message movepage-max-pages
Brad Jorsch [Fri, 23 Dec 2016 03:55:45 +0000 (22:55 -0500)]
Remove duplicate message movepage-max-pages

Change-Id: I129a9b0e22236bd08daf7d9f7aaeb599a68b0108

7 years agoMerge "build: Karma proxy should convert Host header"
jenkins-bot [Fri, 23 Dec 2016 02:06:16 +0000 (02:06 +0000)]
Merge "build: Karma proxy should convert Host header"

7 years agobuild: Karma proxy should convert Host header
Antoine Musso [Tue, 20 Dec 2016 15:46:20 +0000 (16:46 +0100)]
build: Karma proxy should convert Host header

By default the Karma proxy does requests against 'localhost', however
if the target wiki server has strict host validation (e.g. multiple
virtual hosts or otherwise strictly verified) then requests may fail
since load.php is not found. An example is with MW_SERVER=devwiki.local.

MediaWiki-Vagrant and Wikimedia CI are not affected since they use
'localhost' as the virtual host.

Set Karma proxy to change the hostname accordingly.

Reference:
 https://github.com/karma-runner/karma/issues/1729
 https://github.com/karma-runner/karma/commit/ae05ea4

Bug: T153757
Change-Id: I317d5686aecd1fb6cf6921cdca77670cded85607

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Thu, 22 Dec 2016 20:54:42 +0000 (21:54 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I8f7e0aa4d80a56ad1526ca949310fe81495bf9bb

7 years agoMerge "Fix tests that don't check composer's autoloader"
jenkins-bot [Thu, 22 Dec 2016 18:20:14 +0000 (18:20 +0000)]
Merge "Fix tests that don't check composer's autoloader"

7 years agoMerge "Sync up with Parsoid parserTests."
jenkins-bot [Thu, 22 Dec 2016 17:56:27 +0000 (17:56 +0000)]
Merge "Sync up with Parsoid parserTests."

7 years agoSync up with Parsoid parserTests.
Subramanya Sastry [Thu, 22 Dec 2016 17:29:32 +0000 (11:29 -0600)]
Sync up with Parsoid parserTests.

This now aligns with Parsoid commit 471eb1031510e06a82a18007222396934b34264f

Change-Id: I676b656c9d45c73cfb4e8fdddd23d9c3c85845cd

7 years agoDon't parse language converter markup as a cell parameter in tables.
C. Scott Ananian [Tue, 13 Dec 2016 22:22:25 +0000 (17:22 -0500)]
Don't parse language converter markup as a cell parameter in tables.

Bug: T153140
Change-Id: I799363727162a0f337652b26bb69fe35c61a8553

7 years agoMerge "Align mw.widgets.DateInputWidget to OOjs UI's MediaWiki theme widgets"
jenkins-bot [Thu, 22 Dec 2016 13:49:57 +0000 (13:49 +0000)]
Merge "Align mw.widgets.DateInputWidget to OOjs UI's MediaWiki theme widgets"

7 years agoMerge "Special:RC filter: userExpLevel"
jenkins-bot [Thu, 22 Dec 2016 12:41:45 +0000 (12:41 +0000)]
Merge "Special:RC filter: userExpLevel"

7 years agoAlign mw.widgets.DateInputWidget to OOjs UI's MediaWiki theme widgets
Volker E [Fri, 28 Oct 2016 02:23:49 +0000 (19:23 -0700)]
Align mw.widgets.DateInputWidget to OOjs UI's MediaWiki theme widgets

Aligning mw.widgets.DateInputWidget to improved color palette and to
similar MediaWiki theme widgets. Removing distinction of theme specific
styles for now. Introducing transitions in several places to improve
user experience and changing CalendarWidget to `box-sizing: border-box`
to enable border on IE 8.

Bug: T149270
Change-Id: I6b5b99f444a02f68933c85ccd2b8898d3a8758bf

7 years agoFix tests that don't check composer's autoloader
Aleksey Bekh-Ivanov (WMDE) [Wed, 21 Dec 2016 15:06:57 +0000 (16:06 +0100)]
Fix tests that don't check composer's autoloader

Tests were failing if class cannot be loaded using `\AutoLoader` but can be loaded by composer's autoloader.

Change-Id: I005c9d99245f4733a9666c4bfe9e39baeaad3960

7 years agoMerge "Title: Fix subpage move error reporting"
jenkins-bot [Thu, 22 Dec 2016 09:54:07 +0000 (09:54 +0000)]
Merge "Title: Fix subpage move error reporting"

7 years agoMerge "Remove FileRepoStatus references"
jenkins-bot [Thu, 22 Dec 2016 05:58:04 +0000 (05:58 +0000)]
Merge "Remove FileRepoStatus references"

7 years agoMerge "Add a caught_by context field to exceptions"
jenkins-bot [Thu, 22 Dec 2016 05:50:27 +0000 (05:50 +0000)]
Merge "Add a caught_by context field to exceptions"

7 years agoAdd a caught_by context field to exceptions
Aaron Schulz [Thu, 22 Dec 2016 04:46:06 +0000 (20:46 -0800)]
Add a caught_by context field to exceptions

This distinguishes random errors caught and explicitly logged by various
callers from those that were only caught by the registered exception handler.
The later are likely to have more visibily impact on the user.

Change-Id: Icb4c4e9376270c5475c95cf40708a7ca3e4e0a49

7 years agoAvoid pointless use of isset() in LBFactoryMulti()
Aaron Schulz [Thu, 22 Dec 2016 03:10:04 +0000 (19:10 -0800)]
Avoid pointless use of isset() in LBFactoryMulti()

Change-Id: Ibaaa97a515f627860f6681f204aa1542b1639640

7 years agoMerge "Default block-cookies to 24 hours only"
jenkins-bot [Thu, 22 Dec 2016 02:22:40 +0000 (02:22 +0000)]
Merge "Default block-cookies to 24 hours only"

7 years agoDefault block-cookies to 24 hours only
Sam Wilson [Tue, 20 Dec 2016 12:08:38 +0000 (20:08 +0800)]
Default block-cookies to 24 hours only

Rather than use wgCookieExpiration as the basis for the maximum
life of a block cookie, just use 1 day.

Tests have been updated also.

Bug: T153347
Change-Id: I3447d97af3170308834f365c5c600430f47c66a7

7 years agoAllow HTML tags in LanguageConverter output.
C. Scott Ananian [Fri, 16 Dec 2016 18:41:51 +0000 (13:41 -0500)]
Allow HTML tags in LanguageConverter output.

A "remove HTML tags to avoid disrupting the layout" block is removed
(previously added in f16d1e4ed70cd5a8fa6ae6ca8bb71bfe62f4f47e).

This is a follow-up to I9b099273203482ffb570a5654d8ba50c833e526d.

Bug: T54192
Change-Id: I565fac58b3b0da7bfaedf64f5001c364f52e2244

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Wed, 21 Dec 2016 21:52:02 +0000 (22:52 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I418c1d6ebcf34623dad0fa52674d3c9d52928306

7 years agoMerge "Remove FSRepo"
jenkins-bot [Wed, 21 Dec 2016 19:32:37 +0000 (19:32 +0000)]
Merge "Remove FSRepo"

7 years agoRemove FSRepo
Reedy [Tue, 29 Nov 2016 23:34:47 +0000 (23:34 +0000)]
Remove FSRepo

Change-Id: Id6ca36cfa14077efc3d07fd5129ad9e4cc224e2c

7 years agoRemove FileRepoStatus references
Aaron Schulz [Wed, 21 Dec 2016 06:21:34 +0000 (22:21 -0800)]
Remove FileRepoStatus references

Change-Id: I03190273670f5c255423cf59019cbf12220c5498

7 years agoMerge "Work around &$this usage in SkinTemplate"
jenkins-bot [Wed, 21 Dec 2016 18:58:02 +0000 (18:58 +0000)]
Merge "Work around &$this usage in SkinTemplate"

7 years agoMerge "CoreParserFunctions: Use Title::inNamespace instead of manual comparison"
jenkins-bot [Wed, 21 Dec 2016 18:47:03 +0000 (18:47 +0000)]
Merge "CoreParserFunctions: Use Title::inNamespace instead of manual comparison"

7 years agoSpecial:RC filter: userExpLevel
Stephane Bisson [Tue, 15 Nov 2016 21:35:54 +0000 (16:35 -0500)]
Special:RC filter: userExpLevel

Allows filtering changes based on user
experience level. Supports the following
levels: 'newcomer', 'learner', 'experienced'

Will be used by the ERI project.

Bug: T149637
Change-Id: Ib2ac92925836ce2f3706d898968538aa18d14d5d

7 years agoMerge "Use FileBaseSiteLookup if $wgSitesCacheFile is set."
jenkins-bot [Wed, 21 Dec 2016 12:26:54 +0000 (12:26 +0000)]
Merge "Use FileBaseSiteLookup if $wgSitesCacheFile is set."

7 years agoCoreParserFunctions: Use Title::inNamespace instead of manual comparison
Niklas Laxström [Wed, 21 Dec 2016 09:54:33 +0000 (10:54 +0100)]
CoreParserFunctions: Use Title::inNamespace instead of manual comparison

Change-Id: I60c02bc68ef0d48b1dc66ba0961275feec5789fb

7 years agoMerge "wfMessage: use Message::params() to handle all the message parameters"
jenkins-bot [Wed, 21 Dec 2016 08:18:33 +0000 (08:18 +0000)]
Merge "wfMessage: use Message::params() to handle all the message parameters"

7 years agoMerge "mediawiki.api.watch: Remove the uselang parameter in POST"
jenkins-bot [Wed, 21 Dec 2016 08:06:09 +0000 (08:06 +0000)]
Merge "mediawiki.api.watch: Remove the uselang parameter in POST"

7 years agoMerge "Check for expiry dates in a 10-second window"
jenkins-bot [Wed, 21 Dec 2016 08:04:27 +0000 (08:04 +0000)]
Merge "Check for expiry dates in a 10-second window"

7 years agoMerge "Parser functions now format numbers according to page language (2nd attempt)"
Nikerabbit [Wed, 21 Dec 2016 07:58:25 +0000 (07:58 +0000)]
Merge "Parser functions now format numbers according to page language (2nd attempt)"

7 years agomediawiki.api.watch: Remove the uselang parameter in POST
Fomafix [Wed, 21 Dec 2016 07:21:28 +0000 (08:21 +0100)]
mediawiki.api.watch: Remove the uselang parameter in POST

Since 1f15d1d5828dfbc70d036a52da57460ea0e89175 the response does not contain
any user language specific messages anymore.

Change-Id: I525af200e3d1a48877438a997e78bb5fff297357

7 years agoMerge "Pin eslint version"
jenkins-bot [Wed, 21 Dec 2016 07:20:18 +0000 (07:20 +0000)]
Merge "Pin eslint version"

7 years agoMerge "Fixes and tests for ApiErrorFormatter ILocalizedException handling"
jenkins-bot [Wed, 21 Dec 2016 06:35:12 +0000 (06:35 +0000)]
Merge "Fixes and tests for ApiErrorFormatter ILocalizedException handling"

7 years agoMerge "Do not lose message parameters in UploadFromChunks::verifyChunk()"
jenkins-bot [Wed, 21 Dec 2016 05:59:36 +0000 (05:59 +0000)]
Merge "Do not lose message parameters in UploadFromChunks::verifyChunk()"

7 years agoMerge "ApiWatch: Set 'missing' to true, not 1"
jenkins-bot [Wed, 21 Dec 2016 05:35:33 +0000 (05:35 +0000)]
Merge "ApiWatch: Set 'missing' to true, not 1"

7 years agoMerge "ApiQueryWatchlist: Handle empty wltypes"
jenkins-bot [Wed, 21 Dec 2016 05:34:04 +0000 (05:34 +0000)]
Merge "ApiQueryWatchlist: Handle empty wltypes"

7 years agoCheck for expiry dates in a 10-second window
Sam Wilson [Tue, 20 Dec 2016 12:13:56 +0000 (20:13 +0800)]
Check for expiry dates in a 10-second window

This changes a test of expiry dates to be a 10-second range,
to account for slow testing. For example, a test may start and
set the block's expiry in one second, but by the time it is
reading the value from that block's cookie it can sometimes be
the next second. Making it 10 seconds just gives it more room
for being slow.

Bug: T153527
Change-Id: I5efde7785134a75487d31ef3d8b7b14f53b7f5d0

7 years agoMerge "API: Add action=validatepassword"
jenkins-bot [Wed, 21 Dec 2016 01:41:46 +0000 (01:41 +0000)]
Merge "API: Add action=validatepassword"

7 years agoMerge "ApiTag: Return 'noop' as a boolean in formatversion=2"
jenkins-bot [Wed, 21 Dec 2016 01:37:38 +0000 (01:37 +0000)]
Merge "ApiTag: Return 'noop' as a boolean in formatversion=2"

7 years agoMerge "ApiMove: Fix fatal when attempting to move to a namespace with no talkpages"
jenkins-bot [Wed, 21 Dec 2016 00:58:03 +0000 (00:58 +0000)]
Merge "ApiMove: Fix fatal when attempting to move to a namespace with no talkpages"

7 years agoPin eslint version
Paladox [Sun, 18 Dec 2016 16:29:41 +0000 (16:29 +0000)]
Pin eslint version

We don't want tests failing every time upstream publishing a new
version.

Instead we should bump this manually everytime they update to make sure
no failures happen.

Bug: T118941
Change-Id: I1c76dacd0950100825b85a3791f74c1f6d5477d9

7 years agoWork around &$this usage in SkinTemplate
Geoffrey Mon [Wed, 21 Dec 2016 00:39:07 +0000 (19:39 -0500)]
Work around &$this usage in SkinTemplate

Using &$this triggers warnings with PHP 7.1.

Bug: T153505
Change-Id: I7798b08a356c64796c9aea1273eef88f8678f8d4

7 years agoDo not lose message parameters in UploadFromChunks::verifyChunk()
Matthias Mullie [Thu, 15 Dec 2016 13:34:13 +0000 (14:34 +0100)]
Do not lose message parameters in UploadFromChunks::verifyChunk()

This change is similar to If9ce05045ada1e3f55e031639e4c4ebc2a216de8

Having verifyChunk inside doStashFile was annoying. We'd have to
catch the exception in UploadBase::tryStashFile in order to convert
it to a proper Status object instead of the generic one that is
currently built there.
I felt like UploadBase::tryStashFile shouldn't have to be aware of
this exception, so I moved that catch into a new
UploadFromChunks::tryStashFile.
It makes no sense to perform that check twice when running
tryStashFile, so I got rid of it in doStashFile. But that also
meant we had to add it to a few other (now deprecated) places calling
doStashFile... But they should be cleaned up at some point anyway.

This will make sure we get error output like this:
"code":"filetype-bad-ie-mime",
"key":"filetype-bad-ie-mime",
"params":["text/html"]

instead of:
"code":"stashfailed",
"key":"Cannot upload this file because Internet Explorer would detect it as \"text/html\", which is a disallowed and potentially dangerous file type.",
"params":[]

Bug: T32095
Change-Id: I2fa767656cb3a5b366210042b8b504dc10ddaf68