lhc/web/wiklou.git
6 years agoMerge "Add | to error message about invalid change tag characters"
jenkins-bot [Thu, 15 Jun 2017 16:22:37 +0000 (16:22 +0000)]
Merge "Add | to error message about invalid change tag characters"

6 years agoFix call to makeContent in SpecialChangeContentModel
daniel [Thu, 15 Jun 2017 15:56:10 +0000 (17:56 +0200)]
Fix call to makeContent in SpecialChangeContentModel

ContentHandler::makeContent expects serialized content as the first
parameter, not native data.

Change-Id: Ibf1825a191d10b4dd8b9a5cee95b02b2b91f3d92

6 years agoAdd missing dependencies to module 'mediawiki.api'
Fomafix [Thu, 15 Jun 2017 13:52:55 +0000 (15:52 +0200)]
Add missing dependencies to module 'mediawiki.api'

Change-Id: I62f6e75d840d07a4ae6676fa88c6b655aa575bba

6 years agoMake DatabasePostgres::serverIsReadOnly() check default_transaction_read_only
Aaron Schulz [Thu, 15 Jun 2017 08:36:39 +0000 (01:36 -0700)]
Make DatabasePostgres::serverIsReadOnly() check default_transaction_read_only

Change-Id: If6088c15271a827fedc6a585e070bab6c1acc371

6 years agoSet flush mode in DatabasePostgres::reportQueryError()
Aaron Schulz [Thu, 15 Jun 2017 08:25:17 +0000 (01:25 -0700)]
Set flush mode in DatabasePostgres::reportQueryError()

Bug: T167927
Change-Id: Ib02608cf33d369939a9e587cebfc736336a1e979

6 years agoFix typo "developement" in MockFSFile comment
Federico Leva [Wed, 14 Jun 2017 09:07:48 +0000 (11:07 +0200)]
Fix typo "developement" in MockFSFile comment

Change-Id: If5beaff9bceea44a7e2d4d893b82a294e61afc84

6 years agoMerge "objectcache: Forward MultiWriteBagOStuff::makeKey to primary backend"
jenkins-bot [Thu, 15 Jun 2017 02:45:08 +0000 (02:45 +0000)]
Merge "objectcache: Forward MultiWriteBagOStuff::makeKey to primary backend"

6 years agoAdd | to error message about invalid change tag characters
Matthew Flaschen [Thu, 15 Jun 2017 00:38:48 +0000 (20:38 -0400)]
Add | to error message about invalid change tag characters

Pipe itself is already not allowed.

Bug: T92956
Change-Id: Icb98b5e8040fa91685adcdfdb46e1173162f2b9e

6 years agoFix enhanced RC data attribute sanitizing
Gergő Tisza [Wed, 14 Jun 2017 21:01:31 +0000 (23:01 +0200)]
Fix enhanced RC data attribute sanitizing

We push 'class' in the attribute array so the hook
can manipulate it, so it needs to be added to the attribute
whitelist as well.

Broken in I6dd006d0b1b0fd35c0020f0f9eea9113eca30b35.

Bug: T167922
Bug: T167535
Change-Id: Ic24400382a9dcbb990e12dfddae4ab7db14553cc

6 years agoMerge "New language variant 'en-x-piglatin' for easier variant testing"
jenkins-bot [Wed, 14 Jun 2017 23:57:13 +0000 (23:57 +0000)]
Merge "New language variant 'en-x-piglatin' for easier variant testing"

6 years agoMerge "RCFilters: Add 'views' concept and a namespace view to RCFilters"
jenkins-bot [Wed, 14 Jun 2017 22:51:46 +0000 (22:51 +0000)]
Merge "RCFilters: Add 'views' concept and a namespace view to RCFilters"

6 years agoMerge "Replace deprecated $wgDummyLanguageCodes in WebInstallerLanguage.php"
jenkins-bot [Wed, 14 Jun 2017 21:18:44 +0000 (21:18 +0000)]
Merge "Replace deprecated $wgDummyLanguageCodes in WebInstallerLanguage.php"

6 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Wed, 14 Jun 2017 20:42:42 +0000 (22:42 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I6dd2ce2c8fab01838c84bc016d04192e397fb3c9

6 years agoMerge "Use strtr() for clarity"
jenkins-bot [Wed, 14 Jun 2017 20:18:58 +0000 (20:18 +0000)]
Merge "Use strtr() for clarity"

6 years agoRCFilters: Always replaceState the URL
Moriel Schottlender [Wed, 14 Jun 2017 20:04:01 +0000 (13:04 -0700)]
RCFilters: Always replaceState the URL

Allow users to hit 'back' button to actually go back to their
previous page, rather than use 'back' button to undo their filter
toggling before they're allowed to go back to their previous
page.

Bug: T167919
Change-Id: I171799bd5c139addebcccc4799003f040c3f119b

6 years agoUse strtr() for clarity
Max Semenik [Tue, 13 Jun 2017 00:01:38 +0000 (17:01 -0700)]
Use strtr() for clarity

Change-Id: I35e7530c13fee028ea95a56df1bd2714a610db6e

6 years agoRCFilters: Add 'views' concept and a namespace view to RCFilters
Moriel Schottlender [Thu, 11 May 2017 00:28:26 +0000 (17:28 -0700)]
RCFilters: Add 'views' concept and a namespace view to RCFilters

Enhanced RCFilters: Add the ability to filter by namespaces to RCFilters.
🎉 🎁 🎊

- Add the ability to separate groups of filters by 'views'
- Add the first views as 'default' (for predefined filters)
  and 'namespace' as the list of namespaces.
- Add 'nsinvert' to namespace group
- Allow highlighting namespaces
- Allow searching on either view, depending on prefix
- Add a way to switch views by typing prefix, clicking the
  'Namespaces' button or clicking a tag (either namespace
  or filter tag, changes the view accordingly, and adds
  or removes the prefix from the input to stay consistent)
- Add an optional wrapper text for tags, so we can represent
  them with their respective prefixes and (if needed) with
  a special message for inverted state.
- Add unit tests and make pass
- Bonus: Fix issue with URL not updating (and not being updated)
  the inverted and highlight enabled states.

Bug: T159942
Bug: T163521
Bug: T164130
Change-Id: I7e83f0800cbeb289dfd3461c1c5a197c053147ca

6 years agoMerge "RCFilters: Make frontend URL follow backend rules and add 'urlversion=2'"
jenkins-bot [Wed, 14 Jun 2017 19:31:15 +0000 (19:31 +0000)]
Merge "RCFilters: Make frontend URL follow backend rules and add 'urlversion=2'"

6 years agoMerge "ChangesListSpecialPage: Add urlversion and make urlversion=2 ignore defaults"
jenkins-bot [Wed, 14 Jun 2017 19:30:48 +0000 (19:30 +0000)]
Merge "ChangesListSpecialPage: Add urlversion and make urlversion=2 ignore defaults"

6 years agoMerge "Require $key in msg() functions"
jenkins-bot [Wed, 14 Jun 2017 18:07:08 +0000 (18:07 +0000)]
Merge "Require $key in msg() functions"

6 years agoMerge "Introduce MessageLocalizer interface for exposing msg() method"
jenkins-bot [Wed, 14 Jun 2017 18:01:50 +0000 (18:01 +0000)]
Merge "Introduce MessageLocalizer interface for exposing msg() method"

6 years agoRCFilters: Make frontend URL follow backend rules and add 'urlversion=2'
Moriel Schottlender [Sun, 4 Jun 2017 08:13:47 +0000 (11:13 +0300)]
RCFilters: Make frontend URL follow backend rules and add 'urlversion=2'

The backend always merges the query with wiki/user defaults before
it gives us data. The frontend, though, initially assumed that the
state is given strictly by the URL parameters (especially after the
URL shorening commit). This made it so that the frontend state is
incompatible with backend state.

However, always merging frontend state with user/wiki defaults can
produce inconsistencies between URLs in the same wiki, preventing
users from sharing them -- and making it potentially break if ever
a wiki default changes.

The solution is to add 'urlversion=2' to all RCFilters-generated
URLs and have the backend recognize this parameter as 'do not
merge with defaults'.

When RCFilters frontend loads, it checks whether the parameter
exists; if it doesn't, it merges whatever it sees with the defaults
just like the backend, then it transforms the URL to represent the
correct full state, and adds 'urlversion=2' to the URL parameters,
making it consistent across accounts and through time for the
next time it will load.

This means several new behaviors over the 'short url' commit:
- Accessing Special:RecentChanges directly (no query) will result
  in one of two things:
  -- If there is a saved query that's set to default:
     The system will load that saved query "straight forward" (as
     if the user clicked that option from the menu) causing, also,
     an ajax re-request from the server (since the server does not
     yet know about saved queries or their potential for being
     the default state.)
  -- If there is no saved query default: The system will load
     user/wiki defaults (like the backend does) and then fix the
     url to represent this state fully (with parameters showing the
     actual state of the filters.
  -- Both cases will also result in adding 'urlversion=2' to
     the end result URL.
- Accessing Special:RecentChanges?urlversion=2 (without any other
  parameters) will result in loading a completely empty filter set
  in RCFilters. We assume that 'urlversion=2' does not load defaults
  even if it is the only parameter in the URL.
- Accessing Special:RecentChanges?hideX=1 (parameter set without
  urlversion=2) will result in the front end taking the requested
  parameters, merging them with user/wiki default (reproducing what
  the backend does) and then adding urlversion=2 to the URL.

In all cases except for the default-saved-query-load case, the initial
load will **not** re-request data from the backend. The backend needs
to adjust to respect urlversion=2 as well (will come in an upcoming
commit) so the state and expectation of both the front- and back-end
are the same.

This commit also factors out URL handing to a separate class (UriProcessor)
and adds unit tests for it.

Bug: T166907
Bug: T166972
Bug: T166974
Change-Id: I0eed3bc0d4fa4810b6301b535c75b6bfbc8b4a5b

6 years agoobjectcache: Forward MultiWriteBagOStuff::makeKey to primary backend
Timo Tijhof [Wed, 14 Jun 2017 17:06:46 +0000 (18:06 +0100)]
objectcache: Forward MultiWriteBagOStuff::makeKey to primary backend

Similar to what WANObjectCache and CachedBagOStuff are already doing.

Also add missing tests for WANObjectCache (similar to those for CachedBagOStuff).

Bug: T167465
Change-Id: I1a0c9324726aa6a1b221def985773b1b819181fd

6 years agoParserCache: Delete old-style key when saving
Brad Jorsch [Sun, 11 Jun 2017 15:21:21 +0000 (11:21 -0400)]
ParserCache: Delete old-style key when saving

It was noticed that disk usage on the parser cache machines was
increasing since shortly after wmf.4 was redeployed everywhere on the
9th. One theory is that I7fb9ffca9 causes this by making reparses for an
existing old-style cache entry start writing the new-style key where
they would previously have overwritten the old-style key. On that
theory, let's delete that old-style key (that should now be useless) on
save.

I'm assuming here that firing a blind delete for keys that probably
don't exist in the cache (i.e. every new edit) isn't going to hurt
anything. If that's not the case, we'd need to check existence before
deleting.

Bug: T167784
Change-Id: Ie5efb05722cb7da2a90da195a1f244468177175d

6 years agoMerge "Linked HTML representation of a format to formatted output"
jenkins-bot [Wed, 14 Jun 2017 13:39:23 +0000 (13:39 +0000)]
Merge "Linked HTML representation of a format to formatted output"

6 years agoLinked HTML representation of a format to formatted output
KeerthanaS [Mon, 25 Jan 2016 21:25:57 +0000 (02:55 +0530)]
Linked HTML representation of a format to formatted output

Added Hyperlink to non-HTML formatted output from the HTML
representation of the output

Bug: T123905
Change-Id: Id55c524a29f679b8e06d4e3d05bd50e8685fb830

6 years agoRequire $key in msg() functions
Amir Sarabadani [Mon, 12 Jun 2017 09:53:51 +0000 (14:23 +0430)]
Require $key in msg() functions

Note: calling msg() with no parameter was never supported,
doing this on a RequestContext for example would result in:
PHP Warning:  Missing argument 1 for wfMessage() ...followed
by a bunch of fallout.

So this patch only formally declares what was already a
requirement in reality.

Change-Id: I1864afb8bcc641698689828914949a06506d8f3a

6 years agoMerge "Fix Postgres support"
jenkins-bot [Wed, 14 Jun 2017 08:19:53 +0000 (08:19 +0000)]
Merge "Fix Postgres support"

6 years agoMerge "Skin: Don't use parser cache in getCachedNotice()"
jenkins-bot [Wed, 14 Jun 2017 05:25:15 +0000 (05:25 +0000)]
Merge "Skin: Don't use parser cache in getCachedNotice()"

6 years agoSkin: Don't use parser cache in getCachedNotice()
Kunal Mehta [Sun, 11 Jun 2017 01:15:35 +0000 (18:15 -0700)]
Skin: Don't use parser cache in getCachedNotice()

Just use wfGetCache( CACHE_ANYTHING ) which should be sufficient for
most cases.

Change-Id: Ic97549c9649d0cc1938773b10e26f6e8f819c7fa

6 years agoDB: Add join conditions to selectField, selectFieldValues, and insertSelect
Brad Jorsch [Fri, 9 Jun 2017 16:58:09 +0000 (12:58 -0400)]
DB: Add join conditions to selectField, selectFieldValues, and insertSelect

selectField() and selectFieldValues() are trivial, they just need to
pass it through to select(). In fact, selectFieldValues() was already
doing it, just no one ever updated IDatabase.

insertSelect() is a little more work. nativeInsertSelect() was
originally written as largely a copy-paste of select() and has since
gotten well out of sync. Now that we have selectSQLText(), we should be
able to just use that. DatabasePostgres's implementation can wrap the
parent implementation instead of being another copy-paste, but
DatabaseOracle seems to still need to be special.

Change-Id: I0e6a9e6daa510639d3212641606047a5db96c500

6 years agoParserOptions: Fix handling of 'editsection'
Brad Jorsch [Sun, 11 Jun 2017 14:49:32 +0000 (10:49 -0400)]
ParserOptions: Fix handling of 'editsection'

The handling of the 'editsection' option prior to I7fb9ffca9 was
unusual: it was included in the cache key, but the getter didn't ever
flag it as "used". This was overlooked in I7fb9ffca9.

This fixes the handling to restore that behavior. It's no longer
considered to be a real parser option, so changing it won't make
isSafeToCache() fail while reading it won't flag it as 'used'.

But to keep Wikibase working (see T85252), if 'editsection' is supplied
in $forOptions optionsHash() will still include it in the hash so
whatever Wikibase is doing by forcing that doesn't break. The hash when
it is included is the same as was used in I7fb9ffca9 to reuse keys.

Once optionsHashPre30() is removed, Wikibase should be changed to use
some other method to fix T85252 so we can remove that hack from
optionsHash().

Change-Id: I77b5519c5a1122a1fafbfc523b77b2268c0efeb1

6 years agoMake Titles with an unknown namespace ID refer to Special:Badtitle.
daniel [Fri, 9 Jun 2017 16:39:33 +0000 (18:39 +0200)]
Make Titles with an unknown namespace ID refer to Special:Badtitle.

Without this patch, Title::getPrefixedText() would return ":Foo"
if the namespace was unknown, potentially creating a misleading
link to the main namespace. With this change, getPrefixedText()
will return something like "Special:Badtitle/NS12345:Foo".

Note that round trip behavior is broken either way.

Bug: T165149
Change-Id: I0d491a2b58ff45f207f83ee62ca6e7e6ffbf790a

6 years agoMerge "Hide <style> tags from Tidy"
jenkins-bot [Wed, 14 Jun 2017 04:23:07 +0000 (04:23 +0000)]
Merge "Hide <style> tags from Tidy"

6 years agoMerge "RCFilters: Send form info even for empty checkboxes"
jenkins-bot [Wed, 14 Jun 2017 01:36:59 +0000 (01:36 +0000)]
Merge "RCFilters: Send form info even for empty checkboxes"

6 years agoMerge "LoadMonitor: Group some logging parameters"
jenkins-bot [Wed, 14 Jun 2017 01:13:45 +0000 (01:13 +0000)]
Merge "LoadMonitor: Group some logging parameters"

6 years agoMerge "API: Restore ability for dieStatus() to be passed a non-fatal Status"
jenkins-bot [Tue, 13 Jun 2017 23:25:34 +0000 (23:25 +0000)]
Merge "API: Restore ability for dieStatus() to be passed a non-fatal Status"

6 years agoRCFilters: Send form info even for empty checkboxes
Moriel Schottlender [Tue, 13 Jun 2017 23:04:57 +0000 (16:04 -0700)]
RCFilters: Send form info even for empty checkboxes

Make sure the url params override previous ones in case they are
empty, make sure we still send them through the fieldset form with
an empty value, rather than not send them at all (and then they are
being re-merged into the existing URL and become essentially 'sticky')

Change-Id: I294dba17c5a5b792f5bf5064a76dedefa4d12557

6 years agoLoadMonitor: Group some logging parameters
Chad Horohoe [Tue, 13 Jun 2017 21:42:33 +0000 (14:42 -0700)]
LoadMonitor: Group some logging parameters

Change-Id: Iefd59db547d799a02edc9f733cadb7668176d4cd

6 years agoRemove "@author Umherirrender" annotations
Umherirrender [Tue, 13 Jun 2017 20:28:50 +0000 (22:28 +0200)]
Remove "@author Umherirrender" annotations

Also remove my name from i18n files I am not translate

Bug: T139301
Change-Id: If806324cd07e662f5e995e11cf899b5b934cd79b

6 years agoMerge "Update magic words and special page aliases for Arabic and Egyptian Arabic"
jenkins-bot [Tue, 13 Jun 2017 20:24:43 +0000 (20:24 +0000)]
Merge "Update magic words and special page aliases for Arabic and Egyptian Arabic"

6 years agoMerge "ApiParse: Fetch content with parsetree"
jenkins-bot [Tue, 13 Jun 2017 20:00:14 +0000 (20:00 +0000)]
Merge "ApiParse: Fetch content with parsetree"

6 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Tue, 13 Jun 2017 19:57:04 +0000 (21:57 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I3aa05ab2b7d18f6d134e4b395e2a50526cba5630

6 years agoApiParse: Fetch content with parsetree
Brad Jorsch [Tue, 13 Jun 2017 19:42:21 +0000 (15:42 -0400)]
ApiParse: Fetch content with parsetree

I0079e10a assumed callers were correctly passing $getContent to
getParsedContent(). Apparently they weren't.

Bug: T167826
Change-Id: I85cbdfb5d0580252c1df23a0f27c8052f1d65dc3

6 years agoHide <style> tags from Tidy
Brad Jorsch [Tue, 13 Jun 2017 16:03:56 +0000 (12:03 -0400)]
Hide <style> tags from Tidy

Some versions of html-tidy (e.g. the one currently in use on WMF wikis)
will try to move all <style> tags in the body into the head, effectively
removing them for our purposes. We need to avoid that for TemplateStyles.

Bug: T167349
Change-Id: I133776d16f366cad73ed30af0e5a665fdf9f5ed9

6 years agoUpdate magic words and special page aliases for Arabic and Egyptian Arabic
محمد شعیب [Fri, 9 Sep 2016 12:24:29 +0000 (12:24 +0000)]
Update magic words and special page aliases for Arabic and Egyptian Arabic

It is requested by User:Meno25 to update magic words and special page aliases for Arabic and Egyptian Arabic languages.

Bug: T143880
Change-Id: I5701ab523aea6c9a933586c86a478c4dbcc8cf7a

6 years agoAPI: Restore ability for dieStatus() to be passed a non-fatal Status
Brad Jorsch [Mon, 12 Jun 2017 16:54:24 +0000 (12:54 -0400)]
API: Restore ability for dieStatus() to be passed a non-fatal Status

This ability was accidentally removed in Iae0e2ce3.

Bug: T167690
Change-Id: I79cc9f2f8e75c3cf4e0942d17faafa84955aa020

6 years agoMake Special:PageData accept two-part subpage
Amir Sarabadani [Tue, 13 Jun 2017 09:30:41 +0000 (14:00 +0430)]
Make Special:PageData accept two-part subpage

Bug: T163923
Change-Id: I9fc55fd1eb956871fc5dd3e104c6786d380ef445

6 years agoMerge "Disable addHelpLink when including special pages"
jenkins-bot [Tue, 13 Jun 2017 08:49:58 +0000 (08:49 +0000)]
Merge "Disable addHelpLink when including special pages"

6 years agoMerge "ApiParse: Clean up parsing code"
jenkins-bot [Tue, 13 Jun 2017 03:23:58 +0000 (03:23 +0000)]
Merge "ApiParse: Clean up parsing code"

6 years agoChangesListSpecialPage: Add urlversion and make urlversion=2 ignore defaults
Roan Kattouw [Fri, 9 Jun 2017 19:36:26 +0000 (12:36 -0700)]
ChangesListSpecialPage: Add urlversion and make urlversion=2 ignore defaults

This allows us to build reliable URLs that will be consistent over time
and between users (because the defaults depend on preferences,
extension presence, etC) by using urlversion=2 and specifying the
state of each filter relative to the empty state (i.e. nothing enabled).

urlversion defaults to 1, and urlversion=1 maintains the current
behavior where the parameters are interpreted relative to the
user's default state.

Bug: T166906
Change-Id: Iaf33c14e3f909092d96453e78016814aa417673a

6 years agoNew language variant 'en-x-piglatin' for easier variant testing
Liangent [Sat, 27 Jul 2013 23:01:54 +0000 (01:01 +0200)]
New language variant 'en-x-piglatin' for easier variant testing

Guarded by the $wgUsePigLatinVariant variable, off by default.

Pig Latin is a language game where words in English are altered
according to the following rules:

* Words starting with a vowel have a '-way' suffix appended.
* Words starting with a consonant have the initial consonants (or 'qu'
  group) moved to the end and an '-ay' suffix appended.

https://en.wikipedia.org/wiki/Pig_Latin

* Added 'en-x-piglatin' as a language name.
* Added 'en' to LanguageConverter::$languagesWithVariants.
* Added LanguageEn class and its corresponding EnConverter which
  provides one-way translation from English to Pig Latin.
* Some minor internal changes in code that assumed that English
  doesn't have a language class or converter.

Bug: T45547
Depends-On: I1d9691c784032669979f8109c9a5f65cbf4122c9
Change-Id: I7fa2d85d6364958c5138366e8b4504a2697a8731

6 years agoMerge "Sync up with Parsoid parserTests.txt"
jenkins-bot [Mon, 12 Jun 2017 20:51:54 +0000 (20:51 +0000)]
Merge "Sync up with Parsoid parserTests.txt"

6 years agoMerge "RELEASE-NOTES: OutputPage::enableTOC was removed"
jenkins-bot [Mon, 12 Jun 2017 20:39:59 +0000 (20:39 +0000)]
Merge "RELEASE-NOTES: OutputPage::enableTOC was removed"

6 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Mon, 12 Jun 2017 19:59:18 +0000 (21:59 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I11b382a06772ebb9f908ba543f2276a8cf6e1a8b

6 years agoSync up with Parsoid parserTests.txt
Arlo Breault [Mon, 12 Jun 2017 19:39:42 +0000 (15:39 -0400)]
Sync up with Parsoid parserTests.txt

This now aligns with Parsoid commit 108eed81b3eb78b77ade5ba5daac71fb43fff6de

Change-Id: Ib2b31f008adaf16866de16ef963bc58d6cabb088

6 years agoMerge "Delete CologneBlue messages"
jenkins-bot [Mon, 12 Jun 2017 19:19:44 +0000 (19:19 +0000)]
Merge "Delete CologneBlue messages"

6 years agoDelete CologneBlue messages
Amire80 [Wed, 8 Mar 2017 21:06:10 +0000 (23:06 +0200)]
Delete CologneBlue messages

They are moved to the CologneBlue repo.

Bug: T159921
Depends-On: Ide5c96b418f6abfb4244efa777c57ec2ffa9f087
Depends-On: Ib46d62e2464d7292482e8ea63ce187987104c59d
Depends-On: I522a52e548b88d0904f6890ddc7d0adb5d54eba2
Change-Id: Ib262d89e4485dfff2ef7ee9bbaa1152604626c4c

6 years agoMerge "Allow CategoryPageView to set $mCategoryViewerClass"
jenkins-bot [Mon, 12 Jun 2017 18:46:01 +0000 (18:46 +0000)]
Merge "Allow CategoryPageView to set $mCategoryViewerClass"

6 years agoMerge "Remove X-Content-Dimensions header"
jenkins-bot [Mon, 12 Jun 2017 18:25:15 +0000 (18:25 +0000)]
Merge "Remove X-Content-Dimensions header"

6 years agoMerge "Log when transactions affect many rows in TransactionProfiler"
jenkins-bot [Mon, 12 Jun 2017 18:16:00 +0000 (18:16 +0000)]
Merge "Log when transactions affect many rows in TransactionProfiler"

6 years agoMerge "Add $wgMaxJobDBWriteDuration setting for avoiding replication lag"
jenkins-bot [Mon, 12 Jun 2017 18:15:57 +0000 (18:15 +0000)]
Merge "Add $wgMaxJobDBWriteDuration setting for avoiding replication lag"

6 years agoMerge "Allow skins to control style of mediawiki.hlist"
jenkins-bot [Mon, 12 Jun 2017 18:10:16 +0000 (18:10 +0000)]
Merge "Allow skins to control style of mediawiki.hlist"

6 years agoRemove X-Content-Dimensions header
Gilles Dubuc [Thu, 8 Jun 2017 20:30:07 +0000 (22:30 +0200)]
Remove X-Content-Dimensions header

Reverts 84e4d7508893, and parts of cdfe08439c3b and 4511f6fa9fa0.

Bug: T150741
Bug: T167034
Change-Id: I39cfcf2cb231b6dfef569968fba6f473da258916

6 years agoMerge "Do not try to parse empty argument in getErrorsOrWarnings in OOUI"
jenkins-bot [Mon, 12 Jun 2017 18:03:20 +0000 (18:03 +0000)]
Merge "Do not try to parse empty argument in getErrorsOrWarnings in OOUI"

6 years agoMerge "RCFilters: Retain extra url params when comparing url equivalency"
jenkins-bot [Mon, 12 Jun 2017 17:48:49 +0000 (17:48 +0000)]
Merge "RCFilters: Retain extra url params when comparing url equivalency"

6 years agoRELEASE-NOTES: OutputPage::enableTOC was removed
Timo Tijhof [Mon, 12 Jun 2017 17:15:07 +0000 (18:15 +0100)]
RELEASE-NOTES: OutputPage::enableTOC was removed

Follows-up c7e00974c7eb1 (T130632).

Also announced on Wikitech:
<https://lists.wikimedia.org/pipermail/wikitech-l/2017-June/088301.html>

Change-Id: I9dde207d2314993b9e88e6bb000b0a11b37799ad

6 years agoApiParse: Clean up parsing code
Brad Jorsch [Mon, 12 Jun 2017 15:02:58 +0000 (11:02 -0400)]
ApiParse: Clean up parsing code

Now that ParserOptions->isSafeToCache() exists, use it where necessary.
This also moves the use inside the makeParserOptions() method so other
callers can pick it up as well.

Then pass the flag as $forceParse into WikiPage::getParserOutput()
instead of duplicating the logic in several cases, and generally clean
up the logic in the module to let WikiPage decide when to use the cache
in more cases.

Change-Id: I0079e10a40997e4a3b59ac21ef6c92246a147736

6 years agoRemove unused and unnecessary imports
Thiemo Mättig [Mon, 12 Jun 2017 10:30:56 +0000 (12:30 +0200)]
Remove unused and unnecessary imports

Change-Id: I26e623a4e4ba965c07670369a90c8a95185ea1e4

6 years agoMove HttpAccept* to libs
Amir Sarabadani [Mon, 12 Jun 2017 13:45:51 +0000 (18:15 +0430)]
Move HttpAccept* to libs

Bug: T163923
Change-Id: I4984f6b77843669950afeff82351827cd416a80d

6 years agoUse "target" instead "title" as the param name in SpecialPageData
Amir Sarabadani [Mon, 12 Jun 2017 13:02:02 +0000 (17:32 +0430)]
Use "target" instead "title" as the param name in SpecialPageData

Using "title" confuses mediawiki and causes redirect loops

Bug: T163923
Change-Id: I29e0e6a61703cc04397205a3f7f38df5906622e1

6 years agoRCFilters: Retain extra url params when comparing url equivalency
Moriel Schottlender [Mon, 12 Jun 2017 12:56:17 +0000 (05:56 -0700)]
RCFilters: Retain extra url params when comparing url equivalency

The extra params should also dictate whether the URL should change,
so we update parameters that are external to RCFilters' model, like
limit and from, etc.

Bug: T167551
Change-Id: I21e35e7871abbc57634231b6330cc1fad8299860

6 years agoMerge "Start a very basic version of Special:PageData"
jenkins-bot [Mon, 12 Jun 2017 12:51:28 +0000 (12:51 +0000)]
Merge "Start a very basic version of Special:PageData"

6 years agoMerge "Move HttpAcceptNegotiator and HttpAcceptParser from Wikibase to core"
jenkins-bot [Mon, 12 Jun 2017 12:43:59 +0000 (12:43 +0000)]
Merge "Move HttpAcceptNegotiator and HttpAcceptParser from Wikibase to core"

6 years agoDo not try to parse empty argument in getErrorsOrWarnings in OOUI
Amir Sarabadani [Mon, 12 Jun 2017 11:33:17 +0000 (16:03 +0430)]
Do not try to parse empty argument in getErrorsOrWarnings in OOUI

Bug: T167644
Change-Id: I0dcb9bd51ad0cecbdab868fed056b4077d1c9fa8

6 years agoIntroduce MessageLocalizer interface for exposing msg() method
Amir Sarabadani [Sat, 27 May 2017 13:07:13 +0000 (15:07 +0200)]
Introduce MessageLocalizer interface for exposing msg() method

Bug: T162594
Change-Id: I2d9af9fc05264bffda675af46f656038cd72d0db

6 years agoMerge "SpecialNewimages: Do not add the module when the special page is included"
jenkins-bot [Mon, 12 Jun 2017 06:13:10 +0000 (06:13 +0000)]
Merge "SpecialNewimages: Do not add the module when the special page is included"

6 years agoDisable addHelpLink when including special pages
Fomafix [Sun, 11 Jun 2017 19:31:36 +0000 (21:31 +0200)]
Disable addHelpLink when including special pages

The help link does not make sence on includes special pages and is not
shown. But the style module 'mediawiki.helplink' is still loaded.
This change disables the loading of the module 'mediawiki.helplink' for
included special pages.

Change-Id: I8115dc2e46f3498441c30caede4648d387d55d5d

6 years agoMerge "CryptRand: only use random_bytes on php 7 and HHVM"
jenkins-bot [Sun, 11 Jun 2017 20:38:47 +0000 (20:38 +0000)]
Merge "CryptRand: only use random_bytes on php 7 and HHVM"

6 years agoSpecialNewimages: Do not add the module when the special page is included
Fomafix [Sun, 11 Jun 2017 18:46:41 +0000 (20:46 +0200)]
SpecialNewimages: Do not add the module when the special page is included

When the special page is included with
{{Special:NewImages}}
the module 'mediawiki.special.newFiles' throws an error.

This change loads the module 'mediawiki.special.newFiles' together with the
form.

Bug: T167601
Change-Id: I5a0589f62388292851664daf1ab5e63008556a64

6 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sun, 11 Jun 2017 19:54:14 +0000 (21:54 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: Ia549296daf2a571be8bab81768a656bb12570116

6 years agoMove closing quotation mark before punctuation in rcfilters* messages
Felipe L. Ewald [Sat, 15 Apr 2017 01:11:46 +0000 (01:11 +0000)]
Move closing quotation mark before punctuation in rcfilters* messages

Change-Id: I09fb50ee5e3fa9d34535b787a1bfd8aa365d880c

6 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sat, 10 Jun 2017 21:35:39 +0000 (23:35 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I1f0cffc9ef9fb378fd2bb024e406f84606ade576

6 years agoMerge "objectcache: Use faster getArrayCopy() in WAN cache methods"
jenkins-bot [Sat, 10 Jun 2017 15:38:29 +0000 (15:38 +0000)]
Merge "objectcache: Use faster getArrayCopy() in WAN cache methods"

6 years agoMerge "Make DeferredUpdates detect LBFactory transaction rounds"
jenkins-bot [Sat, 10 Jun 2017 15:35:46 +0000 (15:35 +0000)]
Merge "Make DeferredUpdates detect LBFactory transaction rounds"

6 years agoobjectcache: Use faster getArrayCopy() in WAN cache methods
Aaron Schulz [Thu, 8 Jun 2017 14:49:28 +0000 (07:49 -0700)]
objectcache: Use faster getArrayCopy() in WAN cache methods

Change-Id: I5f0543a59bdc59656c54fab4d7c4ae33fd233f9a

6 years agoMake DeferredUpdates detect LBFactory transaction rounds
Aaron Schulz [Fri, 9 Jun 2017 02:56:02 +0000 (19:56 -0700)]
Make DeferredUpdates detect LBFactory transaction rounds

Previously, tryOpportunisticExecute() tried to nest transaction rounds,
which would fail. Added LBFactory::hasTransactionRound() as needed.

Also cleaned up some unqualified class names in callbacks and set the
PRESEND flag for the JobQueueDB AutoCommitUpdate callback. Use the
proper getMasterDB() method while at it. These follow up 24842cfac.

Bug: T154425
Change-Id: Ib1d38f68bd217903d1a7d46fb15b7d7d9620daa6

6 years agoMerge "Remove id selector for toctitle"
jenkins-bot [Sat, 10 Jun 2017 14:51:28 +0000 (14:51 +0000)]
Merge "Remove id selector for toctitle"

6 years agoMerge "Fix SqlBagOStuff exptime uniqueness assumption"
jenkins-bot [Sat, 10 Jun 2017 12:40:07 +0000 (12:40 +0000)]
Merge "Fix SqlBagOStuff exptime uniqueness assumption"

6 years agoFix SqlBagOStuff exptime uniqueness assumption
Tim Starling [Sat, 10 Jun 2017 10:54:23 +0000 (20:54 +1000)]
Fix SqlBagOStuff exptime uniqueness assumption

The WMF parser cache tables have some 30000 rows with an identical, old
expiry time. So each time deleteObjectsExpiringBefore() is run, the
first batch on each table is correct, but the keys for the second batch
are selected with exptime > X, where X is shared exptime of the many old
rows.

So, use exptime >= X instead.

Change-Id: I6853f64f88f65d4529be2a42c9ed70cfa62cf653

6 years agoStart a very basic version of Special:PageData
Amir Sarabadani [Thu, 1 Jun 2017 15:39:21 +0000 (20:09 +0430)]
Start a very basic version of Special:PageData

Bug: T163923
Change-Id: I2a1a12f20a38d8d3c50a8f6c9a363be1cb656c70

6 years agoMove HttpAcceptNegotiator and HttpAcceptParser from Wikibase to core
Amir Sarabadani [Mon, 29 May 2017 23:41:15 +0000 (01:41 +0200)]
Move HttpAcceptNegotiator and HttpAcceptParser from Wikibase to core

This will be needed for implementing Special:PageData

Bug: T163923
Change-Id: I2315d7dcdfa5973998917af311ebecc855b37f73

6 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Fri, 9 Jun 2017 19:57:07 +0000 (21:57 +0200)]
Localisation updates from https://translatewiki.net.

Change-Id: I1c435df7c4d1a6e081cbc708c20e55a62933c567

6 years agoReplace deprecated $wgDummyLanguageCodes in WebInstallerLanguage.php
Fomafix [Thu, 9 Mar 2017 07:33:10 +0000 (08:33 +0100)]
Replace deprecated $wgDummyLanguageCodes in WebInstallerLanguage.php

The internal language codes of the reserved for local use area 'qqq' and 'qqx'
are not in Language::fetchLanguageNames().

The check for deprecated language codes can removed, when they are removed
from Language::fetchLanguageNames().

Change-Id: I5d67ac3f9fbf341ee6bd84094fb671e97e512dd4

6 years agoMerge "Remove unused key in WANObjectCache::newEmpty()"
jenkins-bot [Fri, 9 Jun 2017 00:54:15 +0000 (00:54 +0000)]
Merge "Remove unused key in WANObjectCache::newEmpty()"

6 years agoMerge "ChangesList: Expose basic properties of lines as data attributes"
jenkins-bot [Thu, 8 Jun 2017 23:39:27 +0000 (23:39 +0000)]
Merge "ChangesList: Expose basic properties of lines as data attributes"

6 years agoMerge "Add skipping to nth page option/ability for dump importing process"
jenkins-bot [Thu, 8 Jun 2017 23:29:38 +0000 (23:29 +0000)]
Merge "Add skipping to nth page option/ability for dump importing process"

6 years agoChangesList: Expose basic properties of lines as data attributes
Gergő Tisza [Fri, 10 Feb 2017 05:31:32 +0000 (05:31 +0000)]
ChangesList: Expose basic properties of lines as data attributes

We have several types of change lists (old RC/watchlist/related
changes, enhanced RC/watchlist, history) with slightly different
HTML, each with their own idiosyncracies. JavaScript code trying
to identify lines by log ID / revision ID has to jump through all
kinds of hoops to work with that.

To simplify the lives of frontend / gadget maintainers and provide
something approaching an API for these pages, we now expose the basic
attributes of each change line (revision ID for edits, log type/action
and ID for log events) as data attributes.

The OldChangesListRecentChangesLine, EnhancedChangesListModifyLineData,
EnhancedChangesListModifyBlockLineData, PageHistoryLine,
ContributionsLineEnding and DeletedContributionsLineEnding hooks
are updated accordingly. New hooks (LogEventsListLineEnding and
NewPagesLineEnding) are added for the change list pages which did
not yet have them.

Change-Id: I6dd006d0b1b0fd35c0020f0f9eea9113eca30b35

6 years agoAdd skipping to nth page option/ability for dump importing process
Mehmet Mert Yıldıran [Fri, 26 May 2017 01:54:32 +0000 (04:54 +0300)]
Add skipping to nth page option/ability for dump importing process

Usage: php importDump.php --skip-to 271500 /path_to/dumpfile.xml.gz

When importing a database dump and the import process crashes
(for random reasons) after a certain number of pages, the
"--skip-to" parameter allows restarting the import process at
a certain page instead of starting the import from scratch.

Change-Id: Ib36063b69d6846fc197800bba44287493b0632c0

6 years agoAllow CategoryPageView to set $mCategoryViewerClass
Louperivois [Thu, 8 Jun 2017 20:35:00 +0000 (16:35 -0400)]
Allow CategoryPageView to set $mCategoryViewerClass

Bug: T166483
Change-Id: I9937148dd8114e7167d6a581e64bfed5fdcc568e