4 years agoMerge "resourceloader: Update startup mock in jsduck/eg-iframe"
jenkins-bot [Mon, 10 Sep 2018 21:05:56 +0000 (21:05 +0000)]
Merge "resourceloader: Update startup mock in jsduck/eg-iframe"

4 years agoresourceloader: Update startup mock in jsduck/eg-iframe
Timo Tijhof [Mon, 10 Sep 2018 20:22:49 +0000 (21:22 +0100)]
resourceloader: Update startup mock in jsduck/eg-iframe

Follows-up dec800968eb. Without it, the mediawiki.base.js script
fails upon trying to access 'window.RLQ', which startup.js normally

Bug: T203578
Change-Id: Icfe16948b1b7af47f6e3f058500aa8fa86cafbfc

4 years agoMerge "resources: Register CLDRPluralRuleParser as foreign resource"
jenkins-bot [Mon, 10 Sep 2018 20:36:19 +0000 (20:36 +0000)]
Merge "resources: Register CLDRPluralRuleParser as foreign resource"

4 years agoMerge "build: Update grunt-karma from 2.0.0 to 3.0.0"
jenkins-bot [Mon, 10 Sep 2018 20:20:05 +0000 (20:20 +0000)]
Merge "build: Update grunt-karma from 2.0.0 to 3.0.0"

4 years agoresources: Register CLDRPluralRuleParser as foreign resource
Timo Tijhof [Mon, 10 Sep 2018 19:38:43 +0000 (20:38 +0100)]
resources: Register CLDRPluralRuleParser as foreign resource

The script verifies that our copy still matches the original

Change-Id: Idc982434c066f3b38cb95c6c2aaad7839f261ab1

4 years agoMerge "Consolidate tests for getQueryInfo() and related methods."
jenkins-bot [Mon, 10 Sep 2018 18:41:02 +0000 (18:41 +0000)]
Merge "Consolidate tests for getQueryInfo() and related methods."

4 years agoMerge "mediawiki.notification: Use data-mw-foo instead of data-mw.foo"
jenkins-bot [Mon, 10 Sep 2018 18:38:04 +0000 (18:38 +0000)]
Merge "mediawiki.notification: Use data-mw-foo instead of data-mw.foo"

4 years agoConsolidate tests for getQueryInfo() and related methods.
daniel [Mon, 3 Sep 2018 17:15:37 +0000 (19:15 +0200)]
Consolidate tests for getQueryInfo() and related methods.

This consolidates tests for getQueryInfo, getArchiveQueryInfo,
getSlotQueryInfo, and similar methods that help application logic
be compatible with different migration stages of different aspects
of the revision storage schema.

Bug: T198561
Change-Id: I8e4ae69d7e00721a0af125afaf9a708f7fe99b0a

4 years agoSpecial:Preferences OOUI: Limit `max-width` override to inputs only
Volker E [Mon, 10 Sep 2018 18:08:38 +0000 (11:08 -0700)]
Special:Preferences OOUI: Limit `max-width` override to inputs only

Follow-up to I23e2e98a389a60

Change-Id: I08c41916418349172530204d070f12ef05b9246b

4 years agoMerge "Special:Preferences OOUI: Reduce width of number inputs to 10em "
jenkins-bot [Mon, 10 Sep 2018 16:51:14 +0000 (16:51 +0000)]
Merge "Special:Preferences OOUI: Reduce width of number inputs to 10em "

4 years agobuild: Update grunt-karma from 2.0.0 to 3.0.0
James D. Forrester [Mon, 10 Sep 2018 16:46:17 +0000 (09:46 -0700)]
build: Update grunt-karma from 2.0.0 to 3.0.0

Bug: T194280
Change-Id: Iba043c036c06bebd961896f390063ca9a0129eb2

4 years agoSpecial:Preferences OOUI: Reduce width of number inputs to 10em
Ed Sanders [Sat, 8 Sep 2018 13:33:59 +0000 (14:33 +0100)]
Special:Preferences OOUI: Reduce width of number inputs to 10em

Bug: T181844
Change-Id: I23e2e98a389a609145fa451902e62ca53b83c72e

4 years agomediawiki.notification: Use data-mw-foo instead of data-mw.foo
Fomafix [Mon, 10 Sep 2018 13:53:31 +0000 (15:53 +0200)]
mediawiki.notification: Use data-mw-foo instead of data-mw.foo

All other data-mw attributes or .data() parameters use 'mw-foo' instead
of 'mw.foo'.

Change-Id: I2f7290c8a7ba1684c65b976c17912aa85846de02

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Mon, 10 Sep 2018 07:07:15 +0000 (09:07 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Id9ce66ace073f0974d15610e14c64a565ce575dd

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sun, 9 Sep 2018 08:00:52 +0000 (10:00 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Id50ca26cf97d5d23e50ab7f597d68827c31ac1da

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sat, 8 Sep 2018 07:57:21 +0000 (09:57 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Ia40c19790cdf5164d2bd787d8b0e404b9d578572

4 years agoMerge "Linker: Remove outdated comment"
jenkins-bot [Sat, 8 Sep 2018 01:35:49 +0000 (01:35 +0000)]
Merge "Linker: Remove outdated comment"

4 years agoMerge "Make Schema changes for Partial Blocks"
jenkins-bot [Fri, 7 Sep 2018 22:44:50 +0000 (22:44 +0000)]
Merge "Make Schema changes for Partial Blocks"

4 years agoMake Schema changes for Partial Blocks
David Barratt [Mon, 18 Jun 2018 14:26:20 +0000 (10:26 -0400)]
Make Schema changes for Partial Blocks

Update the database schema so a block can be switched between a sitewide and
partial block. Also add the restrictions table for specifiying the partial

Bug: T197144
Change-Id: I4a725312c4b980a1b14e5ca826069fa2278a5913

4 years agoMerge "build: Bump most devDependencies to latest"
jenkins-bot [Fri, 7 Sep 2018 21:54:47 +0000 (21:54 +0000)]
Merge "build: Bump most devDependencies to latest"

4 years agoMerge "mw.special.preferences/confirmClose: Catch clicks inside OOUI dropdowns"
jenkins-bot [Fri, 7 Sep 2018 20:28:15 +0000 (20:28 +0000)]
Merge "mw.special.preferences/confirmClose: Catch clicks inside OOUI dropdowns"

4 years agomw.special.preferences/confirmClose: Catch clicks inside OOUI dropdowns
Bartosz Dziewoński [Fri, 7 Sep 2018 17:58:34 +0000 (19:58 +0200)]
mw.special.preferences/confirmClose: Catch clicks inside OOUI dropdowns

I did what needed to be done. I am not proud of it.

Bug: T203825
Change-Id: I57d6177cfb50641d8e085a48258e321e4d028712

4 years agoPrevent field margin FOUC when loading OOUI Special:Preferences
Ed Sanders [Fri, 7 Sep 2018 17:46:19 +0000 (18:46 +0100)]
Prevent field margin FOUC when loading OOUI Special:Preferences

Bug: T195986
Change-Id: Ib99db544faa4881efc0d762abf4b80bfcf034f50

4 years agoMerge "Allow dumps to function with MCR in read-new mode."
jenkins-bot [Fri, 7 Sep 2018 17:14:36 +0000 (17:14 +0000)]
Merge "Allow dumps to function with MCR in read-new mode."

4 years agoUnwrap HTML loaded from parser cache
Gergő Tisza [Fri, 7 Sep 2018 08:42:29 +0000 (10:42 +0200)]
Unwrap HTML loaded from parser cache

Partially and temporarily reverts I1641b7995 to deal with cached
HTML the same way the old code did.

Bug: T203716
Change-Id: I29846a6513f6b580b429c0bfe6c310ada50b28bb

4 years agoAllow dumps to function with MCR in read-new mode.
daniel [Fri, 7 Sep 2018 12:12:12 +0000 (14:12 +0200)]
Allow dumps to function with MCR in read-new mode.

This is a temporary fix that forces the dump code to continue to
use the old database schema, even when MCR is in
SCHEMA_COMPAT_READ_NEW mode. This will continue to function until
SCHEMA_COMPAT_WRITE_OLD  mode is disabled.

Bug: T198561
Change-Id: Ic54ee703f47d1843f70fdb7185ac1b098f148680

4 years agoMerge "Make assertFileContains not create files by default"
jenkins-bot [Fri, 7 Sep 2018 07:33:47 +0000 (07:33 +0000)]
Merge "Make assertFileContains not create files by default"

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Fri, 7 Sep 2018 06:37:35 +0000 (08:37 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I668054749e5551c2fe306e08b30935a916e91ae6

4 years agoFix table prefixing in patch-change_tag-change_tag_rc_tag_id.sql
Reedy [Thu, 6 Sep 2018 21:40:19 +0000 (22:40 +0100)]
Fix table prefixing in patch-change_tag-change_tag_rc_tag_id.sql

Change-Id: Id1963e93a43d4b183a31788b645c83e3037f3016
Follows-up: I24609c57e47308d1330a97527f4ea374d0d307ba

4 years agoMerge "Linker: more consistent whitespace parsing in formatLinksInComment"
jenkins-bot [Thu, 6 Sep 2018 19:41:59 +0000 (19:41 +0000)]
Merge "Linker: more consistent whitespace parsing in formatLinksInComment"

4 years agoMerge "API: Use ct_tag_id in queries when applicable"
jenkins-bot [Thu, 6 Sep 2018 19:25:50 +0000 (19:25 +0000)]
Merge "API: Use ct_tag_id in queries when applicable"

4 years agoMerge "Update API tests to comply with the new backend for change tags"
jenkins-bot [Thu, 6 Sep 2018 19:25:44 +0000 (19:25 +0000)]
Merge "Update API tests to comply with the new backend for change tags"

4 years agoMerge "Schema change for reading ct_tag_id instead of ct_tag"
jenkins-bot [Thu, 6 Sep 2018 19:16:45 +0000 (19:16 +0000)]
Merge "Schema change for reading ct_tag_id instead of ct_tag"

4 years agoMerge "Watchlist preferences: Disallow zero value for days/limit"
jenkins-bot [Thu, 6 Sep 2018 19:04:45 +0000 (19:04 +0000)]
Merge "Watchlist preferences: Disallow zero value for days/limit"

4 years agoMerge "Provide a RevisionRecord with the correct title after a move"
jenkins-bot [Thu, 6 Sep 2018 18:42:32 +0000 (18:42 +0000)]
Merge "Provide a RevisionRecord with the correct title after a move"

4 years agoProvide a RevisionRecord with the correct title after a move
Brad Jorsch [Thu, 6 Sep 2018 18:02:53 +0000 (14:02 -0400)]
Provide a RevisionRecord with the correct title after a move

Currently we're creating the null revision for the move before actually
updating the page's title, so when it gets passed through
RevisionRenderer the output uses the old page's title in the <h1>.

To make that null revision have the correct title, let's try simply
updating the page table before creating it instead. The ordering
shouldn't matter since this all happens in an atomic section.

Bug: T203661
Change-Id: I9ebdcbc566b11dea3a9bdd402ea4418c4e51b096

4 years agoMerge "Provide new, unsaved revision to PST to fix magic words."
jenkins-bot [Thu, 6 Sep 2018 17:57:12 +0000 (17:57 +0000)]
Merge "Provide new, unsaved revision to PST to fix magic words."

4 years agoMerge "Update OOUI to v0.28.1"
jenkins-bot [Thu, 6 Sep 2018 17:31:24 +0000 (17:31 +0000)]
Merge "Update OOUI to v0.28.1"

4 years agoLinker: more consistent whitespace parsing in formatLinksInComment
Thiemo Kreuz (WMDE) [Tue, 26 Jun 2018 09:55:21 +0000 (09:55 +0000)]
Linker: more consistent whitespace parsing in formatLinksInComment

Try to paste and preview this in the wikitext as well as the summary
line: [[:a]] [[ :a]]

The wikitext will show "a a", but the summary line will show "a :a".
This is only a display issue, all 4 links correctly link to the
article [[A]].

Change-Id: I08253a6d0b55b9aa3eace519bbdc1a456400bf84

4 years agoWatchlist preferences: Disallow zero value for days/limit
Kosta Harlan [Thu, 6 Sep 2018 14:50:08 +0000 (10:50 -0400)]
Watchlist preferences: Disallow zero value for days/limit

"0" used to work as an undocumented shortcut for "maximum allowed" days/edits,
but this behavior was removed in If6280ad6fbad65909e1d0b2a48344e24d485aca2

This commit brings the preference options into alignment with how the code

Bug: T199049
Bug: T176033
Change-Id: I5ffd87565df6b3c602d1f69d9d63621a817ce8cf

4 years agobuild: Bump most devDependencies to latest
James D. Forrester [Wed, 5 Sep 2018 15:14:54 +0000 (08:14 -0700)]
build: Bump most devDependencies to latest

 grunt-stylelint         0.10.0  →  0.10.1
 karma                    2.0.2  →   3.0.0
 karma-firefox-launcher   1.0.1  →   1.1.0
 karma-qunit              2.0.1  →   2.1.0
 postcss-less             1.1.5  →   2.0.0

This reduces our `npm audit` alerts down to just those from grunt-karma.

Bug: T194280
Change-Id: I7d321dd715db9d214e65ed7197e917cb7c6b14f3

4 years agoProvide new, unsaved revision to PST to fix magic words.
daniel [Wed, 5 Sep 2018 18:03:15 +0000 (20:03 +0200)]
Provide new, unsaved revision to PST to fix magic words.

This injects the new, unsaved RevisionRecord object into the Parser used
for Pre-Save Transform, and sets the user and timestamp on that revision,
to allow {{subst:REVISIONUSER}} and {{subst:REVISIONTIMESTAMP}} to function.

Bug: T203583
Change-Id: I31a97d0168ac22346b2dad6b88bf7f6f8a0dd9d0

4 years agoUpdate OOUI to v0.28.1
Bartosz Dziewoński [Thu, 6 Sep 2018 16:16:37 +0000 (18:16 +0200)]
Update OOUI to v0.28.1

Release notes:

Depends-On: Ief8dd72fa454277c75aee367cd6421a61cff26f8
Change-Id: I8d8d99545151898ae9710c2c2ea46565b28258a3

4 years agoMerge "Allow skins to place notification container for mw.notify"
jenkins-bot [Thu, 6 Sep 2018 16:15:15 +0000 (16:15 +0000)]
Merge "Allow skins to place notification container for mw.notify"

4 years agoAllow skins to place notification container for mw.notify
Moriel Schottlender [Tue, 30 Aug 2016 23:02:18 +0000 (16:02 -0700)]
Allow skins to place notification container for mw.notify

Give skins the ability to place the mw.notification notifications
in a div of their choosing rather than force the container to be
in the content area.

This is particularly useful for skins that deal with multiple
overlays that are created and displayed outside the content div,
which then in turn hides the notification area. A good example of
this behavior is in MobileFrontend's overlays that are created as
siblings to the content div, and so all mw.notify() notifications
are then hidden behind them.

Bug: T143837
Bug: T202466
Change-Id: I5a78949efef88083bdafc4207a6872c76b463970

4 years agoexception: Do not log PHP errors with severity DEBUG or INFO
Timo Tijhof [Fri, 24 Aug 2018 20:13:57 +0000 (21:13 +0100)]
exception: Do not log PHP errors with severity DEBUG or INFO

All PHP errors should be considered by monitoring queries
and error-rate alerts.

Levels DEBUG and INFO are for manual entries that can help in
debugging to see what path a program went down or what the
circumstances were in that code.

There is no reason to spread PHP error-types out on the full range
of PSR-3's DEBUG to ERROR spectrum. Instead, keep it within either
WARNING or ERROR, not below it.

Change-Id: I3f35a519b50aef5b93b9ab7a89a7c3e11d70681f

4 years agoHygiene: Discourage use of $.each
jdlrobson [Fri, 10 Aug 2018 18:02:22 +0000 (11:02 -0700)]
Hygiene: Discourage use of $.each

Even though Array.prototype.forEach only works on arrays, and
$.each is more generic, I think it makes sense to begin discouraging
the usage of $.each now. This can be overriden by ignore lines or
by Array.prototype.forEach compatible lines. This doesn't seem too
much of an ask of engineers and helps future migrations

Bug: T200877
Change-Id: I339cff311a830699c8e32f07cec338a39870c53f

4 years agoMake assertFileContains not create files by default
Stanislav Malyshev [Wed, 5 Sep 2018 22:00:25 +0000 (15:00 -0700)]
Make assertFileContains not create files by default

This makes us miss test bugs like one in

Change-Id: I2a96ed180be216aa615d8506999aa75f04c267bf
Depends-On: Ic85db75c2dba6c1c1fa6fd74dbea64f213609c0d

4 years agoReplace $.proxy by Function.prototype.bind
Fomafix [Tue, 4 Sep 2018 07:51:49 +0000 (09:51 +0200)]
Replace $.proxy by Function.prototype.bind

Also prevent further usage by an eslint rule.

jQuery.proxy is deprecated:
* https://github.com/jquery/jquery/issues/2958

Bug: T200877
Change-Id: I3a4977f9b90c2104db320d2d939a1cbaa1819de0

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Wed, 5 Sep 2018 20:02:00 +0000 (22:02 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Ib115cf8605089085e6b52836daca2e0ae4755642

4 years agoMerge "Don't wait for thumbnails that take long to render"
jenkins-bot [Wed, 5 Sep 2018 19:34:05 +0000 (19:34 +0000)]
Merge "Don't wait for thumbnails that take long to render"

4 years agoDon't wait for thumbnails that take long to render
Gilles Dubuc [Mon, 3 Sep 2018 09:09:08 +0000 (11:09 +0200)]
Don't wait for thumbnails that take long to render

The prerendering job is an optimization, should
thumbnails fail to prerender, they will be reattempted
when a user views them again.

Bug: T203135
Change-Id: I2907bf10a2d22af9beffc530856f458a6adbfe45

4 years agoMerge "Selenium: Daily Jenkins job targeting beta cluster should run only tests that...
jenkins-bot [Wed, 5 Sep 2018 16:22:57 +0000 (16:22 +0000)]
Merge "Selenium: Daily Jenkins job targeting beta cluster should run only tests that pass"

4 years agoMerge "ApiComparePages: Clean up handling of slot deletion"
jenkins-bot [Wed, 5 Sep 2018 15:53:57 +0000 (15:53 +0000)]
Merge "ApiComparePages: Clean up handling of slot deletion"

4 years agoLinker: Remove outdated comment
Bartosz Dziewoński [Wed, 5 Sep 2018 14:39:27 +0000 (16:39 +0200)]
Linker: Remove outdated comment

This talks about references and values the way they worked in PHP 4.
Comment was added in r4927 (b025ad54) in 2004.

Change-Id: I58a74219665bed9e804d7c01f271fd96fd889072

4 years agoMerge "[MCR] Move getSecondaryDataUpdates to the page level"
jenkins-bot [Wed, 5 Sep 2018 12:40:40 +0000 (12:40 +0000)]
Merge "[MCR] Move getSecondaryDataUpdates to the page level"

4 years agoMerge "DifferenceEngine: use a fake title when there's no real title"
jenkins-bot [Wed, 5 Sep 2018 12:18:34 +0000 (12:18 +0000)]
Merge "DifferenceEngine: use a fake title when there's no real title"

4 years agoMerge "SpecialPageExecutor: Use `finally` now that we're in a PHP 5.5+ world"
jenkins-bot [Wed, 5 Sep 2018 05:15:34 +0000 (05:15 +0000)]
Merge "SpecialPageExecutor: Use `finally` now that we're in a PHP 5.5+ world"

4 years agoMerge "mediawiki.api: Use loadMessages in loadMessagesIfMissing"
jenkins-bot [Wed, 5 Sep 2018 05:12:07 +0000 (05:12 +0000)]
Merge "mediawiki.api: Use loadMessages in loadMessagesIfMissing"

4 years agomediawiki.api: Use loadMessages in loadMessagesIfMissing
Fomafix [Tue, 4 Sep 2018 09:56:59 +0000 (11:56 +0200)]
mediawiki.api: Use loadMessages in loadMessagesIfMissing

This removes duplicate code.

Change-Id: I6f4bbb816ec8e20aff164a9128ecdd31eabb1d1f

4 years agoMerge "Make phpunit.php less hackish, and install the listener unconditionally"
jenkins-bot [Wed, 5 Sep 2018 04:32:49 +0000 (04:32 +0000)]
Merge "Make phpunit.php less hackish, and install the listener unconditionally"

4 years agoMerge "TemplateParser: Pass FLAG_MUSTACHELOOKUP to enable parent context access"
jenkins-bot [Wed, 5 Sep 2018 00:33:42 +0000 (00:33 +0000)]
Merge "TemplateParser: Pass FLAG_MUSTACHELOOKUP to enable parent context access"

4 years agoMerge "Add missing dependency on module 'mediawiki.util'"
jenkins-bot [Wed, 5 Sep 2018 00:02:35 +0000 (00:02 +0000)]
Merge "Add missing dependency on module 'mediawiki.util'"

4 years agoAPI: Use ct_tag_id in queries when applicable
Amir Sarabadani [Tue, 4 Sep 2018 19:17:29 +0000 (21:17 +0200)]
API: Use ct_tag_id in queries when applicable

Bug: T194162
Change-Id: I2146cd1f72b546277723102ab64c79567549ff5b

4 years agoMerge "Join decomposition on change_tag and change_tag_def when filtering"
jenkins-bot [Tue, 4 Sep 2018 20:11:48 +0000 (20:11 +0000)]
Merge "Join decomposition on change_tag and change_tag_def when filtering"

4 years agoAdd missing dependency on module 'mediawiki.util'
Fomafix [Tue, 4 Sep 2018 20:00:35 +0000 (22:00 +0200)]
Add missing dependency on module 'mediawiki.util'

mediawiki.action.edit.stash.js from module 'mediawiki.action.edit' uses
mw.util.getParamValue from module 'mediawiki.util'.

Change-Id: If56029f892ce79ff2ea01dd16814d5b7e826daa0

4 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Tue, 4 Sep 2018 19:55:19 +0000 (21:55 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I76a715667cf1c3a87f0cbf85646e82700a0f923e

4 years ago[MCR] Move getSecondaryDataUpdates to the page level
Gergő Tisza [Tue, 28 Aug 2018 15:34:25 +0000 (17:34 +0200)]
[MCR] Move getSecondaryDataUpdates to the page level

Replaces Content::getSecondaryDataUpdates with
WikiPage::getSecondaryDataUpdates so that aggregation of
data updates from multiple page slots can be handled without
the caller having to care about it.
Also adds a WikiPage::updateParserCache method for convenience.

This is a temporary measure until DerivedPageDataUpdater
(or its replacement) can be exposed directly, at which point
the WikiPage methods will be deprecated.

Also fixes a parameter handling bug in DerivedPageDataUpdater.

Bug: T194043
Change-Id: Idbe7d582b49fcb7c90aea813773b7610ad44b1a8

4 years agoUpdate API tests to comply with the new backend for change tags
Amir Sarabadani [Tue, 4 Sep 2018 19:50:46 +0000 (21:50 +0200)]
Update API tests to comply with the new backend for change tags

Bug: T194162
Change-Id: I35f6e36f988a9483dcb624c39e3f0cc969724fdf

4 years agoTemplateParser: Pass FLAG_MUSTACHELOOKUP to enable parent context access
Roan Kattouw [Fri, 31 Aug 2018 03:18:44 +0000 (20:18 -0700)]
TemplateParser: Pass FLAG_MUSTACHELOOKUP to enable parent context access

This allows variables defined in an outer context to be used in inner
contexts. For example:

    <!-- bar is a property of each thing, foo is an outer variable -->
    <li>{{foo}} is a {{bar}}</li>

Bug: T203209
Change-Id: Ib0ae0fb0b4be6b161f548c79db6fb6f4b831f7c1

4 years agoMerge "HTMLCheckMatrix: Treat row/column labels as HTML in OOUI mode"
jenkins-bot [Tue, 4 Sep 2018 19:37:37 +0000 (19:37 +0000)]
Merge "HTMLCheckMatrix: Treat row/column labels as HTML in OOUI mode"

4 years agoMerge "libs: Bump wikimedia/timestamp from 2.0.0 to 2.1.0"
jenkins-bot [Tue, 4 Sep 2018 19:26:16 +0000 (19:26 +0000)]
Merge "libs: Bump wikimedia/timestamp from 2.0.0 to 2.1.0"

4 years agolibs: Bump wikimedia/timestamp from 2.0.0 to 2.1.0
James D. Forrester [Tue, 4 Sep 2018 18:57:12 +0000 (11:57 -0700)]
libs: Bump wikimedia/timestamp from 2.0.0 to 2.1.0

Depends-On: I209cdce85d0fb224af8521bc5d6b1f367719e30a
Change-Id: I209cdce85d0fb224af8521bc5d6b1f367719e30b

4 years agoMerge "resourceloader: Avoid clear/set timer overhead in mw.loader.store.add"
jenkins-bot [Tue, 4 Sep 2018 18:59:53 +0000 (18:59 +0000)]
Merge "resourceloader: Avoid clear/set timer overhead in mw.loader.store.add"

4 years agoJoin decomposition on change_tag and change_tag_def when filtering
Amir Sarabadani [Tue, 4 Sep 2018 18:58:41 +0000 (20:58 +0200)]
Join decomposition on change_tag and change_tag_def when filtering

Since the service uses cache and MySQL also caches, this is faster

Bug: T194162
Change-Id: I57bbbf4f566d8140f9f80c16ecc454f857d363b2

4 years agoMerge "resourceloader: Remove module stringification from execute path"
jenkins-bot [Tue, 4 Sep 2018 18:55:56 +0000 (18:55 +0000)]
Merge "resourceloader: Remove module stringification from execute path"

4 years agoMerge "resourceloader: Reduce memory cost of mw.config.set()"
jenkins-bot [Tue, 4 Sep 2018 18:09:29 +0000 (18:09 +0000)]
Merge "resourceloader: Reduce memory cost of mw.config.set()"

4 years agoresourceloader: Avoid clear/set timer overhead in mw.loader.store.add
Timo Tijhof [Sat, 1 Sep 2018 03:54:47 +0000 (04:54 +0100)]
resourceloader: Avoid clear/set timer overhead in mw.loader.store.add

Follows-up d269e1d91f76 (2018), 4174b662f623b (2015).

Bug: T202598
Change-Id: I45b9f17357e6fb372456a1a4841ad948a5526437

4 years agoresourceloader: Remove module stringification from execute path
Timo Tijhof [Fri, 31 Aug 2018 03:02:18 +0000 (04:02 +0100)]
resourceloader: Remove module stringification from execute path

After execute() is finished and markModuleReady() is called,
the execute path reaches handlePending() which calls
mw.loader.store.set(). This prepares the contents of the module
we just finished executing, for localStorage.

While the writing to localStorage was already debounced via #update,
the stringification of all functions and stylesheets was still
happening within the execute path, and other checks as well.

This commit replaces the mw.loader.store.set() call with a new
method mw.loader.store.add(). The serialisation is now performed
as part of flushWrites(), which is the debounced update that
happens in an idle callback.

While mw.loader.store is itself private within mw.loader, this
commit also marks the set() and update() methods as @private
within mw.loader.store as they are not (and should not) called
from outside this class.

Bug: T202703
Bug: T127328
Change-Id: I23ef28e096acf3bab57b88922ba21366fed06155

4 years agoSchema change for reading ct_tag_id instead of ct_tag
Amir Sarabadani [Tue, 28 Aug 2018 21:32:55 +0000 (23:32 +0200)]
Schema change for reading ct_tag_id instead of ct_tag

Adding unique index on ct_tag_id and making indexes on ct_tag non unique

Bug: T193874
Change-Id: I24609c57e47308d1330a97527f4ea374d0d307ba

4 years agoMerge "Update jQuery from v3.2.1 to v3.3.1"
jenkins-bot [Tue, 4 Sep 2018 16:25:49 +0000 (16:25 +0000)]
Merge "Update jQuery from v3.2.1 to v3.3.1"

4 years agoMerge "resourceloader: Remove unused string[] module logic in register()"
jenkins-bot [Tue, 4 Sep 2018 13:17:07 +0000 (13:17 +0000)]
Merge "resourceloader: Remove unused string[] module logic in register()"

4 years agoMerge "resourceloader: Remove obsolete aliases from closure"
jenkins-bot [Tue, 4 Sep 2018 12:54:21 +0000 (12:54 +0000)]
Merge "resourceloader: Remove obsolete aliases from closure"

4 years agoMerge "resourceloader: Use 'enableModuleContentVersion' for startup module"
jenkins-bot [Tue, 4 Sep 2018 12:41:47 +0000 (12:41 +0000)]
Merge "resourceloader: Use 'enableModuleContentVersion' for startup module"

4 years agoSelenium: Daily Jenkins job targeting beta cluster should run only tests that pass
Željko Filipin [Tue, 4 Sep 2018 09:27:01 +0000 (11:27 +0200)]
Selenium: Daily Jenkins job targeting beta cluster should run only tests that pass

Selenium tests run fine when targeting MediaWiki installation in
MediaWiki-Vagrant and in Jenkins, but fail when targeting beta cluster.
Until tests are refactored to run without failure for beta cluster, let's disable
failing tests.

Bug: T185011
Change-Id: I12da893e7d624d4ebe478bccf0706aa07c965796

4 years agoMake phpunit.php less hackish, and install the listener unconditionally
Tim Starling [Mon, 3 Sep 2018 07:02:44 +0000 (17:02 +1000)]
Make phpunit.php less hackish, and install the listener unconditionally

* Instead of rewriting $argv, add a Command subclass called
  MediaWikiPHPUnitCommand which overrides the configuration using the
  stub functions in Command which were provided for that purpose.
* Revert c804a0b5b9be8be9, which added redundant debug output to tests,
  and instead install the MediaWikiPHPUnitTestListener listener
  unconditionally. Deprecate and make non-functional the --debug-tests
  option. If you don't want tests to produce debug output, you can
  always turn the channel off.
* Because I added our listener to the listener array instead of making
  it override the printer, it's no longer necessary to derive from
  PHPUnit\TextUI\ResultPrinter. Instead we derive from BaseTestListener.
  So we don't need to call the (empty) parent methods.
* Remove the --with-phpunitclass feature since it doesn't work with this
* Instead of passing CLI args to MediaWikiTestCase via a public static
  variable, inject it non-statically by overriding the TestRunner and
* Remove --file, which has been non-functional since my 2016 refactor.

Change-Id: Ibcaf9ca81c8dc63cce6dc6f6fb1fffee19f8804e

4 years agoSpecialPageExecutor: Use `finally` now that we're in a PHP 5.5+ world
Kunal Mehta [Tue, 4 Sep 2018 05:10:06 +0000 (22:10 -0700)]
SpecialPageExecutor: Use `finally` now that we're in a PHP 5.5+ world

Change-Id: I2f91998781be492557d90444b773951ae1e1580e

4 years agoIntroduce NameTableStoreFactory
Tim Starling [Tue, 4 Sep 2018 01:59:03 +0000 (11:59 +1000)]
Introduce NameTableStoreFactory

With a separate service for each of the NameTableStore tables, it
wasn't possible to instantiate a NameTableStore for a foreign wiki,
leading to the inelegant situation of having RevisionStoreFactory
construct a new NameTableStoreFactory every time a RevisionStore for a
foreign wiki was requested. These NameTableStore objects were not
tracked in any structured way, so there was no way to reset them for

So, introduce NameTableStoreFactory, which tracks object instances for
both local and remote table access.

This also avoids having schema details in ServiceWiring.php.

Depends-On: I5c78cfb8bf90eca935a3264592366f63517c4fad
Bug: T202641
Change-Id: Ic0f2d1d94bad9dcc047ff19a1f92db89b7e014ce

4 years agoMerge "Don't save and restore the interwiki table"
jenkins-bot [Tue, 4 Sep 2018 04:49:41 +0000 (04:49 +0000)]
Merge "Don't save and restore the interwiki table"

4 years agoDon't save and restore the interwiki table
Tim Starling [Tue, 4 Sep 2018 00:51:18 +0000 (10:51 +1000)]
Don't save and restore the interwiki table

In fact it always has zero rows. Well, at least it does until
ApiQuerySiteinfoTest::testInterwikiMap() inserts two rows without using
@group Database, and then it has two rows from then on. It's meant to
have zero rows.

This saves time and memory.

Revert of f17feae3a991de9f54e0f57d91fe95bf84211fcb

Change-Id: Ibdb12ff941d2cb47143bdff176072ef9078fa0f7

4 years agoUpdate jQuery from v3.2.1 to v3.3.1
Timo Tijhof [Tue, 4 Sep 2018 03:52:55 +0000 (04:52 +0100)]
Update jQuery from v3.2.1 to v3.3.1

Notable change:

- Ajax: In Safari, $.ajax() previously did not reject the
        Deferred if the XHR timed out. It now does, just as
        it previously did already in other browsers.

- Deferred: Fixed a memory leak with callback closures.

- All: Misc perf optimisations and removal of code that
       provided compat for browsers no longer supported.

Full release notes at
- https://blog.jquery.com/2018/01/19/jquery-3-3-0-a-fragrant-bouquet
- https://blog.jquery.com/2018/01/20/jquery-3-3-1-fixed-dependencies

Change-Id: Ia141dd46dc5b97c0f9766b44fea7559b1148538a

4 years agoMerge "Don't throw an exception when waiting for replication times out"
jenkins-bot [Tue, 4 Sep 2018 02:20:12 +0000 (02:20 +0000)]
Merge "Don't throw an exception when waiting for replication times out"

4 years agoregistration: Use null coalescing operator
MGChecker [Tue, 4 Sep 2018 01:39:41 +0000 (03:39 +0200)]
registration: Use null coalescing operator

Change-Id: Iba5df6fe8c647baaaff91df311efec22cca7e88f

4 years agoresourceloader: Remove unused string[] module logic in register()
Timo Tijhof [Tue, 4 Sep 2018 01:05:00 +0000 (02:05 +0100)]
resourceloader: Remove unused string[] module logic in register()

There are two signatures for this method that we test, document,
and use:

1. register( name, version, ... )

2. register( [ [name,version,...], [name,version,..], ... ] )

But the code was also allowing a third kind that is never used,
and also not documented anywhere or tested.

3. register( [ name, name, ... ] )

Change-Id: I3ed69117affd83d03c4c629d352f19bad50395c9

4 years agoMerge "Reset services before every test"
jenkins-bot [Tue, 4 Sep 2018 00:27:07 +0000 (00:27 +0000)]
Merge "Reset services before every test"

4 years agoMerge "Avoid constructing Title objects in data providers"
jenkins-bot [Tue, 4 Sep 2018 00:23:29 +0000 (00:23 +0000)]
Merge "Avoid constructing Title objects in data providers"

4 years agoMerge "Reduce memory usage on ServiceContainer destruction"
jenkins-bot [Tue, 4 Sep 2018 00:23:24 +0000 (00:23 +0000)]
Merge "Reduce memory usage on ServiceContainer destruction"

4 years agoresourceloader: Avoid duplicate existence check
Fomafix [Sat, 1 Sep 2018 14:07:57 +0000 (16:07 +0200)]
resourceloader: Avoid duplicate existence check

The check above with the mw.loader.register( name ) ensures that
  hasOwn.call( registry, name )
is always true.

Change-Id: I10e2a23bd5c11fbf53fd4fc59ba2e5d94f157254

4 years agoDocument expected escaping level for Xml::submitButton()
Kunal Mehta [Mon, 3 Sep 2018 22:17:19 +0000 (15:17 -0700)]
Document expected escaping level for Xml::submitButton()

Change-Id: I36db99c7f6efc79e52e7fad6cf8b8bad7a6ded37

4 years agoMerge "registration: Add ability to check if a specific extension version is loaded"
jenkins-bot [Mon, 3 Sep 2018 22:07:08 +0000 (22:07 +0000)]
Merge "registration: Add ability to check if a specific extension version is loaded"