lhc/web/wiklou.git
7 years agoFix EditPage button accessors on PageObject
WMDE-Fisch [Tue, 18 Apr 2017 09:13:54 +0000 (11:13 +0200)]
Fix EditPage button accessors on PageObject

This will change the accessors to the EditPage in the PageObject to
fit the new DOM when using OOUI.

Bug: T163193
Change-Id: Ic6858d458e2f781c20a101105eb03bd483d6af73

7 years agoMerge "Use .toc instead of #toc as selector for TOC"
jenkins-bot [Tue, 18 Apr 2017 01:47:48 +0000 (01:47 +0000)]
Merge "Use .toc instead of #toc as selector for TOC"

7 years agoUse .toc instead of #toc as selector for TOC
Fomafix [Sat, 15 Apr 2017 06:45:25 +0000 (08:45 +0200)]
Use .toc instead of #toc as selector for TOC

Since 1bf5a652 multiple TOCs are supported.

In CSS the selector #toc is kept for backward compatibility for uses in the
content.

Change-Id: I07036c0d5782420fc127781a15c675fc7e6fafaf

7 years agoMerge "RCFilters UI: Don't steal focus when clicking highlight button"
jenkins-bot [Tue, 18 Apr 2017 00:31:28 +0000 (00:31 +0000)]
Merge "RCFilters UI: Don't steal focus when clicking highlight button"

7 years agoMerge "RCFilters UI: Prevent label from stealing focus on click"
jenkins-bot [Tue, 18 Apr 2017 00:26:47 +0000 (00:26 +0000)]
Merge "RCFilters UI: Prevent label from stealing focus on click"

7 years agoMerge "RCFilters UI: Display 'no results found' if... no results were found!"
jenkins-bot [Tue, 18 Apr 2017 00:26:08 +0000 (00:26 +0000)]
Merge "RCFilters UI: Display 'no results found' if... no results were found!"

7 years agoMerge "RCFilters UI: Fix scrolling to item on tag click"
jenkins-bot [Tue, 18 Apr 2017 00:26:04 +0000 (00:26 +0000)]
Merge "RCFilters UI: Fix scrolling to item on tag click"

7 years agoRCFilters UI: Display 'no results found' if... no results were found!
Moriel Schottlender [Tue, 18 Apr 2017 00:06:47 +0000 (17:06 -0700)]
RCFilters UI: Display 'no results found' if... no results were found!

The "normal" operation of an OO.ui.MenuSelectWidget is to hide itself
if no results are found in the filtering process. However, we want
the menu to remain visible but display a 'no filters found' message
like it did before the migration to a MenuTagMultiselectWidget.

Bug: T163170
Change-Id: Iee7b07961b90ac514a4aa1f7c56019ecd7b4c3cc

7 years agoMerge "Split up LoadBalancer::getReaderIndex() and simplify the code a bit"
jenkins-bot [Mon, 17 Apr 2017 23:48:01 +0000 (23:48 +0000)]
Merge "Split up LoadBalancer::getReaderIndex() and simplify the code a bit"

7 years agoSplit up LoadBalancer::getReaderIndex() and simplify the code a bit
Aaron Schulz [Sun, 16 Apr 2017 03:30:43 +0000 (20:30 -0700)]
Split up LoadBalancer::getReaderIndex() and simplify the code a bit

Change-Id: I4e0b5318ad2c987b2a059c4ef2bda3de14486687

7 years agoRCFilters UI: Fix scrolling to item on tag click
Moriel Schottlender [Mon, 17 Apr 2017 23:30:03 +0000 (16:30 -0700)]
RCFilters UI: Fix scrolling to item on tag click

Bug: T163138
Change-Id: I1f3a5b29eb3d9125faf1d4d27c84b8711fd4fdda

7 years agoRCFilters UI: Don't steal focus when clicking highlight button
Moriel Schottlender [Mon, 17 Apr 2017 23:14:14 +0000 (16:14 -0700)]
RCFilters UI: Don't steal focus when clicking highlight button

Change-Id: I6c41803221fc09ae2676bd09dd734d36f284cc09

7 years agoRCFilters UI: Fix input direction in RTL again
Roan Kattouw [Mon, 17 Apr 2017 22:32:58 +0000 (15:32 -0700)]
RCFilters UI: Fix input direction in RTL again

The style rule for this was in a block for &-search,
which doesn't exist any more.

Change-Id: I1d60cd42df173f7f71085c2a3e5d46bd4bf23ef1

7 years agoMerge "Move DB errors to Rdbms namespace"
jenkins-bot [Mon, 17 Apr 2017 22:06:42 +0000 (22:06 +0000)]
Merge "Move DB errors to Rdbms namespace"

7 years agoRCFilters UI: Prevent label from stealing focus on click
Moriel Schottlender [Mon, 17 Apr 2017 21:19:31 +0000 (14:19 -0700)]
RCFilters UI: Prevent label from stealing focus on click

The filter options' labels are set as "label for" the checkbox
which means that by default they "give" the focus away to the
checkbox when clicked. However, we don't want that behavior so
that we can continue arrow movement through the filter option
items rather than the DOM elements. Also, the checkbox prevents
defaults on click as well as it is.

Change-Id: I9758b0dacd8cd647ec5e3e623edc66e1d7f7420a

7 years agoMerge "Clarify getLaggedReplicaMode()/laggedReplicaUsed() in LoadBalancer"
jenkins-bot [Mon, 17 Apr 2017 20:58:17 +0000 (20:58 +0000)]
Merge "Clarify getLaggedReplicaMode()/laggedReplicaUsed() in LoadBalancer"

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Mon, 17 Apr 2017 19:54:55 +0000 (21:54 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I6518eb7aa39e3933714d2df77f881a0929196d71

7 years agoMerge "RCFilters: Remove 'overflow:hidden' from filter header"
jenkins-bot [Mon, 17 Apr 2017 18:19:02 +0000 (18:19 +0000)]
Merge "RCFilters: Remove 'overflow:hidden' from filter header"

7 years agoMerge "Support GENDER in the message "sp-contributions-userrights""
jenkins-bot [Mon, 17 Apr 2017 16:19:57 +0000 (16:19 +0000)]
Merge "Support GENDER in the message "sp-contributions-userrights""

7 years agoChanged "modified" to "edited"
Amire80 [Mon, 17 Apr 2017 14:14:26 +0000 (17:14 +0300)]
Changed "modified" to "edited"

There were two messages that said "This page was last modified etc.".
They are now "This page was last edited". The word "modify" is used
elsewhere in MediaWiki messages for things other than editing a page,
like uploaded files, databases, and configuration, whereas actual
pages are edited and not modified.

Change-Id: I79b68bbec35f7747cd2a27c1a29e154139e3ab76

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Mon, 17 Apr 2017 07:57:10 +0000 (09:57 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Id03227c4e4d8963db6cd44ee0bde953dbe2128c6

7 years agoMerge "EditPage: Make input and button widgets infusable"
jenkins-bot [Sun, 16 Apr 2017 20:06:34 +0000 (20:06 +0000)]
Merge "EditPage: Make input and button widgets infusable"

7 years agoMerge "Convert various FormActions to OOUI"
jenkins-bot [Sun, 16 Apr 2017 19:30:55 +0000 (19:30 +0000)]
Merge "Convert various FormActions to OOUI"

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sun, 16 Apr 2017 07:43:40 +0000 (09:43 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Ib5b863d0778647034f75e65c45e4a10986ec1a3d

7 years agoEditPage: Make input and button widgets infusable
Ed Sanders [Sat, 15 Apr 2017 12:56:48 +0000 (13:56 +0100)]
EditPage: Make input and button widgets infusable

This will allow gadget developers greater control, e.g. disabling.

Change-Id: I9a21cd2dd3fc7695fc09632b844cc1afd0db0355

7 years agoChange File namespace name
Pikne [Wed, 12 Apr 2017 06:33:03 +0000 (06:33 +0000)]
Change File namespace name

Set File namespace name for Estonian to literal translation "Fail" ('file') and set previous name "Pilt" ('image') as a namespace alias.

Bug: T162744
Change-Id: Id9616825f8335f512ccfeca167ddeef42d0220c3

7 years agoMove DB errors to Rdbms namespace
Aaron Schulz [Fri, 24 Feb 2017 16:17:16 +0000 (08:17 -0800)]
Move DB errors to Rdbms namespace

Change-Id: I463bd86123501abc68fdb78b4cda6110f7af2549

7 years agoSupport GENDER in the message "sp-contributions-userrights"
Matěj Suchánek [Sat, 15 Apr 2017 15:21:10 +0000 (15:21 +0000)]
Support GENDER in the message "sp-contributions-userrights"

Bug: T130960
Change-Id: Iab6418c6c60c94a0c77e25243e83d1a13b7ca6e0

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sat, 15 Apr 2017 07:56:12 +0000 (09:56 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I077d94de0c0681f31bac6aab7257151eb8b76fec

7 years agoClarify getLaggedReplicaMode()/laggedReplicaUsed() in LoadBalancer
Aaron Schulz [Fri, 14 Apr 2017 01:59:39 +0000 (18:59 -0700)]
Clarify getLaggedReplicaMode()/laggedReplicaUsed() in LoadBalancer

Change-Id: I4ea9033d2d643c6758c49f34a69c9837598eea33

7 years agomedia: Capture stderr when running 'convert --version'
Antoine Musso [Fri, 14 Apr 2017 14:51:27 +0000 (16:51 +0200)]
media: Capture stderr when running 'convert --version'

At Wikimedia, $wgImageMagickConvertCommand points to a shell wrapper
that invokes ImageMagick convert with:

  firejail --profile=/etc/firejail/mediawiki-converters.profile

firejail emits to stderr an information message:

  Reading profile /etc/firejail/mediawiki-converters.profile

That ends up in HHVM stderr and is populated up to logstash as an error.

MediaWiki does check imagemagick version by running `convert -version`,
switch from wfShellExec() to wfShellExecWithStderr().

Bug: T158649
Change-Id: I78d1ef59533c605f59b42e10556bb595d6c2cc15

7 years agobuild: Update karma to 1.5.0, karma-firefox-launcher to 1.0.1
Paladox [Mon, 20 Mar 2017 19:25:36 +0000 (19:25 +0000)]
build: Update karma to 1.5.0, karma-firefox-launcher to 1.0.1

karma:
 Changelog at https://github.com/karma-runner/karma/releases
 https://github.com/karma-runner/karma/compare/v1.1.0...v1.5.0

karma-firefox-launcher:
 Changelog at https://github.com/karma-runner/karma-firefox-launcher/blob/master/CHANGELOG.md#101-2017-03-04
 https://github.com/karma-runner/karma-firefox-launcher/compare/v1.0.0...v1.0.1

Karma v1.1.1 added use of `<script crossorigin="anonymous">` for
the urls it initially loads. While most requests will be done by
MW itself directly (and served locally via the proxy at /w/) the
initial request cannot come from the proxy and is loaded from wgServer
directly. Therefore we need to set crossOriginAttribute=false to override
the new default that v1.1.1 introduced.

Change-Id: I9f5067b949c0a77e46f47c2a110a7b5df5953fda

7 years agoMerge "phpunit: Make LogFormatterTest less slow"
jenkins-bot [Sat, 15 Apr 2017 02:11:02 +0000 (02:11 +0000)]
Merge "phpunit: Make LogFormatterTest less slow"

7 years agoMerge "qunit: Improve testrunner logging for pending ajax"
jenkins-bot [Sat, 15 Apr 2017 02:06:33 +0000 (02:06 +0000)]
Merge "qunit: Improve testrunner logging for pending ajax"

7 years agoMerge "Add grep infos to Parser::getImageParams"
jenkins-bot [Sat, 15 Apr 2017 00:37:35 +0000 (00:37 +0000)]
Merge "Add grep infos to Parser::getImageParams"

7 years agoqunit: Improve testrunner logging for pending ajax
Timo Tijhof [Sat, 15 Apr 2017 00:12:06 +0000 (17:12 -0700)]
qunit: Improve testrunner logging for pending ajax

* Move `restoreWarnings()` in tearDown() to the mirrored location
  of related code in setUp().

* Ensure that accidentally calling `suppressWarnings()` twice will
  not wipe out the original reference indefinitely. If it was
  already set, subsequent calls should do nothing instead of
  overwriting them again so that recovery is still possible.

* Log all ajax requests logged during the test, not just the
  one currently still pending. This should avoid situations
  where we throw "Pending ajax requests" but no information
  is logged about which requests those might be.

Change-Id: I900ad98c4c8520bdd6ae00a24ac82272f3becfee

7 years agophpunit: Make LogFormatterTest less slow
Timo Tijhof [Fri, 14 Apr 2017 23:13:39 +0000 (16:13 -0700)]
phpunit: Make LogFormatterTest less slow

Right now it's quite slow because it reloads LocalisationCache
for every test case.

Change the reload to only happen once for the entire class.

Also use RequestContext instead of wgLang to match logic in
the parent class (MediaWikiLangTestCase).

$ phpunit includes/logging/LogFormatterTest.php
Before
- run 1) Time: 23.56 seconds, Memory: 48.00MB
- run 2) Time: 22.41 seconds, Memory: 48.75MB
After
- run 1) Time: 14.27 seconds, Memory: 47.50MB
- run 2) Time: 13.45 seconds, Memory: 47.25MB

Change-Id: Ia791563ca9094c36782acfe9826def45f2a1d621

7 years agoAdd grep infos to Parser::getImageParams
Umherirrender [Fri, 14 Apr 2017 21:42:15 +0000 (23:42 +0200)]
Add grep infos to Parser::getImageParams

Comments for grep makes searching easier

Change-Id: I98e93baf6bd89df36185d535d6e63c51c6f65bc9

7 years agoFix some LoadBalancer::waitFor*() inconsistencies
Aaron Schulz [Fri, 14 Apr 2017 02:15:42 +0000 (19:15 -0700)]
Fix some LoadBalancer::waitFor*() inconsistencies

* Make sure waitFor() always handles laggedReplicaMode updates,
  even if the actual waiting was deferred until a connection was
  needed.
* Restore the old mWaitForPos in waitForOne()/waitForAll() since
  this do not care about the generic reader index or the sort of
  ChronologyProtector logic related to it.

Change-Id: I0767e9831b8fd7fd115a472354977e3c1e12114a

7 years agoRCFilters: Remove 'overflow:hidden' from filter header
Moriel Schottlender [Fri, 14 Apr 2017 00:10:11 +0000 (17:10 -0700)]
RCFilters: Remove 'overflow:hidden' from filter header

This will make it possible to z-index it on top of the list
for other elements (like the guided tour 'pulsing dot') to appear
on top of the list.

Bug: T162971
Change-Id: Iac3b8eabdeaee009b65c7b0c104179c760705306

7 years agoMerge "RCFilters: Followup I42be06913: Destroy tag widget when removing"
jenkins-bot [Thu, 13 Apr 2017 22:48:50 +0000 (22:48 +0000)]
Merge "RCFilters: Followup I42be06913: Destroy tag widget when removing"

7 years agoRCFilters: Followup I42be06913: Destroy tag widget when removing
Moriel Schottlender [Thu, 13 Apr 2017 22:01:25 +0000 (15:01 -0700)]
RCFilters: Followup I42be06913: Destroy tag widget when removing

Change-Id: Ifa051dd88dd36fa8ab14eacbeaea49f9aa0dbcdc

7 years agojquery.tablesorter: Disable a flaky isoDate test case
Timo Tijhof [Thu, 13 Apr 2017 21:18:22 +0000 (14:18 -0700)]
jquery.tablesorter: Disable a flaky isoDate test case

This one varies by local timezone. To be fixed up later.

Change-Id: I42f3684b721d4c8a9a687adbaf0b4f770c1f057d

7 years agoqunit: Remove test for deprecated jquery.placeholder
Timo Tijhof [Thu, 13 Apr 2017 21:00:24 +0000 (14:00 -0700)]
qunit: Remove test for deprecated jquery.placeholder

It's not very useful and needlessly emits deprecation warnings
which unfortunately cannot be surpressed at runtime.

The test just asserts that a no-op function exists.

Change-Id: I2768ba40191a3c0cc7be6202ffa5bed529eabfee

7 years agoMerge "RCFilters: Adjust to use MenuTagMultiselectWidget"
jenkins-bot [Thu, 13 Apr 2017 20:04:40 +0000 (20:04 +0000)]
Merge "RCFilters: Adjust to use MenuTagMultiselectWidget"

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Thu, 13 Apr 2017 19:57:59 +0000 (21:57 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I69e7808271ea3f7afc65989ab13250d4022a603b

7 years agoRCFilters: Adjust to use MenuTagMultiselectWidget
Moriel Schottlender [Mon, 27 Mar 2017 16:58:29 +0000 (09:58 -0700)]
RCFilters: Adjust to use MenuTagMultiselectWidget

The new widget in OOUI is more stable and easier to manage,
and gives us a few features that we were missing, like
arrow behavior in the menu.

Depends on OOUI release 0.21.0

Bug: T162829
Bug: T159768
Bug: T162709
Bug: T162917
Change-Id: I42be0691304b1e93b4e9c02eba2e3a724a5ffd67
Depends-On: Ic216769f48e4677da5b7274f491aa08a95aa8076

7 years agoMerge "Localize namespaces in Doteli"
jenkins-bot [Thu, 13 Apr 2017 19:08:15 +0000 (19:08 +0000)]
Merge "Localize namespaces in Doteli"

7 years agoMerge "Make LoadBalancer::waitFor() and friends more robust via try/finally"
Krinkle [Thu, 13 Apr 2017 18:33:48 +0000 (18:33 +0000)]
Merge "Make LoadBalancer::waitFor() and friends  more robust via try/finally"

7 years agoLocalize namespaces in Doteli
Sébastien Santoro [Thu, 13 Apr 2017 13:48:11 +0000 (13:48 +0000)]
Localize namespaces in Doteli

Translation authors:
  - @Rameshti (Ram Prasad Joshi)
  - @nirajan_pant (Nirajan Pant)
  - @Janak_bhatta (Janak Bhatta)

Bug: T162872
Change-Id: I3f28ebd5e5486e6e5f3bde7c3cbc42975e26af40

7 years agoMerge "rewording for cascadeprotectedwarning"
jenkins-bot [Thu, 13 Apr 2017 15:06:38 +0000 (15:06 +0000)]
Merge "rewording for cascadeprotectedwarning"

7 years agoMake LoadBalancer::waitFor() and friends more robust via try/finally
Aaron Schulz [Wed, 12 Apr 2017 23:48:40 +0000 (16:48 -0700)]
Make LoadBalancer::waitFor() and friends  more robust via try/finally

Change-Id: I50742752bb94ca17997138b440b911849bcbadf3

7 years agoUpgrade to jQuery v3
Timo Tijhof [Tue, 22 Nov 2016 01:52:30 +0000 (17:52 -0800)]
Upgrade to jQuery v3

Source code:
 https://code.jquery.com/jquery-3.2.1.js
 https://code.jquery.com/jquery-migrate-3.0.0.js

Documentation:
 https://blog.jquery.com/2016/06/09/jquery-3-0-final-released/
 https://jquery.com/upgrade-guide/3.0/

This is not a breaking change because jQuery Migrate covers
all breaking changes.

However some extensions (especially unit tests) may've relied
on undocumented behaviour. For that reason, and due to unresolved
upsteam issues this is still behind a feature flag for now.

It is true by default to ensure this has wide exposure to discover
issues as quickly as possible. If this is not resolved before
the end of the 1.29 release cycle it should be turned off again.

Bug: T124742
Change-Id: I3c3dedaa9a9d449eaa2b7e5d24b4540e7fa421c0

7 years agoMerge "resourceloader: Fold legacy modules into base modules request"
jenkins-bot [Thu, 13 Apr 2017 01:45:22 +0000 (01:45 +0000)]
Merge "resourceloader: Fold legacy modules into base modules request"

7 years agoMerge "Add comments to ApiBase::isWriteMode()"
jenkins-bot [Thu, 13 Apr 2017 00:29:42 +0000 (00:29 +0000)]
Merge "Add comments to ApiBase::isWriteMode()"

7 years agoAdd comments to ApiBase::isWriteMode()
Aaron Schulz [Wed, 12 Apr 2017 23:17:00 +0000 (16:17 -0700)]
Add comments to ApiBase::isWriteMode()

Change-Id: I3581f5e3055c425367d265a5c57831bb34dd5a2f

7 years agorewording for cascadeprotectedwarning
Zach [Wed, 12 Apr 2017 22:00:06 +0000 (14:00 -0800)]
rewording for cascadeprotectedwarning

Bug: T60228
Change-Id: I2ec4cbe4c552dc095dce0fae0f0b8e4a52f0c6a9

7 years agoMerge "Ensure logo preload transforms urls if needed"
jenkins-bot [Wed, 12 Apr 2017 21:50:07 +0000 (21:50 +0000)]
Merge "Ensure logo preload transforms urls if needed"

7 years agoMerge "RC Filters: Disable defaults for legacy filters in structured UI"
jenkins-bot [Wed, 12 Apr 2017 21:48:10 +0000 (21:48 +0000)]
Merge "RC Filters: Disable defaults for legacy filters in structured UI"

7 years agoEnsure logo preload transforms urls if needed
Timo Tijhof [Wed, 12 Apr 2017 20:43:57 +0000 (13:43 -0700)]
Ensure logo preload transforms urls if needed

Follows-up 5f55e9c9c2a24.

If the logo url is from within /w, then ResourceLoaderSkinModule
will (as it should) apply a file hash query to it.

The preloader didn't do that, so it specified the wrong url.

Refactored SkinModule to make this logic re-usable.

Bug: T100999
Change-Id: I1ba11f7c70d1a725ad72754fee4a3f33c2a4c1be

7 years agoMerge "mw.widgets.Complex*: Fix setDisabled"
jenkins-bot [Wed, 12 Apr 2017 21:16:50 +0000 (21:16 +0000)]
Merge "mw.widgets.Complex*: Fix setDisabled"

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Wed, 12 Apr 2017 19:57:18 +0000 (21:57 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I9d431f5c949ec909d85949436b90ffde42139962

7 years agomw.widgets.Complex*: Fix setDisabled
Prateek Saxena [Wed, 12 Apr 2017 19:27:22 +0000 (00:57 +0530)]
mw.widgets.Complex*: Fix setDisabled

* Check if elements exists before trying to disable them
* Return `this`, as the method is marked as chainable

Follows-up I6747f4e64dd81197bb3e37c09876399f1cb3be07

Bug: T162667
Change-Id: I17665e57537dbed0821bc3226377849eb8388a32

7 years agoMerge "Convert EditPage buttons, checkboxes and summary input to OOUI"
jenkins-bot [Wed, 12 Apr 2017 18:19:00 +0000 (18:19 +0000)]
Merge "Convert EditPage buttons, checkboxes and summary input to OOUI"

7 years agoMerge "Use delete_and_move_reason in content language on move over redirect"
jenkins-bot [Wed, 12 Apr 2017 18:13:52 +0000 (18:13 +0000)]
Merge "Use delete_and_move_reason in content language on move over redirect"

7 years agoMerge "Move Database and subclasses to Rdbms namespace"
jenkins-bot [Wed, 12 Apr 2017 18:07:43 +0000 (18:07 +0000)]
Merge "Move Database and subclasses to Rdbms namespace"

7 years agoMerge "mw.loader: Don't assume var 'loading' assigns before Promise resolves"
jenkins-bot [Wed, 12 Apr 2017 17:52:18 +0000 (17:52 +0000)]
Merge "mw.loader: Don't assume var 'loading' assigns before Promise resolves"

7 years agoMove Database and subclasses to Rdbms namespace
Aaron Schulz [Tue, 7 Feb 2017 04:49:57 +0000 (20:49 -0800)]
Move Database and subclasses to Rdbms namespace

Change-Id: I52bef87512f9ddd155d1f4cc0052f6b7a0db5b42

7 years agomw.loader: Don't assume var 'loading' assigns before Promise resolves
Fomafix [Wed, 12 Apr 2017 05:15:24 +0000 (07:15 +0200)]
mw.loader: Don't assume var 'loading' assigns before Promise resolves

In rare situations the variable loading already assigned with a promise and
the call to loading.map fails with

  TypeError: loading.map is not a function

Change-Id: Ie50bdda229e48b159702fc2a83e641a35d7c850c

7 years agoRemove multiple spaces in PHP files
Fomafix [Wed, 12 Apr 2017 15:25:28 +0000 (17:25 +0200)]
Remove multiple spaces in PHP files

Change-Id: Id9c26ec5ca730a9536f8fdccb8853eb03cbe87a4

7 years agoMerge "Remove some ancient upgrade information from release notes"
jenkins-bot [Wed, 12 Apr 2017 11:45:18 +0000 (11:45 +0000)]
Merge "Remove some ancient upgrade information from release notes"

7 years agoMerge "Preload the logo using link rel="preload" http header"
jenkins-bot [Wed, 12 Apr 2017 06:58:13 +0000 (06:58 +0000)]
Merge "Preload the logo using link rel="preload" http header"

7 years agoMerge "Prevent PHPDBG from issuing notices in unit tests"
jenkins-bot [Wed, 12 Apr 2017 05:56:47 +0000 (05:56 +0000)]
Merge "Prevent PHPDBG from issuing notices in unit tests"

7 years agophpunit: Avoid use of wmf-production host names
Timo Tijhof [Tue, 11 Apr 2017 00:57:16 +0000 (17:57 -0700)]
phpunit: Avoid use of wmf-production host names

* Remove used of 'eqiad' and 'wmnet' in unit tests.

Change-Id: I5bf19b63876e4dc8deaca8cd9907dca0bfa15455

7 years agoPreload the logo using link rel="preload" http header
Gilles Dubuc [Mon, 1 Jun 2015 16:58:42 +0000 (18:58 +0200)]
Preload the logo using link rel="preload" http header

This greatly increases the priority of loading
the logo on browsers that support rel="preload".

Bug: T100999
Change-Id: I0738fcc0a575153dab65016fa87faaa9b8b97a9d

7 years agoConvert EditPage buttons, checkboxes and summary input to OOUI
Florian [Fri, 14 Aug 2015 18:07:35 +0000 (20:07 +0200)]
Convert EditPage buttons, checkboxes and summary input to OOUI

Several methods now have a new implementation using OOjs UI widgets
(ButtonInputWidget/ButtonWidget, CheckboxInputWidget, TextInputWidget).
The existing (public) methods are unchanged. The OOjs UI version is
used by default.

Because this change can cause problems for extensions and on-wiki
scripts depending on the exact HTML, the old version is still available
and can be used by setting $wgOOUIEditPage = false; in LocalSettings.php.
This will be removed later and OOjs UI will become the only option.
To make testing easier, users can also force either mode by adding
&ooui=true or &ooui=false to the action=edit URL.

* EditPage::getSummaryInput() and EditPage::getSummaryInputOOUI()
* EditPage::getCheckboxes() and EditPage::getCheckboxesOOUI()
* EditPage::getCancelLink()
* EditPage::getEditButtons()

Bug: T111088
Co-Authored-By: Amir Sarabadani <ladsgroup@gmail.com>
Co-Authored-By: Florian Schmidt <florian.schmidt.welzow@t-online.de>
Change-Id: I25aa78ac59082789938ecfb5878eb16614392995

7 years agoMerge "Remove "editusercssjs" user right"
jenkins-bot [Wed, 12 Apr 2017 01:29:58 +0000 (01:29 +0000)]
Merge "Remove "editusercssjs" user right"

7 years agoMerge "RCFilters UI: Adjust styles to OOUI's newest release"
jenkins-bot [Wed, 12 Apr 2017 00:08:25 +0000 (00:08 +0000)]
Merge "RCFilters UI: Adjust styles to OOUI's newest release"

7 years agoRCFilters UI: Adjust styles to OOUI's newest release
Moriel Schottlender [Tue, 11 Apr 2017 01:09:58 +0000 (18:09 -0700)]
RCFilters UI: Adjust styles to OOUI's newest release

Slight modificationsfor OOUI 0.21.0

Change-Id: I8b1db97fd7d52a57a7e3bdd13cc7dc4e364b8976

7 years agoUpdate OOjs UI to v0.21.0
Volker E [Tue, 11 Apr 2017 23:41:59 +0000 (16:41 -0700)]
Update OOjs UI to v0.21.0

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

Change-Id: I94d5b7a89551e7d34d53223872ad3005f0ac4a04

7 years agoMerge "objectcache: Complete coverage for newAnything()"
jenkins-bot [Tue, 11 Apr 2017 23:13:33 +0000 (23:13 +0000)]
Merge "objectcache: Complete coverage for newAnything()"

7 years agoMerge "wikibits: Remove methods deprecated since 1.17 and 1.18"
jenkins-bot [Tue, 11 Apr 2017 23:00:36 +0000 (23:00 +0000)]
Merge "wikibits: Remove methods deprecated since 1.17 and 1.18"

7 years agoresourceloader: Fold legacy modules into base modules request
Timo Tijhof [Sun, 10 Apr 2016 02:05:14 +0000 (03:05 +0100)]
resourceloader: Fold legacy modules into base modules request

Follows-up 0ac4f998 (restore "blocking" legacy modules).

After d790562, legacy modules in the top queue were no longer consistently
loaded before the bottom queue due to the top queue being async.

The implied dependency was made explicit by 0ac4f998 by forcing all modules
to wait for legacy modules before executing.

This had the negative side-effect of putting an extra HTTP request between
the startup module request, base modules request, and actual execution
of page modules.

(Indentation aligns with when a request is triggered.)

Before:
 1. Request: Startup module.
   2. Request: Base modules
   3. Request: Legacy modules
     4. Page module request (or local store hit) and execution

After:
 1. Request: Startup module.
   2. Request: Base+legacy modules
     3. Page module request (or local store hit) and execution

This could alternatively be fixed by moving the top queue to be before
the embedded modules and enforcing the embed in a different way.
It could also be fixed by debouncing module load calls so they naturally
end up in the same request as page modules.

However for now I'm addressing this by adding legacy modules to the
list of modules in the initial load request from the startup module.

This was not possible before because the legacy wikibits had dependencies
and base modules cannot have dependencies. Fixed in I7f9f61ea81ad1ef.

Bug: T159911
Change-Id: I54f087655e1cde1b8ff1ca5fe56e82f7f7d80965

7 years agoMerge "interwiki: Remove inappropiate use of wfMemcKey()"
jenkins-bot [Tue, 11 Apr 2017 22:48:27 +0000 (22:48 +0000)]
Merge "interwiki: Remove inappropiate use of wfMemcKey()"

7 years agointerwiki: Remove inappropiate use of wfMemcKey()
Timo Tijhof [Tue, 11 Apr 2017 02:34:38 +0000 (19:34 -0700)]
interwiki: Remove inappropiate use of wfMemcKey()

This is used for lookup in a CDB file or PHP static array.
In neither case is the key created by wfMemcKey() or any other
implementation of BagOStuff::makeKey().

This is already broken if:
* An interwiki prefix were to contain characters not supported by
  Memcached.
* An interwiki prefix and wikiid together are too long for Memcached.
* If the site has wgCachePrefix configured, which overrides the
  wfWikiID() namespace makeKey() normally uses.

dumpInterwiki.php does not use wfMemcKey() either (and should not).

This was simply here as leftover from many rewrites ago, its
only purpose is to create wikiid + prefix joined by colon.

Ref T148958.

Change-Id: I45682133ed593fbb0d66af5a67751f77f15a4a14

7 years agoMerge "resourceloader: Add unit tests for ResourceLoaderImage"
jenkins-bot [Tue, 11 Apr 2017 22:25:33 +0000 (22:25 +0000)]
Merge "resourceloader: Add unit tests for ResourceLoaderImage"

7 years agoresourceloader: Add unit tests for ResourceLoaderImage
Bartosz Dziewoński [Mon, 20 Mar 2017 19:34:21 +0000 (20:34 +0100)]
resourceloader: Add unit tests for ResourceLoaderImage

Follows-up I5b14d65a and I5a563c59.

Change-Id: Id42e1b868c9fe97cdb14b4bc7328947820a7fd94

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Tue, 11 Apr 2017 20:18:15 +0000 (22:18 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I9d8d4197b88a4ded273ec2ed874b0965d9df1bb8

7 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Tue, 11 Apr 2017 20:11:37 +0000 (22:11 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Ib863e1b841bed4ddf5bed7adb27d49cfa4b82ce3

7 years agowikibits: Remove methods deprecated since 1.17 and 1.18
Timo Tijhof [Sun, 10 Apr 2016 02:10:42 +0000 (03:10 +0100)]
wikibits: Remove methods deprecated since 1.17 and 1.18

Keeping only importScript and friends and addOnloadHook for now.

Inline wikiUrlencode logic so that the dependency on mediawiki.util can be
removed, which caused significant performance overhead (See I54f087655e1c).

Follows-up:
68fae478a8 (1.22; deprecation warnings for ua vars)
ec69391a4f (1.22; deprecation warnings for jsMsg)
fcf4934a52 (1.23; deprecation warnings for the rest)

The following have been deprecated since either 1.17 or 1.18. Deprecation
warnings were added in 1.22. Most of these variables have also been replaced
with dummy placeholders in 1.22 so that calling code is silently disabled
instead of causing cascading failures into other code. Anything still using
these variables to date has been broken since at least April 2013.

* User-Agent variables:
  is_gecko, is_chrome_mac, is_chrome, webkit_version, is_safari_win, is_safari,
  webkit_match, is_ff2, ff2_bugs, is_ff2_win, is_ff2_x11, opera95_bugs,
  opera7_bugs, opera6_bugs, is_opera_95, is_opera_preseven, is_opera, ie6_bugs.
  (deprecated since 1.17; warnings and hardcoded to false since 1.22)
  clientPC
  (deprecated since 1.17; warnings added in 1.22)

* DOM manipulation:
  changeText, killEvt, addHandler, hookEvent, addClickHandler, removeHandler,
  getElementsByClassName, getInnerText.
  (deprecated since 1.17; replaced with no-op warning dummies in 1.22)

* Checkbox utilities:
  setupCheckboxShiftClick, addCheckboxClickHandlers.
  (deprecated since 1.17; replaced with no-op warning dummies in 1.22)

* Classic toolbar utilities:
  mwEditButtons, mwCustomEditButtons
  (deprecated since 1.17; replaced with no-op warning dummies in 1.22)

* Misc utilities:
  - injectSpinner, removeSpinner, escapeQuotes, escapeQuotesHTML, jsMsg
    (deprecated since 1.17; replaced with no-op warning dummies in 1.22)
  - addPortletLink, appendCSS, tooltipAccessKeyPrefix,
    tooltipAccessKeyRegexp, updateTooltipAccessKeys
    (deprecated since 1.17; warnings added in 1.22)

Bug: T122755
Change-Id: I7f9f61ea81ad1efa0b5cff79b5e5f4bbe2d401fe

7 years agoCorrecting qqq message about Special:AutoblockList submit button
Kaldari [Tue, 11 Apr 2017 18:30:09 +0000 (11:30 -0700)]
Correcting qqq message about Special:AutoblockList submit button

Change-Id: I6d9c1f4cb223c12ee986848308aa1060499eac48

7 years agoMerge "First version of AutoblockList special page"
jenkins-bot [Tue, 11 Apr 2017 18:05:36 +0000 (18:05 +0000)]
Merge "First version of AutoblockList special page"

7 years agoFirst version of AutoblockList special page
mainframe98 [Mon, 6 Mar 2017 20:09:36 +0000 (21:09 +0100)]
First version of AutoblockList special page

This patch introduces a new special page named AutoblockList.
Its design is reused from Special:BlockList.

Bug: T146414
Change-Id: I811d23c98be749d8df36700b07a295355691af77

7 years agoMerge "API: Optionally include in job queue size in maxlag"
jenkins-bot [Tue, 11 Apr 2017 14:07:11 +0000 (14:07 +0000)]
Merge "API: Optionally include in job queue size in maxlag"

7 years agoRemove "editusercssjs" user right
zppix1 [Thu, 19 Jan 2017 02:37:17 +0000 (20:37 -0600)]
Remove "editusercssjs" user right

Deprecated since MediaWiki1.16

Change-Id: Ic9851d53affe0f4ece7a79f541ec5cb39133b109

7 years agoMerge "chmod -x SpecialNewpages.php"
jenkins-bot [Tue, 11 Apr 2017 04:23:44 +0000 (04:23 +0000)]
Merge "chmod -x SpecialNewpages.php"

7 years agoAPI: Optionally include in job queue size in maxlag
Kunal Mehta [Mon, 10 Apr 2017 06:54:01 +0000 (23:54 -0700)]
API: Optionally include in job queue size in maxlag

maxlag is the default mechanism most bots and libraries use in
determining when to back off due to wiki overload. However these days,
there are other things that should be considered when asking bots to
back off, one of those is job queue size.

For compatibility and simplicity of use, the number of jobs is converted
into something resembling seconds using a configurable factor. We also
output the total number of jobs in the API error output so more
sophisticated clients can do a more advanced back off.

Bug: T160003
Change-Id: Iedae2344a3d93202efbdd1bf807cef6165b6257a

7 years agochmod -x SpecialNewpages.php
Kunal Mehta [Mon, 10 Apr 2017 22:07:49 +0000 (15:07 -0700)]
chmod -x SpecialNewpages.php

This is not an executable script.

Change-Id: I1daa0eff24f5a7b65c2df75f44c0e28d0795d9f6

7 years agoobjectcache: Complete coverage for newAnything()
Timo Tijhof [Mon, 10 Apr 2017 21:41:12 +0000 (14:41 -0700)]
objectcache: Complete coverage for newAnything()

* Fix typo that disabled testNewAnythingNoAccel().
  Follows-up c5a0fa5bed, accidentally committed a local hack
  to disable the test.

* Add missing case other types falling back and no DB.
* Add missing case of no other types and no DB.

Change-Id: If158f21053f0b3741f2625fe4455fdb31955a22f

7 years agoSync up with Parsoid parserTests.txt
Arlo Breault [Mon, 10 Apr 2017 21:13:56 +0000 (17:13 -0400)]
Sync up with Parsoid parserTests.txt

This now aligns with Parsoid commit 906375badbbf3d10455f36d9ecbaa8f66f5e6425

Change-Id: I1a102a4b6988eb972215eb7210a44cdf19d04c47