Commit graph

68257 commits

Author SHA1 Message Date
jenkins-bot
c879d5be2c Merge "Add Special:UserLogin/signup to search suggestions" 2016-02-05 16:46:30 +00:00
Alex Monk
e4fe015e9f Add Special:UserLogin/signup to search suggestions
Change-Id: I8aa1c7526f5c8d4c80b2cc649b39a30c1da3946a
2016-02-05 15:15:23 +00:00
jenkins-bot
829b2e7d01 Merge "mediawiki.api.parse: Use formatversion=2 for API requests" 2016-02-05 11:44:16 +00:00
jenkins-bot
630a39ce6b Merge "mediawiki.userSuggest: Use formatversion=2 for API request" 2016-02-05 11:28:18 +00:00
jenkins-bot
97483221af Merge "mw.loader: Guard localStorage access with try/catch in mw.store.clear()" 2016-02-05 00:04:30 +00:00
Bryan Davis
f57044ee1c mw.loader: Guard localStorage access with try/catch in mw.store.clear()
We use try/catch appropriately in other places but it was missing
in mw.store.clear().

If the user agent has localStorage disabled an exception will be thrown
for any operation that touches the object.

Change-Id: Idcd0e4c8ba9b0843b2ddcad0ae1781e4915e04fe
2016-02-04 16:41:49 -07:00
jenkins-bot
a70e996690 Merge "mediawiki.jqueryMsg.test: Call async() before each async test step" 2016-02-04 23:06:11 +00:00
jenkins-bot
74174fca25 Merge "Add logic for "tags" in ApiBase" 2016-02-04 22:01:33 +00:00
Translation updater bot
9c299f6da6 Localisation updates from https://translatewiki.net.
Change-Id: Ic35ee8090408696e1b609bae1289aa0036462333
2016-02-04 21:57:23 +01:00
jenkins-bot
2e62b66556 Merge "ForeignAPIRepo: Remove incorrect 'thumbnail' from $imageInfoProps" 2016-02-04 20:50:07 +00:00
victorbarbu
4044a49374 Add logic for "tags" in ApiBase
Bug: T97720
Change-Id: I275c516b4744e243333ec0818d2be1e5508e54a3
2016-02-04 22:30:50 +02:00
Thiemo Mättig
f769ca6ce0 mediawiki.jqueryMsg.test: Call async() before each async test step
Previously, this code ran into the problem that the timeout for dozens of
API requests was hit and the test failed.
The timeout now starts within each individual step.

Bug: T125484
Change-Id: Ia7874ccafadf93986278a241d9d308be0bc99493
2016-02-04 20:41:54 +01:00
jenkins-bot
7a8fdad5cf Merge "Page is an interface not a class" 2016-02-04 19:24:54 +00:00
jenkins-bot
48fdd531c8 Merge "Pass function to Database::selectField in SpecialActiveusers.php" 2016-02-04 19:24:50 +00:00
jenkins-bot
15e1de71cb Merge "qunit: Increase individual test timeout to 60 seconds" 2016-02-04 18:15:55 +00:00
Jan Zerebecki
8f4d5c5d54 qunit: Increase individual test timeout to 60 seconds
Bug: T125484
Change-Id: If4147d678fdef168d79bc2b4d0c606b8c82dc6af
2016-02-04 18:59:36 +01:00
Bartosz Dziewoński
747f38a1d1 ForeignAPIRepo: Remove incorrect 'thumbnail' from $imageInfoProps
'thumbnail' doesn't seem to have ever been a valid 'iiprop' value.
It's currently causing harmless warnings on every InstantCommons request.
Added in 8d1fa96578e8570a08a0cb5f7e2945f09819fbfb for unknown reasons.

Change-Id: I6286ce3ac07207c0dcfc1171084cb358b3fcecda
2016-02-04 18:14:05 +01:00
jenkins-bot
e2e2a83697 Merge "Avoid unstubbing $wgUser before the end of Setup.php in User::getBlockedStatus()" 2016-02-04 16:42:07 +00:00
jenkins-bot
00cef5ba59 Merge "When serializing Message, don't try to unstub StubUserLang" 2016-02-04 16:29:28 +00:00
jenkins-bot
a55b821f3a Merge "Disable automatic cache headers associated with starting a session" 2016-02-04 16:29:20 +00:00
Bartosz Dziewoński
2aba862486 BitmapHandler: Implement validateParam()
Follow-up to 695a93dd33.

Bug: T125804
Change-Id: Ifde40bb5d7c60dd19727f5e47041a6e676f7e3c8
2016-02-04 17:01:44 +01:00
jenkins-bot
5a4fdb5b4e Merge "[debug] Remove BC code from AvroFormatter" 2016-02-04 13:17:31 +00:00
jenkins-bot
69cc66efeb Merge "Split ImagePage.php into separate classes" 2016-02-04 11:48:37 +00:00
Thomas Arrow
2c2d6248f9 Split ImagePage.php into separate classes
Change-Id: Id2ca94c50b75d24da4d02fe82747a7ce7edccd9f
2016-02-04 12:26:36 +01:00
jenkins-bot
733bafe46f Merge "Add User::isSafeToLoad() and ParserOptions::newFromAnon()" 2016-02-04 06:08:07 +00:00
jenkins-bot
ff20437da7 Merge "Include completion search into SearchEngine" 2016-02-04 02:09:46 +00:00
jenkins-bot
f5eb18ea67 Merge "Change bug ID to Phabricator task ID" 2016-02-04 01:28:01 +00:00
wctaiwan
da6dd475f6 Change bug ID to Phabricator task ID
Change-Id: I8e1fc6ed9434a331eb7c66273305576eebed3125
2016-02-03 20:13:10 -05:00
Bartosz Dziewoński
0fd1a6b62b Merge "Revert "Preprocessor: Don't allow unclosed extension tags (matching until end of input)"" 2016-02-04 01:10:58 +00:00
Legoktm
543f46e9c0 Revert "Preprocessor: Don't allow unclosed extension tags (matching until end of input)"
This reverts commit f51d0d9a81.

Breaks templates with non-closed </noinclude> tags, which
were previously acceptable.

Bug: T125754
Change-Id: I8bafb15eefac4e1d3e727c1c84782636d8b82c2b
2016-02-04 00:38:35 +00:00
Stanislav Malyshev
027972a20f Include completion search into SearchEngine
By default it still uses PrefixSearch and supports PrefixSearchBackend
but it can be deprecated and phased out and SearchEngine extensions used
instead.

New APIs:
- SearchEngine
	public function defaultPrefixSearch( $search );
	public function completionSearch( $search );
	public function completionSearchWithVariants( $search );

Search engines should override:
protected function completionSearchBackend( $search );

Bug: T121430
Change-Id: Ie78649591dff94d21b72fad8e4e5eab010a461df
2016-02-03 23:41:49 +00:00
Brad Jorsch
6eec9fb355 Avoid unstubbing $wgUser before the end of Setup.php in User::getBlockedStatus()
Autocreation needs to check if the current IP is blocked from account
creation.

There are two ways we could go here: treat $wgUser as logged-out, or
assume it will eventually be the user name specified by the session.
This patch chooses the former, by the logic that at this early point in
the setup process we don't have a logged-in user determined yet so no
username can really be considered to match the logged-in user.

Bug: T124367
Change-Id: I631bec85291b57f07c378cf6554a8f06cf3fb00c
2016-02-03 21:46:12 +00:00
Brad Jorsch
35c38ce319 Add User::isSafeToLoad() and ParserOptions::newFromAnon()
Useful for avoiding "User::loadFromSession called before the end of
Setup.php".

Bug: T124367
Change-Id: I0b018a623fc833ca95d249ee21667a8f5690d50e
2016-02-03 21:45:56 +00:00
Bryan Davis
514725e7fe Disable automatic cache headers associated with starting a session
Follow up to 7491b52. The 'private, must-revalidate' argument to
session_cache_limiter() does not match any expected values for the
function. This results in the PHP runtime treating it like the
documented empty string argument which completely disables the automatic
addition of cache related headers. Change the implementation to use the
empty string argument explicitly rather than continuing to rely on
the undocumented and potentially confusing existing behavior.

session_cache_limiter( '' ) is called unconditionally in
MediaWiki\Session\PHPSessionHandler::install(). This is safe now that it
is understood that we are disabling the setting of the automatic
headers.

Bug: T124510
Change-Id: I63164f8b7a408e370ff01dead42be27a0135dd35
2016-02-03 21:45:28 +00:00
Brad Jorsch
25dbd91513 Clean up after Ie161e0f
Ie161e0f was done in a hurry, and so didn't do things in the best ways.
This introduces a new "CachedBagOStuff" that transparently handles all
the logic that had been copy-pasted all over in Ie161e0f.

The differences between CachedBagOStuff and MultiWriteBagOStuff are:
* CachedBagOStuff supports only one "backend".
* There's a flag for writes to only go to the in-memory cache.
* The in-memory cache is always updated.
* Locks go to the backend cache (with MultiWriteBagOStuff, it would wind
  up going to the HashBagOStuff used for the in-memory cache).

Change-Id: Iea494729bd2e8c6c5ab8facf4c241232e31e8215
2016-02-03 21:45:18 +00:00
Brad Jorsch
2257fe4228 Revert "Remove SessionManager, temporarily"
This reverts commit 823db5d63dd5200d04c63da50ba6bf16f928e70b.

Change-Id: Ibb3e023e4eb6715295586dea87d0725c344a8271
2016-02-03 21:44:59 +00:00
Translation updater bot
8aa6c9f43e Merge "Localisation updates from https://translatewiki.net." 2016-02-03 21:44:43 +00:00
Translation updater bot
0cd42ad86c Localisation updates from https://translatewiki.net.
Change-Id: Ia72df7f41e81cc99e25bcc9804c6b0bd43bfa61b
2016-02-03 22:40:15 +01:00
jenkins-bot
889fa96027 Merge "resources: Load OOjs UI from its four parts" 2016-02-03 21:38:34 +00:00
Bartosz Dziewoński
1bbcb4da12 mediawiki.widgets: Remove backwards-compatibility dependency on 'mediawiki.widgets.CategorySelector'
Follow-up to 40a8367fe9.

Change-Id: I28faea785cf13d1e741ae6f746a76bd7aeeaf3eb
2016-02-03 19:33:20 +00:00
Bartosz Dziewoński
1f49b66c6f resources: Load OOjs UI from its four parts
See the task for more details. This is a backwards-compatible change.
If your script only needs a subset of OOjs UI functionality, you can
use one of the new smaller modules instead of the old big one.

New modules:
  oojs-ui-core
    The core JavaScript library.
  oojs-ui-widgets
    Additional widgets and layouts module.
  oojs-ui-toolbars
    Toolbar and tools module.
  oojs-ui-windows
    Windows and dialogs module.

Changed modules:
  oojs-ui.styles
    Now correctly only loads the styles needed by OOjs UI PHP.
  oojs-ui
    Now just loads core+widgets+toolbars+windows as dependencies.

Using the new modules in I58799e22f9c0a2f78c1b4a02c4b7af576157883a.

Bug: T113677
Change-Id: I0a3bf8fb25fb82325705a473cebd883e20b3ab8d
2016-02-03 19:27:12 +00:00
Brad Jorsch
f0207e8ca6 Add Special:ApiSandbox
Like Extension:ApiSandbox, but rewritten to use OOJS-UI and to add many
long-requested features.

Bug: T89386
Bug: T92893
Bug: T98457
Bug: T98083
Bug: T89229
Bug: T66008
Bug: T50607
Bug: T47811
Bug: T38875
Bug: T36962
Bug: T34740
Change-Id: Ic42a6c5ef54b811cd63cfef2132942b27a626fe5
Depends-On: I85c0eedcd31a0e419d8055eca0d9cb1ba872ae62
Depends-On: Ic85ff4abbbcd2076ebf5cdfaa0e95e98878e2308
2016-02-03 11:13:59 -05:00
jenkins-bot
920c06e42c Merge "Use LinkTarget in TitleValue only methods" 2016-02-03 13:36:59 +00:00
jenkins-bot
9a3a412f86 Merge "Add LinkTarget interface" 2016-02-03 13:23:08 +00:00
Brad Jorsch
7d4d9016d4 Set title on context in ApiDocumentationTest
For some reason the unit testing infrastructure doesn't set one, and
that makes RequestContext warn.

Bug: T125491
Change-Id: I3e0ec0f567dd06231bca0d3d923e9d4e05ef5514
2016-02-03 12:16:54 +00:00
jenkins-bot
314fa3e2eb Merge "Pass WikiPage objects to ParserCache" 2016-02-03 12:01:09 +00:00
Timo Tijhof
419db58c8b Centralise url handling for urls to static resources
Keep in CSSMin as-is for back-compat and to ensure library remains
independent of MediaWiki.

Moved down a few lines as there is no need to compute the md5 hash when we're
returning a data URI. Previously md5_file was called twice during module builds
(once for the fallback url, and another time when producing the embedded data uri).

Applied to logo in SkinModule as example. To be applied elsewhere as needed.
Without it, fallback is current behaviour (no cache invalidation).

Bug: T99096
Change-Id: I7f38bfc1bea5c241bc4f8ec4f4b640fd65f2c04f
2016-02-02 23:26:16 +00:00
James D. Forrester
e310a0b017 Update OOjs UI to v0.15.2
Release notes:
 https://git.wikimedia.org/blob/oojs%2Fui.git/v0.15.2/History.md

Change-Id: I8124a726660443ce514c48182871d46e6b086a10
2016-02-02 14:10:54 -08:00
jenkins-bot
48fc4dc199 Merge "Unroll Article::__call again" 2016-02-02 20:29:19 +00:00
jenkins-bot
8371987580 Merge "Add Blob to accepted types for uploads" 2016-02-02 20:25:34 +00:00