[MediaWiki-commits] [Gerrit] wikimedia/portals[master]: Adding Node 6 compatibility to dependancies

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Adding Node 6 compatibility to dependancies
..


Adding Node 6 compatibility to dependancies

Making the gulp tasks work with Node 6.
- fixing `gulp sprite` by swapping out the official
  version of sprity for a forked one that works with
  node 6. See https://github.com/sprity/sprity/pull/71
- fixing `gulp fetch-meta` by replace `gulp-download`
  with a curl command.
- upgrading all npm packages.

This patch requires deleting your node_modules dir
and doing a fresh npm install.

Bug: T150190
Change-Id: Ia031b43aed5a293c0fa313149503e3ac60122cd3
---
M gulpfile.js
M package.json
2 files changed, 16 insertions(+), 30 deletions(-)

Approvals:
  MarcoAurelio: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/gulpfile.js b/gulpfile.js
index c48a570..11ac713 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -11,6 +11,7 @@
imageminZopfli = require( 'imagemin-zopfli' ),
siteStats = require( './data/site-stats' ),
fs = require( 'fs' ),
+   exec = require( 'child_process' ).exec,
sprity = require( 'sprity' ),
postCSSNext = require( 'postcss-cssnext' ),
postCSSImport = require( 'postcss-import' ),
@@ -103,7 +104,7 @@
compatibility: 'ie7',
keepSpecialComments: '0'
};
-   return plugins.minifyCss.call( this, options );
+   return plugins.cleanCss.call( this, options );
};
 
config.inline = {
@@ -341,21 +342,11 @@
var portalsFromMeta = [ 'wikibooks.org', 'wikimedia.org', 
'wikinews.org', 'wikiquote.org', 'wikiversity.org', 'wikivoyage.org', 
'wiktionary.org' ];
 
portalsFromMeta.forEach( function ( wiki ) {
-   plugins.downloader( {
-   fileName: 'index.html',
-   request: {
-   url: 
'https://meta.wikimedia.org/w/index.php?title=Www.' + wiki + 
'_template=raw'
-   }
-   } ).pipe( gulp.dest( 'prod/' + wiki + '/' ) );
+   exec( ' curl -Lo prod/' + wiki + '/index.html  
"https://meta.wikimedia.org/w/index.php?title=Www.' + wiki + 
'_template=raw" ' );
} );
 
} else {
-   plugins.downloader( {
-   fileName: 'index.html',
-   request: {
-   url: 
'https://meta.wikimedia.org/w/index.php?title=Www.' + portalParam + 
'_template=raw'
-   }
-   } ).pipe( gulp.dest( getProdDir() ) );
+   exec( ' curl -Lo ' + getProdDir() + 'index.html  
"https://meta.wikimedia.org/w/index.php?title=Www.' + portalParam + 
'_template=raw" ' );
}
 
 } );
diff --git a/package.json b/package.json
index 7bcfad7..f0799d3 100644
--- a/package.json
+++ b/package.json
@@ -11,44 +11,39 @@
   "devDependencies": {
 "bluebird": "^3.0.5",
 "casperjs": "git+https://github.com/n1k0/casperjs.git;,
-"cssnext": "^1.8.4",
-"deepmerge": "^0.2.10",
+"deepmerge": "^1.2.0",
 "del": "^2.2.0",
-"gulp": "^3.9.0",
-"gulp-compile-handlebars": "^0.5.0",
-"gulp-downloader": "^1.0.4",
-"gulp-htmlmin": "^1.2.0",
+"gulp": "^3.9.1",
+"gulp-clean-css": "^2.0.13",
+"gulp-compile-handlebars": "^0.6.1",
+"gulp-htmlmin": "^3.0.0",
 "gulp-if": "^2.0.0",
 "gulp-imagemin": "^3.0.3",
 "gulp-inline": "^0.1.0",
-"gulp-jscs": "^3.0.2",
+"gulp-jscs": "^4.0.0",
 "gulp-jshint": "^2.0.0",
 "gulp-load-plugins": "^1.0.0",
-"gulp-minify-css": "^1.2.1",
 "gulp-postcss": "^6.0.1",
 "gulp-rename": "^1.2.2",
-"gulp-rev": "^6.0.1",
+"gulp-rev": "^7.1.2",
 "gulp-rev-replace": "^0.4.3",
 "gulp-stylelint": "^3.5.0",
-"gulp-uglify": "^1.4.2",
+"gulp-uglify": "^2.0.0",
 "gulp-useref": "^3.0.5",
 "handlebars": "^4.0.4",
 "imagemin-pngquant": "^5.0.0",
 "imagemin-zopfli": "^5.0.0",
 "jshint": "^2.9.2",
-"lwip": "0.0.9",
 "moment": "^2.10.6",
+"phantomjs-prebuilt": "^2.1.3",
 "postcss-cssnext": "^2.4.0",
 "postcss-import": "^8.0.2",
 "postcss-reporter": "^2.0.0",
-"preq": "^0.4.6",
-"sprity": "^1.0.8",
+"preq": "^0.4.12",
+"sprity": "git+https://github.com/nealfennimore/sprity;,
 "stylelint-config-wikimedia": "^0.3.0",
 "sync-request": "^3.0.1",
 "underscore": "^1.8.3",
-"yargs": "^3.29.0"
-  },
-  "dependencies": {
-"phantomjs-prebuilt": "^2.1.3"
+"yargs": "^6.3.0"
   }
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/314592
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia031b43aed5a293c0fa313149503e3ac60122cd3
Gerrit-PatchSet: 8
Gerrit-Project: wikimedia/portals
Gerrit-Branch: 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: wdqs - upgrade to Java 8

2016-12-05 Thread Gehel (Code Review)
Gehel has submitted this change and it was merged.

Change subject: wdqs - upgrade to Java 8
..


wdqs - upgrade to Java 8

Change-Id: I879f5c738787266fd8e3108c5387797fe1618da9
---
M modules/wdqs/manifests/packages.pp
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Gehel: Looks good to me, approved
  Smalyshev: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/modules/wdqs/manifests/packages.pp 
b/modules/wdqs/manifests/packages.pp
index 1dd68ab..7ab4799e 100644
--- a/modules/wdqs/manifests/packages.pp
+++ b/modules/wdqs/manifests/packages.pp
@@ -5,6 +5,6 @@
 class wdqs::packages {
 include ::java::tools
 
-require_package('openjdk-7-jdk')
+require_package('openjdk-8-jdk')
 require_package('curl')
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/324763
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I879f5c738787266fd8e3108c5387797fe1618da9
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Gehel 
Gerrit-Reviewer: Gehel 
Gerrit-Reviewer: Smalyshev 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] pywikibot/core[master]: Improve fake user agent usage control

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Improve fake user agent usage control
..


Improve fake user agent usage control

comms.http.get_fake_user_agent() is renamed to fake_user_agent() to match the 
style of user_agent(). Logic checking config variable fake_user_agent is 
removed, as it should not be responsible for deciding whether if fake UA should 
be used. Test cases testing the config-checking logic are removed.

The use_fake_user_agent argument is added to comms.http.fetch(), which will 
specify if fake UAs should be used when the method is called to make HTTP 
requests. Test cases testing this logic are added.

The fake_user_agent config variable is deprecated. fake_user_agent_default is 
introduced to set per-script behaviour. fake_user_agent_exceptions is 
introduced to set per-domain behaviours (will be checked by fetch()).

Bug: T152075
Change-Id: I28594fd1b5ccb6ed3e885db5600bb0464dccfa0e
---
M pywikibot/comms/http.py
M pywikibot/config2.py
M scripts/reflinks.py
M scripts/weblinkchecker.py
M tests/http_tests.py
5 files changed, 186 insertions(+), 61 deletions(-)

Approvals:
  John Vandenberg: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/pywikibot/comms/http.py b/pywikibot/comms/http.py
index 908f3f1..7bf6235 100644
--- a/pywikibot/comms/http.py
+++ b/pywikibot/comms/http.py
@@ -38,10 +38,11 @@
 
 if sys.version_info[0] > 2:
 from http import cookiejar as cookielib
-from urllib.parse import quote
+from urllib.parse import quote, urlparse
 else:
 import cookielib
 from urllib2 import quote
+from urlparse import urlparse
 
 from pywikibot import config
 
@@ -53,6 +54,7 @@
 )
 from pywikibot.logging import critical, debug, error, log, warning
 from pywikibot.tools import (
+deprecated,
 deprecate_arg,
 file_mode_checker,
 issue_deprecation_warning,
@@ -234,31 +236,43 @@
 return formatted
 
 
+@deprecated('pywikibot.comms.http.fake_user_agent')
 def get_fake_user_agent():
 """
-Return a user agent to be used when faking a web browser.
+Return a fake user agent depending on `fake_user_agent` option in config.
+
+Deprecated, use fake_user_agent() instead.
 
 @rtype: str
 """
-# Check fake_user_agent configuration variable
 if isinstance(config.fake_user_agent, StringTypes):
-return pywikibot.config2.fake_user_agent
+return config.fake_user_agent
+elif config.fake_user_agent or config.fake_user_agent is None:
+return fake_user_agent()
+else:
+return user_agent()
 
-if config.fake_user_agent is None or config.fake_user_agent is True:
-try:
-import browseragents
-return browseragents.core.random()
-except ImportError:
-pass
 
-try:
-import fake_useragent
-return fake_useragent.fake.UserAgent().random
-except ImportError:
-pass
+def fake_user_agent():
+"""
+Return a fake user agent.
 
-# Use the default real user agent
-return user_agent()
+@rtype: str
+"""
+try:
+import browseragents
+return browseragents.core.random()
+except ImportError:
+pass
+
+try:
+import fake_useragent
+return fake_useragent.fake.UserAgent().random
+except ImportError:
+pass
+
+raise ImportError(  # Actually complain when neither is installed.
+'Either browseragents or fake_useragent must be installed to get fake 
UAs.')
 
 
 @deprecate_arg('ssl', None)
@@ -443,7 +457,7 @@
 
 
 def fetch(uri, method="GET", body=None, headers=None,
-  default_error_handling=True, **kwargs):
+  default_error_handling=True, use_fake_user_agent=False, **kwargs):
 """
 Blocking HTTP request.
 
@@ -454,8 +468,27 @@
 
 @param default_error_handling: Use default error handling
 @type default_error_handling: bool
+@type use_fake_user_agent: bool, str
+@param use_fake_user_agent: Set to True to use fake UA, False to use
+pywikibot's UA, str to specify own UA. This behaviour might be
+overridden by domain in config.
 @rtype: L{threadedhttp.HttpRequest}
 """
+# Change user agent depending on fake UA settings.
+# Set header to new UA if needed.
+headers = headers or {}
+if not headers.get('user-agent', None):  # Skip if already specified in 
request.
+# Get fake UA exceptions from `fake_user_agent_exceptions` config.
+uri_domain = urlparse(uri).netloc
+use_fake_user_agent = config.fake_user_agent_exceptions.get(
+uri_domain, use_fake_user_agent)
+
+if use_fake_user_agent and isinstance(
+use_fake_user_agent, StringTypes):  # Custom UA.
+headers['user-agent'] = use_fake_user_agent
+elif use_fake_user_agent is True:
+headers['user-agent'] = 

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Fix article description subtitle capitalization

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Fix article description subtitle capitalization
..


Fix article description subtitle capitalization

Looks like this got knocked out in a recent commit.  This fixes it.

Change-Id: Id416ffc29007e915900dbdbdec5963a9b7d33637
---
M app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
1 file changed, 2 insertions(+), 1 deletion(-)

Approvals:
  jenkins-bot: Verified
  Niedzielski: Looks good to me, approved



diff --git 
a/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java 
b/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
index cf36120..d4be8ca 100755
--- a/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
+++ b/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
@@ -11,6 +11,7 @@
 import android.view.animation.Animation;
 import android.view.animation.AnimationUtils;
 
+import org.apache.commons.lang3.StringUtils;
 import org.json.JSONException;
 import org.json.JSONObject;
 import org.wikipedia.Constants;
@@ -191,7 +192,7 @@
  * @param description WikiData description to be shown.
  */
 private void layoutWikiDataDescription(@Nullable final String description) 
{
-articleHeaderView.setSubtitle(description);
+articleHeaderView.setSubtitle(StringUtils.capitalize(description));
 }
 
 /**

-- 
To view, visit https://gerrit.wikimedia.org/r/324806
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id416ffc29007e915900dbdbdec5963a9b7d33637
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Mholloway 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Niedzielski 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...ContentTranslation[master]: ContentTranslation.alias.php translations for Bengali

2016-12-05 Thread Aftab (Code Review)
Aftab has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325356

Change subject: ContentTranslation.alias.php translations for Bengali
..

ContentTranslation.alias.php translations for Bengali

Change-Id: Ie216f20b4b76a0d024b3c6f6526716b8c63ffcad
---
M ContentTranslation.alias.php
1 file changed, 6 insertions(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ContentTranslation 
refs/changes/56/325356/2

diff --git a/ContentTranslation.alias.php b/ContentTranslation.alias.php
index 7c9aa21..e0e88dc 100644
--- a/ContentTranslation.alias.php
+++ b/ContentTranslation.alias.php
@@ -35,6 +35,12 @@
'ContentTranslationStats' => array( 'ContentTranslationStats' ),
 );
 
+/** Bengali (বাংলা) */
+$specialPageAliases['bn'] = array(
+   'ContentTranslation' => array( 'বিষয়বস্তু_অনুবাদ' ),
+   'ContentTranslationStats' => array( 'বিষয়বস্তু_অনুবাদের_পরিসংখ্যান' ),
+);
+
 /** German (Deutsch) */
 $specialPageAliases['de'] = array(
'ContentTranslation' => array( 'Inhaltsübersetzung' ),

-- 
To view, visit https://gerrit.wikimedia.org/r/325356
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie216f20b4b76a0d024b3c6f6526716b8c63ffcad
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Aftab 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: phpunit: Make getResourceLoaderContext() more extendable

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: phpunit: Make getResourceLoaderContext() more extendable
..


phpunit: Make getResourceLoaderContext() more extendable

This makes it easier to add other options in the future,
such as setting 'modules' in the context to something else.

Change-Id: I53c25fa7ad705cc34e44f95e4f87eb53612d800e
---
M tests/phpunit/ResourceLoaderTestCase.php
M tests/phpunit/includes/resourceloader/ResourceLoaderFileModuleTest.php
M tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php
3 files changed, 30 insertions(+), 12 deletions(-)

Approvals:
  Catrope: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/tests/phpunit/ResourceLoaderTestCase.php 
b/tests/phpunit/ResourceLoaderTestCase.php
index baa481e..45cfdbf 100644
--- a/tests/phpunit/ResourceLoaderTestCase.php
+++ b/tests/phpunit/ResourceLoaderTestCase.php
@@ -11,14 +11,23 @@
const BLANK_VERSION = '09p30q0';
 
/**
-* @param string $lang
-* @param string $dir
+* @param array|string $options Language code or options array
+* - string 'lang' Language code
+* - string 'dir' Language direction (ltr or rtl)
 * @return ResourceLoaderContext
 */
-   protected function getResourceLoaderContext( $lang = 'en', $dir = 'ltr' 
) {
+   protected function getResourceLoaderContext( $options = [] ) {
+   if ( is_string( $options ) ) {
+   // Back-compat for extension tests
+   $options = [ 'lang' => $options ];
+   }
+   $options += [
+   'lang' => 'en',
+   'dir' => 'ltr',
+   ];
$resourceLoader = new ResourceLoader();
$request = new FauxRequest( [
-   'lang' => $lang,
+   'lang' => $options['lang'],
'modules' => 'startup',
'only' => 'scripts',
'skin' => 'vector',
@@ -28,7 +37,7 @@
->setConstructorArgs( [ $resourceLoader, $request ] )
->setMethods( [ 'getDirection' ] )
->getMock();
-   $ctx->method( 'getDirection' )->willReturn( $dir );
+   $ctx->method( 'getDirection' )->willReturn( $options['dir'] );
return $ctx;
}
 
diff --git 
a/tests/phpunit/includes/resourceloader/ResourceLoaderFileModuleTest.php 
b/tests/phpunit/includes/resourceloader/ResourceLoaderFileModuleTest.php
index 8b29983..4a3b90a 100644
--- a/tests/phpunit/includes/resourceloader/ResourceLoaderFileModuleTest.php
+++ b/tests/phpunit/includes/resourceloader/ResourceLoaderFileModuleTest.php
@@ -130,7 +130,7 @@
$modules = self::getModules();
$rl = new ResourceLoaderFileModule( $modules[$name] );
$rl->setName( $name );
-   $ctx = $this->getResourceLoaderContext( 'en', 'ltr' );
+   $ctx = $this->getResourceLoaderContext();
$this->assertEquals( $rl->getScript( $ctx ), $expected );
}
 
@@ -210,8 +210,14 @@
] );
$expectedModule->setName( 'testing' );
 
-   $contextLtr = $this->getResourceLoaderContext( 'en', 'ltr' );
-   $contextRtl = $this->getResourceLoaderContext( 'he', 'rtl' );
+   $contextLtr = $this->getResourceLoaderContext( [
+   'lang' => 'en',
+   'dir' => 'ltr',
+   ] );
+   $contextRtl = $this->getResourceLoaderContext( [
+   'lang' => 'he',
+   'dir' => 'rtl',
+   ] );
 
// Since we want to compare the effect of @noflip+@embed 
against the effect of just @embed, and
// the @noflip annotations are always preserved, we need to 
strip them first.
@@ -282,9 +288,9 @@
'File has leading BOM'
);
 
-   $contextLtr = $this->getResourceLoaderContext( 'en', 'ltr' );
+   $context = $this->getResourceLoaderContext();
$this->assertEquals(
-   $testModule->getStyles( $contextLtr ),
+   $testModule->getStyles( $context ),
[ 'all' => ".efbbbf_bom_char_at_start_of_file {}\n" ],
'Leading BOM removed when concatenating files'
);
diff --git a/tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php 
b/tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php
index 179a8ed..84b56d4 100644
--- a/tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php
+++ b/tests/phpunit/includes/resourceloader/ResourceLoaderImageTest.php
@@ -61,7 +61,10 @@

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Bump versionCode

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Bump versionCode
..


Bump versionCode

Change-Id: If4203873101395655f93da02b8ed7f8af2f9e2f7
---
M app/build.gradle
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Dbrant: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/app/build.gradle b/app/build.gradle
index a101d9f..cc05015 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -54,7 +54,7 @@
 applicationId 'org.wikipedia'
 minSdkVersion 16
 targetSdkVersion 25
-versionCode 180
+versionCode 181
 testApplicationId 'org.wikipedia.test'
 testInstrumentationRunner 'org.wikipedia.test.AndroidTestRunner'
 vectorDrawables.useSupportLibrary = true

-- 
To view, visit https://gerrit.wikimedia.org/r/325354
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If4203873101395655f93da02b8ed7f8af2f9e2f7
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Dbrant 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Niedzielski 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...mobileapps[master]: Temporarily skip Wikivoyage geo unit test

2016-12-05 Thread Fjalapeno (Code Review)
Fjalapeno has submitted this change and it was merged.

Change subject: Temporarily skip Wikivoyage geo unit test
..


Temporarily skip Wikivoyage geo unit test

A test was broken by an underlying content change (probably a template
change).

Skip it for now so it's not blocking other work and fix or remove the
test.  (Why are we testing against Wikivoyage?)

Change-Id: I32cfc52096cf292c2e2bbd65544961bacffd352e
---
M test/features/mobile-sections-lead/pagecontent.js
1 file changed, 2 insertions(+), 1 deletion(-)

Approvals:
  Fjalapeno: Verified; Looks good to me, approved



diff --git a/test/features/mobile-sections-lead/pagecontent.js 
b/test/features/mobile-sections-lead/pagecontent.js
index c7f1b9e..5b41378 100644
--- a/test/features/mobile-sections-lead/pagecontent.js
+++ b/test/features/mobile-sections-lead/pagecontent.js
@@ -121,7 +121,8 @@
 assert.deepEqual(lead.geo.longitude, 28.88305556);
 });
 });
-it('Wikivoyage en Paris should have a lead object with a geo property', () 
=> {
+// TODO: FIX OR REMOVE
+it.skip('Wikivoyage en Paris should have a lead object with a geo 
property', () => {
 const uri = 
`${server.config.uri}en.wikivoyage.org/v1/page/mobile-sections-lead/Paris`;
 return preq.get({ uri })
 .then((res) => {

-- 
To view, visit https://gerrit.wikimedia.org/r/325342
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I32cfc52096cf292c2e2bbd65544961bacffd352e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/mobileapps
Gerrit-Branch: master
Gerrit-Owner: Mholloway 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Fjalapeno 
Gerrit-Reviewer: GWicke 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Jhernandez 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Mhurd 
Gerrit-Reviewer: Mobrovac 
Gerrit-Reviewer: Niedzielski 
Gerrit-Reviewer: Ppchelko 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageForms[master]: Added "datetimepicker" input type from Semantic Forms Inputs

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Added "datetimepicker" input type from Semantic Forms Inputs
..


Added "datetimepicker" input type from Semantic Forms Inputs

Change-Id: Ieb6e8348c64cd0d0cf0c8fe86f776d393fe7d65c
---
M PageForms.php
M extension.json
M includes/PF_FormPrinter.php
A includes/forminputs/PF_DateTimePicker.php
A includes/forminputs/PF_TimePickerInput.php
A libs/PF_datetimepicker.js
A libs/PF_timepicker.js
A skins/PF_Timepicker.css
8 files changed, 766 insertions(+), 0 deletions(-)

Approvals:
  Yaron Koren: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/PageForms.php b/PageForms.php
index 2f59d37..dfffafe 100644
--- a/PageForms.php
+++ b/PageForms.php
@@ -210,6 +210,8 @@
 $GLOBALS['wgAutoloadClasses']['PFComboBoxInput'] = __DIR__ . 
'/includes/forminputs/PF_ComboBoxInput.php';
 $GLOBALS['wgAutoloadClasses']['PFDateInput'] = __DIR__ . 
'/includes/forminputs/PF_DateInput.php';
 $GLOBALS['wgAutoloadClasses']['PFDatePickerInput'] = __DIR__ . 
'/includes/forminputs/PF_DatePickerInput.php';
+$GLOBALS['wgAutoloadClasses']['PFTimePickerInput'] = __DIR__ . 
'/includes/forminputs/PF_TimePickerInput.php';
+$GLOBALS['wgAutoloadClasses']['PFDateTimePicker'] = __DIR__ . 
'/includes/forminputs/PF_DateTimePicker.php';
 $GLOBALS['wgAutoloadClasses']['PFDateTimeInput'] = __DIR__ . 
'/includes/forminputs/PF_DateTimeInput.php';
 $GLOBALS['wgAutoloadClasses']['PFYearInput'] = __DIR__ . 
'/includes/forminputs/PF_YearInput.php';
 $GLOBALS['wgAutoloadClasses']['PFTreeInput'] = __DIR__ . 
'/includes/forminputs/PF_TreeInput.php';
@@ -339,6 +341,23 @@
),
'position' => 'bottom', // MW 1.26
),
+   'ext.pageforms.timepicker' => $wgPageFormsResourceTemplate + array(
+   'scripts' => array(
+   'libs/PF_timepicker.js',
+   ),
+   'styles' => 'skins/PF_Timepicker.css',
+   'position' => 'bottom', // MW 1.26
+   ),
+   'ext.pageforms.datetimepicker' => $wgPageFormsResourceTemplate + array(
+   'scripts' => array(
+   'libs/PF_datetimepicker.js',
+   ),
+   'dependencies' => array(
+   'ext.pageforms.datepicker',
+   'ext.pageforms.timepicker'
+   ),
+   'position' => 'bottom', // MW 1.26
+   ),
'ext.pageforms.regexp' => $wgPageFormsResourceTemplate + array(
'scripts' => 'libs/PF_regexp.js',
'dependencies' => array(
diff --git a/extension.json b/extension.json
index ad5658f..425ce4f 100644
--- a/extension.json
+++ b/extension.json
@@ -129,6 +129,8 @@
"PFComboBoxInput": "includes/forminputs/PF_ComboBoxInput.php",
"PFDateInput": "includes/forminputs/PF_DateInput.php",
"PFDatePickerInput": 
"includes/forminputs/PF_DatePickerInput.php",
+   "PFTimePickerInput": 
"includes/forminputs/PF_TimePickerInput.php",
+   "PFDateTimePicker": "includes/forminputs/PF_DateTimePicker.php",
"PFDateTimeInput": "includes/forminputs/PF_DateTimeInput.php",
"PFYearInput": "includes/forminputs/PF_YearInput.php",
"PFTreeInput": "includes/forminputs/PF_TreeInput.php",
@@ -267,6 +269,19 @@
],
"position": "bottom"
},
+   "ext.pageforms.timepicker": {
+   "scripts": "libs/PF_timepicker.js",
+   "styles": "skins/PF_Timepicker.css",
+   "position": "bottom"
+   },
+   "ext.pageforms.datetimepicker": {
+   "scripts": "libs/PF_datetimepicker.js",
+   "dependencies": [
+   "ext.pageforms.datepicker",
+   "ext.pageforms.timepicker"
+   ],
+   "position": "bottom"
+   },
"ext.pageforms.regexp": {
"scripts": "libs/PF_regexp.js",
"dependencies": [
diff --git a/includes/PF_FormPrinter.php b/includes/PF_FormPrinter.php
index 1b87ae0..22cb60d 100644
--- a/includes/PF_FormPrinter.php
+++ b/includes/PF_FormPrinter.php
@@ -44,6 +44,7 @@
$this->registerInputType( 'PFTextAreaWithAutocompleteInput' );
$this->registerInputType( 'PFDateInput' );
$this->registerInputType( 'PFDatePickerInput' );
+   $this->registerInputType( 'PFDateTimePicker' );
$this->registerInputType( 'PFDateTimeInput' );
$this->registerInputType( 'PFYearInput' );
$this->registerInputType( 'PFCheckboxInput' );
diff --git a/includes/forminputs/PF_DateTimePicker.php 
b/includes/forminputs/PF_DateTimePicker.php
new 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: Labs ldap: Hide the novaobserver account from everyone but ...

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325371

Change subject: Labs ldap:  Hide the novaobserver account from everyone but 
keystone
..

Labs ldap:  Hide the novaobserver account from everyone but keystone

Bug: T150092
Change-Id: I10ea7b203fa5fed10e0110ab844c15eb6dcac4d8
---
M modules/openldap/templates/labs-acls.erb
M modules/role/manifests/openldap/labs.pp
2 files changed, 8 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/71/325371/1

diff --git a/modules/openldap/templates/labs-acls.erb 
b/modules/openldap/templates/labs-acls.erb
index d2a91ed..a5cb167 100644
--- a/modules/openldap/templates/labs-acls.erb
+++ b/modules/openldap/templates/labs-acls.erb
@@ -9,3 +9,9 @@
 # novaadmin needs to run queries on all users.  10,000 users is less than
 #  'unlimited' but should keep us happy for a year at least :/
 limits dn.exact="uid=novaadmin,ou=people,dc=wikimedia,dc=org" time=unlimited 
size=1
+
+# novaobserver is an account used only for keystone access.  We don't want it
+#  to appear on wikitech, gerrit, etc. so limit access only to the keystone 
host
+access to dn=uid=novaobserver,ou=people,dc=wikimedia,dc=org
+   by peername.ip=<%= @labs_keystone_ip %>  users read
+   by * break
diff --git a/modules/role/manifests/openldap/labs.pp 
b/modules/role/manifests/openldap/labs.pp
index ba95b10..a16d517 100644
--- a/modules/role/manifests/openldap/labs.pp
+++ b/modules/role/manifests/openldap/labs.pp
@@ -7,6 +7,8 @@
 $ldapconfig = hiera_hash('labsldapconfig', {})
 $ldap_labs_hostname = $ldapconfig['hostname']
 
+$labs_keystone_ip = ipresolve(hiera('labs_keystone_host'),4)
+
 system::role { 'role::openldap::labs':
 description => 'LDAP servers for labs (based on OpenLDAP)'
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/325371
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I10ea7b203fa5fed10e0110ab844c15eb6dcac4d8
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Update: fix card enter / exit animations when added / remove...

2016-12-05 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325355

Change subject: Update: fix card enter / exit animations when added / removed 
by button tap
..

Update: fix card enter / exit animations when added / removed by button tap

Change-Id: Iae02e654f17c7e751f4a8bacd03809e5de259d31
---
M app/src/main/java/org/wikipedia/feed/FeedCoordinatorBase.java
M app/src/main/java/org/wikipedia/feed/FeedFragment.java
2 files changed, 25 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia 
refs/changes/55/325355/1

diff --git a/app/src/main/java/org/wikipedia/feed/FeedCoordinatorBase.java 
b/app/src/main/java/org/wikipedia/feed/FeedCoordinatorBase.java
index 417711e..a1acd39 100644
--- a/app/src/main/java/org/wikipedia/feed/FeedCoordinatorBase.java
+++ b/app/src/main/java/org/wikipedia/feed/FeedCoordinatorBase.java
@@ -21,7 +21,10 @@
 private static final int MAX_HIDDEN_CARDS = 100;
 
 public interface FeedUpdateListener {
+// todo: should we remove update?
 void update(List cards);
+void insert(Card card, int pos);
+void remove(Card card, int pos);
 }
 
 @NonNull private Context context;
@@ -88,7 +91,7 @@
 cards.remove(card);
 addHiddenCard(card);
 if (updateListener != null) {
-updateListener.update(cards);
+updateListener.remove(card, position);
 }
 return position;
 }
@@ -97,7 +100,7 @@
 cards.add(position, card);
 unHideCard(card);
 if (updateListener != null) {
-updateListener.update(cards);
+updateListener.insert(card, position);
 }
 }
 
@@ -138,6 +141,7 @@
 }
 
 private void appendProgressCard(List cards) {
+// todo: can we consolidate remove / add operations on list?
 cards.remove(progressCard);
 cards.add(progressCard);
 }
diff --git a/app/src/main/java/org/wikipedia/feed/FeedFragment.java 
b/app/src/main/java/org/wikipedia/feed/FeedFragment.java
index e21720e..4078712 100644
--- a/app/src/main/java/org/wikipedia/feed/FeedFragment.java
+++ b/app/src/main/java/org/wikipedia/feed/FeedFragment.java
@@ -111,8 +111,7 @@
 });
 
 coordinator.setFeedUpdateListener(new 
FeedCoordinator.FeedUpdateListener() {
-@Override
-public void update(List cards) {
+@Override public void update(List cards) {
 if (isAdded()) {
 swipeRefreshLayout.setRefreshing(false);
 if (feedView != null && feedAdapter != null) {
@@ -120,6 +119,24 @@
 }
 }
 }
+
+@Override public void insert(Card card, int pos) {
+if (isAdded()) {
+swipeRefreshLayout.setRefreshing(false);
+if (feedView != null && feedAdapter != null) {
+feedAdapter.notifyItemInserted(pos);
+}
+}
+}
+
+@Override public void remove(Card card, int pos) {
+if (isAdded()) {
+swipeRefreshLayout.setRefreshing(false);
+if (feedView != null && feedAdapter != null) {
+feedAdapter.notifyItemRemoved(pos);
+}
+}
+}
 });
 
 return view;

-- 
To view, visit https://gerrit.wikimedia.org/r/325355
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iae02e654f17c7e751f4a8bacd03809e5de259d31
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Niedzielski 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: scap clean plugin: fix minor typo in progress tracking/repor...

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: scap clean plugin: fix minor typo in progress tracking/reporting
..


scap clean plugin: fix minor typo in progress tracking/reporting

Change-Id: Ib9126ccd8e68af732717650796f0313dc88bfdcd
---
M scap/plugins/clean.py
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Chad: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/scap/plugins/clean.py b/scap/plugins/clean.py
index 77c3c19..495f2ce 100644
--- a/scap/plugins/clean.py
+++ b/scap/plugins/clean.py
@@ -22,11 +22,11 @@
 clean_job.exclude_hosts([socket.getfqdn()])
 clean_job.shuffle()
 clean_job.command(self._clean_command(self.config['stage_dir']))
-clean_job.progress('clean-apaches')
+clean_job.progress('clean-masters')
 succeeded, failed = clean_job.run()
 if failed:
 self.get_logger().warning(
-'%d apaches had clean errors', failed)
+'%d masters had clean errors', failed)
 
 # Update apaches
 with log.Timer('clean-apaches', self.get_stats()):

-- 
To view, visit https://gerrit.wikimedia.org/r/325353
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib9126ccd8e68af732717650796f0313dc88bfdcd
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Chad 
Gerrit-Reviewer: Chad 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageForms[master]: Renamed PFDatePickerInput::textHTML() to genericTextHTML(), ...

2016-12-05 Thread Yaron Koren (Code Review)
Yaron Koren has submitted this change and it was merged.

Change subject: Renamed PFDatePickerInput::textHTML() to genericTextHTML(), for 
clarity
..


Renamed PFDatePickerInput::textHTML() to genericTextHTML(), for clarity

Change-Id: Ia4c9852bf39becd9a6c6d768b1e87968c1ecc71d
---
M includes/forminputs/PF_DatePickerInput.php
1 file changed, 2 insertions(+), 3 deletions(-)

Approvals:
  Yaron Koren: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/forminputs/PF_DatePickerInput.php 
b/includes/forminputs/PF_DatePickerInput.php
index f95f0ba..3952c1b 100644
--- a/includes/forminputs/PF_DatePickerInput.php
+++ b/includes/forminputs/PF_DatePickerInput.php
@@ -647,7 +647,7 @@
 */
public function getHtmlText() {
// Assemble HTML code.
-   $html = self::textHTML( $this->mCurrentValue, 
$this->mInputName, $this->mIsDisabled, $this->mOtherArgs, 'input_' . 
$this->mInputNumber );
+   $html = self::genericTextHTML( $this->mCurrentValue, 
$this->mInputName, $this->mIsDisabled, $this->mOtherArgs, 'input_' . 
$this->mInputNumber );
 
if ( ! array_key_exists( 'part of dtp', $this->mOtherArgs ) ) {
// wrap in span (e.g. used for mandatory inputs)
@@ -684,8 +684,7 @@
 * @param string $class
 * @return string the html text of an input element
 */
-   static function textHTML( $currentValue, $inputName, $isDisabled, 
$otherArgs, $inputId = null, $tabIndex = null, $class = '' ) {
-
+   static function genericTextHTML( $currentValue, $inputName, 
$isDisabled, $otherArgs, $inputId = null, $tabIndex = null, $class = '' ) {
global $wgPageFormsTabIndex;
 
// array of attributes to pass to the input field

-- 
To view, visit https://gerrit.wikimedia.org/r/325351
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia4c9852bf39becd9a6c6d768b1e87968c1ecc71d
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/PageForms
Gerrit-Branch: master
Gerrit-Owner: Yaron Koren 
Gerrit-Reviewer: Yaron Koren 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Enable banners on Finnish Wikivoyage

2016-12-05 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325369

Change subject: Enable banners on Finnish Wikivoyage
..

Enable banners on Finnish Wikivoyage

In process convert the whitelist to a blacklist to explicitly
show which projects of Wikivoyage do not have this enabled.

Bug: T152344
Change-Id: I08ed6ecceb7e5ae98100a043b2cd28319c84208a
---
M wmf-config/InitialiseSettings.php
1 file changed, 12 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/69/325369/1

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index a861610..bfeabea 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -17586,15 +17586,18 @@
 // WikidataPageBanner extension (T98029)
 'wmgUseWikidataPageBanner' => [
'default' => false,
-   'enwikivoyage' => true,
-   'eswikivoyage' => true, // T125000
-   'frwikivoyage' => true, // T115023
-   'hewikivoyage' => true, // T140717
-   'itwikivoyage' => true, // T145328
-   'rowikivoyage' => true, // T142963
-   'ruwikivoyage' => true, // T110837
-   'ukwikivoyage' => true, // T121999
-   'zhwikivoyage' => true, // T114334
+   // T125000, T115023, T140717, T145328, T142963
+   // T110837, T121999, T114334, T152344
+   'wikivoyage' => true,
+   'plwikivoyage' => false,
+   'fawikivoyage' => false,
+   'dewikivoyage' => false,
+   'elwikivoyage' => false,
+   'ptwikivoyage' => false,
+   'nlwikivoyage' => false,
+   'rowikivoyage' => false,
+   'svwikivoyage' => false,
+   'viwikivoyage' => false,
'cawiki' => true, // T114392
'enwiki' => true, // T101108
 ],

-- 
To view, visit https://gerrit.wikimedia.org/r/325369
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I08ed6ecceb7e5ae98100a043b2cd28319c84208a
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageForms[master]: Add image TimePickerButton.gif

2016-12-05 Thread Yaron Koren (Code Review)
Yaron Koren has submitted this change and it was merged.

Change subject: Add image TimePickerButton.gif
..


Add image TimePickerButton.gif

Change-Id: Ib1b3e35f2be86f491802c4dcc4aa7223c60f553b
---
A images/TimePickerButton.gif
1 file changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Yaron Koren: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/images/TimePickerButton.gif b/images/TimePickerButton.gif
new file mode 100644
index 000..a9e9b17
--- /dev/null
+++ b/images/TimePickerButton.gif
Binary files differ

-- 
To view, visit https://gerrit.wikimedia.org/r/325367
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib1b3e35f2be86f491802c4dcc4aa7223c60f553b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/PageForms
Gerrit-Branch: master
Gerrit-Owner: Paladox 
Gerrit-Reviewer: Yaron Koren 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...Contributors[master]: Contributors.alias.php translation for Bengali

2016-12-05 Thread Aftab (Code Review)
Aftab has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325357

Change subject: Contributors.alias.php translation for Bengali
..

Contributors.alias.php translation for Bengali

Change-Id: I8fbd442a490bcd9607c9e03ea7d44059b6d122b2
---
M Contributors.alias.php
1 file changed, 5 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Contributors 
refs/changes/57/325357/2

diff --git a/Contributors.alias.php b/Contributors.alias.php
index 09e23fa..1561c53 100644
--- a/Contributors.alias.php
+++ b/Contributors.alias.php
@@ -59,6 +59,11 @@
'Contributors' => array( 'Panyumbang' ),
 );
 
+/** Bengali (বাংলা) */
+$specialPageAliases['bn'] = array(
+   'Contributors' => array( 'অবদানকারীগণ' ),
+);
+
 /** Breton (brezhoneg) */
 $specialPageAliases['br'] = array(
'Contributors' => array( 'Kenlabourerien' ),

-- 
To view, visit https://gerrit.wikimedia.org/r/325357
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8fbd442a490bcd9607c9e03ea7d44059b6d122b2
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Contributors
Gerrit-Branch: master
Gerrit-Owner: Aftab 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...ansible-wikifarm[master]: Updated extensions; Fixed logo issue.

2016-12-05 Thread Cicalese (Code Review)
Cicalese has submitted this change and it was merged.

Change subject: Updated extensions; Fixed logo issue.
..


Updated extensions; Fixed logo issue.

Change-Id: Ic941cb099b253629442a4384099667d59479c36e
---
M group_vars/all/default_extensions
M roles/install_mediawiki/files/Debug.php
M roles/install_mediawiki/templates/LocalSettings.php.j2
3 files changed, 8 insertions(+), 3 deletions(-)

Approvals:
  Cicalese: Verified; Looks good to me, approved



diff --git a/group_vars/all/default_extensions 
b/group_vars/all/default_extensions
index fa08d84..d059035 100644
--- a/group_vars/all/default_extensions
+++ b/group_vars/all/default_extensions
@@ -53,6 +53,10 @@
 composer: "mediawiki/semantic-scribunto"
 version: "dev-master"
 
+  - name: "Header Footer"
+composer: "mediawiki/header-footer"
+version: "dev-master"
+
   - name: "WikiEditor"
 url: "{{ MW_GIT_URL_ROOT }}EWED/extension-wikieditor.git"
 enable: global
@@ -169,6 +173,7 @@
 config: |
   $wgAllowDisplayTitle = true;
   $wgRestrictDisplayTitle = false;
+  $wgDisplayTitleHideSubtitle = true;
 
   - name: "VIKI"
 url: "{{ MW_GIT_URL_ROOT }}EVIK/extension-viki.git"
diff --git a/roles/install_mediawiki/files/Debug.php 
b/roles/install_mediawiki/files/Debug.php
index 9772032..e76ad3d 100644
--- a/roles/install_mediawiki/files/Debug.php
+++ b/roles/install_mediawiki/files/Debug.php
@@ -3,5 +3,5 @@
 #error_reporting( -1 );
 #ini_set( 'display_errors', 1 );
 #$wgResourceLoaderDebug = true;
-#$wgShowExceptionDetails = true;
+#$wgShowDBErrorBacktrace = true;
 #$wgDebugLogFile= "/tmp/MediaWikiDebug.log";
diff --git a/roles/install_mediawiki/templates/LocalSettings.php.j2 
b/roles/install_mediawiki/templates/LocalSettings.php.j2
index d45d520..b69fa68 100644
--- a/roles/install_mediawiki/templates/LocalSettings.php.j2
+++ b/roles/install_mediawiki/templates/LocalSettings.php.j2
@@ -37,12 +37,12 @@
 
 ## The relative URL path to the logo.
 if( file_exists( "$INSTANCE_DIR/branding/logo.png" ) ) {
-  $wgLogo = "/$wgSitename/branding/logo.png";
+  $wgLogo = "$wgServer/$wgSitename/branding/logo.png";
 } else {
   $wgLogo = "$wgResourceBasePath/resources/assets/wiki.png";
 }
 if( file_exists( "$INSTANCE_DIR/branding/favicon.ico" ) ) {
-  $wgFavicon = "/$wgSitename/branding/favicon.ico";
+  $wgFavicon = "$wgServer/$wgSitename/branding/favicon.ico";
 }
 
 require_once( __DIR__ . "/WikiFarm/Email.php" );

-- 
To view, visit https://gerrit.wikimedia.org/r/325345
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic941cb099b253629442a4384099667d59479c36e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/tools/ansible-wikifarm
Gerrit-Branch: master
Gerrit-Owner: Cicalese 
Gerrit-Reviewer: Cicalese 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] integration/config[master]: Add trendingedits packages to CI image

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add trendingedits packages to CI image
..


Add trendingedits packages to CI image

Adds rdkafka libs and development headers, on the same model as other
services. Will be on Jessie instances.

Bug: T151469
Change-Id: I9244aaeb084faf8e486d3553c1db2c40ef6bedc9
---
M dib/puppet/ciimage.pp
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Hashar: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/dib/puppet/ciimage.pp b/dib/puppet/ciimage.pp
index 414b21b..6d11c72 100644
--- a/dib/puppet/ciimage.pp
+++ b/dib/puppet/ciimage.pp
@@ -134,6 +134,7 @@
 # run. NOTE: hiera must have: service::configuration::use_dev_pkgs: true
 include graphoid::packages
 include mathoid::packages
+include trendingedits::packages
 }
 
 ensure_packages(['mariadb-client', 'mariadb-server'])

-- 
To view, visit https://gerrit.wikimedia.org/r/325330
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I9244aaeb084faf8e486d3553c1db2c40ef6bedc9
Gerrit-PatchSet: 1
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Hashar 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...mobileapps[master]: Add new survey link for android

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add new survey link for android
..


Add new survey link for android

Update caption text

Bug:T145830
Change-Id: I6dbb0367a94ddbac24714bd0b36dbc990d993e79
---
M routes/announcements.js
1 file changed, 3 insertions(+), 3 deletions(-)

Approvals:
  Mholloway: Looks good to me, approved
  jenkins-bot: Verified
  Niedzielski: Looks good to me, but someone else must approve



diff --git a/routes/announcements.js b/routes/announcements.js
index 18aaceb..3ba2b4d 100644
--- a/routes/announcements.js
+++ b/routes/announcements.js
@@ -23,7 +23,7 @@
 title: "Take the survey",
 url: 
"https://docs.google.com/forms/d/e/1FAIpQLSdaqvKojvyXGSewEZ395RPOQ6AcD3e87MZnh5pvO7phqqKwVg/viewform;
 },
-caption_HTML: "Survey data handled by a third party. https://wikimediafoundation.org/wiki/Survey_Privacy_Statement\;>Privacy.",
+caption_HTML: "Survey powered by 3rd-party service; see https://wikimediafoundation.org/wiki/Apps_Reader_Motivation_Survey_Privacy_Statement\;>privacy
 statement.",
 countries: [
 "US",
 "CA",
@@ -41,9 +41,9 @@
 text: "Answer three questions and help us improve Wikipedia.",
 action: {
 title: "Take the survey",
-url: 
"https://docs.google.com/forms/d/e/1FAIpQLSdaqvKojvyXGSewEZ395RPOQ6AcD3e87MZnh5pvO7phqqKwVg/viewform;
+url: 
"https://docs.google.com/forms/d/e/1FAIpQLSfqzFyCmoQBs9z8i1PQSY-8hnBpCaRFS0gWGiAvTYFf6Y8WAQ/viewform;
 },
-caption_HTML: "Survey data handled by a third party. https://wikimediafoundation.org/wiki/Survey_Privacy_Statement\;>Privacy.",
+caption_HTML: "Survey powered by 3rd-party service; see https://wikimediafoundation.org/wiki/Apps_Reader_Motivation_Survey_Privacy_Statement\;>privacy
 statement.",
 countries: [
 "US",
 "CA",

-- 
To view, visit https://gerrit.wikimedia.org/r/325335
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6dbb0367a94ddbac24714bd0b36dbc990d993e79
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/services/mobileapps
Gerrit-Branch: master
Gerrit-Owner: Fjalapeno 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: GWicke 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Jhernandez 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Mhurd 
Gerrit-Reviewer: Mobrovac 
Gerrit-Reviewer: Niedzielski 
Gerrit-Reviewer: Ppchelko 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...GlobalUsage[master]: Make Special:GlobalUsage use OOUI

2016-12-05 Thread Ladsgroup (Code Review)
Ladsgroup has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325364

Change subject: Make Special:GlobalUsage use OOUI
..

Make Special:GlobalUsage use OOUI

Bug: T152447
Change-Id: Ibf70f86691b07a5c731c9ddf1b1cd09640eec3d1
---
M SpecialGlobalUsage.php
M i18n/en.json
2 files changed, 73 insertions(+), 21 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/GlobalUsage 
refs/changes/64/325364/1

diff --git a/SpecialGlobalUsage.php b/SpecialGlobalUsage.php
index 75c0506..dabea75 100644
--- a/SpecialGlobalUsage.php
+++ b/SpecialGlobalUsage.php
@@ -52,40 +52,91 @@
private function showForm() {
global $wgScript;
 
+   $this->getOutput()->enableOOUI();
/* Build form */
-   $html = Xml::openElement( 'form', array( 'action' => $wgScript 
) ) . "\n";
-   // Name of SpecialPage
-   $html .= Html::hidden( 'title', 
$this->getPageTitle()->getPrefixedText() ) . "\n";
-   // Limit
-   $html .= Html::hidden( 'limit', $this->getRequest()->getInt( 
'limit', 50 ) );
-   // Input box with target prefilled if available
-   $formContent = "\t" . Xml::input( 'target', 40, is_null( 
$this->target ) ? ''
-   : $this->target->getText() )
-   // Submit button
-   . "\n\t" . Xml::element( 'input', array(
-   'type' => 'submit',
-   'value' => $this->msg( 'globalusage-ok' )->text()
-   ) )
-   // Filter local checkbox
-   . "\n\t" . Xml::checkLabel( $this->msg( 
'globalusage-filterlocal' )->text(),
-   'filterlocal', 'mw-filterlocal', $this->filterLocal ) . 
'';
+   $form = new OOUI\FormLayout( [
+   'method' => 'get',
+   'action' => $wgScript,
+   ] );
+
+   $fields = [];
+   $fields[] = new OOUI\FieldLayout(
+   new OOUI\TextInputWidget( [
+   'name' => 'target',
+   'id' => 'target',
+   'maxLength' => 40,
+   'infusable' => true,
+   'value' => is_null( $this->target ) ? '' : 
$this->target->getText(),
+   ] ),
+   [
+   'label' => $this->msg( 'globalusage-filename' 
)->text(),
+   'align' => 'top',
+   ]
+   );
+
+   // Filter local checkbox
+   $fields[] = new OOUI\FieldLayout(
+   new OOUI\CheckboxInputWidget( [
+   'name' => 'filterlocal',
+   'id' => 'mw-filterlocal',
+   'value' => '1',
+   'selected' => $this->filterLocal,
+   ] ),
+   [
+   'align' => 'inline',
+   'label' => $this->msg( 
'globalusage-filterlocal' )->text(),
+   ]
+   );
+
+   // Submit button
+   $fields[] = new OOUI\FieldLayout(
+   new OOUI\ButtonInputWidget( [
+   'value' => $this->msg( 'globalusage-ok' 
)->text(),
+   'label' => $this->msg( 'globalusage-ok' 
)->text(),
+   'flags' => [ 'primary', 'progressive' ],
+   'type' => 'submit',
+   ] ),
+   [
+   'align' => 'top',
+   ]
+   );
+
+   $fieldset = new OOUI\FieldsetLayout( [
+   'label' => $this->msg( 'globalusage-text' )->text(),
+   'id' => 'globalusage-text',
+   'items' => $fields,
+   ] );
+
 
if ( !is_null( $this->target ) && wfFindFile( $this->target ) ) 
{
// Show the image if it exists
-   $html .= Linker::makeThumbLinkObj(
+   $html = Linker::makeThumbLinkObj(
$this->target,
wfFindFile( $this->target ),
/* $label */ $this->target->getPrefixedText(),
/* $alt */ '', /* $align */ 
$this->getLanguage()->alignEnd(),
-   /* $handlerParams */ array(), /* $framed */ 
false,
+   /* $handlerParams */ [], /* $framed */ false,
/* $manualThumb */ false
);
+   

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Enable ReadMore on mobile jawiki and eswiki

2016-12-05 Thread Bmansurov (Code Review)
Bmansurov has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325365

Change subject: Enable ReadMore on mobile jawiki and eswiki
..

Enable ReadMore on mobile jawiki and eswiki

The ReadMore feature of the RelatedArticles extension is
being enabled on mobile web stable channel of Japanese
and Spanish wikis.

Bug: T151346
Change-Id: I436cd491812c5b58b050bcfbcf77d2a3c79d2a8f
---
M wmf-config/InitialiseSettings.php
1 file changed, 4 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/65/325365/1

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index a861610..cbef34a 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -16325,6 +16325,8 @@
'wikipedia' => true,
'wikivoyage' => true,
'frwikinews' => true, // T143480
+   'jawiki' => true,  // T151346
+   'eswiki' => true  // T151346
 ],
 
 'wmgRelatedArticlesShowInSidebar' => [
@@ -16336,6 +16338,8 @@
'default' => false,
'wikipedia' => true,
'frwikinews' => true, // T143480
+   'jawiki' => true,  // T151346
+   'eswiki' => true  // T151346
 ],
 
 'wmgRelatedArticlesFooterBlacklistedSkins' => [

-- 
To view, visit https://gerrit.wikimedia.org/r/325365
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I436cd491812c5b58b050bcfbcf77d2a3c79d2a8f
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Bmansurov 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Update: don't truncate article descriptions

2016-12-05 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325363

Change subject: Update: don't truncate article descriptions
..

Update: don't truncate article descriptions

Bug: T152213
Change-Id: I747b5f346b4e1d3f864a3e276c78a2608d3dd9db
---
M app/src/main/res/layout/view_article_header.xml
1 file changed, 0 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia 
refs/changes/63/325363/1

diff --git a/app/src/main/res/layout/view_article_header.xml 
b/app/src/main/res/layout/view_article_header.xml
index 250b7a7..c55c590 100644
--- a/app/src/main/res/layout/view_article_header.xml
+++ b/app/src/main/res/layout/view_article_header.xml
@@ -46,8 +46,6 @@
 android:paddingRight="40dp"
 android:textSize="@dimen/descriptionTextSize"
 android:lineSpacingMultiplier="@dimen/lead_subtitle_leading_scalar"
-android:maxLines="2"
-android:ellipsize="end"
 android:textColor="@color/foundation_gray"
 android:textColorLink="@color/foundation_gray"
 android:textColorHighlight="?attr/window_background_color"

-- 
To view, visit https://gerrit.wikimedia.org/r/325363
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I747b5f346b4e1d3f864a3e276c78a2608d3dd9db
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Niedzielski 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...WikimediaEvents[master]: Increase user sampling rate from 1% yo 10%

2016-12-05 Thread JGirault (Code Review)
JGirault has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325362

Change subject: Increase user sampling rate from 1% yo 10%
..

Increase user sampling rate from 1% yo 10%

Bug: T152174
Change-Id: I166e07c238835beace0340dc62438b060d5b095b
---
M modules/ext.wikimediaEvents.kartographer.js
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikimediaEvents 
refs/changes/62/325362/1

diff --git a/modules/ext.wikimediaEvents.kartographer.js 
b/modules/ext.wikimediaEvents.kartographer.js
index 41d14fd..62cd873 100644
--- a/modules/ext.wikimediaEvents.kartographer.js
+++ b/modules/ext.wikimediaEvents.kartographer.js
@@ -9,9 +9,9 @@
var isMobile = mw.config.get( 'skin' ) === 'minerva',
userToken,
trackedFeatures = {},
-   // We only track 1% of the user sessions.
+   // We only track 10% of the user sessions.
// A user session id is defined in a cookie that lasts 10 
minutes.
-   userSampling = 100;
+   userSampling = 10;
 
/**
 * Returns an unique token identifying current user.

-- 
To view, visit https://gerrit.wikimedia.org/r/325362
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I166e07c238835beace0340dc62438b060d5b095b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikimediaEvents
Gerrit-Branch: master
Gerrit-Owner: JGirault 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki/core[wmf/1.29.0-wmf.4]: OOjs UI: Backport I73f95965694ec7fb0fa9a474742286e1105e5c85

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: OOjs UI: Backport I73f95965694ec7fb0fa9a474742286e1105e5c85
..


OOjs UI: Backport I73f95965694ec7fb0fa9a474742286e1105e5c85

Bug: T151061
Change-Id: I715d2ac077c5a6f9de420d90f19ef4b631168f26
---
M resources/lib/oojs-ui/oojs-ui-core.js
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Thcipriani: Looks good to me, approved
  Jforrester: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/resources/lib/oojs-ui/oojs-ui-core.js 
b/resources/lib/oojs-ui/oojs-ui-core.js
index fd4e033..987388e 100644
--- a/resources/lib/oojs-ui/oojs-ui-core.js
+++ b/resources/lib/oojs-ui/oojs-ui-core.js
@@ -10148,7 +10148,7 @@
 
// Mixin constructors
OO.ui.mixin.IconElement.call( this, config );
-   OO.ui.mixin.LabelElement.call( this, $.extend( {}, config, { $label: $( 
'' ) } ) );
+   OO.ui.mixin.LabelElement.call( this, $.extend( {}, config, { $label: $( 
'' ) } ) );
OO.ui.mixin.GroupElement.call( this, config );
 
if ( config.help ) {

-- 
To view, visit https://gerrit.wikimedia.org/r/325246
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I715d2ac077c5a6f9de420d90f19ef4b631168f26
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.29.0-wmf.4
Gerrit-Owner: Bartosz Dziewoński 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Jack Phoenix 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Thcipriani 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki/vendor[wmf/1.29.0-wmf.4]: OOjs UI: Backport I73f95965694ec7fb0fa9a474742286e1105e5c85

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: OOjs UI: Backport I73f95965694ec7fb0fa9a474742286e1105e5c85
..


OOjs UI: Backport I73f95965694ec7fb0fa9a474742286e1105e5c85

Bug: T151061
Change-Id: I715d2ac077c5a6f9de420d90f19ef4b631168f26
---
M oojs/oojs-ui/php/layouts/FieldsetLayout.php
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Thcipriani: Looks good to me, approved
  Jforrester: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/oojs/oojs-ui/php/layouts/FieldsetLayout.php 
b/oojs/oojs-ui/php/layouts/FieldsetLayout.php
index 2a6bb8ce8..74182eb 100644
--- a/oojs/oojs-ui/php/layouts/FieldsetLayout.php
+++ b/oojs/oojs-ui/php/layouts/FieldsetLayout.php
@@ -27,7 +27,7 @@
// Traits
$this->initializeIconElement( $config );
$this->initializeLabelElement( array_merge( $config, [
-   'labelElement' => new Tag( 'legend' )
+   'labelElement' => new Tag( 'div' )
] ) );
$this->initializeGroupElement( $config );
 

-- 
To view, visit https://gerrit.wikimedia.org/r/325247
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I715d2ac077c5a6f9de420d90f19ef4b631168f26
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/vendor
Gerrit-Branch: wmf/1.29.0-wmf.4
Gerrit-Owner: Bartosz Dziewoński 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Thcipriani 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Clarify a comment re: labtest private hiera lookups.

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has submitted this change and it was merged.

Change subject: Clarify a comment re: labtest private hiera lookups.
..


Clarify a comment re: labtest private hiera lookups.

Change-Id: Idde2c5f09ddccb57673fd5c2d73631c5ea845d40
---
M modules/puppetmaster/files/production.hiera.yaml
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Andrew Bogott: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/modules/puppetmaster/files/production.hiera.yaml 
b/modules/puppetmaster/files/production.hiera.yaml
index b75900d..0975900 100644
--- a/modules/puppetmaster/files/production.hiera.yaml
+++ b/modules/puppetmaster/files/production.hiera.yaml
@@ -14,7 +14,7 @@
   - "hosts/%{::hostname}"
   - "regex/%{::fqdn}"
   - "%{::site}"
-  - "private/hosts/%{::hostname}" # TODO: Remove this once labtest realm dies. 
DO NOT USE THIS
+  - "private/hosts/%{::hostname}" # Currently only used for labtest hosts
   - "private/%{::site}"
   - "common"
   - "private/common"

-- 
To view, visit https://gerrit.wikimedia.org/r/324778
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Idde2c5f09ddccb57673fd5c2d73631c5ea845d40
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 
Gerrit-Reviewer: Andrew Bogott 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageForms[master]: Add image TimePickerButton.gif

2016-12-05 Thread Paladox (Code Review)
Paladox has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325367

Change subject: Add image TimePickerButton.gif
..

Add image TimePickerButton.gif

Change-Id: Ib1b3e35f2be86f491802c4dcc4aa7223c60f553b
---
A images/TimePickerButton.gif
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/PageForms 
refs/changes/67/325367/1

diff --git a/images/TimePickerButton.gif b/images/TimePickerButton.gif
new file mode 100644
index 000..a9e9b17
--- /dev/null
+++ b/images/TimePickerButton.gif
Binary files differ

-- 
To view, visit https://gerrit.wikimedia.org/r/325367
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib1b3e35f2be86f491802c4dcc4aa7223c60f553b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/PageForms
Gerrit-Branch: master
Gerrit-Owner: Paladox 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Designate: page if services go down.

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325359

Change subject: Designate:  page if services go down.
..

Designate:  page if services go down.

These services are critical to Labs and CI functionality.

Bug: T152368
Change-Id: I301d99c99dd2538501cb47d67de635f29bfffe11
---
M modules/openstack/manifests/designate/service.pp
1 file changed, 7 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/59/325359/1

diff --git a/modules/openstack/manifests/designate/service.pp 
b/modules/openstack/manifests/designate/service.pp
index 6125838..ca9a224 100644
--- a/modules/openstack/manifests/designate/service.pp
+++ b/modules/openstack/manifests/designate/service.pp
@@ -147,25 +147,32 @@
 require =>  Package['designate'],
 }
 
+# Page if designate processes die.  We only have one of each of these,
+#  and new instance creation will be very broken if services die.
 nrpe::monitor_service { 'check_designate_sink_process':
 description  => 'designate-sink process',
 nrpe_command => "/usr/lib/nagios/plugins/check_procs -c 1: 
--ereg-argument-array '^/usr/bin/python /usr/bin/designate-sink'",
+critical => true,
 }
 nrpe::monitor_service { 'check_designate_api_process':
 description  => 'designate-api process',
 nrpe_command => "/usr/lib/nagios/plugins/check_procs -c 1: 
--ereg-argument-array '^/usr/bin/python /usr/bin/designate-api'",
+critical => true,
 }
 nrpe::monitor_service { 'check_designate_central_process':
 description  => 'designate-central process',
 nrpe_command => "/usr/lib/nagios/plugins/check_procs -c 1: 
--ereg-argument-array '^/usr/bin/python /usr/bin/designate-central'",
+critical => true,
 }
 nrpe::monitor_service { 'check_designate_mdns':
 description  => 'designate-mdns process',
 nrpe_command => "/usr/lib/nagios/plugins/check_procs -c 1: 
--ereg-argument-array '^/usr/bin/python /usr/bin/designate-mdns'",
+critical => true,
 }
 nrpe::monitor_service { 'check_designate_pool-manager':
 description  => 'designate-pool-manager process',
 nrpe_command => "/usr/lib/nagios/plugins/check_procs -c 1: 
--ereg-argument-array '^/usr/bin/python /usr/bin/designate-pool-manager'",
+critical => true,
 }
 
 } else {

-- 
To view, visit https://gerrit.wikimedia.org/r/325359
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I301d99c99dd2538501cb47d67de635f29bfffe11
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Page if a labs dns server stops responding

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325358

Change subject: Page if a labs dns server stops responding
..

Page if a labs dns server stops responding

Bug: T152368
Change-Id: Iccf2f621314dc79ae000d408fac5f6062802e088
---
M modules/role/manifests/labs/dns.pp
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/58/325358/1

diff --git a/modules/role/manifests/labs/dns.pp 
b/modules/role/manifests/labs/dns.pp
index 90b3997..1727661 100644
--- a/modules/role/manifests/labs/dns.pp
+++ b/modules/role/manifests/labs/dns.pp
@@ -137,6 +137,7 @@
 monitoring::service { "${auth_soa_name} Auth DNS TCP":
 host  => $auth_soa_name,
 description   => 'Check for gridmaster host resolution TCP',
+critical  => 'true',
 check_command => 
"check_dig_tcp!${auth_soa_name}!tools-grid-master.tools.eqiad.wmflabs",
 }
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/325358
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iccf2f621314dc79ae000d408fac5f6062802e088
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] wikimedia...tools[master]: Split silverpop export from upload

2016-12-05 Thread Awight (Code Review)
Awight has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325360

Change subject: Split silverpop export from upload
..

Split silverpop export from upload

Bug: T152352
Change-Id: Ifd50947a9753be9fea35bfd64ca021d2da8909db
---
M silverpop_export/export.py
M silverpop_export/update.py
A silverpop_export/upload.py
3 files changed, 50 insertions(+), 13 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/tools 
refs/changes/60/325360/1

diff --git a/silverpop_export/export.py b/silverpop_export/export.py
index ec53199..b063759 100644
--- a/silverpop_export/export.py
+++ b/silverpop_export/export.py
@@ -10,11 +10,13 @@
 
 from database.db import Connection as DbConnection, Query as DbQuery
 import process.lock as lock
-from sftp.client import Client as SftpClient
 import unicode_csv_writer
 
 
-def export_and_upload():
+def export_all():
+"""
+Dump database contents to CSVs.
+"""
 log.info("Begin Silverpop Export")
 config = process.globals.get_config()
 
@@ -31,7 +33,6 @@
 
 export_data(output_path=updatefile)
 export_unsubscribes(output_path=unsubfile)
-upload([updatefile, unsubfile])
 rotate_files()
 
 log.info("End Silverpop Export")
@@ -105,14 +106,6 @@
 )
 
 
-def upload(files=None):
-log.info("Uploading to silverpop")
-sftpc = SftpClient()
-for path in files:
-log.info("Putting file %s" % path)
-sftpc.put(path, os.path.basename(path))
-
-
 def rotate_files():
 config = process.globals.get_config()
 
@@ -147,6 +140,6 @@
 
 lock.begin()
 
-export_and_upload()
+export_all()
 
 lock.end()
diff --git a/silverpop_export/update.py b/silverpop_export/update.py
index 693d9e1..d2bebd7 100644
--- a/silverpop_export/update.py
+++ b/silverpop_export/update.py
@@ -40,6 +40,9 @@
 
 
 def run_queries(db, queries):
+"""
+Build silverpop_export database from CiviCRM.
+"""
 i = 1
 for query in queries:
 no_prefix = query[query.index("\n") + 1:]
@@ -63,7 +66,7 @@
 log.info("Starting update query run")
 run_queries(db, update_queries)
 
-export.export_and_upload()
+export.export_all()
 
 lock.end()
 log.info("End Silverpop Export")
diff --git a/silverpop_export/upload.py b/silverpop_export/upload.py
new file mode 100644
index 000..950a3d4
--- /dev/null
+++ b/silverpop_export/upload.py
@@ -0,0 +1,41 @@
+#!/usr/bin/env python
+
+import glob
+import os
+
+import process
+from process.logging import Logger as log
+from sftp.client import Client as SftpClient
+import process.lock as lock
+
+
+def upload_most_recent():
+"""
+Send recently exported CSVs to Silverpop.
+"""
+config = process.globals.get_config()
+updatesglob = os.path.join(config.working_path, "DatabaseUpdate-*.csv")
+unsubglob = os.path.join(config.working_path, "Unsubscribes-*.csv")
+# Find most recently created export files.
+updatefile = max(glob.iglob(updatesglob), key=os.path.getctime)
+unsubfile = max(glob.iglob(unsubglob), key=os.path.getctime)
+
+upload([updatefile, unsubfile])
+
+
+def upload(files=None):
+log.info("Uploading to silverpop")
+sftpc = SftpClient()
+for path in files:
+log.info("Putting file %s" % path)
+sftpc.put(path, os.path.basename(path))
+
+
+if __name__ == '__main__':
+process.globals.load_config('silverpop_export')
+
+lock.begin()
+
+upload_most_recent()
+
+lock.end()

-- 
To view, visit https://gerrit.wikimedia.org/r/325360
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifd50947a9753be9fea35bfd64ca021d2da8909db
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/tools
Gerrit-Branch: master
Gerrit-Owner: Awight 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageForms[master]: Added "datetimepicker" input type from Semantic Forms Inputs

2016-12-05 Thread Yaron Koren (Code Review)
Yaron Koren has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325361

Change subject: Added "datetimepicker" input type from Semantic Forms Inputs
..

Added "datetimepicker" input type from Semantic Forms Inputs

Change-Id: Ieb6e8348c64cd0d0cf0c8fe86f776d393fe7d65c
---
M PageForms.php
M extension.json
M includes/PF_FormPrinter.php
A includes/forminputs/PF_DateTimePicker.php
A includes/forminputs/PF_TimePickerInput.php
A libs/PF_datetimepicker.js
A libs/PF_timepicker.js
A skins/PF_Timepicker.css
8 files changed, 766 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/PageForms 
refs/changes/61/325361/2

diff --git a/PageForms.php b/PageForms.php
index 2f59d37..dfffafe 100644
--- a/PageForms.php
+++ b/PageForms.php
@@ -210,6 +210,8 @@
 $GLOBALS['wgAutoloadClasses']['PFComboBoxInput'] = __DIR__ . 
'/includes/forminputs/PF_ComboBoxInput.php';
 $GLOBALS['wgAutoloadClasses']['PFDateInput'] = __DIR__ . 
'/includes/forminputs/PF_DateInput.php';
 $GLOBALS['wgAutoloadClasses']['PFDatePickerInput'] = __DIR__ . 
'/includes/forminputs/PF_DatePickerInput.php';
+$GLOBALS['wgAutoloadClasses']['PFTimePickerInput'] = __DIR__ . 
'/includes/forminputs/PF_TimePickerInput.php';
+$GLOBALS['wgAutoloadClasses']['PFDateTimePicker'] = __DIR__ . 
'/includes/forminputs/PF_DateTimePicker.php';
 $GLOBALS['wgAutoloadClasses']['PFDateTimeInput'] = __DIR__ . 
'/includes/forminputs/PF_DateTimeInput.php';
 $GLOBALS['wgAutoloadClasses']['PFYearInput'] = __DIR__ . 
'/includes/forminputs/PF_YearInput.php';
 $GLOBALS['wgAutoloadClasses']['PFTreeInput'] = __DIR__ . 
'/includes/forminputs/PF_TreeInput.php';
@@ -339,6 +341,23 @@
),
'position' => 'bottom', // MW 1.26
),
+   'ext.pageforms.timepicker' => $wgPageFormsResourceTemplate + array(
+   'scripts' => array(
+   'libs/PF_timepicker.js',
+   ),
+   'styles' => 'skins/PF_Timepicker.css',
+   'position' => 'bottom', // MW 1.26
+   ),
+   'ext.pageforms.datetimepicker' => $wgPageFormsResourceTemplate + array(
+   'scripts' => array(
+   'libs/PF_datetimepicker.js',
+   ),
+   'dependencies' => array(
+   'ext.pageforms.datepicker',
+   'ext.pageforms.timepicker'
+   ),
+   'position' => 'bottom', // MW 1.26
+   ),
'ext.pageforms.regexp' => $wgPageFormsResourceTemplate + array(
'scripts' => 'libs/PF_regexp.js',
'dependencies' => array(
diff --git a/extension.json b/extension.json
index ad5658f..425ce4f 100644
--- a/extension.json
+++ b/extension.json
@@ -129,6 +129,8 @@
"PFComboBoxInput": "includes/forminputs/PF_ComboBoxInput.php",
"PFDateInput": "includes/forminputs/PF_DateInput.php",
"PFDatePickerInput": 
"includes/forminputs/PF_DatePickerInput.php",
+   "PFTimePickerInput": 
"includes/forminputs/PF_TimePickerInput.php",
+   "PFDateTimePicker": "includes/forminputs/PF_DateTimePicker.php",
"PFDateTimeInput": "includes/forminputs/PF_DateTimeInput.php",
"PFYearInput": "includes/forminputs/PF_YearInput.php",
"PFTreeInput": "includes/forminputs/PF_TreeInput.php",
@@ -267,6 +269,19 @@
],
"position": "bottom"
},
+   "ext.pageforms.timepicker": {
+   "scripts": "libs/PF_timepicker.js",
+   "styles": "skins/PF_Timepicker.css",
+   "position": "bottom"
+   },
+   "ext.pageforms.datetimepicker": {
+   "scripts": "libs/PF_datetimepicker.js",
+   "dependencies": [
+   "ext.pageforms.datepicker",
+   "ext.pageforms.timepicker"
+   ],
+   "position": "bottom"
+   },
"ext.pageforms.regexp": {
"scripts": "libs/PF_regexp.js",
"dependencies": [
diff --git a/includes/PF_FormPrinter.php b/includes/PF_FormPrinter.php
index 1b87ae0..22cb60d 100644
--- a/includes/PF_FormPrinter.php
+++ b/includes/PF_FormPrinter.php
@@ -44,6 +44,7 @@
$this->registerInputType( 'PFTextAreaWithAutocompleteInput' );
$this->registerInputType( 'PFDateInput' );
$this->registerInputType( 'PFDatePickerInput' );
+   $this->registerInputType( 'PFDateTimePicker' );
$this->registerInputType( 'PFDateTimeInput' );
$this->registerInputType( 'PFYearInput' );
$this->registerInputType( 'PFCheckboxInput' );
diff --git 

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Roll out wikidata description taglines to French and German ...

2016-12-05 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325366

Change subject: Roll out wikidata description taglines to French and German 
Wikipedias
..

Roll out wikidata description taglines to French and German Wikipedias

Update nowikidatadescriptiontaglines.dblist to remove top 6 wikis given
that only 2 wikis (English and Russian) do not have this feature.

Explicitly disable there.

Bug: T151345
Change-Id: Ic3e75fcf3d6a58f93f7077dbdf8ee2e97d6c7053
---
M dblists/nowikidatadescriptiontaglines.dblist
M wmf-config/InitialiseSettings.php
2 files changed, 5 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/66/325366/1

diff --git a/dblists/nowikidatadescriptiontaglines.dblist 
b/dblists/nowikidatadescriptiontaglines.dblist
index 7a94bf1..fdeac05 100644
--- a/dblists/nowikidatadescriptiontaglines.dblist
+++ b/dblists/nowikidatadescriptiontaglines.dblist
@@ -1 +1 @@
-%% wikinews.dblist + wikiversity.dblist + wikisource.dblist + wikibooks.dblist 
+ wiktionary.dblist + top6-wikipedia.dblist + special.dblist - s4.dblist
\ No newline at end of file
+%% wikinews.dblist + wikiversity.dblist + wikisource.dblist + wikibooks.dblist 
+ wiktionary.dblist + special.dblist - s4.dblist
\ No newline at end of file
diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index a861610..7ed3dd8 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -14665,13 +14665,11 @@
'nowikidatadescriptiontaglines' => [
'search' => true, 'nearby' => true, 'watchlist' => true, 
'tagline' => false
],
-   // This can be removed when top6-wikipedia.dblist is no longer inside 
nowikidatadescriptiontaglines
-   'jawiki' => [
-   'search' => true, 'nearby' => true, 'watchlist' => true, 
'tagline' => true
+   'ruwiki' => [
+   'search' => true, 'nearby' => true, 'watchlist' => true, 
'tagline' => false
],
-   // This can be removed when top6-wikipedia.dblist is no longer inside 
nowikidatadescriptiontaglines
-   'eswiki' => [
-   'search' => true, 'nearby' => true, 'watchlist' => true, 
'tagline' => true
+   'enwiki' => [
+   'search' => true, 'nearby' => true, 'watchlist' => true, 
'tagline' => false
],
 ],
 'wgMinervaUseFooterV2' => [

-- 
To view, visit https://gerrit.wikimedia.org/r/325366
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic3e75fcf3d6a58f93f7077dbdf8ee2e97d6c7053
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Disable Wikipedia beta banner experiment

2016-12-05 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325370

Change subject: Disable Wikipedia beta banner experiment
..

Disable Wikipedia beta banner experiment

Bug: T148634
Change-Id: I762bd4c22534bd483e33a4b20dfb246e78e7ed4d
---
M wmf-config/InitialiseSettings.php
1 file changed, 0 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/70/325370/1

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index bfeabea..28a379c 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -17609,12 +17609,10 @@
 
 'wgWPBEnablePageImagesBanners' => [
'default' => false,
-   'enwiki' => true, // T101108
 ],
 
 'wgWPBEnableHeadingOverride' => [
'default' => true,
-   'enwiki' => false, // T101108
 ],
 
 'wgWPBNamespaces' => [

-- 
To view, visit https://gerrit.wikimedia.org/r/325370
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I762bd4c22534bd483e33a4b20dfb246e78e7ed4d
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageImages[master]: Add job queue option for initImageData maintenance script

2016-12-05 Thread EBernhardson (Code Review)
EBernhardson has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325328

Change subject: Add job queue option for initImageData maintenance script
..

Add job queue option for initImageData maintenance script

Trying to run this script in the cluster fatals out due to memory
problems somewhat regularly. The --start option helps to restart
it where it fell down, but when trying to run against hundreds of
wiki's that is a one-off solution that makes ensuring everything is
actually visited a pain.

To try and isolate errors add an option to push the parsing into the
job queue. There is still the possibility to miss pages, but job queue
retries should take care of us for the most part. Attempts to keep
load down on the databases by making sure no more than a specified
number of jobs are queued/processing at a given time.

Bug: T152155
Change-Id: I3a4e3a415b2f03de0bb36ac0515241e950130fde
---
M extension.json
A includes/Job/InitImageDataJob.php
M maintenance/initImageData.php
3 files changed, 45 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/PageImages 
refs/changes/28/325328/1

diff --git a/extension.json b/extension.json
index 4e74d66..f78c44a 100644
--- a/extension.json
+++ b/extension.json
@@ -18,7 +18,8 @@
"ApiQueryPageImages": "includes/ApiQueryPageImages.php",
"PageImages": "includes/PageImages.php",
"PageImages\\Hooks\\LinksUpdateHookHandler": 
"includes/LinksUpdateHookHandler.php",
-   "PageImages\\Hooks\\ParserFileProcessingHookHandlers": 
"includes/ParserFileProcessingHookHandlers.php"
+   "PageImages\\Hooks\\ParserFileProcessingHookHandlers": 
"includes/ParserFileProcessingHookHandlers.php",
+   "PageImages\\Job\\InitImageDataJob": 
"includes/Job/InitImageDataJob.php"
},
"Hooks": {
"ParserMakeImageParams": 
"PageImages\\Hooks\\ParserFileProcessingHookHandlers::onParserMakeImageParams",
@@ -29,6 +30,9 @@
"AfterParserFetchFileAndTitle": 
"PageImages\\Hooks\\ParserFileProcessingHookHandlers::onAfterParserFetchFileAndTitle",
"SpecialMobileEditWatchlist::images": 
"PageImages::onSpecialMobileEditWatchlist_images"
},
+   "JobClasses": {
+   "InitImageDataJob": "PageImages\\Job\\InitImageDataJob"
+   },
"config": {
"PageImagesScores": {
"value": {
diff --git a/includes/Job/InitImageDataJob.php 
b/includes/Job/InitImageDataJob.php
new file mode 100644
index 000..c35adf8
--- /dev/null
+++ b/includes/Job/InitImageDataJob.php
@@ -0,0 +1,17 @@
+getDBLoadBalancerFactory();
+
+   foreach ( $this->params['page_ids'] as $id ) {
+   RefreshLinks::fixLinksFromArticle( $id );
+   $lbFactory->waitForReplication();
+   }
+   }
+}
diff --git a/maintenance/initImageData.php b/maintenance/initImageData.php
index af3453d..0463056 100644
--- a/maintenance/initImageData.php
+++ b/maintenance/initImageData.php
@@ -7,6 +7,7 @@
 require_once ( "$IP/maintenance/Maintenance.php" );
 
 use MediaWiki\MediaWikiServices;
+use PageImages\Job\InitImageDataJob;
 
 /**
  * @license WTFPL 2.0
@@ -21,6 +22,7 @@
$this->addOption( 'earlier-than',
'Run only on pages earlier than this timestamp', false, 
true );
$this->addOption( 'start', 'Starting page ID', false, true );
+   $this->addOption( 'queue-pressure', 'Maximum number of jobs to 
enqueue at a time. If unprovided or 0 will be run in-process.', false, true );
$this->setBatchSize( 100 );
}
 
@@ -28,7 +30,11 @@
global $wgPageImagesNamespaces;
 
$id = $this->getOption( 'start', 0 );
-   $lbFactory = 
MediaWikiServices::getInstance()->getDBLoadBalancerFactory();
+   $queue = null;
+   $maxPressure = $this->getOption( 'queue-pressure', 0 );
+   if ( $maxPressure > 0 ) {
+   $queue = JobQueueGroup::singleton();
+   }
 
do {
$tables = [ 'page', 'imagelinks' ];
@@ -57,15 +63,28 @@
[ 'LIMIT' => $this->mBatchSize, 'ORDER_BY' => 
'page_id', 'GROUP BY' => 'page_id' ],
$joinConds
);
+   $page_ids = [];
foreach ( $res as $row ) {
-   $id = $row->page_id;
-   RefreshLinks::fixLinksFromArticle( $id );
-   $lbFactory->waitForReplication();
+   $page_ids[] = $row->page_id;
+   }
+   $job = new InitImageDataJob( Title::newMainPage(), [ 
'page_ids' => $page_ids ] 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: Follow-up I863367b8, Ic9db0829: These two commits conflicted

2016-12-05 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged.

Change subject: Follow-up I863367b8, Ic9db0829: These two commits conflicted
..


Follow-up I863367b8, Ic9db0829: These two commits conflicted

Bug: T141785
Change-Id: I5bb7dc90764bb6178b97c96f646c8040d8651a58
---
M modules/beta/files/shinken.cfg
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Ottomata: Looks good to me, but someone else must approve
  jenkins-bot: Verified
  Dzahn: Looks good to me, approved



diff --git a/modules/beta/files/shinken.cfg b/modules/beta/files/shinken.cfg
index c638ef6..6389c7e 100644
--- a/modules/beta/files/shinken.cfg
+++ b/modules/beta/files/shinken.cfg
@@ -88,5 +88,5 @@
 service_description Mediawiki Error Rate
 host_name   graphite-labs
 use generic-service
-check_command   
check_graphite_threshold!https://graphite-labs.wikimedia.org!10!transformNull(sumSeries(logstash.rate.mediawiki.fatal.ERROR.sum,
 logstash.rate.mediawiki.exception.ERROR.sum), 0)!1!10!5min!1!--over
+check_command   
check_graphite_threshold!https://graphite-labs.wikimedia.org!10!transformNull(sumSeries(logstash.rate.mediawiki.fatal.ERROR.sum,
 logstash.rate.mediawiki.exception.ERROR.sum), 0)!1!10!5min!0min!1!--over
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/325122
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I5bb7dc90764bb6178b97c96f646c8040d8651a58
Gerrit-PatchSet: 4
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Alex Monk 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Elukey 
Gerrit-Reviewer: Filippo Giunchedi 
Gerrit-Reviewer: Joal 
Gerrit-Reviewer: Ottomata 
Gerrit-Reviewer: Yuvipanda 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...Wikibase[master]: Make SpecialGoToLinkedPage and SpecialListProperties use OOUI

2016-12-05 Thread Ladsgroup (Code Review)
Ladsgroup has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325346

Change subject: Make SpecialGoToLinkedPage and SpecialListProperties use OOUI
..

Make SpecialGoToLinkedPage and SpecialListProperties use OOUI

Change-Id: I8a64a1cbeea7bcad553ec9d290c61a37c01a7670
---
M repo/includes/Specials/SpecialGoToLinkedPage.php
M repo/includes/Specials/SpecialListProperties.php
2 files changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase 
refs/changes/46/325346/1

diff --git a/repo/includes/Specials/SpecialGoToLinkedPage.php 
b/repo/includes/Specials/SpecialGoToLinkedPage.php
index e103127..801b563 100644
--- a/repo/includes/Specials/SpecialGoToLinkedPage.php
+++ b/repo/includes/Specials/SpecialGoToLinkedPage.php
@@ -245,7 +245,7 @@
)
);
 
-   HTMLForm::factory( 'inline', $formDescriptor, 
$this->getContext() )
+   HTMLForm::factory( 'ooui', $formDescriptor, $this->getContext() 
)
->setId( 'wb-gotolinkedpage-form1' )
->setMethod( 'get' )
->setSubmitID( 'wb-gotolinkedpage-submit' )
diff --git a/repo/includes/Specials/SpecialListProperties.php 
b/repo/includes/Specials/SpecialListProperties.php
index 17814cc..39fb56c 100644
--- a/repo/includes/Specials/SpecialListProperties.php
+++ b/repo/includes/Specials/SpecialListProperties.php
@@ -170,7 +170,7 @@
)
);
 
-   HTMLForm::factory( 'inline', $formDescriptor, 
$this->getContext() )
+   HTMLForm::factory( 'ooui', $formDescriptor, $this->getContext() 
)
->setId( 'wb-listproperties-form' )
->setMethod( 'get' )
->setWrapperLegendMsg( 'wikibase-listproperties-legend' 
)

-- 
To view, visit https://gerrit.wikimedia.org/r/325346
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8a64a1cbeea7bcad553ec9d290c61a37c01a7670
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Ladsgroup 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Turn off CirrusSearch interwiki load test

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Turn off CirrusSearch interwiki load test
..


Turn off CirrusSearch interwiki load test

Load test is complete. Remove all the supporting code.

Bug: T149740
Change-Id: I79026a05ad9591f7b972cef8196b647a8b2ce4ce
---
D wmf-config/CirrusSearch-interwikiSources.php
M wmf-config/CirrusSearch-production.php
M wmf-config/InitialiseSettings.php
3 files changed, 0 insertions(+), 874 deletions(-)

Approvals:
  Thcipriani: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/wmf-config/CirrusSearch-interwikiSources.php 
b/wmf-config/CirrusSearch-interwikiSources.php
deleted file mode 100644
index b0b00aa..000
--- a/wmf-config/CirrusSearch-interwikiSources.php
+++ /dev/null
@@ -1,869 +0,0 @@
- 
-  array (
-  ),
-  'afwiki' => 
-  array (
-'b' => 'afwikibooks',
-'q' => 'afwikiquote',
-'wikt' => 'afwiktionary',
-  ),
-  'amwiki' => 
-  array (
-'wikt' => 'amwiktionary',
-  ),
-  'angwiki' => 
-  array (
-'wikt' => 'angwiktionary',
-  ),
-  'anwiki' => 
-  array (
-'wikt' => 'anwiktionary',
-  ),
-  'arwiki' => 
-  array (
-'b' => 'arwikibooks',
-'n' => 'arwikinews',
-'q' => 'arwikiquote',
-'s' => 'arwikisource',
-'v' => 'arwikiversity',
-'wikt' => 'arwiktionary',
-  ),
-  'astwiki' => 
-  array (
-'wikt' => 'astwiktionary',
-  ),
-  'aswiki' => 
-  array (
-'s' => 'aswikisource',
-  ),
-  'aywiki' => 
-  array (
-'wikt' => 'aywiktionary',
-  ),
-  'azwiki' => 
-  array (
-'b' => 'azwikibooks',
-'q' => 'azwikiquote',
-'s' => 'azwikisource',
-'wikt' => 'azwiktionary',
-  ),
-  'bewiki' => 
-  array (
-'b' => 'bewikibooks',
-'q' => 'bewikiquote',
-'s' => 'bewikisource',
-'wikt' => 'bewiktionary',
-  ),
-  'bgwiki' => 
-  array (
-'b' => 'bgwikibooks',
-'n' => 'bgwikinews',
-'q' => 'bgwikiquote',
-'s' => 'bgwikisource',
-'wikt' => 'bgwiktionary',
-  ),
-  'bnwiki' => 
-  array (
-'b' => 'bnwikibooks',
-'s' => 'bnwikisource',
-'wikt' => 'bnwiktionary',
-  ),
-  'brwiki' => 
-  array (
-'q' => 'brwikiquote',
-'s' => 'brwikisource',
-'wikt' => 'brwiktionary',
-  ),
-  'bswiki' => 
-  array (
-'b' => 'bswikibooks',
-'n' => 'bswikinews',
-'q' => 'bswikiquote',
-'s' => 'bswikisource',
-'wikt' => 'bswiktionary',
-  ),
-  'cawiki' => 
-  array (
-'b' => 'cawikibooks',
-'n' => 'cawikinews',
-'q' => 'cawikiquote',
-'s' => 'cawikisource',
-'wikt' => 'cawiktionary',
-  ),
-  'chrwiki' => 
-  array (
-'wikt' => 'chrwiktionary',
-  ),
-  'cowiki' => 
-  array (
-'wikt' => 'cowiktionary',
-  ),
-  'csbwiki' => 
-  array (
-'wikt' => 'csbwiktionary',
-  ),
-  'cswiki' => 
-  array (
-'b' => 'cswikibooks',
-'n' => 'cswikinews',
-'q' => 'cswikiquote',
-'s' => 'cswikisource',
-'v' => 'cswikiversity',
-'wikt' => 'cswiktionary',
-  ),
-  'cvwiki' => 
-  array (
-'b' => 'cvwikibooks',
-  ),
-  'cywiki' => 
-  array (
-'b' => 'cywikibooks',
-'q' => 'cywikiquote',
-'s' => 'cywikisource',
-'wikt' => 'cywiktionary',
-  ),
-  'dawiki' => 
-  array (
-'b' => 'dawikibooks',
-'q' => 'dawikiquote',
-'s' => 'dawikisource',
-'wikt' => 'dawiktionary',
-  ),
-  'dewiki' => 
-  array (
-'b' => 'dewikibooks',
-'n' => 'dewikinews',
-'q' => 'dewikiquote',
-'s' => 'dewikisource',
-'v' => 'dewikiversity',
-'voy' => 'dewikivoyage',
-'wikt' => 'dewiktionary',
-  ),
-  'dvwiki' => 
-  array (
-'wikt' => 'dvwiktionary',
-  ),
-  'elwiki' => 
-  array (
-'b' => 'elwikibooks',
-'n' => 'elwikinews',
-'q' => 'elwikiquote',
-'s' => 'elwikisource',
-'v' => 'elwikiversity',
-'voy' => 'elwikivoyage',
-'wikt' => 'elwiktionary',
-  ),
-  'enwiki' => 
-  array (
-'b' => 'enwikibooks',
-'n' => 'enwikinews',
-'q' => 'enwikiquote',
-'s' => 'enwikisource',
-'v' => 'enwikiversity',
-'voy' => 'enwikivoyage',
-'wikt' => 'enwiktionary',
-  ),
-  'eowiki' => 
-  array (
-'b' => 'eowikibooks',
-'n' => 'eowikinews',
-'q' => 'eowikiquote',
-'s' => 'eowikisource',
-'wikt' => 'eowiktionary',
-  ),
-  'eswiki' => 
-  array (
-'b' => 'eswikibooks',
-'n' => 'eswikinews',
-'q' => 'eswikiquote',
-'s' => 'eswikisource',
-'v' => 'eswikiversity',
-'voy' => 'eswikivoyage',
-'wikt' => 'eswiktionary',
-  ),
-  'etwiki' => 
-  array (
-'b' => 'etwikibooks',
-'q' => 'etwikiquote',
-'s' => 'etwikisource',
-'wikt' => 'etwiktionary',
-  ),
-  'euwiki' => 
-  array (
-'b' => 'euwikibooks',
-'q' => 'euwikiquote',
-'wikt' => 'euwiktionary',
-  ),
-  'fawiki' => 
-  array (
-'b' => 'fawikibooks',
-'n' => 'fawikinews',
-'q' => 'fawikiquote',
-'s' => 'fawikisource',
-'voy' => 'fawikivoyage',
-'wikt' => 'fawiktionary',
-  ),
-  

[MediaWiki-commits] [Gerrit] mediawiki...ImportUsers[master]: ImportUsers.alias.php translations for Bengali

2016-12-05 Thread Aftab (Code Review)
Aftab has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325352

Change subject: ImportUsers.alias.php translations for Bengali
..

ImportUsers.alias.php translations for Bengali

Change-Id: Ia6fab6992684ac91bd0a1da7b62a4bb6bd449d9d
---
M ImportUsers.alias.php
1 file changed, 7 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ImportUsers 
refs/changes/52/325352/2

diff --git a/ImportUsers.alias.php b/ImportUsers.alias.php
index 0f5bea6..2e74398 100644
--- a/ImportUsers.alias.php
+++ b/ImportUsers.alias.php
@@ -43,6 +43,13 @@
]
 ];
 
+/** Bengali (বাংলা) */
+$specialPageAliases['bn'] = [
+   'ImportUsers' => [
+   'ব্যবহারকারী_আমদানি'
+   ]
+];
+
 /** Breton (brezhoneg) */
 $specialPageAliases['br'] = [
'ImportUsers' => [

-- 
To view, visit https://gerrit.wikimedia.org/r/325352
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia6fab6992684ac91bd0a1da7b62a4bb6bd449d9d
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ImportUsers
Gerrit-Branch: master
Gerrit-Owner: Aftab 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: scap clean plugin: fix minor typo in progress tracking/repor...

2016-12-05 Thread Chad (Code Review)
Chad has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325353

Change subject: scap clean plugin: fix minor typo in progress tracking/reporting
..

scap clean plugin: fix minor typo in progress tracking/reporting

Change-Id: Ib9126ccd8e68af732717650796f0313dc88bfdcd
---
M scap/plugins/clean.py
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/53/325353/1

diff --git a/scap/plugins/clean.py b/scap/plugins/clean.py
index 77c3c19..495f2ce 100644
--- a/scap/plugins/clean.py
+++ b/scap/plugins/clean.py
@@ -22,11 +22,11 @@
 clean_job.exclude_hosts([socket.getfqdn()])
 clean_job.shuffle()
 clean_job.command(self._clean_command(self.config['stage_dir']))
-clean_job.progress('clean-apaches')
+clean_job.progress('clean-masters')
 succeeded, failed = clean_job.run()
 if failed:
 self.get_logger().warning(
-'%d apaches had clean errors', failed)
+'%d masters had clean errors', failed)
 
 # Update apaches
 with log.Timer('clean-apaches', self.get_stats()):

-- 
To view, visit https://gerrit.wikimedia.org/r/325353
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib9126ccd8e68af732717650796f0313dc88bfdcd
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Chad 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Bump versionCode

2016-12-05 Thread Dbrant (Code Review)
Dbrant has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325354

Change subject: Bump versionCode
..

Bump versionCode

Change-Id: If4203873101395655f93da02b8ed7f8af2f9e2f7
---
M app/build.gradle
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia 
refs/changes/54/325354/1

diff --git a/app/build.gradle b/app/build.gradle
index a101d9f..cc05015 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -54,7 +54,7 @@
 applicationId 'org.wikipedia'
 minSdkVersion 16
 targetSdkVersion 25
-versionCode 180
+versionCode 181
 testApplicationId 'org.wikipedia.test'
 testInstrumentationRunner 'org.wikipedia.test.AndroidTestRunner'
 vectorDrawables.useSupportLibrary = true

-- 
To view, visit https://gerrit.wikimedia.org/r/325354
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: If4203873101395655f93da02b8ed7f8af2f9e2f7
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Dbrant 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageForms[master]: Renamed PFDatePickerInput::textHTML() to genericTextHTML(), ...

2016-12-05 Thread Yaron Koren (Code Review)
Yaron Koren has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325351

Change subject: Renamed PFDatePickerInput::textHTML() to genericTextHTML(), for 
clarity
..

Renamed PFDatePickerInput::textHTML() to genericTextHTML(), for clarity

Change-Id: Ia4c9852bf39becd9a6c6d768b1e87968c1ecc71d
---
M includes/forminputs/PF_DatePickerInput.php
1 file changed, 2 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/PageForms 
refs/changes/51/325351/2

diff --git a/includes/forminputs/PF_DatePickerInput.php 
b/includes/forminputs/PF_DatePickerInput.php
index f95f0ba..3952c1b 100644
--- a/includes/forminputs/PF_DatePickerInput.php
+++ b/includes/forminputs/PF_DatePickerInput.php
@@ -647,7 +647,7 @@
 */
public function getHtmlText() {
// Assemble HTML code.
-   $html = self::textHTML( $this->mCurrentValue, 
$this->mInputName, $this->mIsDisabled, $this->mOtherArgs, 'input_' . 
$this->mInputNumber );
+   $html = self::genericTextHTML( $this->mCurrentValue, 
$this->mInputName, $this->mIsDisabled, $this->mOtherArgs, 'input_' . 
$this->mInputNumber );
 
if ( ! array_key_exists( 'part of dtp', $this->mOtherArgs ) ) {
// wrap in span (e.g. used for mandatory inputs)
@@ -684,8 +684,7 @@
 * @param string $class
 * @return string the html text of an input element
 */
-   static function textHTML( $currentValue, $inputName, $isDisabled, 
$otherArgs, $inputId = null, $tabIndex = null, $class = '' ) {
-
+   static function genericTextHTML( $currentValue, $inputName, 
$isDisabled, $otherArgs, $inputId = null, $tabIndex = null, $class = '' ) {
global $wgPageFormsTabIndex;
 
// array of attributes to pass to the input field

-- 
To view, visit https://gerrit.wikimedia.org/r/325351
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia4c9852bf39becd9a6c6d768b1e87968c1ecc71d
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/PageForms
Gerrit-Branch: master
Gerrit-Owner: Yaron Koren 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...mobileapps[master]: Add new survey link for android

2016-12-05 Thread Fjalapeno (Code Review)
Fjalapeno has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325335

Change subject: Add new survey link for android
..

Add new survey link for android

Update caption text

Bug:T145830
Change-Id: I6dbb0367a94ddbac24714bd0b36dbc990d993e79
---
M routes/announcements.js
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/mobileapps 
refs/changes/35/325335/1

diff --git a/routes/announcements.js b/routes/announcements.js
index 18aaceb..3ba2b4d 100644
--- a/routes/announcements.js
+++ b/routes/announcements.js
@@ -23,7 +23,7 @@
 title: "Take the survey",
 url: 
"https://docs.google.com/forms/d/e/1FAIpQLSdaqvKojvyXGSewEZ395RPOQ6AcD3e87MZnh5pvO7phqqKwVg/viewform;
 },
-caption_HTML: "Survey data handled by a third party. https://wikimediafoundation.org/wiki/Survey_Privacy_Statement\;>Privacy.",
+caption_HTML: "Survey powered by 3rd-party service; see https://wikimediafoundation.org/wiki/Apps_Reader_Motivation_Survey_Privacy_Statement\;>privacy
 statement.",
 countries: [
 "US",
 "CA",
@@ -41,9 +41,9 @@
 text: "Answer three questions and help us improve Wikipedia.",
 action: {
 title: "Take the survey",
-url: 
"https://docs.google.com/forms/d/e/1FAIpQLSdaqvKojvyXGSewEZ395RPOQ6AcD3e87MZnh5pvO7phqqKwVg/viewform;
+url: 
"https://docs.google.com/forms/d/e/1FAIpQLSfqzFyCmoQBs9z8i1PQSY-8hnBpCaRFS0gWGiAvTYFf6Y8WAQ/viewform;
 },
-caption_HTML: "Survey data handled by a third party. https://wikimediafoundation.org/wiki/Survey_Privacy_Statement\;>Privacy.",
+caption_HTML: "Survey powered by 3rd-party service; see https://wikimediafoundation.org/wiki/Apps_Reader_Motivation_Survey_Privacy_Statement\;>privacy
 statement.",
 countries: [
 "US",
 "CA",

-- 
To view, visit https://gerrit.wikimedia.org/r/325335
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6dbb0367a94ddbac24714bd0b36dbc990d993e79
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/mobileapps
Gerrit-Branch: master
Gerrit-Owner: Fjalapeno 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Misleading messages on Special:Userrights

2016-12-05 Thread Huji (Code Review)
Huji has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325338

Change subject: Misleading messages on Special:Userrights
..

Misleading messages on Special:Userrights

Corrects what is not addressed by I57e9ca4f20fe557e4024c4f5a4865170f02ebb45

Bug: T152428
Change-Id: I105be73acc5a2bc088b557ccafbdf9db726480da
---
M includes/specials/SpecialUserrights.php
M languages/i18n/en.json
M languages/i18n/qqq.json
3 files changed, 13 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/38/325338/1

diff --git a/includes/specials/SpecialUserrights.php 
b/includes/specials/SpecialUserrights.php
index 5b4f1f8..3ba46c1 100644
--- a/includes/specials/SpecialUserrights.php
+++ b/includes/specials/SpecialUserrights.php
@@ -549,9 +549,14 @@
Xml::element(
'legend',
[],
-   $this->msg( 'userrights-editusergroup', 
$user->getName() )->text()
+   $this->msg(
+   $canChangeAny ? 
'userrights-editusergroup' : 'userrights-viewusergroup',
+   $user->getName()
+   )->text()
) .
-   $this->msg( 'editinguser' )->params( wfEscapeWikiText( 
$user->getName() ) )
+   $this->msg(
+   $canChangeAny ? 'editinguser' : 
'viewinguserrights'
+   )->params( wfEscapeWikiText( $user->getName() ) )
->rawParams( $userToolLinks )->parse()
);
if ( $canChangeAny ) {
diff --git a/languages/i18n/en.json b/languages/i18n/en.json
index d167904..733f003 100644
--- a/languages/i18n/en.json
+++ b/languages/i18n/en.json
@@ -1140,7 +1140,9 @@
"userrights-user-editname": "Enter a username:",
"editusergroup": "Load user groups",
"editinguser": "Changing user rights of {{GENDER:$1|user}} 
[[User:$1|$1]] $2",
+   "viewinguserrights": "Viewing user rights of {{GENDER:$1|user}} 
[[User:$1|$1]] $2",
"userrights-editusergroup": "Edit user groups",
+   "userrights-viewusergroup": "View user groups",
"saveusergroups": "Save {{GENDER:$1|user}} groups",
"userrights-groupsmember": "Member of:",
"userrights-groupsmember-auto": "Implicit member of:",
diff --git a/languages/i18n/qqq.json b/languages/i18n/qqq.json
index 936fd8b..fea648d 100644
--- a/languages/i18n/qqq.json
+++ b/languages/i18n/qqq.json
@@ -1323,8 +1323,10 @@
"userrights-lookup-user": "Label text when managing user rights 
([[Special:UserRights]])",
"userrights-user-editname": "Displayed on [[Special:UserRights]].",
"editusergroup": "Button name, in page [[Special:Userrights]], in the 
section named {{MediaWiki:userrights-lookup-user}}. The username or gender of 
the user is not known when this message is displayed.",
-   "editinguser": "Appears on [[Special:UserRights]]. Parameters:\n* $1 - 
a plaintext username\n* $2 - user tool links. e.g. \"(Talk | contribs | block | 
send email)\"",
-   "userrights-editusergroup": "Parameter:\n* $1 - (Optional) a username, 
can be used for GENDER",
+   "editinguser": "Appears on [[Special:UserRights]]. Parameters:\n* $1 - 
a plaintext username\n* $2 - user tool links. e.g. \"(Talk | contribs | block | 
send email)\"\n\nRelated messages:\n* {{msg-mw|viewinguserrights}}",
+   "viewinguserrights": "Appears on [[Special:UserRights]]. Parameters:\n* 
$1 - a plaintext username\n* $2 - user tool links. e.g. \"(Talk | contribs | 
block | send email)\"\n\nRelated messages:\n* {{msg-mw|editinguser}}",
+   "userrights-editusergroup": "Parameter:\n* $1 - (Optional) a username, 
can be used for GENDER\n\nRelated messages:\n* 
{{msg-mw|userrights-viewusergroup}}",
+   "userrights-viewusergroup": "Parameter:\n* $1 - (Optional) a username, 
can be used for GENDER\n\nRelated messages:\n* 
{{msg-mw|userrights-editusergroup}}",
"saveusergroups": "Button text when editing user 
groups.\nParameters:\n* $1 - username, for GENDER support",
"userrights-groupsmember": "Used when editing user groups in 
[[Special:Userrights]].\n\nThe message is followed by a list of group 
names.\n\nParameters:\n* $1 - (Optional) the number of items in the list 
following the message, for PLURAL\n* $2 - (Optional) the user name, for GENDER",
"userrights-groupsmember-auto": "Used when editing user groups in 
[[Special:Userrights]]. The message is followed by a list of group 
names.\n\n\"Implicit\" is for groups that the user was automatically added to 
(such as \"autoconfirmed\"); cf. 
{{msg-mw|userrights-groupsmember}}\n\nParameters:\n* $1 - (Optional) the number 
of items in the list following the message, for PLURAL\n* $2 - 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: Send secondary DNS recursor IP from labs DHCP

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has submitted this change and it was merged.

Change subject: Send secondary DNS recursor IP from labs DHCP
..


Send secondary DNS recursor IP from labs DHCP

Bug: T137460
Change-Id: I7c4942490776301d8fd1a2580e1b956f8c605105
---
M modules/openstack/manifests/nova/network.pp
M modules/openstack/templates/liberty/nova/dnsmasq-nova.conf.erb
M modules/openstack/templates/mitaka/nova/dnsmasq-nova.conf.erb
3 files changed, 3 insertions(+), 2 deletions(-)

Approvals:
  Andrew Bogott: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/modules/openstack/manifests/nova/network.pp 
b/modules/openstack/manifests/nova/network.pp
index 72aeacb..34442ba 100644
--- a/modules/openstack/manifests/nova/network.pp
+++ b/modules/openstack/manifests/nova/network.pp
@@ -38,6 +38,7 @@
 $dnsconfig = hiera_hash('labsdnsconfig', {})
 $labs_metal = hiera('labs_metal',{})
 $recursor_ip = ipresolve($dnsconfig['recursor'],4)
+$recursor_secondary_ip = ipresolve($dnsconfig['recursor_secondary'],4)
 file { '/etc/dnsmasq-nova.conf':
 content => 
template("openstack/${openstack_version}/nova/dnsmasq-nova.conf.erb"),
 owner   => 'root',
diff --git a/modules/openstack/templates/liberty/nova/dnsmasq-nova.conf.erb 
b/modules/openstack/templates/liberty/nova/dnsmasq-nova.conf.erb
index 82f181f..1ba03a2 100644
--- a/modules/openstack/templates/liberty/nova/dnsmasq-nova.conf.erb
+++ b/modules/openstack/templates/liberty/nova/dnsmasq-nova.conf.erb
@@ -14,7 +14,7 @@
 <% end -%>
 
 #Clients should use the designate-backed dns server rather than dnsmasq
-dhcp-option=option:dns-server,<%= @recursor_ip %>
+dhcp-option=option:dns-server,<%= @recursor_ip %>,<%= @recursor_secondary_ip %>
 
 dhcp-boot=jessie-installer/pxelinux.0,<%= @tftp_host -%>,<%= 
scope.function_ipresolve([@tftp_host, 4]) %>
 
diff --git a/modules/openstack/templates/mitaka/nova/dnsmasq-nova.conf.erb 
b/modules/openstack/templates/mitaka/nova/dnsmasq-nova.conf.erb
index 82f181f..1ba03a2 100644
--- a/modules/openstack/templates/mitaka/nova/dnsmasq-nova.conf.erb
+++ b/modules/openstack/templates/mitaka/nova/dnsmasq-nova.conf.erb
@@ -14,7 +14,7 @@
 <% end -%>
 
 #Clients should use the designate-backed dns server rather than dnsmasq
-dhcp-option=option:dns-server,<%= @recursor_ip %>
+dhcp-option=option:dns-server,<%= @recursor_ip %>,<%= @recursor_secondary_ip %>
 
 dhcp-boot=jessie-installer/pxelinux.0,<%= @tftp_host -%>,<%= 
scope.function_ipresolve([@tftp_host, 4]) %>
 

-- 
To view, visit https://gerrit.wikimedia.org/r/325278
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I7c4942490776301d8fd1a2580e1b956f8c605105
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Alex Monk 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: Andrew Bogott 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Replace Linker::link() with LinkRenderer in all revisiondele...

2016-12-05 Thread Divadsn (Code Review)
Divadsn has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325348

Change subject: Replace Linker::link() with LinkRenderer in all revisiondelete 
pages
..

Replace Linker::link() with LinkRenderer in all revisiondelete pages

* RevDelArchiveItem
* RevDelArchivedFileItem
* RevDelFileItem
* RevDelLogItem
* RevDelRevisionItem

Bug: T149346
Change-Id: I96f83d06b4d3ccf3f76ccfca843a6aaf76d89063
---
M includes/revisiondelete/RevDelArchiveItem.php
M includes/revisiondelete/RevDelArchivedFileItem.php
M includes/revisiondelete/RevDelFileItem.php
M includes/revisiondelete/RevDelLogItem.php
M includes/revisiondelete/RevDelRevisionItem.php
5 files changed, 7 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/48/325348/1

diff --git a/includes/revisiondelete/RevDelArchiveItem.php 
b/includes/revisiondelete/RevDelArchiveItem.php
index 2d0d690..fdfe184 100644
--- a/includes/revisiondelete/RevDelArchiveItem.php
+++ b/includes/revisiondelete/RevDelArchiveItem.php
@@ -75,7 +75,7 @@
return $date;
}
 
-   return Linker::link(
+   return $this->getLinkRenderer->makeLink(
SpecialPage::getTitleFor( 'Undelete' ),
$date,
[],
@@ -91,7 +91,7 @@
return $this->list->msg( 'diff' )->escaped();
}
 
-   return Linker::link(
+   return $this->getLinkRenderer->makeLink(
SpecialPage::getTitleFor( 'Undelete' ),
$this->list->msg( 'diff' )->escaped(),
[],
diff --git a/includes/revisiondelete/RevDelArchivedFileItem.php 
b/includes/revisiondelete/RevDelArchivedFileItem.php
index 52df2e3..7c72316 100644
--- a/includes/revisiondelete/RevDelArchivedFileItem.php
+++ b/includes/revisiondelete/RevDelArchivedFileItem.php
@@ -78,7 +78,7 @@
} else {
$undelete = SpecialPage::getTitleFor( 'Undelete' );
$key = $this->file->getKey();
-   $link = Linker::link( $undelete, $date, [],
+   $link = $this->getLinkRenderer->makeLink( $undelete, 
$date, [],
[
'target' => 
$this->list->title->getPrefixedText(),
'file' => $key,
diff --git a/includes/revisiondelete/RevDelFileItem.php 
b/includes/revisiondelete/RevDelFileItem.php
index ff01cee..06399ee 100644
--- a/includes/revisiondelete/RevDelFileItem.php
+++ b/includes/revisiondelete/RevDelFileItem.php
@@ -128,7 +128,7 @@
if ( !$this->canViewContent() ) {
$link = $date;
} else {
-   $link = Linker::link(
+   $link = $this->getLinkRenderer->makeLink(
SpecialPage::getTitleFor( 'Revisiondelete' ),
$date,
[],
diff --git a/includes/revisiondelete/RevDelLogItem.php 
b/includes/revisiondelete/RevDelLogItem.php
index 1ea7271..d53198a 100644
--- a/includes/revisiondelete/RevDelLogItem.php
+++ b/includes/revisiondelete/RevDelLogItem.php
@@ -92,7 +92,7 @@
$formatter->setAudience( LogFormatter::FOR_THIS_USER );
 
// Log link for this page
-   $loglink = Linker::link(
+   $loglink = $this->getLinkRenderer->makeLink(
SpecialPage::getTitleFor( 'Log' ),
$this->list->msg( 'log' )->escaped(),
[],
diff --git a/includes/revisiondelete/RevDelRevisionItem.php 
b/includes/revisiondelete/RevDelRevisionItem.php
index d799113..8cd5320 100644
--- a/includes/revisiondelete/RevDelRevisionItem.php
+++ b/includes/revisiondelete/RevDelRevisionItem.php
@@ -114,7 +114,7 @@
return $date;
}
 
-   return Linker::linkKnown(
+   return $this->getLinkRenderer->makeKnownLink(
$this->list->title,
$date,
[],
@@ -134,7 +134,7 @@
if ( $this->isDeleted() && !$this->canViewContent() ) {
return $this->list->msg( 'diff' )->escaped();
} else {
-   return Linker::linkKnown(
+   return $this->getLinkRenderer->makeKnownLink(
$this->list->title,
$this->list->msg( 'diff' )->escaped(),
[],

-- 
To view, visit https://gerrit.wikimedia.org/r/325348
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: 

[MediaWiki-commits] [Gerrit] wikimedia/portals[master]: Align leftover colors to overhauled color palette

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Align leftover colors to overhauled color palette
..


Align leftover colors to overhauled color palette

Aligning several colors to overhauled color palette, that
were left behind so far. Also making better use of WikimediaUI Base
variables.

Bug: T146231
Change-Id: I8a0ac44228d86c520cd5892b06496881f42d049e
---
M dev/wikipedia.org/assets/postcss/_forms.css
M dev/wikipedia.org/assets/postcss/_lang-dropdown.css
M dev/wikipedia.org/assets/postcss/_search-box.css
M dev/wikipedia.org/assets/postcss/_vars.css
4 files changed, 21 insertions(+), 26 deletions(-)

Approvals:
  JGirault: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/dev/wikipedia.org/assets/postcss/_forms.css 
b/dev/wikipedia.org/assets/postcss/_forms.css
index f92929a..013691e 100644
--- a/dev/wikipedia.org/assets/postcss/_forms.css
+++ b/dev/wikipedia.org/assets/postcss/_forms.css
@@ -28,15 +28,16 @@
 .pure-form input[type="color"],
 .pure-form select,
 .pure-form textarea {
-padding: 0.5em;
+background-color: var( --background-color-base );
 display: inline-block;
-border: 1px solid #ccc;
-box-shadow: inset 0 0 0 0 rgb( 52, 123, 255 );
-border-radius: 0.1em;
-vertical-align: middle;
 -webkit-box-sizing: border-box;
 -moz-box-sizing: border-box;
 box-sizing: border-box;
+border: var( --border-base );
+border-radius: var( --border-radius-base );
+padding: 0.5em;
+box-shadow: inset 0 0 0 1px var( --background-color-base );
+vertical-align: middle;
 }
 
 /*
@@ -46,8 +47,7 @@
 .pure-form input:not( [type] ) {
 padding: 0.5em 0.6em;
 display: inline-block;
-border: 1px solid #ccc;
-box-shadow: inset 0 1px 3px #ddd;
+border: var( --border-base );
 border-radius: 4px;
 -webkit-box-sizing: border-box;
 -moz-box-sizing: border-box;
@@ -78,7 +78,7 @@
 .pure-form textarea:focus {
 outline: 0;
 border-color: var( --color-primary );
-box-shadow: inset 0 0 0 0.1em var( --color-primary );
+box-shadow: var( --box-shadow-base--focus );
 }
 
 /*
@@ -118,9 +118,9 @@
 .pure-form input[type="color"][disabled],
 .pure-form select[disabled],
 .pure-form textarea[disabled] {
-cursor: not-allowed;
+cursor: var( --cursor-base--disabled );
 background-color: #eaeded;
-color: #cad2d3;
+color: var( --color-base--disabled );
 }
 
 /*
@@ -128,7 +128,7 @@
 since IE8 won't execute CSS that contains a CSS3 selector.
 */
 .pure-form input:not([type])[disabled] {
-cursor: not-allowed;
+cursor: var( --cursor-base--disabled );
 background-color: #eaeded;
 color: #cad2d3;
 }
@@ -154,7 +154,7 @@
 .pure-form select {
 /* Normalizes the height; padding is not sufficient. */
 height: 2.25em;
-border: 1px solid #ccc;
+border: var( --border-base );
 background-color: #fff;
 }
 .pure-form select[multiple] {
@@ -173,8 +173,7 @@
 width: 100%;
 padding: 0.3em 0;
 margin-bottom: 0.3em;
-color: #333;
-border-bottom: 1px solid #e5e5e5;
+color: var( --color-base );
 }
 
 .pure-form-stacked input[type="text"],
diff --git a/dev/wikipedia.org/assets/postcss/_lang-dropdown.css 
b/dev/wikipedia.org/assets/postcss/_lang-dropdown.css
index ea9c58e..c07db7e 100644
--- a/dev/wikipedia.org/assets/postcss/_lang-dropdown.css
+++ b/dev/wikipedia.org/assets/postcss/_lang-dropdown.css
@@ -8,7 +8,7 @@
 */
 
 hr {
-border-color: #ccc;
+border-color: var( --border-color-heading );
 }
 
 .lang-list-container {
@@ -18,7 +18,7 @@
 overflow: hidden;
 max-height: 0;
 width: 80%;
-background-color: var( --ss-c-grey-hover );
+background-color: var( --background-color-framed );
 transition: max-height 0.5s ease-out, visibility 0.5s ease-in 1s;
 }
 
@@ -54,10 +54,9 @@
 z-index: 1;
 background-color: var( --background-color-framed );
 border: var( --border-base );
-border-radius: 2px;
+border-radius: var( --border-radius-base );
 outline: 1rem solid #fff;
-transition: outline-width 0.05s ease-in;
-transition-delay: 0.5s;
+transition: outline-width 0.05s ease-in 0.5s;
 }
 
 .lang-list-button:hover {
@@ -99,9 +98,8 @@
 max-width: 460px;
 width: 80%;
 height: 1px;
-background-color: #c8ccd1;
-transition: max-width 0.2s ease-out;
-transition-delay: 0.4s;
+background-color: var( --border-color-heading );
+transition: max-width 0.2s ease-out 0.4s;
 }
 
 .lang-list-active .lang-list-border {
@@ -138,11 +136,11 @@
 .bookshelf {
 text-align: center;
 white-space: normal;
-border-top: 1px solid #ddd;
+border-top: 1px solid var( --border-color-heading );
 box-shadow: 0 -1px 0 #fff;
 }
 .bookshelf span {
-background-color: var( --ss-c-grey-hover );
+background-color: var( --background-color-framed );
 position: relative;
 top: -0.7rem;
 font-weight: 

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Misleading messages on Special:Userrights

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Misleading messages on Special:Userrights
..


Misleading messages on Special:Userrights

Corrects what is not addressed by I57e9ca4f20fe557e4024c4f5a4865170f02ebb45

Bug: T152428
Change-Id: I105be73acc5a2bc088b557ccafbdf9db726480da
---
M includes/specials/SpecialUserrights.php
M languages/i18n/en.json
M languages/i18n/qqq.json
3 files changed, 13 insertions(+), 4 deletions(-)

Approvals:
  Bartosz Dziewoński: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/specials/SpecialUserrights.php 
b/includes/specials/SpecialUserrights.php
index 5b4f1f8..3ba46c1 100644
--- a/includes/specials/SpecialUserrights.php
+++ b/includes/specials/SpecialUserrights.php
@@ -549,9 +549,14 @@
Xml::element(
'legend',
[],
-   $this->msg( 'userrights-editusergroup', 
$user->getName() )->text()
+   $this->msg(
+   $canChangeAny ? 
'userrights-editusergroup' : 'userrights-viewusergroup',
+   $user->getName()
+   )->text()
) .
-   $this->msg( 'editinguser' )->params( wfEscapeWikiText( 
$user->getName() ) )
+   $this->msg(
+   $canChangeAny ? 'editinguser' : 
'viewinguserrights'
+   )->params( wfEscapeWikiText( $user->getName() ) )
->rawParams( $userToolLinks )->parse()
);
if ( $canChangeAny ) {
diff --git a/languages/i18n/en.json b/languages/i18n/en.json
index d167904..733f003 100644
--- a/languages/i18n/en.json
+++ b/languages/i18n/en.json
@@ -1140,7 +1140,9 @@
"userrights-user-editname": "Enter a username:",
"editusergroup": "Load user groups",
"editinguser": "Changing user rights of {{GENDER:$1|user}} 
[[User:$1|$1]] $2",
+   "viewinguserrights": "Viewing user rights of {{GENDER:$1|user}} 
[[User:$1|$1]] $2",
"userrights-editusergroup": "Edit user groups",
+   "userrights-viewusergroup": "View user groups",
"saveusergroups": "Save {{GENDER:$1|user}} groups",
"userrights-groupsmember": "Member of:",
"userrights-groupsmember-auto": "Implicit member of:",
diff --git a/languages/i18n/qqq.json b/languages/i18n/qqq.json
index 936fd8b..fea648d 100644
--- a/languages/i18n/qqq.json
+++ b/languages/i18n/qqq.json
@@ -1323,8 +1323,10 @@
"userrights-lookup-user": "Label text when managing user rights 
([[Special:UserRights]])",
"userrights-user-editname": "Displayed on [[Special:UserRights]].",
"editusergroup": "Button name, in page [[Special:Userrights]], in the 
section named {{MediaWiki:userrights-lookup-user}}. The username or gender of 
the user is not known when this message is displayed.",
-   "editinguser": "Appears on [[Special:UserRights]]. Parameters:\n* $1 - 
a plaintext username\n* $2 - user tool links. e.g. \"(Talk | contribs | block | 
send email)\"",
-   "userrights-editusergroup": "Parameter:\n* $1 - (Optional) a username, 
can be used for GENDER",
+   "editinguser": "Appears on [[Special:UserRights]]. Parameters:\n* $1 - 
a plaintext username\n* $2 - user tool links. e.g. \"(Talk | contribs | block | 
send email)\"\n\nRelated messages:\n* {{msg-mw|viewinguserrights}}",
+   "viewinguserrights": "Appears on [[Special:UserRights]]. Parameters:\n* 
$1 - a plaintext username\n* $2 - user tool links. e.g. \"(Talk | contribs | 
block | send email)\"\n\nRelated messages:\n* {{msg-mw|editinguser}}",
+   "userrights-editusergroup": "Parameter:\n* $1 - (Optional) a username, 
can be used for GENDER\n\nRelated messages:\n* 
{{msg-mw|userrights-viewusergroup}}",
+   "userrights-viewusergroup": "Parameter:\n* $1 - (Optional) a username, 
can be used for GENDER\n\nRelated messages:\n* 
{{msg-mw|userrights-editusergroup}}",
"saveusergroups": "Button text when editing user 
groups.\nParameters:\n* $1 - username, for GENDER support",
"userrights-groupsmember": "Used when editing user groups in 
[[Special:Userrights]].\n\nThe message is followed by a list of group 
names.\n\nParameters:\n* $1 - (Optional) the number of items in the list 
following the message, for PLURAL\n* $2 - (Optional) the user name, for GENDER",
"userrights-groupsmember-auto": "Used when editing user groups in 
[[Special:Userrights]]. The message is followed by a list of group 
names.\n\n\"Implicit\" is for groups that the user was automatically added to 
(such as \"autoconfirmed\"); cf. 
{{msg-mw|userrights-groupsmember}}\n\nParameters:\n* $1 - (Optional) the number 
of items in the list following the message, for PLURAL\n* $2 - (Optional) the 
user name, for 

[MediaWiki-commits] [Gerrit] mediawiki...CirrusSearch[master]: Refactor interwiki support

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Refactor interwiki support
..


Refactor interwiki support

Use the new InterwikiResolver service to handle Interwiki searches.
The goal is to centralize the Elastic Result to Title conversion
into a single place with proper support for interwiki results.
For interwiki results the plan is to rely on the wiki field returned
by elastic to decide if the title is internal or external.
This is still transitional as we need some BC code to support wikis
where the wiki field is not fully populated.
Once done (reindex all wikis) we can remove the BC code marked with a
TODO comment and rely only on the wiki field to determine if the
result refers to an external title.

Added 2 new feature flags to activate either crossproject and
crosslanguage search. These flags are not fully effective, they only
affect behaviors if the config used by CirrusConfigInterwikiResolver
is not present and SiteMatrix is available. This is because it's the
way it works today: if some data are present in some of the map then
the interwiki feature is activated.

The plan is to the SiteMatrix approach for wmf sites and use a
feature flag to activate either crosslanguage fallback and/or
crossproject search.

Bug: T141033
Change-Id: I6aebfa22c05a82f6d887f94ef6c18ce5b3a1b0bc
---
M CirrusSearch.php
M autoload.php
M includes/BaseInterwikiResolver.php
M includes/CirrusSearch.php
M includes/Hooks.php
M includes/InterwikiResolver.php
M includes/InterwikiSearcher.php
M includes/Maintenance/Validators/CacheWarmersValidator.php
M includes/Search/Result.php
M includes/Search/ResultSet.php
M includes/Search/ResultsType.php
A includes/Search/TitleHelper.php
M includes/SearchConfig.php
M includes/Searcher.php
M tests/unit/InterwikiResolverTest.php
M tests/unit/LanguageDetectTest.php
M tests/unit/Search/ResultTest.php
M tests/unit/Search/ResultsTypeTest.php
18 files changed, 407 insertions(+), 233 deletions(-)

Approvals:
  Cindy-the-browser-test-bot: Looks good to me, but someone else must approve
  EBernhardson: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/CirrusSearch.php b/CirrusSearch.php
index bf19fc0..ddb757d 100644
--- a/CirrusSearch.php
+++ b/CirrusSearch.php
@@ -889,6 +889,22 @@
 $wgCirrusSearchWikiToNameMap = [];
 
 /**
+ * Enable crossproject search.
+ * Crossproject works by seaching on so-called sister wikis:
+ * Same language, sister project.
+ * NOTE: Experimental
+ */
+$wgCirrusSearchEnableCrossProjectSearch = false;
+
+/**
+ * Enable cross leanguage search.
+ * Usually implemented as fallback for queries
+ * that returns fewer than $wgCirrusSearchInterwikiThreshold results
+ * NOTE: Experimental
+ */
+$wgCirrusSearchEnableCrossLanguageSearch = false;
+
+/**
  * If set to non-empty string, interwiki results will have ?wprov=XYZ 
parameter added.
  */
 $wgCirrusSearchInterwikiProv = false;
diff --git a/autoload.php b/autoload.php
index bef7cd0..92f7d56 100644
--- a/autoload.php
+++ b/autoload.php
@@ -138,6 +138,7 @@
'CirrusSearch\\Sanity\\Remediator' => __DIR__ . 
'/includes/Sanity/Remediator.php',
'CirrusSearch\\SearchConfig' => __DIR__ . '/includes/SearchConfig.php',
'CirrusSearch\\SearchRequestLog' => __DIR__ . 
'/includes/SearchRequestLog.php',
+   'CirrusSearch\\Search\\BaseResultsType' => __DIR__ . 
'/includes/Search/ResultsType.php',
'CirrusSearch\\Search\\BooleanIndexField' => __DIR__ . 
'/includes/Search/BooleanIndexField.php',
'CirrusSearch\\Search\\BoostTemplatesFunctionScoreBuilder' => __DIR__ . 
'/includes/Search/RescoreBuilders.php',
'CirrusSearch\\Search\\CirrusIndexField' => __DIR__ . 
'/includes/Search/CirrusIndexField.php',
@@ -177,6 +178,7 @@
'CirrusSearch\\Search\\ShortTextIndexField' => __DIR__ . 
'/includes/Search/ShortTextIndexField.php',
'CirrusSearch\\Search\\SourceTextIndexField' => __DIR__ . 
'/includes/Search/SourceTextIndexField.php',
'CirrusSearch\\Search\\TextIndexField' => __DIR__ . 
'/includes/Search/TextIndexField.php',
+   'CirrusSearch\\Search\\TitleHelper' => __DIR__ . 
'/includes/Search/TitleHelper.php',
'CirrusSearch\\Search\\TitleResultsType' => __DIR__ . 
'/includes/Search/ResultsType.php',
'CirrusSearch\\Searcher' => __DIR__ . '/includes/Searcher.php',
'CirrusSearch\\SiteMatrixInterwikiResolver' => __DIR__ . 
'/includes/SiteMatrixInterwikiResolver.php',
diff --git a/includes/BaseInterwikiResolver.php 
b/includes/BaseInterwikiResolver.php
index 2835b8c..d70ca91 100644
--- a/includes/BaseInterwikiResolver.php
+++ b/includes/BaseInterwikiResolver.php
@@ -38,7 +38,7 @@
// Most of the time the language is equal to the interwiki 
prefix.
// But it's not always the case, use the language_map to 
identify the interwiki prefix first.
$lang = isset( $matrix['language_map'][$lang] ) ? 

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Hygiene: Remove unused method and clean up getAPIForSite

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Hygiene: Remove unused method and clean up getAPIForSite
..


Hygiene: Remove unused method and clean up getAPIForSite

The getAPIForMobileSite method in WikipediaApp is no longer used now that
Zero configs are fetched with Retrofit, as it is the only API call using
the mobile subdomain.  This removes it, and consolidates getAPIForSite into
one method, since there is no longer any need to take mobile vs.
non-mobile subdomain requests into account.

No functional changes intended.

Change-Id: Ibc4babd736033e741b41aa84753543e99d655197
---
M app/src/main/java/org/wikipedia/WikipediaApp.java
1 file changed, 1 insertion(+), 9 deletions(-)

Approvals:
  jenkins-bot: Verified
  Niedzielski: Looks good to me, approved



diff --git a/app/src/main/java/org/wikipedia/WikipediaApp.java 
b/app/src/main/java/org/wikipedia/WikipediaApp.java
index db62d90..6d89fef 100644
--- a/app/src/main/java/org/wikipedia/WikipediaApp.java
+++ b/app/src/main/java/org/wikipedia/WikipediaApp.java
@@ -238,11 +238,7 @@
 }
 
 public Api getAPIForSite(WikiSite wiki) {
-return getAPIForSite(wiki, false);
-}
-
-public Api getAPIForSite(WikiSite wiki, boolean mobile) {
-String host = mobile ? wiki.mobileHost() : wiki.host();
+String host = wiki.host();
 String acceptLanguage = getAcceptLanguage(wiki);
 Map customHeaders = 
buildCustomHeadersMap(acceptLanguage);
 Api api;
@@ -258,10 +254,6 @@
 
 api.setHeaderCheckListener(zeroHandler);
 return api;
-}
-
-public Api getApiForMobileSite(WikiSite wiki) {
-return getAPIForSite(wiki, true);
 }
 
 /**

-- 
To view, visit https://gerrit.wikimedia.org/r/325311
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibc4babd736033e741b41aa84753543e99d655197
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Mholloway 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Niedzielski 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics...toolkit-analyzer[master]: Fix examples in README

2016-12-05 Thread Addshore (Code Review)
Addshore has submitted this change and it was merged.

Change subject: Fix examples in README
..


Fix examples in README

Change-Id: I8979a2fdd6f10c5d1cc081da43489671e688c7c2
---
M README.md
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Addshore: Verified; Looks good to me, approved



diff --git a/README.md b/README.md
index f46c025..fd30d44 100644
--- a/README.md
+++ b/README.md
@@ -15,9 +15,9 @@
 
 ** Run me using Java **
 
-java -Xmx2g -jar ./target/toolkit-analyzer.jar BadDate Map ~/data --latest
+java -Xmx2g -jar ./target/toolkit-analyzer.jar --processors BadDate 
--store ~/data --latest
 # or
-java -Xmx2g -jar ./target/toolkit-analyzer.jar BadDate Map ~/data --date 
20160808
+java -Xmx2g -jar ./target/toolkit-analyzer.jar --processors BadDate 
--store ~/data --date 20161031
 
 ** Use my output **
 

-- 
To view, visit https://gerrit.wikimedia.org/r/325332
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I8979a2fdd6f10c5d1cc081da43489671e688c7c2
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wmde/toolkit-analyzer
Gerrit-Branch: master
Gerrit-Owner: Addshore 
Gerrit-Reviewer: Addshore 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] analytics...toolkit-analyzer[master]: Fix examples in README

2016-12-05 Thread Addshore (Code Review)
Addshore has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325332

Change subject: Fix examples in README
..

Fix examples in README

Change-Id: I8979a2fdd6f10c5d1cc081da43489671e688c7c2
---
M README.md
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wmde/toolkit-analyzer 
refs/changes/32/325332/1

diff --git a/README.md b/README.md
index f46c025..fd30d44 100644
--- a/README.md
+++ b/README.md
@@ -15,9 +15,9 @@
 
 ** Run me using Java **
 
-java -Xmx2g -jar ./target/toolkit-analyzer.jar BadDate Map ~/data --latest
+java -Xmx2g -jar ./target/toolkit-analyzer.jar --processors BadDate 
--store ~/data --latest
 # or
-java -Xmx2g -jar ./target/toolkit-analyzer.jar BadDate Map ~/data --date 
20160808
+java -Xmx2g -jar ./target/toolkit-analyzer.jar --processors BadDate 
--store ~/data --date 20161031
 
 ** Use my output **
 

-- 
To view, visit https://gerrit.wikimedia.org/r/325332
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8979a2fdd6f10c5d1cc081da43489671e688c7c2
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wmde/toolkit-analyzer
Gerrit-Branch: master
Gerrit-Owner: Addshore 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] All-Projects[refs/meta/config]: Allows you to edit topic names even after merging a change

2016-12-05 Thread Chad (Code Review)
Chad has submitted this change and it was merged.

Change subject: Allows you to edit topic names even after merging a change
..


Allows you to edit topic names even after merging a change

See 
https://gerrit-review.googlesource.com/Documentation/access-control.html#category_edit_topic_name

Bug: T37534
Change-Id: I466d72d35464982574b385b5174f98662e4077a6
---
M project.config
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Chad: Verified; Looks good to me, approved



diff --git a/project.config b/project.config
index 68161b2..4de275b 100644
--- a/project.config
+++ b/project.config
@@ -13,7 +13,7 @@
label-Code-Review = -2..+2 group Project Owners
label-Code-Review = -1..+1 group Registered Users
create = group Project Owners
-   editTopicName = group Registered Users
+   editTopicName = +force group Registered Users
viewDrafts = group JenkinsBot
viewDrafts = group security
deleteDrafts = group security

-- 
To view, visit https://gerrit.wikimedia.org/r/309832
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I466d72d35464982574b385b5174f98662e4077a6
Gerrit-PatchSet: 2
Gerrit-Project: All-Projects
Gerrit-Branch: refs/meta/config
Gerrit-Owner: Paladox 
Gerrit-Reviewer: 20after4 
Gerrit-Reviewer: Chad 
Gerrit-Reviewer: Florianschmidtwelzow 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Nemo bis 
Gerrit-Reviewer: Paladox 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...Popups[mpga]: WIP: Log events

2016-12-05 Thread Phuedx (Code Review)
Phuedx has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325337

Change subject: WIP: Log events
..

WIP: Log events

Bug: T152225
Change-Id: I02eeb6a981107fa2c643b158f87529612d5240fd
---
M extension.json
M resources/ext.popups/actions.js
M resources/ext.popups/boot.js
A resources/ext.popups/changeListeners/eventLogging.js
M resources/ext.popups/reducers.js
A resources/ext.popups/schema.js
A tests/qunit/ext.popups/changeListeners/eventLogging.test.js
M tests/qunit/ext.popups/reducers.eventLogging.test.js
A tests/qunit/ext.popups/schema.test.js
9 files changed, 252 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Popups 
refs/changes/37/325337/1

diff --git a/extension.json b/extension.json
index 055ac17..828993b 100644
--- a/extension.json
+++ b/extension.json
@@ -68,10 +68,12 @@
"resources/ext.popups/reducers.js",
"resources/ext.popups/changeListener.js",
"resources/ext.popups/renderer.js",
+   "resources/ext.popups/schema.js",

"resources/ext.popups/changeListeners/footerLink.js",

"resources/ext.popups/changeListeners/linkTitle.js",

"resources/ext.popups/changeListeners/render.js",

"resources/ext.popups/changeListeners/previewCount.js",
+   
"resources/ext.popups/changeListeners/eventLogging.js",
"resources/ext.popups/boot.js"
],
"templates": {
diff --git a/resources/ext.popups/actions.js b/resources/ext.popups/actions.js
index 966379b..c90e9a3 100644
--- a/resources/ext.popups/actions.js
+++ b/resources/ext.popups/actions.js
@@ -19,7 +19,8 @@
PREVIEW_CLICK: 'PREVIEW_CLICK',
COG_CLICK: 'COG_CLICK',
SETTINGS_DIALOG_RENDERED: 'SETTINGS_DIALOG_RENDERED',
-   SETTINGS_DIALOG_CLOSED: 'SETTINGS_DIALOG_CLOSED'
+   SETTINGS_DIALOG_CLOSED: 'SETTINGS_DIALOG_CLOSED',
+   EVENT_LOGGING_QUEUE_DRAINED: 
'EVENT_LOGGING_QUEUE_DRAINED'
},
FETCH_START_DELAY = 500, // ms.
ABANDON_END_DELAY = 300; // ms.
@@ -232,6 +233,18 @@
};
};
 
+   /**
+* Represents the Event Logging queue being drained by the
+* `mw.popups.changeListeners.eventLogging` change listener.
+*
+* @return {Object}
+*/
+   actions.eventLoggingQueueDrained = function () {
+   return {
+   type: types.EVENT_LOGGING_QUEUE_DRAINED
+   };
+   };
+
mw.popups.actions = actions;
mw.popups.actionTypes = types;
 
diff --git a/resources/ext.popups/boot.js b/resources/ext.popups/boot.js
index 6729599..a09c67e 100644
--- a/resources/ext.popups/boot.js
+++ b/resources/ext.popups/boot.js
@@ -30,8 +30,9 @@
 * @param {Redux.Store} store
 * @param {Object} actions
 * @param {ext.popups.UserSettings} userSettings
+* @param {mw.eventLog.Schema} schema
 */
-   function registerChangeListeners( store, actions, userSettings ) {
+   function registerChangeListeners( store, actions, userSettings, schema 
) {
 
// Sugar.
var changeListeners = mw.popups.changeListeners,
@@ -41,6 +42,10 @@
registerChangeListener( store, changeListeners.linkTitle() );
registerChangeListener( store, changeListeners.render( actions 
) );
registerChangeListener( store, changeListeners.previewCount( 
userSettings ) );
+
+   if ( window.QUnit === undefined ) {
+   registerChangeListener( store, 
changeListeners.eventLogging( actions, schema ) );
+   }
}
 
/**
@@ -74,9 +79,12 @@
generateToken = mw.user.generateRandomSessionId,
gateway = createGateway(),
userSettings = mw.popups.createUserSettings( 
mw.storage, mw.user ),
-   isUserInCondition;
+   isUserInCondition,
+   schema;
 
isUserInCondition = mw.popups.createExperiment( mw.config, 
mw.user, userSettings );
+
+   schema = mw.popups.createSchema( mw.config, window.navigator );
 
// If debug mode is enabled, then enable Redux DevTools.
if ( mw.config.get( 'debug' ) === true ) {
@@ -90,7 +98,7 @@
) )
);
actions = createBoundActions( store );
-   registerChangeListeners( store, actions, userSettings );
+ 

[MediaWiki-commits] [Gerrit] mediawiki...Popups[mpga]: Hygiene: Organise change listeners

2016-12-05 Thread Phuedx (Code Review)
Phuedx has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325336

Change subject: Hygiene: Organise change listeners
..

Hygiene: Organise change listeners

Move all of the change listeners into
resources/ext.popups/changeListeners and remove the ChangeListener
suffix. Also, do the above for the associated tests.

Change-Id: I90ada465ea291d601f8f1c5c6e775148a2100319
---
M Popups.hooks.php
M extension.json
R resources/ext.popups/changeListeners/footerLink.js
R resources/ext.popups/changeListeners/linkTitle.js
R resources/ext.popups/changeListeners/previewCount.js
R resources/ext.popups/changeListeners/render.js
R tests/qunit/ext.popups/changeListeners/footerLink.test.js
R tests/qunit/ext.popups/changeListeners/linkTitle.test.js
R tests/qunit/ext.popups/changeListeners/previewCount.test.js
R tests/qunit/ext.popups/changeListeners/render.test.js
10 files changed, 9 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Popups 
refs/changes/36/325336/1

diff --git a/Popups.hooks.php b/Popups.hooks.php
index ccc5512..810f515 100644
--- a/Popups.hooks.php
+++ b/Popups.hooks.php
@@ -95,7 +95,7 @@
 */
public static function onResourceLoaderTestModules( array 
&$testModules, ResourceLoader &$resourceLoader ) {
$localBasePath = __DIR__;
-   $scripts = glob( 
"{$localBasePath}/tests/qunit/ext.popups/*.test.js" );
+   $scripts = glob( 
"{$localBasePath}/tests/qunit/ext.popups/{,**/}*.test.js", GLOB_BRACE );
$start = strlen( $localBasePath ) + 1;
 
$scripts = array_map( function ( $script ) use ( $start ) {
diff --git a/extension.json b/extension.json
index 9408bd2..055ac17 100644
--- a/extension.json
+++ b/extension.json
@@ -67,11 +67,11 @@
"resources/ext.popups/gateway.js",
"resources/ext.popups/reducers.js",
"resources/ext.popups/changeListener.js",
-   
"resources/ext.popups/footerLinkChangeListener.js",
-   
"resources/ext.popups/linkTitleChangeListener.js",
"resources/ext.popups/renderer.js",
-   "resources/ext.popups/renderChangeListener.js",
-   
"resources/ext.popups/previewCountChangeListener.js",
+   
"resources/ext.popups/changeListeners/footerLink.js",
+   
"resources/ext.popups/changeListeners/linkTitle.js",
+   
"resources/ext.popups/changeListeners/render.js",
+   
"resources/ext.popups/changeListeners/previewCount.js",
"resources/ext.popups/boot.js"
],
"templates": {
diff --git a/resources/ext.popups/footerLinkChangeListener.js 
b/resources/ext.popups/changeListeners/footerLink.js
similarity index 100%
rename from resources/ext.popups/footerLinkChangeListener.js
rename to resources/ext.popups/changeListeners/footerLink.js
diff --git a/resources/ext.popups/linkTitleChangeListener.js 
b/resources/ext.popups/changeListeners/linkTitle.js
similarity index 100%
rename from resources/ext.popups/linkTitleChangeListener.js
rename to resources/ext.popups/changeListeners/linkTitle.js
diff --git a/resources/ext.popups/previewCountChangeListener.js 
b/resources/ext.popups/changeListeners/previewCount.js
similarity index 100%
rename from resources/ext.popups/previewCountChangeListener.js
rename to resources/ext.popups/changeListeners/previewCount.js
diff --git a/resources/ext.popups/renderChangeListener.js 
b/resources/ext.popups/changeListeners/render.js
similarity index 100%
rename from resources/ext.popups/renderChangeListener.js
rename to resources/ext.popups/changeListeners/render.js
diff --git a/tests/qunit/ext.popups/footerLinkChangeListener.test.js 
b/tests/qunit/ext.popups/changeListeners/footerLink.test.js
similarity index 95%
rename from tests/qunit/ext.popups/footerLinkChangeListener.test.js
rename to tests/qunit/ext.popups/changeListeners/footerLink.test.js
index e09150e..e541a96 100644
--- a/tests/qunit/ext.popups/footerLinkChangeListener.test.js
+++ b/tests/qunit/ext.popups/changeListeners/footerLink.test.js
@@ -2,7 +2,7 @@
 
// Since mw.popups.changeListeners.footerLink manipulates the DOM, this 
test
// is, by necessity, an integration test.
-   QUnit.module( 'ext.popups/footerLinkChangeListener @integration', {
+   QUnit.module( 'ext.popups/changeListeners/footerLink @integration', {
setup: function () {
var boundActions = {},
that = this;
diff --git a/tests/qunit/ext.popups/linkTitleChangeListener.test.js 
b/tests/qunit/ext.popups/changeListeners/linkTitle.test.js

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Replace Linker::link() usage with LinkRendedrer

2016-12-05 Thread Phantom42 (Code Review)
Phantom42 has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325339

Change subject: Replace Linker::link() usage with LinkRendedrer
..

Replace Linker::link() usage with LinkRendedrer

Linker::link() replaced with LinkRenderer in some pages in includes/specials

Bug: T149346
Change-Id: I937bdc99d1342e73f20b8437a9b55dffb04161c5
---
M includes/specials/SpecialRecentchanges.php
M includes/specials/SpecialRevisiondelete.php
M includes/specials/SpecialSearch.php
M includes/specials/SpecialUncategorizedcategories.php
M includes/specials/SpecialUnwatchedpages.php
M includes/specials/SpecialWhatlinkshere.php
M includes/specials/pagers/AllMessagesTablePager.php
M includes/specials/pagers/BlockListPager.php
M includes/specials/pagers/ContribsPager.php
M includes/specials/pagers/DeletedContribsPager.php
M includes/specials/pagers/ImageListPager.php
11 files changed, 82 insertions(+), 65 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/39/325339/1

diff --git a/includes/specials/SpecialRecentchanges.php 
b/includes/specials/SpecialRecentchanges.php
index cd3299c..a7918a4 100644
--- a/includes/specials/SpecialRecentchanges.php
+++ b/includes/specials/SpecialRecentchanges.php
@@ -664,12 +664,13 @@
}
unset( $value );
 
-   $text = htmlspecialchars( $title );
if ( $active ) {
-   $text = '' . $text . '';
+   $text = new HtmlArmor( '' . $title . 
'' );
+   } else {
+   $text = new HtmlArmor( $title );
}
 
-   return Linker::linkKnown( $this->getPageTitle(), $text, [], 
$params );
+   return $this->getLinkRenderer()->makeKnownLink( 
$this->getPageTitle(), $text, [], $params );
}
 
/**
diff --git a/includes/specials/SpecialRevisiondelete.php 
b/includes/specials/SpecialRevisiondelete.php
index 8780c56..4b0fa00 100644
--- a/includes/specials/SpecialRevisiondelete.php
+++ b/includes/specials/SpecialRevisiondelete.php
@@ -466,9 +466,9 @@
Xml::closeElement( 'form' ) . "\n";
// Show link to edit the dropdown reasons
if ( $this->getUser()->isAllowed( 'editinterface' ) ) {
-   $link = Linker::linkKnown(
+   $link = $this->getLinkRenderer()->makeKnownLink(
$this->msg( 'revdelete-reason-dropdown' 
)->inContentLanguage()->getTitle(),
-   $this->msg( 'revdelete-edit-reasonlist' 
)->escaped(),
+   $this->msg( 'revdelete-edit-reasonlist' 
)->text(),
[],
[ 'action' => 'edit' ]
);
diff --git a/includes/specials/SpecialSearch.php 
b/includes/specials/SpecialSearch.php
index 9f83832..abc2342 100644
--- a/includes/specials/SpecialSearch.php
+++ b/includes/specials/SpecialSearch.php
@@ -499,9 +499,11 @@
}
$stParams = array_merge( $params, $this->powerSearchOptions() );
 
-   $suggest = Linker::linkKnown(
+   $linkRenderer = $this->getLinkRenderer();
+
+   $suggest = $linkRenderer->makeKnownLink(
$this->getPageTitle(),
-   $textMatches->getSuggestionSnippet() ?: null,
+   new HtmlArmor( $textMatches->getSuggestionSnippet() ) 
?: null,
[ 'id' => 'mw-search-DYM-suggestion' ],
$stParams
);
@@ -535,18 +537,20 @@
}
$stParams = array_merge( $params, $this->powerSearchOptions() );
 
-   $rewritten = Linker::linkKnown(
+   $linkRenderer = $this->getLinkRenderer();
+
+   $rewritten = $linkRenderer->makeKnownLink(
$this->getPageTitle(),
-   $textMatches->getQueryAfterRewriteSnippet() ?: null,
+   new HtmlArmor( 
$textMatches->getQueryAfterRewriteSnippet() ) ?: null,
[ 'id' => 'mw-search-DYM-rewritten' ],
$stParams
);
 
$stParams['search'] = $term;
$stParams['runsuggestion'] = 0;
-   $original = Linker::linkKnown(
+   $original = $linkRenderer->makeKnownLink(
$this->getPageTitle(),
-   htmlspecialchars( $term ),
+   $term,
[ 'id' => 'mw-search-DYM-original' ],
$stParams
);
@@ -766,9 +770,11 @@
Hooks::run( 'ShowSearchHitTitle',
[ &$link_t, &$titleSnippet, $result, $terms, $this, 
&$query 

[MediaWiki-commits] [Gerrit] mediawiki...mobileapps[master]: Temporarily skip Wikivoyage geo unit test

2016-12-05 Thread Mholloway (Code Review)
Mholloway has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325342

Change subject: Temporarily skip Wikivoyage geo unit test
..

Temporarily skip Wikivoyage geo unit test

A test was broken by an underlying content change (probably a template
change).

Skip it for now so it's not blocking other work and fix or remove the
test.  (Why are we testing against Wikivoyage?)

Change-Id: I32cfc52096cf292c2e2bbd65544961bacffd352e
---
M test/features/mobile-sections-lead/pagecontent.js
1 file changed, 2 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/mobileapps 
refs/changes/42/325342/1

diff --git a/test/features/mobile-sections-lead/pagecontent.js 
b/test/features/mobile-sections-lead/pagecontent.js
index c7f1b9e..5b41378 100644
--- a/test/features/mobile-sections-lead/pagecontent.js
+++ b/test/features/mobile-sections-lead/pagecontent.js
@@ -121,7 +121,8 @@
 assert.deepEqual(lead.geo.longitude, 28.88305556);
 });
 });
-it('Wikivoyage en Paris should have a lead object with a geo property', () 
=> {
+// TODO: FIX OR REMOVE
+it.skip('Wikivoyage en Paris should have a lead object with a geo 
property', () => {
 const uri = 
`${server.config.uri}en.wikivoyage.org/v1/page/mobile-sections-lead/Paris`;
 return preq.get({ uri })
 .then((res) => {

-- 
To view, visit https://gerrit.wikimedia.org/r/325342
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I32cfc52096cf292c2e2bbd65544961bacffd352e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/mobileapps
Gerrit-Branch: master
Gerrit-Owner: Mholloway 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...MassMessage[master]: MassMessage.alias.php translations for Bengali

2016-12-05 Thread Aftab (Code Review)
Aftab has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325349

Change subject: MassMessage.alias.php translations for Bengali
..

MassMessage.alias.php translations for Bengali

Change-Id: I0465dbfac234c967200fac5bdc00ecfc5df2e515
---
M MassMessage.alias.php
1 file changed, 7 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MassMessage 
refs/changes/49/325349/2

diff --git a/MassMessage.alias.php b/MassMessage.alias.php
index 4e9b074..e2b0a85 100644
--- a/MassMessage.alias.php
+++ b/MassMessage.alias.php
@@ -35,6 +35,13 @@
'EditMassMessageList' => array( 'بَزین_پیامی_لیست_ئی_دستکاری_کورتین' ),
 );
 
+/** Bengali (বাংলা) */
+$specialPageAliases['bn'] = array(
+   'MassMessage' => array( 'গণ_বার্তা' ),
+   'CreateMassMessageList' => array( 'গণ_বার্তার_তালিকা_তৈরি' ),
+   'EditMassMessageList' => array( 'গণ_বার্তার_তালিকা_সম্পাদনা' ),
+);
+
 /** German (Deutsch) */
 $specialPageAliases['de'] = array(
'MassMessage' => array( 'Massennachrichten' ),

-- 
To view, visit https://gerrit.wikimedia.org/r/325349
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0465dbfac234c967200fac5bdc00ecfc5df2e515
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/MassMessage
Gerrit-Branch: master
Gerrit-Owner: Aftab 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...CirrusSearch[master]: Remove support for the all field in morelike

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Remove support for the all field in morelike
..


Remove support for the all field in morelike

This was never used in production. It needs another pass
to fetch the data.
It also helps to make Keywordfeatures construction more
homogeneous.

Change-Id: I055816d8f8ff115fe499dbce64fd38a0e70a4ee5
---
M CirrusSearch.php
M i18n/en.json
M includes/Hooks.php
M includes/Query/MoreLikeFeature.php
M includes/Searcher.php
M tests/browser/features/more_like_this_options.feature
M tests/unit/Query/MoreLikeFeatureTest.php
7 files changed, 4 insertions(+), 73 deletions(-)

Approvals:
  EBernhardson: Looks good to me, approved
  jenkins-bot: Verified

Objections:
  Cindy-the-browser-test-bot: There's a problem with this change, please improve



diff --git a/CirrusSearch.php b/CirrusSearch.php
index a108f29..873f960 100644
--- a/CirrusSearch.php
+++ b/CirrusSearch.php
@@ -514,17 +514,7 @@
'auxiliary_text',
'opening_text',
'headings',
-   'all'
 ];
-
-// When set to false cirrus will use the text content to build the query
-// and search on the field listed in $wgCirrusSearchMoreLikeThisFields
-// Set to true if you want to use field data as input text to build the initial
-// query.
-// Note that if the all field is used then this setting will be forced to true.
-// This is because the all field is not part of the _source and its content 
cannot
-// be retrieved by elasticsearch.
-$wgCirrusSearchMoreLikeThisUseFields = false;
 
 // This allows redirecting queries to a separate cluster configured
 // in $wgCirrusSearchClusters. Note that queries can use multiple features, in
diff --git a/i18n/en.json b/i18n/en.json
index f84b64f..54bd983 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -22,7 +22,7 @@
"apihelp-cirrus-settings-dump-example": "Get a dump of CirrusSearch 
settings for this wiki.",
"apierror-cirrus-requesttoolong": "Prefix search request was longer 
than the maximum allowed length. ($1  $2)",
"cirrussearch-give-feedback": "Give us your feedback",
-   "cirrussearch-morelikethis-settings": " # \n# This message lets you configure the settings of the 
\"more like this\" feature.\n# Changes to this take effect immediately.\n# The 
syntax is as follows:\n#   * Everything from a \"#\" character to the end of 
the line is a comment.\n#   * Every non-blank line is the setting name followed 
by a \":\" character followed by the setting value\n# The settings are:\n#   * 
min_doc_freq (integer): Minimum number of documents (per shard) that need a 
term for it to be considered.\n#   * max_doc_freq (integer): Maximum number of 
documents (per shard) that have a term for it to be considered.\n#  
 High frequency terms are generally \"stop words\".\n#   * max_query_terms 
(integer): Maximum number of terms to be considered. This value is limited to 
$wgCirrusSearchMoreLikeThisMaxQueryTermsLimit (100).\n#   * min_term_freq 
(integer): Minimum number of times the term appears in the input to doc to be 
considered. For small fields (title) this value should be 1.\n#   * 
minimum_should_match (percentage -100% to 100%, or integer number of terms): 
The percentage of terms to match on. Defaults to 30%.\n#   * min_word_len 
(integer): Minimal length of a term to be considered. Defaults to 0.\n#   * 
max_word_len (integer): The maximum word length above which words will be 
ignored. Defaults to unbounded (0).\n#   * fields (comma separated list of 
values): These are the fields to use. Allowed fields are title, text, 
auxiliary_text, opening_text, headings and all.\n#   * use_fields (true|false) 
: Tell the \"more like this\" query to use only the field data. Defaults to 
false: the system will extract the content of the text field to build the 
query.\n# Examples of good lines:\n# min_doc_freq:2\n# max_doc_freq:2\n# 
max_query_terms:25\n# min_term_freq:2\n# minimum_should_match:30%\n# 
min_word_len:2\n# max_word_len:40\n# fields:text,opening_text\n# 
use_fields:true\n#  ",
+   "cirrussearch-morelikethis-settings": " # \n# This message lets you configure the settings of the 
\"more like this\" feature.\n# Changes to this take effect immediately.\n# The 
syntax is as follows:\n#   * Everything from a \"#\" character to the end of 
the line is a comment.\n#   * Every non-blank line is the setting name followed 
by a \":\" character followed by the setting value\n# The settings are:\n#   * 
min_doc_freq (integer): Minimum number of documents (per shard) that need a 
term for it to be considered.\n#   * max_doc_freq (integer): Maximum number of 
documents (per shard) that have a term for it to be considered.\n#  
 High frequency terms are generally \"stop words\".\n#   * max_query_terms 
(integer): Maximum number of terms to be considered. This value is limited to 

[MediaWiki-commits] [Gerrit] integration/config[master]: Add trendingedits packages to CI image

2016-12-05 Thread Hashar (Code Review)
Hashar has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325330

Change subject: Add trendingedits packages to CI image
..

Add trendingedits packages to CI image

Adds rdkafka libs and development headers, on the same model as other
services. Will be on Jessie instances.

Bug: T151469
Change-Id: I9244aaeb084faf8e486d3553c1db2c40ef6bedc9
---
M dib/puppet/ciimage.pp
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/30/325330/1

diff --git a/dib/puppet/ciimage.pp b/dib/puppet/ciimage.pp
index 414b21b..6d11c72 100644
--- a/dib/puppet/ciimage.pp
+++ b/dib/puppet/ciimage.pp
@@ -134,6 +134,7 @@
 # run. NOTE: hiera must have: service::configuration::use_dev_pkgs: true
 include graphoid::packages
 include mathoid::packages
+include trendingedits::packages
 }
 
 ensure_packages(['mariadb-client', 'mariadb-server'])

-- 
To view, visit https://gerrit.wikimedia.org/r/325330
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9244aaeb084faf8e486d3553c1db2c40ef6bedc9
Gerrit-PatchSet: 1
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Hashar 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Add search.elastic.host to settings for limited elasticsearc...

2016-12-05 Thread 20after4 (Code Review)
20after4 has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325333

Change subject: Add search.elastic.host to settings for limited elasticsearch 
testing
..

Add search.elastic.host to settings for limited elasticsearch testing

This does not enable elasticsearch but it allows us to test it in
a limited way.

Change-Id: Ica13a6f4eb9c92c3436f64055bf8fe01a203d211
---
M modules/phabricator/data/fixed_settings.yaml
1 file changed, 4 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/33/325333/1

diff --git a/modules/phabricator/data/fixed_settings.yaml 
b/modules/phabricator/data/fixed_settings.yaml
index cec1952..3016504 100644
--- a/modules/phabricator/data/fixed_settings.yaml
+++ b/modules/phabricator/data/fixed_settings.yaml
@@ -5,6 +5,10 @@
 # in Phabricator but only for administrators.  If you do not have the ability 
to restart the
 # associated daemons do not merge changes to this file.
 
+search.elastic.host: 'http://search.svc.eqiad.wmnet:9200'
+search.elastic.version: '2'
+search.elastic.enabled: false
+
 ui.logo:
   'logoImagePHID': 'PHID-FILE-rs3pf2brupiulr6zcnrg'
   'wordmarkText': 'Phabricator'

-- 
To view, visit https://gerrit.wikimedia.org/r/325333
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ica13a6f4eb9c92c3436f64055bf8fe01a203d211
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: 20after4 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...MassMessage[master]: MassMessage.i18n.magic.php translations for Bengali

2016-12-05 Thread Aftab (Code Review)
Aftab has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325347

Change subject: MassMessage.i18n.magic.php translations for Bengali
..

MassMessage.i18n.magic.php translations for Bengali

Change-Id: Icc880ab02a83d9dd30368e68dbfeeaa569fed6df
---
M MassMessage.i18n.magic.php
1 file changed, 5 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MassMessage 
refs/changes/47/325347/2

diff --git a/MassMessage.i18n.magic.php b/MassMessage.i18n.magic.php
index c2b8972..b79ba39 100644
--- a/MassMessage.i18n.magic.php
+++ b/MassMessage.i18n.magic.php
@@ -21,6 +21,11 @@
'target' => array( 0, 'هدف' ),
 );
 
+/** Bengali (বাংলা) */
+$magicWords['bn'] = array(
+   'target' => array( 0, 'লক্ষ্য' ),
+);
+
 /** Czech (čeština) */
 $magicWords['cs'] = array(
'target' => array( 0, 'cíl' ),

-- 
To view, visit https://gerrit.wikimedia.org/r/325347
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Icc880ab02a83d9dd30368e68dbfeeaa569fed6df
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/MassMessage
Gerrit-Branch: master
Gerrit-Owner: Aftab 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Revert "Add CentralAuthTokenClient"

2016-12-05 Thread BearND (Code Review)
BearND has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325327

Change subject: Revert "Add CentralAuthTokenClient"
..

Revert "Add CentralAuthTokenClient"

This reverts commit 8218d146ceb9205cfdf7a2f6fc74d5a6f1ec2c22.

Not needed anymore since we're passing the central auth tokens through the 
ShareCookieManager. 

See patches starting with I91599b410dfbc6136838e9301290866ee733aaa8, in 
particular Ic3e05370d9bb028bac80446acf8b184c49b479a7 "Copy CentralAuth tokens 
for www.wikidata.org requests"

Change-Id: Ic4f2c180f3b85599795c9bce2934c85068c99d2f
---
D app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthToken.java
D 
app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthTokenClient.java
D 
app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthTokenRetrievalFailedException.java
D 
app/src/test/java/org/wikipedia/descriptions/centralauth/CentralAuthClientTest.java
D app/src/test/res/raw/centralauth.json
D app/src/test/res/raw/centralauth_notloggedin.json
6 files changed, 0 insertions(+), 206 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia 
refs/changes/27/325327/1

diff --git 
a/app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthToken.java
 
b/app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthToken.java
deleted file mode 100644
index 4df0068..000
--- 
a/app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthToken.java
+++ /dev/null
@@ -1,36 +0,0 @@
-package org.wikipedia.descriptions.centralauth;
-
-import android.support.annotation.NonNull;
-import android.support.annotation.Nullable;
-
-import com.google.gson.annotations.SerializedName;
-
-import org.wikipedia.dataclient.mwapi.MwResponse;
-import org.wikipedia.json.annotations.Required;
-
-/**
- * Represents the Gson response of a CentralAuth token request.
- *
- * Note: a CentralAuthToken is only valid for a single request, and will 
become invalid after 10
- * seconds.[1]
- *
- * [1] https://www.mediawiki.org/wiki/Extension:CentralAuth/API
- */
-public class CentralAuthToken extends MwResponse {
-@SuppressWarnings("unused") @SerializedName("centralauthtoken") @Nullable
-private Token child;
-
-public boolean success() {
-return child != null && child.centralAuthToken != null;
-}
-
-/** Only call if #success returns true */
-@NonNull String getToken() {
-return child.centralAuthToken;
-}
-
-private static class Token {
-@SuppressWarnings("unused") @SerializedName("centralauthtoken") 
@Required
-private String centralAuthToken;
-}
-}
diff --git 
a/app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthTokenClient.java
 
b/app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthTokenClient.java
deleted file mode 100644
index 51ab11a..000
--- 
a/app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthTokenClient.java
+++ /dev/null
@@ -1,67 +0,0 @@
-package org.wikipedia.descriptions.centralauth;
-
-import android.support.annotation.NonNull;
-import android.support.annotation.VisibleForTesting;
-
-import org.wikipedia.dataclient.WikiSite;
-import org.wikipedia.dataclient.retrofit.MwCachedService;
-import org.wikipedia.dataclient.retrofit.RetrofitException;
-
-import retrofit2.Call;
-import retrofit2.Response;
-import retrofit2.http.GET;
-
-/**
- * When accessing the API using a cross-domain AJAX request (CORS), use this 
to authenticate as the
- * current SUL user. Use action=centralauthtoken on this wiki to retrieve the 
token, before making
- * the CORS request. Each token may only be used once, and expires after 10 
seconds.
- */
-public class CentralAuthTokenClient {
-@NonNull
-private final MwCachedService cachedService = new 
MwCachedService<>(Service.class);
-
-public interface Callback {
-void success(@NonNull Call call, @NonNull String 
token);
-void failure(@NonNull Call call, @NonNull Throwable 
caught);
-}
-
-@NonNull public Call request(@NonNull final WikiSite 
wiki,
-   @NonNull final Callback cb) 
{
-Service service = cachedService.service(wiki);
-return request(service, cb);
-}
-
-@VisibleForTesting @NonNull Call request(@NonNull final 
Service service,
-   @NonNull final 
Callback cb) {
-Call call = service.get();
-call.enqueue(new retrofit2.Callback() {
-@Override
-public void onResponse(Call call, 
Response response) {
-if (response.isSuccessful()) {
-final CentralAuthToken body = response.body();
-if (body.success()) {
-cb.success(call, body.getToken());
-} else if (body.hasError()) {
-

[MediaWiki-commits] [Gerrit] mediawiki...MobileFrontend[master]: Logged in user tests do not work on beta cluster

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Logged in user tests do not work on beta cluster
..


Logged in user tests do not work on beta cluster

On the beta cluster, the same user is used for all interactions.
Until this changes and the step "I am logged in as a new user"
works we should disable this test.

Bug: T148599
Change-Id: I6f24811fbcb58451ad05eb3ccbcf89c65be22503
---
M tests/browser/features/special_watchlist_newuser.feature
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  jenkins-bot: Verified
  Phuedx: Looks good to me, approved



diff --git a/tests/browser/features/special_watchlist_newuser.feature 
b/tests/browser/features/special_watchlist_newuser.feature
index 82aa870..6804cd3 100644
--- a/tests/browser/features/special_watchlist_newuser.feature
+++ b/tests/browser/features/special_watchlist_newuser.feature
@@ -1,4 +1,4 @@
-@chrome @en.m.wikipedia.beta.wmflabs.org @firefox @integration 
@test2.m.wikipedia.org @vagrant @login
+@chrome @firefox @integration @test2.m.wikipedia.org @vagrant @login
 Feature: Manage Watchlist
 
   Background:

-- 
To view, visit https://gerrit.wikimedia.org/r/325321
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6f24811fbcb58451ad05eb3ccbcf89c65be22503
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 
Gerrit-Reviewer: Phuedx 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...Wikibase[master]: Add normalized values even if the value was encountered before.

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add normalized values even if the value was encountered before.
..


Add normalized values even if the value was encountered before.

Bug: T150877
Change-Id: I053292d0fceba9f4551391b30662e78e10f32d65
---
M repo/includes/Rdf/Values/QuantityRdfBuilder.php
M repo/tests/phpunit/includes/Rdf/Values/QuantityRdfBuilderTest.php
2 files changed, 77 insertions(+), 22 deletions(-)

Approvals:
  Daniel Kinzler: Looks good to me, approved
  Thiemo Mättig (WMDE): Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/repo/includes/Rdf/Values/QuantityRdfBuilder.php 
b/repo/includes/Rdf/Values/QuantityRdfBuilder.php
index 33cc262..2d9cf6e 100644
--- a/repo/includes/Rdf/Values/QuantityRdfBuilder.php
+++ b/repo/includes/Rdf/Values/QuantityRdfBuilder.php
@@ -74,32 +74,22 @@
// Can we convert units? This condition may become more 
complex in the future,
// but should keep checks for all prerequisites being 
set.
// FIXME: make this depend on flavor
-   if ( $valueLName && $this->unitConverter != null ) {
+   if ( $this->unitConverter ) {
$newValue = 
$this->unitConverter->toStandardUnits( $value );
 
if ( $newValue ) {
+   $normLName = $this->addValueNode(
+   $writer,
+   $propertyValueNamespace,
+   $propertyValueLName,
+   $dataType,
+   $newValue,
+   true
+   );
if ( $newValue->equals( $value ) ) {
-   
$this->complexValueHelper->attachValueNode(
-   $writer,
-   $propertyValueNamespace,
-   $propertyValueLName,
-   $dataType,
-   $value,
-   true
-   );
-
-   // The unnormalize value is 
always its own normalization.
+   // The normalized value is 
always its own normalization.
$this->linkNormalizedValue( 
$valueLName, $valueLName );
} else {
-   $normLName = 
$this->addValueNode(
-   $writer,
-   $propertyValueNamespace,
-   $propertyValueLName,
-   $dataType,
-   $newValue,
-   true
-   );
-
// The normalized value is 
always its own normalization.
$this->linkNormalizedValue( 
$normLName, $normLName );
 
@@ -114,10 +104,13 @@
/**
 * Connects a normalized value node to its base node via the 
quantityNormalized predicate.
 *
-* @param string $valueLName
-* @param string $normLName
+* @param string|null $valueLName
+* @param string|null $normLName
 */
private function linkNormalizedValue( $valueLName, $normLName ) {
+   if ( is_null( $valueLName ) || is_null( $normLName ) ) {
+   return;
+   }
$valueWriter = $this->complexValueHelper->getValueNodeWriter();
$valueWriter->about( RdfVocabulary::NS_VALUE, $valueLName )
->say( RdfVocabulary::NS_ONTOLOGY, 'quantityNormalized' 
)
diff --git a/repo/tests/phpunit/includes/Rdf/Values/QuantityRdfBuilderTest.php 
b/repo/tests/phpunit/includes/Rdf/Values/QuantityRdfBuilderTest.php
index 25fc238..3ae16cf 100644
--- a/repo/tests/phpunit/includes/Rdf/Values/QuantityRdfBuilderTest.php
+++ b/repo/tests/phpunit/includes/Rdf/Values/QuantityRdfBuilderTest.php
@@ -330,4 +330,66 @@
$this->helper->assertNTriplesEquals( $expected, $result );
}
 
+   /**
+* @ticket T150877
+*/
+   public function testWriteTwice() {

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Turn off CirrusSearch interwiki load test

2016-12-05 Thread EBernhardson (Code Review)
EBernhardson has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325329

Change subject: Turn off CirrusSearch interwiki load test
..

Turn off CirrusSearch interwiki load test

Load test is complete. Remove all the supporting code.

Bug: T149740
Change-Id: I79026a05ad9591f7b972cef8196b647a8b2ce4ce
---
D wmf-config/CirrusSearch-interwikiSources.php
M wmf-config/CirrusSearch-production.php
M wmf-config/InitialiseSettings.php
3 files changed, 0 insertions(+), 874 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/29/325329/1

diff --git a/wmf-config/CirrusSearch-interwikiSources.php 
b/wmf-config/CirrusSearch-interwikiSources.php
deleted file mode 100644
index b0b00aa..000
--- a/wmf-config/CirrusSearch-interwikiSources.php
+++ /dev/null
@@ -1,869 +0,0 @@
- 
-  array (
-  ),
-  'afwiki' => 
-  array (
-'b' => 'afwikibooks',
-'q' => 'afwikiquote',
-'wikt' => 'afwiktionary',
-  ),
-  'amwiki' => 
-  array (
-'wikt' => 'amwiktionary',
-  ),
-  'angwiki' => 
-  array (
-'wikt' => 'angwiktionary',
-  ),
-  'anwiki' => 
-  array (
-'wikt' => 'anwiktionary',
-  ),
-  'arwiki' => 
-  array (
-'b' => 'arwikibooks',
-'n' => 'arwikinews',
-'q' => 'arwikiquote',
-'s' => 'arwikisource',
-'v' => 'arwikiversity',
-'wikt' => 'arwiktionary',
-  ),
-  'astwiki' => 
-  array (
-'wikt' => 'astwiktionary',
-  ),
-  'aswiki' => 
-  array (
-'s' => 'aswikisource',
-  ),
-  'aywiki' => 
-  array (
-'wikt' => 'aywiktionary',
-  ),
-  'azwiki' => 
-  array (
-'b' => 'azwikibooks',
-'q' => 'azwikiquote',
-'s' => 'azwikisource',
-'wikt' => 'azwiktionary',
-  ),
-  'bewiki' => 
-  array (
-'b' => 'bewikibooks',
-'q' => 'bewikiquote',
-'s' => 'bewikisource',
-'wikt' => 'bewiktionary',
-  ),
-  'bgwiki' => 
-  array (
-'b' => 'bgwikibooks',
-'n' => 'bgwikinews',
-'q' => 'bgwikiquote',
-'s' => 'bgwikisource',
-'wikt' => 'bgwiktionary',
-  ),
-  'bnwiki' => 
-  array (
-'b' => 'bnwikibooks',
-'s' => 'bnwikisource',
-'wikt' => 'bnwiktionary',
-  ),
-  'brwiki' => 
-  array (
-'q' => 'brwikiquote',
-'s' => 'brwikisource',
-'wikt' => 'brwiktionary',
-  ),
-  'bswiki' => 
-  array (
-'b' => 'bswikibooks',
-'n' => 'bswikinews',
-'q' => 'bswikiquote',
-'s' => 'bswikisource',
-'wikt' => 'bswiktionary',
-  ),
-  'cawiki' => 
-  array (
-'b' => 'cawikibooks',
-'n' => 'cawikinews',
-'q' => 'cawikiquote',
-'s' => 'cawikisource',
-'wikt' => 'cawiktionary',
-  ),
-  'chrwiki' => 
-  array (
-'wikt' => 'chrwiktionary',
-  ),
-  'cowiki' => 
-  array (
-'wikt' => 'cowiktionary',
-  ),
-  'csbwiki' => 
-  array (
-'wikt' => 'csbwiktionary',
-  ),
-  'cswiki' => 
-  array (
-'b' => 'cswikibooks',
-'n' => 'cswikinews',
-'q' => 'cswikiquote',
-'s' => 'cswikisource',
-'v' => 'cswikiversity',
-'wikt' => 'cswiktionary',
-  ),
-  'cvwiki' => 
-  array (
-'b' => 'cvwikibooks',
-  ),
-  'cywiki' => 
-  array (
-'b' => 'cywikibooks',
-'q' => 'cywikiquote',
-'s' => 'cywikisource',
-'wikt' => 'cywiktionary',
-  ),
-  'dawiki' => 
-  array (
-'b' => 'dawikibooks',
-'q' => 'dawikiquote',
-'s' => 'dawikisource',
-'wikt' => 'dawiktionary',
-  ),
-  'dewiki' => 
-  array (
-'b' => 'dewikibooks',
-'n' => 'dewikinews',
-'q' => 'dewikiquote',
-'s' => 'dewikisource',
-'v' => 'dewikiversity',
-'voy' => 'dewikivoyage',
-'wikt' => 'dewiktionary',
-  ),
-  'dvwiki' => 
-  array (
-'wikt' => 'dvwiktionary',
-  ),
-  'elwiki' => 
-  array (
-'b' => 'elwikibooks',
-'n' => 'elwikinews',
-'q' => 'elwikiquote',
-'s' => 'elwikisource',
-'v' => 'elwikiversity',
-'voy' => 'elwikivoyage',
-'wikt' => 'elwiktionary',
-  ),
-  'enwiki' => 
-  array (
-'b' => 'enwikibooks',
-'n' => 'enwikinews',
-'q' => 'enwikiquote',
-'s' => 'enwikisource',
-'v' => 'enwikiversity',
-'voy' => 'enwikivoyage',
-'wikt' => 'enwiktionary',
-  ),
-  'eowiki' => 
-  array (
-'b' => 'eowikibooks',
-'n' => 'eowikinews',
-'q' => 'eowikiquote',
-'s' => 'eowikisource',
-'wikt' => 'eowiktionary',
-  ),
-  'eswiki' => 
-  array (
-'b' => 'eswikibooks',
-'n' => 'eswikinews',
-'q' => 'eswikiquote',
-'s' => 'eswikisource',
-'v' => 'eswikiversity',
-'voy' => 'eswikivoyage',
-'wikt' => 'eswiktionary',
-  ),
-  'etwiki' => 
-  array (
-'b' => 'etwikibooks',
-'q' => 'etwikiquote',
-'s' => 'etwikisource',
-'wikt' => 'etwiktionary',
-  ),
-  'euwiki' => 
-  array (
-'b' => 'euwikibooks',
-'q' => 'euwikiquote',
-'wikt' => 'euwiktionary',
-  ),
-  'fawiki' => 
-  array (
-'b' => 'fawikibooks',
-'n' => 'fawikinews',
-'q' => 'fawikiquote',
-'s' => 'fawikisource',
-'voy' => 

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Feed cards for Surveys and Fundraising.

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Feed cards for Surveys and Fundraising.
..


Feed cards for Surveys and Fundraising.

...plus Tests!

Bug: T140012
Change-Id: If2f32bdf869b17210e9e9efbd9d774e8cbcd33b4
---
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testFocus-320dp-en-ltr-font1.0x-dark.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testFocus-320dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testLayoutDirection-320dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testLayoutDirection-320dp-en-rtl-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testTheme-320dp-en-ltr-font1.0x-dark.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testTheme-320dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testWidth-320dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testWidth-320dp-en-ltr-font1.5x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testWidth-480dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testWidth-480dp-en-ltr-font1.5x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testFocus-320dp-en-ltr-font1.0x-dark.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testFocus-320dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testLayoutDirection-320dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testLayoutDirection-320dp-en-rtl-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testTheme-320dp-en-ltr-font1.0x-dark.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testTheme-320dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testWidth-320dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testWidth-320dp-en-ltr-font1.5x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testWidth-480dp-en-ltr-font1.0x-light.png
A 
app/screenshots-ref/org.wikipedia.feed.announcement.SurveyCardViewTest.testWidth-480dp-en-ltr-font1.5x-light.png
A 
app/src/androidTest/java/org/wikipedia/feed/announcement/FundraisingCardViewTest.java
A 
app/src/androidTest/java/org/wikipedia/feed/announcement/SurveyCardViewTest.java
M app/src/main/java/org/wikipedia/feed/FeedFragment.java
M app/src/main/java/org/wikipedia/feed/announcement/Announcement.java
M app/src/main/java/org/wikipedia/feed/announcement/AnnouncementCardView.java
M app/src/main/java/org/wikipedia/feed/announcement/AnnouncementClient.java
A app/src/main/java/org/wikipedia/feed/announcement/FundraisingCard.java
A app/src/main/java/org/wikipedia/feed/announcement/FundraisingCardView.java
A app/src/main/java/org/wikipedia/feed/announcement/SurveyCard.java
A app/src/main/java/org/wikipedia/feed/announcement/SurveyCardView.java
M app/src/main/java/org/wikipedia/feed/model/CardType.java
M app/src/main/java/org/wikipedia/util/GeoUtil.java
A app/src/main/res/drawable/ic_fundraising_header_2016.xml
M app/src/main/res/layout/view_card_announcement.xml
M app/src/main/res/values-qq/strings.xml
M app/src/main/res/values/strings.xml
36 files changed, 386 insertions(+), 31 deletions(-)

Approvals:
  Mholloway: Looks good to me, but someone else must approve
  jenkins-bot: Verified
  Niedzielski: Looks good to me, approved



diff --git 
a/app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testFocus-320dp-en-ltr-font1.0x-dark.png
 
b/app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testFocus-320dp-en-ltr-font1.0x-dark.png
new file mode 100644
index 000..7d531cd
--- /dev/null
+++ 
b/app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testFocus-320dp-en-ltr-font1.0x-dark.png
Binary files differ
diff --git 
a/app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testFocus-320dp-en-ltr-font1.0x-light.png
 
b/app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testFocus-320dp-en-ltr-font1.0x-light.png
new file mode 100644
index 000..4dd71e2
--- /dev/null
+++ 
b/app/screenshots-ref/org.wikipedia.feed.announcement.FundraisingCardViewTest.testFocus-320dp-en-ltr-font1.0x-light.png
Binary files differ
diff --git 

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Re-enable the Flow beta feature

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Re-enable the Flow beta feature
..


Re-enable the Flow beta feature

Bug: T138310
Change-Id: I6343e469c93039d74d56c6413d59d9bedb932a84
---
M wmf-config/InitialiseSettings.php
1 file changed, 12 insertions(+), 12 deletions(-)

Approvals:
  Thcipriani: Looks good to me, approved
  Catrope: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index 5480bbe..cde4bb9 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -16148,19 +16148,19 @@
'testwiki' => true,
 
// Temporarily disabled for T138310
-// 'bswiki' => true,
-// 'cawiki' => true, // T120829
-// 'elwiki' => true, // T144384
-// 'frwiki' => true, // T136684
+   'bswiki' => true,
+   'cawiki' => true, // T120829
+   'elwiki' => true, // T144384
+   'frwiki' => true, // T136684
'frwikiquote' => true, // T138064
-// 'frwikisource' => true, // T132914
-// 'frwikivoyage' => true, // T135702
-// 'nowiki' => true, // T132693
-// 'urwiki' => true,
-// 'zhwiki' => true,
-// 'wikidatawiki' => true,
-// 'specieswiki' => true, // T134898
-// 'outreachwiki' => true, // T135582
+   'frwikisource' => true, // T132914
+   'frwikivoyage' => true, // T135702
+   'nowiki' => true, // T132693
+   'urwiki' => true,
+   'zhwiki' => true,
+   'wikidatawiki' => true,
+   'specieswiki' => true, // T134898
+   'outreachwiki' => true, // T135582
 ],
 'wmgUseDisambiguator' => [
'default' => true,

-- 
To view, visit https://gerrit.wikimedia.org/r/324764
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6343e469c93039d74d56c6413d59d9bedb932a84
Gerrit-PatchSet: 2
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Catrope 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: Florianschmidtwelzow 
Gerrit-Reviewer: Thcipriani 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Add b/c for the $wgEchoConfig -> $wgEchoEventLoggingSchema r...

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add b/c for the $wgEchoConfig -> $wgEchoEventLoggingSchema 
rename in I2f9d5d111f
..


Add b/c for the $wgEchoConfig -> $wgEchoEventLoggingSchema rename in I2f9d5d111f

Change-Id: I544f37dd5d89a1abe8a3e86740e69e2a2157ffe3
---
M wmf-config/CommonSettings.php
1 file changed, 9 insertions(+), 4 deletions(-)

Approvals:
  Thcipriani: Looks good to me, approved
  Legoktm: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/wmf-config/CommonSettings.php b/wmf-config/CommonSettings.php
index ab0e3b9..4bf2aee 100644
--- a/wmf-config/CommonSettings.php
+++ b/wmf-config/CommonSettings.php
@@ -2624,10 +2624,15 @@
 if ( $wmgUseEcho ) {
require_once( "$IP/extensions/Echo/Echo.php" );
 
-   // Eventlogging for Schema:EchoMail
-   $wgEchoConfig['eventlogging']['EchoMail']['enabled'] = true;
-   // Eventlogging for Schema:EchoInteraction
-   $wgEchoConfig['eventlogging']['EchoInteraction']['enabled'] = true;
+   if ( isset( $wgEchoConfig ) ) {
+   // Eventlogging for Schema:EchoMail
+   $wgEchoConfig['eventlogging']['EchoMail']['enabled'] = true;
+   // Eventlogging for Schema:EchoInteraction
+   $wgEchoConfig['eventlogging']['EchoInteraction']['enabled'] = 
true;
+   } else {
+   $wgEchoEventLoggingSchemas['EchoMail']['enabled'] = true;
+   $wgEchoEventLoggingSchemas['EchoInteraction']['enabled'] = true;
+   }
 
$wgEchoEnableEmailBatch = $wmgEchoEnableEmailBatch;
$wgEchoEmailFooterAddress = $wmgEchoEmailFooterAddress;

-- 
To view, visit https://gerrit.wikimedia.org/r/324792
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I544f37dd5d89a1abe8a3e86740e69e2a2157ffe3
Gerrit-PatchSet: 2
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Catrope 
Gerrit-Reviewer: Florianschmidtwelzow 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Thcipriani 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...Popups[mpga]: Don't use $.extend in nextState to preserve undefined fields

2016-12-05 Thread Jhernandez (Code Review)
Jhernandez has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325344

Change subject: Don't use $.extend in nextState to preserve undefined fields
..

Don't use $.extend in nextState to preserve undefined fields

Since the state was cloned into an empty object with $.extend, undefined
properties were being deleted from it, not actually preserving those
keys. So:

 nextState({hi: undefined, ho: 1}, {ho: 2})
 //> {ho: 2}

It seems like a more consistent behavior would be to not lose any own
keys on the state as we do with the updates too, so that:

 nextState({hi: undefined, ho: 1}, {ho: 2})
 //> {hi: undefined, ho: 2}

Which is what this commit does by not using $.extend to clone the state
and instead just manually copy the keys to the new object, even the
undefined ones.

Change-Id: If4f2a3b0d25bb5ef34cfbc1f2c9c0b5479aeee9b
---
M resources/ext.popups/reducers.js
1 file changed, 11 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Popups 
refs/changes/44/325344/1

diff --git a/resources/ext.popups/reducers.js b/resources/ext.popups/reducers.js
index cee40f7..c7bc80d 100644
--- a/resources/ext.popups/reducers.js
+++ b/resources/ext.popups/reducers.js
@@ -6,10 +6,10 @@
 *
 * N.B. OO.copy doesn't copy Element instances, whereas $.extend does.
 * However, OO.copy does copy properties whose values are undefined or 
null,
-* whereas $.extend doesn't. Since the state tree contains an Element
-* instance - the preview.activeLink property - we need to use 
$.extend. But
-* to copy undefined/null into the state we need to manually iterate 
over
-* updates and check with hasOwnProperty to copy over to the new state.
+* whereas $.extend doesn't. Since the state tree contains an Element 
instance
+* - the preview.activeLink property - and we want to copy 
undefined/null into
+* the state we need to manually iterate over updates and check with
+* hasOwnProperty to copy over to the new state.
 *
 * In [change listeners](/doc/change_listeners.md), for example, we 
talk about
 * the previous state and the current state (the `prevState` and `state`
@@ -22,9 +22,15 @@
 * @return {Object}
 */
function nextState( state, updates ) {
-   var result = $.extend( {}, state ),
+   var result = {},
key;
 
+   for ( key in state ) {
+   if ( state.hasOwnProperty( key ) && 
!updates.hasOwnProperty( key ) ) {
+   result[key] = state[key];
+   }
+   }
+
for ( key in updates ) {
if ( updates.hasOwnProperty( key ) ) {
result[key] = updates[key];

-- 
To view, visit https://gerrit.wikimedia.org/r/325344
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: If4f2a3b0d25bb5ef34cfbc1f2c9c0b5479aeee9b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Popups
Gerrit-Branch: mpga
Gerrit-Owner: Jhernandez 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Disable wgAbuseFilterProfile at cswiki

2016-12-05 Thread Urbanecm (Code Review)
Urbanecm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325323

Change subject: Disable wgAbuseFilterProfile at cswiki
..

Disable wgAbuseFilterProfile at cswiki

This reverts commit 1d1e5e68c2079e2290b1071e13a2ee20e4b00def.

Change-Id: I16534abcdc72110927ff35a596c4bd63acb01849
---
M wmf-config/abusefilter.php
1 file changed, 0 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/23/325323/1

diff --git a/wmf-config/abusefilter.php b/wmf-config/abusefilter.php
index 264c3fa..8123a46 100644
--- a/wmf-config/abusefilter.php
+++ b/wmf-config/abusefilter.php
@@ -83,9 +83,6 @@
$wgAbuseFilterConditionLimit = 2000; // T132048
$wgGroupPermissions['sysop']['abusefilter-modify-restricted'] = 
true;
break;
-   case 'cswiki':
-   $wgAbuseFilterProfile = true; // T149899
-   break;
case 'cswiktionary':
$wgAbuseFilterNotificationsPrivate = true;
break;

-- 
To view, visit https://gerrit.wikimedia.org/r/325323
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I16534abcdc72110927ff35a596c4bd63acb01849
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Urbanecm 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Always request edit token before Wikidata description edits

2016-12-05 Thread BearND (Code Review)
BearND has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325324

Change subject: Always request edit token before Wikidata description edits
..

Always request edit token before Wikidata description edits

Note that the edit token is fetched from Wikidata. This is a
step towards making description edits using logged in credentials.
We still want to request a token for the non-logged in case
since the hard-coded token will go away soon. See T40417.

Bug: T150705
Bug: T146641
Change-Id: I91599b410dfbc6136838e9301290866ee733aaa8
---
M app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
M app/src/main/java/org/wikipedia/descriptions/DescriptionEditFragment.java
M 
app/src/main/java/org/wikipedia/descriptions/centralauth/CentralAuthTokenClient.java
M app/src/main/java/org/wikipedia/edit/token/EditTokenClient.java
M app/src/test/java/org/wikipedia/descriptions/DescriptionEditClientTest.java
5 files changed, 73 insertions(+), 30 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia 
refs/changes/24/325324/1

diff --git 
a/app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java 
b/app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
index 268e81b..5a437e7 100644
--- a/app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
+++ b/app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
@@ -21,8 +21,8 @@
  * Data Client to submit a new or updated description to wikidata.org.
  */
 class DescriptionEditClient {
-private static final String ANONYMOUS_TOKEN = "+\\";
-private static final WikiSite WIKI_DATA_SITE = new 
WikiSite("www.wikidata.org", "");
+static final String ANONYMOUS_TOKEN = "+\\";
+static final WikiSite WIKI_DATA_SITE = new WikiSite("www.wikidata.org", 
"");
 
 @NonNull private final MwCachedService cachedService
 = new MwCachedService<>(Service.class);
@@ -36,29 +36,32 @@
 /**
  * Submit a new value for the Wikidata description associated with the 
given Wikipedia page.
  *
- * @param pageTitle   specifies the Wikipedia page the Wikidata item is 
linked to
- * @param description the new value for the Wikidata description
- * @param cb  called when this is done successfully or failed
+ * @param pageTitlespecifies the Wikipedia page the Wikidata item 
is linked to
+ * @param description  the new value for the Wikidata description
+ * @param editTokena token from Wikidata
+ * @param cb   called when this is done successfully or failed
  * @return Call object which can be used to cancel the request
  */
 public Call request(@NonNull PageTitle pageTitle,
  @NonNull String description,
+ @NonNull String editToken,
  @NonNull Callback cb) {
 return request(cachedService.service(WIKI_DATA_SITE), pageTitle, 
description,
-pageTitle.getWikiSite().languageCode(), User.isLoggedIn(), cb);
+pageTitle.getWikiSite().languageCode(), editToken, 
User.isLoggedIn(), cb);
 }
 
 @SuppressWarnings("WeakerAccess") @VisibleForTesting
 Call request(@NonNull Service service,
-  @NonNull final PageTitle pageTitle,
-  @NonNull final String description,
-  @NonNull final String languageCode,
-  final boolean loggedIn,
+  @NonNull PageTitle pageTitle,
+  @NonNull String description,
+  @NonNull String languageCode,
+  @NonNull String editToken,
+  boolean loggedIn,
   @NonNull final Callback cb) {
 
 Call call = service.edit(languageCode, languageCode + 
"wiki",
-pageTitle.getPrefixedText(), description, ANONYMOUS_TOKEN, 
null,
-/* TODO: loggedIn ? "user" : */ null);
+pageTitle.getPrefixedText(), description, editToken,
+/* loggedIn ? "user" : */ null);
 call.enqueue(new retrofit2.Callback() {
 @Override
 public void onResponse(Call call,
@@ -111,7 +114,6 @@
@NonNull @Field("title") String title,
@NonNull @Field("value") String 
newDescription,
@NonNull @Field("token") String token,
-   @Nullable @Field("centralauthtoken") String 
centralAuthToken,
@Nullable @Field("assert") String user
 );
 }
diff --git 

[MediaWiki-commits] [Gerrit] pywikibot/i18n[master]: Revert "Localisation updates from https://translatewiki.net."

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Revert "Localisation updates from https://translatewiki.net.;
..


Revert "Localisation updates from https://translatewiki.net.;

This reverts commit 02dfc2fd02e4d1372e1a48a83ab96187b62ec6e5.

Bug: T152264
Change-Id: I2d426a59bce71059f328367f7e392a70012cd173
---
D core_stable
1 file changed, 0 insertions(+), 1 deletion(-)

Approvals:
  Dalba: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/core_stable b/core_stable
deleted file mode 16
index 5811bf0..000
--- a/core_stable
+++ /dev/null
@@ -1 +0,0 @@
-Subproject commit 5811bf089975a624a5c35b3f786738fa7014ee45

-- 
To view, visit https://gerrit.wikimedia.org/r/325340
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I2d426a59bce71059f328367f7e392a70012cd173
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/i18n
Gerrit-Branch: master
Gerrit-Owner: Dalba 
Gerrit-Reviewer: Dalba 
Gerrit-Reviewer: Merlijn van Deen 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...parsoid[master]: WIP: T151277: Quick first pass to support [[Media:Foo.bar|..]]

2016-12-05 Thread Subramanya Sastry (Code Review)
Subramanya Sastry has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325341

Change subject: WIP: T151277: Quick first pass to support [[Media:Foo.bar|..]]
..

WIP: T151277: Quick first pass to support [[Media:Foo.bar|..]]

* TODO: Verify for sanity, code duplication
* Fix wt2wt
* Update tests

Change-Id: I656de2fc7882cd53f25478d1698f40bb05bb54fd
---
M lib/html2wt/LinkHandler.js
M lib/wt2html/tt/LinkHandler.js
M tests/parserTests-blacklist.js
3 files changed, 113 insertions(+), 24 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid 
refs/changes/41/325341/1

diff --git a/lib/html2wt/LinkHandler.js b/lib/html2wt/LinkHandler.js
index 7ad924e..8cca5a4 100644
--- a/lib/html2wt/LinkHandler.js
+++ b/lib/html2wt/LinkHandler.js
@@ -95,7 +95,7 @@
// Parsoid only emits and recognizes ExtLink, WikiLink, and 
PageProp rel values.
// Everything else defaults to ExtLink during serialization 
(unless it is
// serializable to a wikilink)
-   var typeMatch = 
rel.match(/\b(mw:(?:WikiLink|ExtLink|PageProp)[^\s]*)\b/);
+   var typeMatch = 
rel.match(/\b(mw:(?:WikiLink|ExtLink|Media|PageProp)[^\s]*)\b/);
if (typeMatch) {
rtData.type = typeMatch[1];
// Strip link subtype info
@@ -648,7 +648,7 @@
}
if (linkType !== null && linkData.target.value !== null) {
// We have a type and target info
-   if (/^mw:WikiLink$/.test(linkType) ||
+   if (/^mw:WikiLink|mw:Media$/.test(linkType) ||

Util.solTransparentLinkRegexp.test(linkType)) {
// [[..]] links: normal, category, redirect, or 
lang links
// (except images)
diff --git a/lib/wt2html/tt/LinkHandler.js b/lib/wt2html/tt/LinkHandler.js
index d5ce28c..1bcfbe7 100644
--- a/lib/wt2html/tt/LinkHandler.js
+++ b/lib/wt2html/tt/LinkHandler.js
@@ -280,6 +280,8 @@
if (title.getNamespace().isFile()) {
// Render as a file.
return this.renderFile.bind(this);
+   } else if (title.getNamespace().isMedia()) {
+   return this.renderMedia.bind(this);
} else if (title.getNamespace().isCategory()) {
// Render as a category membership.
return this.renderCategory.bind(this);
@@ -1511,6 +1513,81 @@
).nodify(this.handleImageInfo.bind(this, cb, token, title, opts, 
optSources));
 };
 
+WikiLinkHandler.prototype.linkToMedia = function(cb, token, title,  err, data) 
{
+   var image, info;
+   var rdfaType;
+   var dataMW = token.getAttribute("data-mw");
+   var dataMWObj = null;
+
+   if (!err && data) {
+   if (data.batchResponse !== undefined) {
+   info = data.batchResponse;
+   } else {
+   var ns = data.imgns;
+   image = data.pages[ns + ':' + title.getKey()];
+   if (image && image.imageinfo && image.imageinfo[0]) {
+   info = image.imageinfo[0];
+   } else {
+   info = false;
+   }
+   }
+   }
+
+   if (!info) {
+   // Use sane defaults.
+   info = {
+   url: './Special:FilePath/' + (title ? 
Util.sanitizeTitleURI(title.getKey()) : ''),
+   };
+
+   // Add mw:Error to the RDFa type.
+   // Prepend since rdfaType is updated with / further 
down.
+   rdfaType = "mw:Error " + rdfaType;
+
+   // Add error info to data-mw
+   dataMWObj = dataMW ? JSON.parse(dataMW) : {};
+   var errs = dataMWObj.errors;
+   if (!errs) {
+   errs = [];
+   dataMWObj.errors = errs;
+   }
+
+   // Set appropriate error info
+   if (title && (err || !data)) {
+   errs.push({"key": "api-error", "message": err || "Empty 
API info"});
+   } else {
+   errs.push({"key": "missing-image", "message": "This 
image does not exist." });
+   }
+   }
+
+   // Create the  tag with right attributes
+   var link = new TagTk('a', [], Util.clone(token.dataAttribs));
+   link.addAttribute('href', getPath(info));
+   link.addAttribute('rel', 'mw:Media');
+   if (rdfaType) {
+   link.addAttribute("typeof", rdfaType);
+   }
+   var type = token.getAttribute("typeof");
+   if (type) {
+   

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Copy CentralAuth tokens for www.wikidata.org requests

2016-12-05 Thread BearND (Code Review)
BearND has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325326

Change subject: Copy CentralAuth tokens for www.wikidata.org requests
..

Copy CentralAuth tokens for www.wikidata.org requests

Copy CentralAuth tokens for www.wikidata.org requests from wikipedia.org
if the user is logged in. There are tokens that start with "centralauth_".

Examples:
* centralauth_Token
* centralauth_User
* centralauth_Session

Gergo mentioned that this would create the local session on the fly.
This would allow us to skip CentralAuthClient implementation we had added 
earlier
and reduce the number of requests per description edit.

Bug: T150705
Change-Id: Ic3e05370d9bb028bac80446acf8b184c49b479a7
(cherry picked from commit c5400639bb916e44b50b32e66113464db2bfa821)
---
M app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java
M app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
2 files changed, 20 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia 
refs/changes/26/325326/1

diff --git 
a/app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java 
b/app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java
index bc314b9..31da327 100644
--- 
a/app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java
+++ 
b/app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java
@@ -3,6 +3,7 @@
 import android.support.annotation.NonNull;
 import android.support.annotation.Nullable;
 
+import org.wikipedia.login.User;
 import org.wikipedia.settings.Prefs;
 import org.wikipedia.util.StringUtil;
 
@@ -20,6 +21,7 @@
 
 public final class SharedPreferenceCookieManager extends CookieManager {
 private static final String DELIMITER = ";";
+private static final String CENTRALAUTH_PREFIX = "centralauth_";
 private final Map> cookieJar = new HashMap<>();
 
 private static SharedPreferenceCookieManager INSTANCE;
@@ -52,6 +54,13 @@
 String domain = uri.getAuthority();
 
 for (String domainSpec: cookieJar.keySet()) {
+// For sites outside the wikipedia.org domain, like wikidata.org,
+// transfer the centralauth cookies from wikipedia.org, too, if 
the user is logged in
+if (User.isLoggedIn()
+&& domain.equals("www.wikidata.org") && 
domainSpec.equals("wikipedia.org")) {
+cookiesList.addAll(makeCookieList(cookieJar.get(domainSpec), 
CENTRALAUTH_PREFIX));
+}
+
 // Very weak domain matching.
 // Primarily to make sure that cookies set for .wikipedia.org are 
sent for
 // en.wikipedia.org and *.wikimedia.org
@@ -161,15 +170,22 @@
 return cookiesMap;
 }
 
-private List makeCookieList(Map cookies) {
+private List makeCookieList(@NonNull Map cookies) {
+return makeCookieList(cookies, null);
+}
+
+private List makeCookieList(@NonNull Map cookies,
+@Nullable String prefixFilter) {
 List cookiesList = new ArrayList<>();
 for (Map.Entry entry: cookies.entrySet()) {
-cookiesList.add(entry.getKey() + "=" + entry.getValue());
+if (prefixFilter == null || 
entry.getKey().startsWith(prefixFilter)) {
+cookiesList.add(entry.getKey() + "=" + entry.getValue());
+}
 }
 return cookiesList;
 }
 
-private String makeString(Iterable list) {
+private String makeString(@NonNull Iterable list) {
 return StringUtil.listToDelimitedString(list, DELIMITER);
 }
 }
diff --git 
a/app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java 
b/app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
index 5a437e7..a5290be 100644
--- a/app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
+++ b/app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
@@ -61,7 +61,7 @@
 
 Call call = service.edit(languageCode, languageCode + 
"wiki",
 pageTitle.getPrefixedText(), description, editToken,
-/* loggedIn ? "user" : */ null);
+loggedIn ? "user" : null);
 call.enqueue(new retrofit2.Callback() {
 @Override
 public void onResponse(Call call,

-- 
To view, visit https://gerrit.wikimedia.org/r/325326
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic3e05370d9bb028bac80446acf8b184c49b479a7
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: BearND 

___
MediaWiki-commits mailing list

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Hygiene: move SharedPreferenceCookieManager to dataclient pa...

2016-12-05 Thread BearND (Code Review)
BearND has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325325

Change subject: Hygiene: move SharedPreferenceCookieManager to dataclient 
package
..

Hygiene: move SharedPreferenceCookieManager to dataclient package

This really belongs to dataclient.

Change-Id: Ia3d7f8ff207b97c337ccae4a327cd37b87d14509
(cherry picked from commit 280a735b583a4e80c41c07f64ddfcfc966a5e2bb)
---
M app/src/main/java/org/wikipedia/WikipediaApp.java
M app/src/main/java/org/wikipedia/dataclient/OkHttpConnectionFactory.java
R app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java
M app/src/main/java/org/wikipedia/settings/Prefs.java
4 files changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia 
refs/changes/25/325325/1

diff --git a/app/src/main/java/org/wikipedia/WikipediaApp.java 
b/app/src/main/java/org/wikipedia/WikipediaApp.java
index db62d90..3d6dbd0 100644
--- a/app/src/main/java/org/wikipedia/WikipediaApp.java
+++ b/app/src/main/java/org/wikipedia/WikipediaApp.java
@@ -32,6 +32,7 @@
 import org.wikipedia.database.contract.AppContentProviderContract;
 import org.wikipedia.database.contract.ReadingListPageContract;
 import org.wikipedia.dataclient.OkHttpConnectionFactory;
+import org.wikipedia.dataclient.SharedPreferenceCookieManager;
 import org.wikipedia.dataclient.WikiSite;
 import org.wikipedia.edit.summaries.EditSummary;
 import org.wikipedia.edit.token.EditTokenStorage;
diff --git 
a/app/src/main/java/org/wikipedia/dataclient/OkHttpConnectionFactory.java 
b/app/src/main/java/org/wikipedia/dataclient/OkHttpConnectionFactory.java
index fbe90b0..51febf2 100644
--- a/app/src/main/java/org/wikipedia/dataclient/OkHttpConnectionFactory.java
+++ b/app/src/main/java/org/wikipedia/dataclient/OkHttpConnectionFactory.java
@@ -4,7 +4,6 @@
 
 import com.github.kevinsawicki.http.HttpRequest;
 
-import org.wikipedia.SharedPreferenceCookieManager;
 import org.wikipedia.WikipediaApp;
 import org.wikipedia.settings.Prefs;
 
diff --git a/app/src/main/java/org/wikipedia/SharedPreferenceCookieManager.java 
b/app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java
similarity index 99%
rename from app/src/main/java/org/wikipedia/SharedPreferenceCookieManager.java
rename to 
app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java
index 5303e27..bc314b9 100644
--- a/app/src/main/java/org/wikipedia/SharedPreferenceCookieManager.java
+++ 
b/app/src/main/java/org/wikipedia/dataclient/SharedPreferenceCookieManager.java
@@ -1,4 +1,4 @@
-package org.wikipedia;
+package org.wikipedia.dataclient;
 
 import android.support.annotation.NonNull;
 import android.support.annotation.Nullable;
diff --git a/app/src/main/java/org/wikipedia/settings/Prefs.java 
b/app/src/main/java/org/wikipedia/settings/Prefs.java
index 308d5d0..43f7aac 100644
--- a/app/src/main/java/org/wikipedia/settings/Prefs.java
+++ b/app/src/main/java/org/wikipedia/settings/Prefs.java
@@ -6,7 +6,7 @@
 
 import org.wikipedia.Constants;
 import org.wikipedia.R;
-import org.wikipedia.SharedPreferenceCookieManager;
+import org.wikipedia.dataclient.SharedPreferenceCookieManager;
 import org.wikipedia.WikipediaApp;
 import org.wikipedia.analytics.SessionData;
 import org.wikipedia.analytics.SessionFunnel;

-- 
To view, visit https://gerrit.wikimedia.org/r/325325
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia3d7f8ff207b97c337ccae4a327cd37b87d14509
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: BearND 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...trending-edits[master]: Record bytes change

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Record bytes change
..


Record bytes change

Note the bytes changed by the first revision are not available
and since we throw away bot edits we can't tell the total amount of
bytes changed by all users.

Thus, this number is not as accurate as it could be but accurate enough.

Bug: T145554
Change-Id: I04ba6e57e8e02917ea48388346524ed4a08498bd
---
M lib/processor.js
M test/features/lib/processor.js
2 files changed, 8 insertions(+), 4 deletions(-)

Approvals:
  Pmiazga: Looks good to me, but someone else must approve
  Mobrovac: Looks good to me, but someone else must approve
  Jhobs: Looks good to me, but someone else must approve
  Jhernandez: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/lib/processor.js b/lib/processor.js
index 383e561..8c7edab 100644
--- a/lib/processor.js
+++ b/lib/processor.js
@@ -96,6 +96,7 @@
 edits: 1,
 from: ts,
 updated: ts,
+rev_len: edit.rev_len,
 anonEdits: 0,
 contributors: {
 total: 0,
@@ -124,6 +125,7 @@
 if (contributors.names[username].edits > 
contributors.names[contributors.main].edits) {
 contributors.main = username;
 }
+pages[id].bytes = edit.rev_len - pages[id].rev_len;
 pages[id].bias = contributors.names[contributors.main].edits / 
pages[id].edits;
 }
 }
diff --git a/test/features/lib/processor.js b/test/features/lib/processor.js
index 5e7f8a3..c471831 100644
--- a/test/features/lib/processor.js
+++ b/test/features/lib/processor.js
@@ -37,7 +37,7 @@
   page_id: 3
 };
 
-function edit( id, username, ts, ns, isBot ) {
+function edit( id, username, ts, ns, isBot, data ) {
 var performer = {
 user_groups: ["*"],
 user_is_bot: isBot,
@@ -47,7 +47,7 @@
 if ( username.indexOf( '.' ) === -1 ) {
   performer.user_id = 1;
 }
-return {
+return Object.assign( {
 comment: '',
 meta: { topic: "mediawiki.revision-create" },
 page_id: id,
@@ -59,14 +59,14 @@
 rev_parent_id: 4,
 rev_minor_edit: false,
 rev_timestamp: ts
-};
+}, data );
 }
 
 describe('processor - series of events', function() {
 processor.reset();
 processor.process( edit( 1, 'Jon', '2016-11-15T18:00:55+00:00' ) );
 processor.process( edit( 1, 'Corey', '2016-11-15T18:02:55+00:00' ) );
-processor.process( edit( 1, 'Bernd', '2016-11-15T18:03:55+00:00' ) );
+processor.process( edit( 1, 'Bernd', '2016-11-15T18:03:55+00:00', 0, 
false, { rev_len: 600 } ) );
 processor.process( edit( 2, 'Talker', '2016-11-15T18:03:55+00:00', 1 ) );
 processor.process( edit( 1, 'Bot', '2016-11-15T18:03:55+00:00', 0, true ) 
);
 
@@ -75,6 +75,8 @@
 assert.ok( pages.length === 1, 'Pages with same name are combined into 
single page' );
 assert.ok( pages[0].edits === 3, 'Edits are counted for all non-bot 
edits' );
 assert.ok( pages[0].title === 'Foo', 'Title is present' );
+assert.ok( pages[0].bytes === 400,
+'Bytes are calculated based on the rev_len of the first edit and 
last' );
 assert.ok( pages[0].updated.toISOString() === 
'2016-11-15T18:03:55.000Z',
 'Updated is timestamp of last edit' );
 assert.ok( pages[0].from.toISOString() === '2016-11-15T18:00:55.000Z',

-- 
To view, visit https://gerrit.wikimedia.org/r/323324
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I04ba6e57e8e02917ea48388346524ed4a08498bd
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/services/trending-edits
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Jhernandez 
Gerrit-Reviewer: Jhobs 
Gerrit-Reviewer: Mobrovac 
Gerrit-Reviewer: Pmiazga 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageAssessments[master]: Add new special page for searching assessments

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add new special page for searching assessments
..


Add new special page for searching assessments

This adds Special:PageAssessments with a basic search form
and results table. The special page can also be transcluded,
in which case the search form isn't shown (all search and sort
parameters must be provided in the transclusion).

Bug: T120407
Change-Id: I6ee898059ffc62bb5f2788ad83a49b650cdb1335
---
M extension.json
M i18n/en.json
M i18n/qqq.json
A src/NamespaceSelect.php
A src/Pager.php
A src/SpecialPage.php
6 files changed, 319 insertions(+), 3 deletions(-)

Approvals:
  Kaldari: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/extension.json b/extension.json
index 49a9529..bd8ccd7 100644
--- a/extension.json
+++ b/extension.json
@@ -19,7 +19,10 @@
"PageAssessmentsHooks": "PageAssessments.hooks.php",
"PageAssessmentsBody": "PageAssessmentsBody.php",
"ApiQueryPageAssessments": "api/ApiQueryPageAssessments.php",
-   "ApiQueryProjectPages": "api/ApiQueryProjectPages.php"
+   "ApiQueryProjectPages": "api/ApiQueryProjectPages.php",
+   "PageAssessments\\SpecialPage": "src/SpecialPage.php",
+   "PageAssessments\\Pager": "src/Pager.php",
+   "PageAssessments\\NamespaceSelect": "src/NamespaceSelect.php"
},
"ExtensionMessagesFiles": {
"PageAssessmentsMagic": "PageAssessments.i18n.magic.php"
@@ -47,6 +50,9 @@
"localBasePath": "",
"remoteExtPath": "examples/PageAssessments"
},
+   "SpecialPages": {
+   "PageAssessments": "PageAssessments\\SpecialPage"
+   },
"config": {
"PageAssessmentsOnTalkPages": true
},
diff --git a/i18n/en.json b/i18n/en.json
index f5a0313..676a955 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -16,5 +16,14 @@
"apihelp-query+projectpages-param-limit": "The maximum number of pages 
to return.",
"apihelp-query+projectpages-example-simple-1": "Get first 10 pages 
associated with any WikiProject.",
"apihelp-query+projectpages-example-simple-2": "Get first 10 pages 
associated with WikiProject Medicine, including assessment data.",
-   "apihelp-query+projectpages-example-generator": "Get page info for 
first 10 pages associated with WikiProject Textile Arts."
+   "apihelp-query+projectpages-example-generator": "Get page info for 
first 10 pages associated with WikiProject Textile Arts.",
+   "pageassessments-special": "Page assessments",
+   "pageassessments-project": "Project",
+   "pageassessments-page-namespace": "Page namespace",
+   "pageassessments-page-title": "Page title",
+   "pageassessments-search": "Search",
+   "pageassessments-importance": "Importance",
+   "pageassessments-class": "Class",
+   "pageassessments-timestamp": "Timestamp",
+   "pageassessments-total-results": "Total results: $1"
 }
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 6caf8ec..75e10db 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -16,5 +16,14 @@
"apihelp-query+projectpages-param-limit": 
"{{doc-apihelp-param|query+projectpages|limit}}",
"apihelp-query+projectpages-example-simple-1": 
"{{doc-apihelp-example|query+projectpages}}",
"apihelp-query+projectpages-example-simple-2": 
"{{doc-apihelp-example|query+projectpages}}",
-   "apihelp-query+projectpages-example-generator": 
"{{doc-apihelp-example|query+projectpages}}"
+   "apihelp-query+projectpages-example-generator": 
"{{doc-apihelp-example|query+projectpages}}",
+   "pageassessments-special": "Name of the Special page",
+   "pageassessments-project": "Form label for the WikiProject search field 
and the results table column header",
+   "pageassessments-page-namespace": "Form label for the page namespace 
dropdown select field",
+   "pageassessments-page-title": "Form label for the page title search 
field and the results table column header",
+   "pageassessments-search": "Search form submit button label",
+   "pageassessments-importance": "Label for the results table column 
header",
+   "pageassessments-class": "Label for the results table column header",
+   "pageassessments-timestamp": "Label for the results table column 
header",
+   "pageassessments-total-results": "Summary shown above the search 
results, with total number found"
 }
diff --git a/src/NamespaceSelect.php b/src/NamespaceSelect.php
new file mode 100644
index 000..49a09b4
--- /dev/null
+++ b/src/NamespaceSelect.php
@@ -0,0 +1,37 @@
+ $value,
+   'name' => $this->mName,
+   'id' => $this->mID,
+   'includeAllValue' => $this->mAllValue,
+   'exclude' => $excludedNsIds,
+  

[MediaWiki-commits] [Gerrit] mediawiki...Flow[master]: Get rid of $wgFlowGroupPermissions hack

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Get rid of $wgFlowGroupPermissions hack
..


Get rid of $wgFlowGroupPermissions hack

Just read the default permissions out of extension.json for tests.

Change-Id: I59f8ebc8bcac204092bfda6c526fec7b62bcea6d
---
M Hooks.php
M tests/phpunit/Collection/RevisionCollectionPermissionsTest.php
M tests/phpunit/FlowTestCase.php
M tests/phpunit/PermissionsTest.php
4 files changed, 13 insertions(+), 30 deletions(-)

Approvals:
  Catrope: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/Hooks.php b/Hooks.php
index ac977d4..5058e65 100644
--- a/Hooks.php
+++ b/Hooks.php
@@ -32,22 +32,6 @@
 
require_once __DIR__ . '/defines.php';
 
-   // User permissions
-   // Added to $wgFlowGroupPermissions instead of 
$wgGroupPermissions immediately,
-   // to easily fetch Flow-specific permissions in 
tests/PermissionsTest.php.
-   // If you wish to make local permission changes, add them to 
$wgGroupPermissions
-   // directly - tests will fail otherwise, since they'll be based 
on a different
-   // permissions config than what's assumed to test.
-   $wgFlowGroupPermissions = array();
-   $wgFlowGroupPermissions['*']['flow-hide'] = true;
-   $wgFlowGroupPermissions['user']['flow-lock'] = true;
-   $wgFlowGroupPermissions['sysop']['flow-lock'] = true;
-   $wgFlowGroupPermissions['sysop']['flow-delete'] = true;
-   $wgFlowGroupPermissions['sysop']['flow-edit-post'] = true;
-   $wgFlowGroupPermissions['oversight']['flow-suppress'] = true;
-   $wgFlowGroupPermissions['flow-bot']['flow-create-board'] = true;
-   $wgGroupPermissions = array_merge_recursive( 
$wgGroupPermissions, $wgFlowGroupPermissions );
-
// Make sure all of these are granted via OAuth in Hooks.php
$wgAvailableRights[] = 'flow-hide';
$wgAvailableRights[] = 'flow-lock';
diff --git a/tests/phpunit/Collection/RevisionCollectionPermissionsTest.php 
b/tests/phpunit/Collection/RevisionCollectionPermissionsTest.php
index 0734d35..073a1a0 100644
--- a/tests/phpunit/Collection/RevisionCollectionPermissionsTest.php
+++ b/tests/phpunit/Collection/RevisionCollectionPermissionsTest.php
@@ -57,13 +57,7 @@
 
// We don't want local config getting in the way of testing 
whether or
// not our permissions implementation works well.
-   // This will load default $wgGroupPermissions + Flow settings, 
so we can
-   // test if permissions work well, regardless of any custom 
config.
-   global $IP, $wgFlowGroupPermissions;
-   $wgGroupPermissions = array();
-   require "$IP/includes/DefaultSettings.php";
-   $wgGroupPermissions = array_merge_recursive( 
$wgGroupPermissions, $wgFlowGroupPermissions );
-   $this->setMwGlobals( 'wgGroupPermissions', $wgGroupPermissions 
);
+   $this->resetPermissions();
 
// When external store is used, data is written to "blobs" 
table, which
// by default doesn't exist - let's just not use 
externalstorage in test
diff --git a/tests/phpunit/FlowTestCase.php b/tests/phpunit/FlowTestCase.php
index 18ae56f..87d4e89 100644
--- a/tests/phpunit/FlowTestCase.php
+++ b/tests/phpunit/FlowTestCase.php
@@ -3,6 +3,7 @@
 namespace Flow\Tests;
 
 use EventRelayerNull;
+use ExtensionRegistry;
 use Flow\Container;
 use Flow\Data\FlowObjectCache;
 use Flow\Model\UUID;
@@ -39,4 +40,14 @@
 
return new FlowObjectCache( $wanCache, Container::get( 
'db.factory' ), $wgFlowCacheTime );
}
+
+   protected function resetPermissions() {
+   $registry = new ExtensionRegistry();
+   $data = $registry->readFromQueue( [ __DIR__ . 
'/../../extension.json' => 1 ] );
+   $perms = $data['globals']['wgGroupPermissions'];
+   unset( $perms[$registry::MERGE_STRATEGY] );
+   $this->stashMwGlobals( [ 'wgGroupPermissions'] );
+   global $wgGroupPermissions;
+   $wgGroupPermissions = wfArrayPlus2d( $perms, 
$wgGroupPermissions );
+   }
 }
diff --git a/tests/phpunit/PermissionsTest.php 
b/tests/phpunit/PermissionsTest.php
index 6d1d410..d9e9b7d 100644
--- a/tests/phpunit/PermissionsTest.php
+++ b/tests/phpunit/PermissionsTest.php
@@ -52,13 +52,7 @@
 
// We don't want local config getting in the way of testing 
whether or
// not our permissions implementation works well.
-   // This will load default $wgGroupPermissions + Flow settings, 
so we can
-   // test if permissions work well, regardless of any custom 
config.
-   global $IP, $wgFlowGroupPermissions;
-   

[MediaWiki-commits] [Gerrit] mediawiki...Flow[master]: Remove duplicate $wgAvailableRights additions

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Remove duplicate $wgAvailableRights additions
..


Remove duplicate $wgAvailableRights additions

These are already set in extension.json, there's no need to also
duplicate them in the callback.

Change-Id: Id07aae286b0545f8e971551a4cb5352d7e3a6cab
---
M Hooks.php
1 file changed, 0 insertions(+), 8 deletions(-)

Approvals:
  Catrope: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/Hooks.php b/Hooks.php
index 5058e65..0c22690 100644
--- a/Hooks.php
+++ b/Hooks.php
@@ -32,14 +32,6 @@
 
require_once __DIR__ . '/defines.php';
 
-   // Make sure all of these are granted via OAuth in Hooks.php
-   $wgAvailableRights[] = 'flow-hide';
-   $wgAvailableRights[] = 'flow-lock';
-   $wgAvailableRights[] = 'flow-delete';
-   $wgAvailableRights[] = 'flow-suppress';
-   $wgAvailableRights[] = 'flow-edit-post';
-   $wgAvailableRights[] = 'flow-create-board';
-
// Action details config file
require __DIR__ . '/FlowActions.php';
 

-- 
To view, visit https://gerrit.wikimedia.org/r/325157
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id07aae286b0545f8e971551a4cb5352d7e3a6cab
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] pywikibot/i18n[master]: Revert "Localisation updates from https://translatewiki.net."

2016-12-05 Thread Dalba (Code Review)
Dalba has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325340

Change subject: Revert "Localisation updates from https://translatewiki.net.;
..

Revert "Localisation updates from https://translatewiki.net.;

This reverts commit 02dfc2fd02e4d1372e1a48a83ab96187b62ec6e5.

Bug: T152264
Change-Id: I2d426a59bce71059f328367f7e392a70012cd173
---
D core_stable
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/i18n 
refs/changes/40/325340/1

diff --git a/core_stable b/core_stable
deleted file mode 16
index 5811bf0..000
--- a/core_stable
+++ /dev/null
@@ -1 +0,0 @@
-Subproject commit 5811bf089975a624a5c35b3f786738fa7014ee45

-- 
To view, visit https://gerrit.wikimedia.org/r/325340
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2d426a59bce71059f328367f7e392a70012cd173
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/i18n
Gerrit-Branch: master
Gerrit-Owner: Dalba 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] translatewiki[master]: Support $1 as insertables in the Intuition Project

2016-12-05 Thread MtDu (Code Review)
MtDu has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325343

Change subject: Support $1 as insertables in the Intuition Project
..

Support $1 as insertables in the Intuition Project

Bug: T150242
Change-Id: I058da157d016054aa3c593aafccf193a9e70690a
---
M groups/Intuition/IntuitionAgg.yaml
A groups/Intuition/IntuitionInsertablesSuggester.php
M groups/Intuition/dcatap.yaml
M groups/Intuition/heritage.yaml
M groups/Intuition/orphantalk.yaml
M groups/Intuition/raun.yaml
M groups/Intuition/refill.yaml
7 files changed, 63 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/translatewiki 
refs/changes/43/325343/1

diff --git a/groups/Intuition/IntuitionAgg.yaml 
b/groups/Intuition/IntuitionAgg.yaml
index 7fee2f0..67e0cb4 100644
--- a/groups/Intuition/IntuitionAgg.yaml
+++ b/groups/Intuition/IntuitionAgg.yaml
@@ -10,3 +10,9 @@
 GROUPS:
   - tsint-*
   - int-*
+
+INSERTABLES:
+  class: IntuitionInsertablesSuggester
+
+AUTOLOAD:
+  CopyPatrolInsertablesSuggester: IntuitionInsertablesSuggester.php
diff --git a/groups/Intuition/IntuitionInsertablesSuggester.php 
b/groups/Intuition/IntuitionInsertablesSuggester.php
new file mode 100644
index 000..52c4ce1
--- /dev/null
+++ b/groups/Intuition/IntuitionInsertablesSuggester.php
@@ -0,0 +1,27 @@
+https://gerrit.wikimedia.org/r/325343
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I058da157d016054aa3c593aafccf193a9e70690a
Gerrit-PatchSet: 1
Gerrit-Project: translatewiki
Gerrit-Branch: master
Gerrit-Owner: MtDu 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki/core[wmf/1.29.0-wmf.4]: Add DB ConnectionManagers

2016-12-05 Thread Paladox (Code Review)
Paladox has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325350

Change subject: Add DB ConnectionManagers
..

Add DB ConnectionManagers

This moves and refactors the ConsistentReadConnectionManager
from Wikibase into the core rdbms lib.
The refactoring also creates a generic ConnectionManager.

This relates to Iff20a22f9f2bc7ceefd6defc0ed9a494a6fe62c0
which introduced a DB factory / connection manager in
an extension revealing the need for this in multiple places.

Change-Id: I0c58e15aed5bed88323d18cb95e5008f8d3381c5
(cherry picked from commit c3c3cf96968e49ef5becfc079cea02c970faaf5a)
---
M autoload.php
A includes/libs/rdbms/connectionmanager/ConnectionManager.php
A includes/libs/rdbms/connectionmanager/SessionConsistentConnectionManager.php
A tests/phpunit/includes/libs/rdbms/connectionmanager/ConnectionManagerTest.php
A 
tests/phpunit/includes/libs/rdbms/connectionmanager/ConsistentReadConnectionManagerTest.php
5 files changed, 603 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/50/325350/1

diff --git a/autoload.php b/autoload.php
index f0bbe92..0d6407b 100644
--- a/autoload.php
+++ b/autoload.php
@@ -1570,6 +1570,8 @@
'WikiRevision' => __DIR__ . '/includes/import/WikiRevision.php',
'WikiStatsOutput' => __DIR__ . '/maintenance/language/StatOutputs.php',
'WikiTextStructure' => __DIR__ . 
'/includes/content/WikiTextStructure.php',
+   'Wikimedia\\Rdbms\\ConnectionManager' => __DIR__ . 
'/includes/libs/rdbms/connectionmanager/ConnectionManager.php',
+   'Wikimedia\\Rdbms\\SessionConsistentConnectionManager' => __DIR__ . 
'/includes/libs/rdbms/connectionmanager/SessionConsistentConnectionManager.php',
'WikitextContent' => __DIR__ . '/includes/content/WikitextContent.php',
'WikitextContentHandler' => __DIR__ . 
'/includes/content/WikitextContentHandler.php',
'WinCacheBagOStuff' => __DIR__ . 
'/includes/libs/objectcache/WinCacheBagOStuff.php',
diff --git a/includes/libs/rdbms/connectionmanager/ConnectionManager.php 
b/includes/libs/rdbms/connectionmanager/ConnectionManager.php
new file mode 100644
index 000..6d5d8ab
--- /dev/null
+++ b/includes/libs/rdbms/connectionmanager/ConnectionManager.php
@@ -0,0 +1,180 @@
+loadBalancer = $loadBalancer;
+   $this->domain = $domain;
+   $this->groups = $groups;
+   }
+
+   /**
+* @param int $i
+* @param string[]|null $groups
+*
+* @return Database
+*/
+   private function getConnection( $i, array $groups = null ) {
+   $groups = $groups === null ? $this->groups : $groups;
+   return $this->loadBalancer->getConnection( $i, $groups, 
$this->domain );
+   }
+
+   /**
+* @param int $i
+* @param string[]|null $groups
+*
+* @return DBConnRef
+*/
+   private function getConnectionRef( $i, array $groups = null ) {
+   $groups = $groups === null ? $this->groups : $groups;
+   return $this->loadBalancer->getConnectionRef( $i, $groups, 
$this->domain );
+   }
+
+   /**
+* Returns a connection to the master DB, for updating. The connection 
should later be released
+* by calling releaseConnection().
+*
+* @since 1.29
+*
+* @return Database
+*/
+   public function getWriteConnection() {
+   return $this->getConnection( DB_MASTER );
+   }
+
+   /**
+* Returns a database connection for reading. The connection should 
later be released by
+* calling releaseConnection().
+*
+* @since 1.29
+*
+* @param string[]|null $groups
+*
+* @return Database
+*/
+   public function getReadConnection( array $groups = null ) {
+   $groups = $groups === null ? $this->groups : $groups;
+   return $this->getConnection( DB_REPLICA, $groups );
+   }
+
+   /**
+* @since 1.29
+*
+* @param IDatabase $db
+*/
+   public function releaseConnection( IDatabase $db ) {
+   $this->loadBalancer->reuseConnection( $db );
+   }
+
+   /**
+* Returns a connection ref to the master DB, for updating.
+*
+* @since 1.29
+*
+* @return DBConnRef
+*/
+   public function getWriteConnectionRef() {
+   return $this->getConnectionRef( DB_MASTER );
+   }
+
+   /**
+* Returns a database connection ref for reading.
+*
+* @since 1.29
+*
+* @param string[]|null $groups
+*
+* @return DBConnRef
+*/
+   public function getReadConnectionRef( array $groups = null ) {
+   $groups = $groups === null ? $this->groups : $groups;
+   return 

[MediaWiki-commits] [Gerrit] mediawiki...ansible-wikifarm[master]: Updated extensions; Fixed logo issue.

2016-12-05 Thread Cicalese (Code Review)
Cicalese has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325345

Change subject: Updated extensions; Fixed logo issue.
..

Updated extensions; Fixed logo issue.

Change-Id: Ic941cb099b253629442a4384099667d59479c36e
---
M group_vars/all/default_extensions
M roles/install_mediawiki/files/Debug.php
M roles/install_mediawiki/templates/LocalSettings.php.j2
3 files changed, 8 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/tools/ansible-wikifarm 
refs/changes/45/325345/1

diff --git a/group_vars/all/default_extensions 
b/group_vars/all/default_extensions
index fa08d84..d059035 100644
--- a/group_vars/all/default_extensions
+++ b/group_vars/all/default_extensions
@@ -53,6 +53,10 @@
 composer: "mediawiki/semantic-scribunto"
 version: "dev-master"
 
+  - name: "Header Footer"
+composer: "mediawiki/header-footer"
+version: "dev-master"
+
   - name: "WikiEditor"
 url: "{{ MW_GIT_URL_ROOT }}EWED/extension-wikieditor.git"
 enable: global
@@ -169,6 +173,7 @@
 config: |
   $wgAllowDisplayTitle = true;
   $wgRestrictDisplayTitle = false;
+  $wgDisplayTitleHideSubtitle = true;
 
   - name: "VIKI"
 url: "{{ MW_GIT_URL_ROOT }}EVIK/extension-viki.git"
diff --git a/roles/install_mediawiki/files/Debug.php 
b/roles/install_mediawiki/files/Debug.php
index 9772032..e76ad3d 100644
--- a/roles/install_mediawiki/files/Debug.php
+++ b/roles/install_mediawiki/files/Debug.php
@@ -3,5 +3,5 @@
 #error_reporting( -1 );
 #ini_set( 'display_errors', 1 );
 #$wgResourceLoaderDebug = true;
-#$wgShowExceptionDetails = true;
+#$wgShowDBErrorBacktrace = true;
 #$wgDebugLogFile= "/tmp/MediaWikiDebug.log";
diff --git a/roles/install_mediawiki/templates/LocalSettings.php.j2 
b/roles/install_mediawiki/templates/LocalSettings.php.j2
index d45d520..b69fa68 100644
--- a/roles/install_mediawiki/templates/LocalSettings.php.j2
+++ b/roles/install_mediawiki/templates/LocalSettings.php.j2
@@ -37,12 +37,12 @@
 
 ## The relative URL path to the logo.
 if( file_exists( "$INSTANCE_DIR/branding/logo.png" ) ) {
-  $wgLogo = "/$wgSitename/branding/logo.png";
+  $wgLogo = "$wgServer/$wgSitename/branding/logo.png";
 } else {
   $wgLogo = "$wgResourceBasePath/resources/assets/wiki.png";
 }
 if( file_exists( "$INSTANCE_DIR/branding/favicon.ico" ) ) {
-  $wgFavicon = "/$wgSitename/branding/favicon.ico";
+  $wgFavicon = "$wgServer/$wgSitename/branding/favicon.ico";
 }
 
 require_once( __DIR__ . "/WikiFarm/Email.php" );

-- 
To view, visit https://gerrit.wikimedia.org/r/325345
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic941cb099b253629442a4384099667d59479c36e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/tools/ansible-wikifarm
Gerrit-Branch: master
Gerrit-Owner: Cicalese 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Explicitly set labs_keystone_host for labtestservices

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has submitted this change and it was merged.

Change subject: Explicitly set labs_keystone_host for labtestservices
..


Explicitly set labs_keystone_host for labtestservices

Change-Id: I58855c3b7825674a51fefd66f000a5e0410afe95
---
A hieradata/hosts/labtestservices2001.yaml
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Andrew Bogott: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/hieradata/hosts/labtestservices2001.yaml 
b/hieradata/hosts/labtestservices2001.yaml
new file mode 100644
index 000..ca0b81f
--- /dev/null
+++ b/hieradata/hosts/labtestservices2001.yaml
@@ -0,0 +1 @@
+labs_keystone_host: "labtestcontrol2001.wikimedia.org"

-- 
To view, visit https://gerrit.wikimedia.org/r/325422
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I58855c3b7825674a51fefd66f000a5e0410afe95
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 
Gerrit-Reviewer: Andrew Bogott 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Explicitly set labs_keystone_host for labtestservices

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325422

Change subject: Explicitly set labs_keystone_host for labtestservices
..

Explicitly set labs_keystone_host for labtestservices

Change-Id: I58855c3b7825674a51fefd66f000a5e0410afe95
---
A hieradata/hosts/labtestservices2001.yaml
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/22/325422/1

diff --git a/hieradata/hosts/labtestservices2001.yaml 
b/hieradata/hosts/labtestservices2001.yaml
new file mode 100644
index 000..ca0b81f
--- /dev/null
+++ b/hieradata/hosts/labtestservices2001.yaml
@@ -0,0 +1 @@
+labs_keystone_host: "labtestcontrol2001.wikimedia.org"

-- 
To view, visit https://gerrit.wikimedia.org/r/325422
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I58855c3b7825674a51fefd66f000a5e0410afe95
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageForms[master]: Added TODO for "values from concept"

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Added TODO for "values from concept"
..


Added TODO for "values from concept"

Change-Id: I640483184a0e8a8cf59c4f2189192cb7709b96a3
---
M includes/PF_ValuesUtils.php
1 file changed, 4 insertions(+), 0 deletions(-)

Approvals:
  Yaron Koren: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/PF_ValuesUtils.php b/includes/PF_ValuesUtils.php
index c8ac4a2..5d07e3d 100644
--- a/includes/PF_ValuesUtils.php
+++ b/includes/PF_ValuesUtils.php
@@ -252,6 +252,10 @@
// be better to do this filtering in the
// original SMW query, but that doesn't seem
// possible yet.
+   // @TODO - this will miss a lot of results for
+   // concepts with > 1000 pages. Instead, this
+   // code should loop through all the pages,
+   // using "offset".
$lowercasePageName = strtolower( $pageName );
if ( $wgPageFormsAutocompleteOnAllChars ) {
if ( strpos( $lowercasePageName, 
$substring ) >= 0 ) {

-- 
To view, visit https://gerrit.wikimedia.org/r/325375
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I640483184a0e8a8cf59c4f2189192cb7709b96a3
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/PageForms
Gerrit-Branch: master
Gerrit-Owner: Yaron Koren 
Gerrit-Reviewer: Yaron Koren 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] oojs/ui[master]: TextInputWidget/MediaWiki theme: Improve Less code and align...

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: TextInputWidget/MediaWiki theme: Improve Less code and align 
labels
..


TextInputWidget/MediaWiki theme: Improve Less code and align labels

Following-up I1ecbf767a598704c3913d8853a458f0fe526f5d1 to align
labels with new `padding` in MediaWiki theme. Also:
* simplifying selectors by concatenating,
* relying on `left` and `right` only instead of mixing them with
`margin` and `padding`
* introducing new variables instead of fixed values,
* increasing `textarea`'s `line-height` for better readability,
* removing superfluos properties, that were either not applied or
duplicated in theme, or just setting default UA value (`margin: 0`) and
* putting `-enabled` & `-disabled` selectors at the bottom as with
other widgets.

Change-Id: Ib0db2c123366ca443bcaa718d7ee1c4c4759
---
M src/styles/widgets/TextInputWidget.less
M src/themes/mediawiki/common.less
M src/themes/mediawiki/widgets.less
3 files changed, 85 insertions(+), 82 deletions(-)

Approvals:
  Jforrester: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/styles/widgets/TextInputWidget.less 
b/src/styles/widgets/TextInputWidget.less
index 534c0be..76b3556 100644
--- a/src/styles/widgets/TextInputWidget.less
+++ b/src/styles/widgets/TextInputWidget.less
@@ -56,40 +56,17 @@
}
 
&.oo-ui-iconElement > .oo-ui-iconElement-icon,
-   &.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator {
+   &.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator,
+   > .oo-ui-labelElement-label {
display: block;
position: absolute;
top: 0;
+   }
+
+   &.oo-ui-iconElement > .oo-ui-iconElement-icon,
+   &.oo-ui-indicatorElement > .oo-ui-indicatorElement-indicator {
height: 100%;
-
.oo-ui-unselectable();
-   }
-
-   &.oo-ui-widget-enabled {
-   > .oo-ui-iconElement-icon,
-   > .oo-ui-indicatorElement-indicator {
-   cursor: text;
-   }
-
-   &.oo-ui-textInputWidget-type-search {
-   > .oo-ui-indicatorElement-indicator {
-   cursor: pointer;
-   }
-   }
-   }
-
-   &.oo-ui-widget-disabled {
-   input,
-   textarea {
-   .oo-ui-unselectable();
-   }
-   & .oo-ui-labelElement-label {
-   .oo-ui-unselectable();
-   }
-   }
-
-   &.oo-ui-labelElement > .oo-ui-labelElement-label {
-   display: block;
}
 
> .oo-ui-iconElement-icon,
@@ -102,9 +79,26 @@
right: 0;
}
 
-   > .oo-ui-labelElement-label {
-   position: absolute;
-   top: 0;
+   &.oo-ui-widget-enabled {
+   > .oo-ui-iconElement-icon,
+   > .oo-ui-indicatorElement-indicator,
+   > .oo-ui-labelElement-label {
+   cursor: text;
+   }
+
+   &.oo-ui-textInputWidget-type-search {
+   > .oo-ui-indicatorElement-indicator {
+   cursor: pointer;
+   }
+   }
+   }
+
+   &.oo-ui-widget-disabled {
+   input,
+   textarea,
+   & .oo-ui-labelElement-label {
+   .oo-ui-unselectable();
+   }
}
 
.theme-oo-ui-textInputWidget();
diff --git a/src/themes/mediawiki/common.less b/src/themes/mediawiki/common.less
index ec7d6a7..47369de 100644
--- a/src/themes/mediawiki/common.less
+++ b/src/themes/mediawiki/common.less
@@ -60,6 +60,8 @@
 @min-height-toggleswitch: 26px; // equals `16px` @size-toggleswitch-grip-min + 
4px*2 distance top/bottom + 1px*2 border top/bottom
 @max-width-default: 50em;
 @max-width-input: @max-width-default;
+@max-height-icon: 32 / @oo-ui-font-size-browser / @oo-ui-font-size-default; // 
equals `2.5em`≈`32px` at base `font-size: 12.8px`
+@max-height-indicator: @max-height-icon;
 
 @size-default: 32 / @oo-ui-font-size-browser / @oo-ui-font-size-default; // 
equals `2.5em`≈`32px` at base `font-size: 12.8px`
 @size-button-default: @size-default;
@@ -94,6 +96,13 @@
 
 @padding-widget-default: 7 / @oo-ui-font-size-browser / 
@oo-ui-font-size-default; // equals `0.547em`≈`7px` at base `font-size: 12.8px`
 @padding-top-input-text: 8 / @oo-ui-font-size-browser / 
@oo-ui-font-size-default; // equals `0.625em`≈`8px` at base `font-size: 12.8px`
+@padding-top-textarea: 6 / @oo-ui-font-size-browser / 
@oo-ui-font-size-default; // equals `0.625em`≈`8px` at base `font-size: 12.8px`
+@padding-left-widget-icon: @size-icon + ( 10 / @oo-ui-font-size-browser / 
@oo-ui-font-size-default ); // equals `2.65625em`≈`34px` at base `font-size: 
12.8px`
+@left-icon: 6 

[MediaWiki-commits] [Gerrit] oojs/ui[master]: MediaWiki theme: Address sub-pixel rendering issues of Radio...

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: MediaWiki theme: Address sub-pixel rendering issues of 
RadioInputWidgets
..


MediaWiki theme: Address sub-pixel rendering issues of RadioInputWidgets

Replace fixed `em` value with computed one based on OOjs UI's
root default font-size.

Bug: T148941
Change-Id: I8e073e0a21c8e0f55724089323e76a54d8246c9d
---
M src/themes/mediawiki/common.less
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Jforrester: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/themes/mediawiki/common.less b/src/themes/mediawiki/common.less
index 3553a94..60f14ca 100644
--- a/src/themes/mediawiki/common.less
+++ b/src/themes/mediawiki/common.less
@@ -124,7 +124,7 @@
 // Binary Input Widgets (CheckboxInput, RadioInput, ToggleSwitch)
 @background-color-input-binary-active: @color-progressive-active;
 @background-color-input-binary-on: @color-progressive;
-@size-input-binary: 1.6em;
+@size-input-binary: 20 / @oo-ui-font-size-browser / @oo-ui-font-size-default; 
// equals `1.5625em`≈`20px` at base `font-size: 12.8px`
 @border-input-binary: @border-width-default solid @border-color-input-binary;
 @border-color-input-binary: @border-color-default-active;
 @border-color-input-binary-active: @color-progressive-active;

-- 
To view, visit https://gerrit.wikimedia.org/r/324848
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I8e073e0a21c8e0f55724089323e76a54d8246c9d
Gerrit-PatchSet: 1
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: VolkerE 
Gerrit-Reviewer: Bartosz Dziewoński 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Prtksxna 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...PageTriage[master]: Improve JSDuck

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Improve JSDuck
..


Improve JSDuck

Import tags and externals, and related jscsrc change, from Echo.

Change-Id: I788275e5d26652f23665c9d1a27a9a457780386b
---
M .jscsrc
A jsduck.external.js
A jsduck.json
A jsduck_custom_tags.rb
4 files changed, 165 insertions(+), 1 deletion(-)

Approvals:
  Catrope: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/.jscsrc b/.jscsrc
index 9d22e3f..70e9673 100644
--- a/.jscsrc
+++ b/.jscsrc
@@ -1,3 +1,22 @@
 {
-   "preset": "wikimedia"
+   "preset": "wikimedia",
+   "jsDoc": {
+   "checkAnnotations": {
+   "preset": "jsduck5",
+   "extra": {
+   "mixin": false,
+   "todo": true,
+   "see": true
+   }
+   },
+   "requireParamTypes": true,
+   "checkReturnTypes": true,
+   "checkParamNames": true,
+   "checkTypes": "strictNativeCase",
+   "requireReturnTypes": true,
+   "checkRedundantAccess": true,
+   "checkRedundantParams": true,
+   "checkRedundantReturns": true,
+   "requireNewlineAfterDescription": true
+   }
 }
diff --git a/jsduck.external.js b/jsduck.external.js
new file mode 100644
index 000..5a9a22c
--- /dev/null
+++ b/jsduck.external.js
@@ -0,0 +1,49 @@
+/**
+ * Source: 
+ * @class jQuery
+ */
+
+/**
+ * Source: 
+ * @method ajax
+ * @static
+ *
+ * @return {jqXHR}
+ */
+
+/**
+ * Source: 
+ * @class jQuery.Event
+ */
+
+/**
+ * Source: 
+ * @class jQuery.Promise
+ */
+
+/**
+ * Source: 
+ * @class jQuery.Deferred
+ * @mixins jQuery.Promise
+ */
+
+/**
+ * Source: 
+ * @class jQuery.jqXHR
+ * @alternateClassName jqXHR
+ */
+
+/**
+ * Source: 
+ * @class mw.Api
+ */
+
+/**
+ * Source: 

+ * @class mw.Title
+ */
diff --git a/jsduck.json b/jsduck.json
new file mode 100644
index 000..04fede7
--- /dev/null
+++ b/jsduck.json
@@ -0,0 +1,13 @@
+{
+   "--title": "PageTriage - Documentation",
+   "--processes": "0",
+   "--warnings-exit-nonzero": true,
+   "--external": "OO.*",
+   "--output": "docs",
+   "--tags": "jsduck_custom_tags.rb",
+   "--": [
+   "jsduck.external.js",
+   "modules",
+   "tests"
+   ]
+}
diff --git a/jsduck_custom_tags.rb b/jsduck_custom_tags.rb
new file mode 100644
index 000..6a4da00
--- /dev/null
+++ b/jsduck_custom_tags.rb
@@ -0,0 +1,83 @@
+# Custom tags for JSDuck 5.x
+# See also:
+# - https://github.com/senchalabs/jsduck/wiki/Tags
+# - https://github.com/senchalabs/jsduck/wiki/Custom-tags
+# - 
https://github.com/senchalabs/jsduck/wiki/Custom-tags/7f5c32e568eab9edc8e3365e935bcb836cb11f1d
+require 'jsduck/tag/tag'
+
+class CommonTag < JsDuck::Tag::Tag
+  def initialize
+@html_position = POS_DOC + 0.1
+@repeatable = true
+  end
+
+  def parse_doc(scanner, _position)
+if @multiline
+  return { tagname: @tagname, doc: :multiline }
+else
+  text = scanner.match(/.*$/)
+  return { tagname: @tagname, doc: text }
+end
+  end
+
+  def process_doc(context, tags, _position)
+context[@tagname] = tags
+  end
+
+  def format(context, formatter)
+context[@tagname].each do |tag|
+  tag[:doc] = formatter.format(tag[:doc])
+end
+  end
+end
+
+class SeeTag < CommonTag
+  def initialize
+@tagname = :see
+@pattern = 'see'
+super
+  end
+
+  def format(context, formatter)
+position = context[:files][0]
+context[@tagname].each do |tag|
+  tag[:doc] = '' + render_long_see(tag[:doc], formatter, position) + 
''
+end
+  end
+
+  def to_html(context)
+<<-EOHTML
+  Related
+  
+  #{context[@tagname].map {|tag| tag[:doc]}.join("\n")}
+  
+EOHTML
+  end
+
+  def render_long_see(tag, formatter, position)
+match = tag.match(/\A([^\s]+)( .*)?\Z/m)
+if match
+  name = match[1]
+  doc = match[2] ? ': ' + match[2] : ''
+  return formatter.format("{@link #{name}} #{doc}")
+else
+  JsDuck::Logger.warn(nil, 'Unexpected @see argument: "' + tag + '"', 
position)
+  return tag
+end
+  end
+end
+
+class TodoTag < CommonTag
+  def initialize
+@tagname = :todo
+@pattern = 'todo'
+super
+  end
+
+  def to_html(context)
+<<-EOHTML
+  TODO
+  

[MediaWiki-commits] [Gerrit] mediawiki...PageTriage[master]: Import templates from English Wikipedia

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Import templates from English Wikipedia
..


Import templates from English Wikipedia

This will make testing easier (they should also be auto-imported
via MediaWiki-Vagrant later), and is useful to show required changes
to the templates connected to code changes.

The new templates can then be imported back to production after
testing.

Bug: T145891
Change-Id: I09604ed1fe75ad213ed8a6c30e21db9dd0979a13
---
A CC-BY-SA-3.0.txt
A NewPagesFeed_Templates.xml
M README
3 files changed, 6,560 insertions(+), 0 deletions(-)

Approvals:
  Catrope: Looks good to me, approved
  jenkins-bot: Verified




-- 
To view, visit https://gerrit.wikimedia.org/r/311178
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I09604ed1fe75ad213ed8a6c30e21db9dd0979a13
Gerrit-PatchSet: 5
Gerrit-Project: mediawiki/extensions/PageTriage
Gerrit-Branch: master
Gerrit-Owner: Mattflaschen 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Remove an unneeded line in observerenv.sh

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325443

Change subject: Remove an unneeded line in observerenv.sh
..

Remove an unneeded line in observerenv.sh

Change-Id: Ie8f61ef7517c597ce28edf9dfda254e14b86cb69
---
M modules/openstack/templates/observerenv.sh.erb
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/43/325443/1

diff --git a/modules/openstack/templates/observerenv.sh.erb 
b/modules/openstack/templates/observerenv.sh.erb
index bf28940..f05a40a 100644
--- a/modules/openstack/templates/observerenv.sh.erb
+++ b/modules/openstack/templates/observerenv.sh.erb
@@ -8,4 +8,3 @@
 export OS_TENANT_NAME="admin"
 export OS_NO_CACHE=1
 export OS_IDENTITY_API_VERSION=3
-export NOVA_MYSQL_PASS="<%= @novaconfig['db_pass'] %>"

-- 
To view, visit https://gerrit.wikimedia.org/r/325443
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie8f61ef7517c597ce28edf9dfda254e14b86cb69
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...CirrusSearch[master]: Wait for job to finish processing before doing commons checks

2016-12-05 Thread EBernhardson (Code Review)
EBernhardson has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325428

Change subject: Wait for job to finish processing before doing commons checks
..

Wait for job to finish processing before doing commons checks

The browser tests have been intermittently failing the commons tests,
and it's quite annoying. The retrys in cindy don't help here, because
the test setup deletes and recreates these pages. If the commons tests
are the only ones being run its probably more likely than in a full test
that the jobs havn't completed.

This is a bit of a hack, to make this better we would probably want to
add an API action that mimics action=cirrusdump, but it will do the
trick for now at least.

Change-Id: I7f3a8e21907ef136038efa507d5150b76e805d1d
---
M tests/browser/features/commons.feature
M tests/browser/features/step_definitions/search_steps.rb
2 files changed, 10 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CirrusSearch 
refs/changes/28/325428/1

diff --git a/tests/browser/features/commons.feature 
b/tests/browser/features/commons.feature
index 675b196..3051ae7 100644
--- a/tests/browser/features/commons.feature
+++ b/tests/browser/features/commons.feature
@@ -5,7 +5,8 @@
 Then File:OnCommons.svg is the first api search result
 
   Scenario: A file that exists on commons and the local wiki returns the local 
result
-When I api search in namespace 6 for duplicated
+When within 20 seconds File:DuplicatedLocally.svg has cirrustestwiki as 
local_sites_with_dupe
+Then I api search in namespace 6 for duplicated
 Then File:DuplicatedLocally.svg is the first api search result
 And Locally stored file *duplicated* on commons is the highlighted snippet 
of the first api search result
 And there is no second api search result
diff --git a/tests/browser/features/step_definitions/search_steps.rb 
b/tests/browser/features/step_definitions/search_steps.rb
index adecca3..793aa97 100644
--- a/tests/browser/features/step_definitions/search_steps.rb
+++ b/tests/browser/features/step_definitions/search_steps.rb
@@ -497,6 +497,14 @@
 step("#{title} is the first suggestion")
   end
 end
+Then(/^within (\d+) seconds (.*) has (.*) as local_sites_with_dupe$/) do 
|seconds, page, value|
+  on_wiki('commons') do
+within(seconds) do
+  step("I dump the cirrus data for " + page)
+  step('the page text contains "local_sites_with_dupe":["' + value + '"]')
+end
+  end
+end
 Then(/^there is (no|a)? link to create a new page from the search result$/) do 
|modifier|
   with_browser do
 if modifier == "a"

-- 
To view, visit https://gerrit.wikimedia.org/r/325428
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7f3a8e21907ef136038efa507d5150b76e805d1d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/CirrusSearch
Gerrit-Branch: master
Gerrit-Owner: EBernhardson 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: prometheus: tune ops retention in eqiad

2016-12-05 Thread Filippo Giunchedi (Code Review)
Filippo Giunchedi has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325432

Change subject: prometheus: tune ops retention in eqiad
..

prometheus: tune ops retention in eqiad

Prometheus Ganeti VM has less space in eqiad than codfw, tune retention
to 40d while waiting for Prometheus baremetal HW to be provisioned.

Change-Id: I82aa44a53b2b4f4cd547250350dec4359a4165e4
---
A hieradata/role/eqiad/prometheus/ops.yaml
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/32/325432/1

diff --git a/hieradata/role/eqiad/prometheus/ops.yaml 
b/hieradata/role/eqiad/prometheus/ops.yaml
new file mode 100644
index 000..6a4b525
--- /dev/null
+++ b/hieradata/role/eqiad/prometheus/ops.yaml
@@ -0,0 +1 @@
+prometheus::server::storage_retention: '960h0m0s'

-- 
To view, visit https://gerrit.wikimedia.org/r/325432
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I82aa44a53b2b4f4cd547250350dec4359a4165e4
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Filippo Giunchedi 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki...trending-edits[master]: Use Map for storing trending information

2016-12-05 Thread Ppchelko (Code Review)
Ppchelko has submitted this change and it was merged.

Change subject: Use Map for storing trending information
..


Use Map for storing trending information

It's better suited to this job.

Change-Id: I41f21fb26b96176b05eb196ef7632e4c3d72f1ed
---
M lib/processor.js
1 file changed, 25 insertions(+), 25 deletions(-)

Approvals:
  Ppchelko: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/lib/processor.js b/lib/processor.js
index 8c7edab..a11e99f 100644
--- a/lib/processor.js
+++ b/lib/processor.js
@@ -1,15 +1,14 @@
 "use strict";
 
 // Capture the status of the wiki
-var pages = {};
-var totalPages = 0;
+var pages = new Map();
 
 /**
  * Return unsorted array of objects representing edit activity on pages
  * @return {Array} of all pages that have been processed
  */
 function getPages() {
-return Object.values(pages);
+return Array.from(pages.values());
 }
 
 /**
@@ -19,10 +18,7 @@
  * @param {Number} id
  */
 function remove(id) {
-if (pages[id]) {
-delete pages[id];
-totalPages--;
-}
+pages.delete(id);
 }
 
 /**
@@ -37,19 +33,20 @@
 var time = date.getTime();
 var maxAgeDate = new Date(time - options.max_age * 6);
 var maxInactivityDate = new Date(time - options.max_inactivity * 6);
-Object.entries(pages).forEach((entry) => {
-var page = entry[1];
+pages.forEach((page) => {
 var timePassed = (date - page.from) / 6;
 var speed = timePassed > 0 ? page.edits / timePassed : page.edits;
 if (page.updated < maxInactivityDate || page.from < maxAgeDate || 
speed < options.min_speed) {
 remove(page.id);
 }
 });
+
+var size = pages.size;
 // Only do this if we have to
-if (totalPages > options.max_pages) {
+if (size > options.max_pages) {
 getPages().sort(function(a, b) {
 return a.from < b.from ? -1 : 1;
-}).slice(0, totalPages - options.max_pages).forEach(function(page) {
+}).slice(0, size - options.max_pages).forEach(function(page) {
 remove(page.id);
 });
 }
@@ -59,8 +56,7 @@
  * Reset all previous processing of edits
  */
 function reset() {
-pages = {};
-totalPages = 0;
+pages.clear();
 }
 
 /**
@@ -70,6 +66,7 @@
  */
 function process(edit) {
 var contributors;
+var page;
 var id = edit.page_id;
 var ts = new Date(edit.rev_timestamp);
 var performer = edit.performer;
@@ -79,18 +76,19 @@
 
 if (topic === 'mediawiki.page-delete') {
 remove(id);
-} else if (topic === 'mediawiki.page-move' && pages[id]) {
-pages[id].title = edit.page_title;
+} else if (topic === 'mediawiki.page-move' && pages.has(id)) {
+page = pages.get(id);
+page.title = edit.page_title;
 // assumption here made that anons cannot move pages so we do not 
touch anonEdits
-pages[id].edits -= 1;
+page.edits -= 1;
 } else if (topic === 'mediawiki.revision-create' && !edit.page_is_redirect 
&&
 !performer.user_is_bot && edit.page_namespace === 0) {
-if (pages[id]) {
-pages[id].edits++;
-pages[id].updated = ts;
+if (pages.has(id)) {
+page = pages.get(id);
+page.edits++;
+page.updated = ts;
 } else {
-totalPages++;
-pages[id] = {
+page = {
 id: id,
 isNew: edit.rev_parent_id === undefined,
 edits: 1,
@@ -107,9 +105,9 @@
 title: edit.page_title
 };
 }
-contributors = pages[id].contributors;
+contributors = page.contributors;
 if (isAnon) {
-pages[id].anonEdits += 1;
+page.anonEdits += 1;
 if (!contributors.names[username]) {
 contributors.anons++;
 }
@@ -125,8 +123,10 @@
 if (contributors.names[username].edits > 
contributors.names[contributors.main].edits) {
 contributors.main = username;
 }
-pages[id].bytes = edit.rev_len - pages[id].rev_len;
-pages[id].bias = contributors.names[contributors.main].edits / 
pages[id].edits;
+page.bytes = edit.rev_len - page.rev_len;
+page.bias = contributors.names[contributors.main].edits / page.edits;
+// update
+pages.set(id,page);
 }
 }
 

-- 
To view, visit https://gerrit.wikimedia.org/r/323489
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I41f21fb26b96176b05eb196ef7632e4c3d72f1ed
Gerrit-PatchSet: 6
Gerrit-Project: mediawiki/services/trending-edits
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Mobrovac 
Gerrit-Reviewer: Pmiazga 
Gerrit-Reviewer: Ppchelko 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: Labs ldap: Further attempt to get the keystone IP in an acl

2016-12-05 Thread Andrew Bogott (Code Review)
Andrew Bogott has submitted this change and it was merged.

Change subject: Labs ldap: Further attempt to get the keystone IP in an acl
..


Labs ldap: Further attempt to get the keystone IP in an acl

Change-Id: Icd1309b407d69318ad6d143a97ac034e00e3a7a7
---
D hieradata/hosts/labtestservices2001.yaml
M modules/openldap/templates/labs-acls.erb
M modules/role/manifests/openldap/labs.pp
3 files changed, 1 insertion(+), 4 deletions(-)

Approvals:
  Andrew Bogott: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/hieradata/hosts/labtestservices2001.yaml 
b/hieradata/hosts/labtestservices2001.yaml
deleted file mode 100644
index ca0b81f..000
--- a/hieradata/hosts/labtestservices2001.yaml
+++ /dev/null
@@ -1 +0,0 @@
-labs_keystone_host: "labtestcontrol2001.wikimedia.org"
diff --git a/modules/openldap/templates/labs-acls.erb 
b/modules/openldap/templates/labs-acls.erb
index 62fc6fe..db66711 100644
--- a/modules/openldap/templates/labs-acls.erb
+++ b/modules/openldap/templates/labs-acls.erb
@@ -13,4 +13,4 @@
 # novaobserver is an account used only for keystone access.  We don't want it
 #  to appear on wikitech, gerrit, etc. so limit access only to the keystone 
host
 access to dn=uid=novaobserver,ou=people,dc=wikimedia,dc=org
-   by peername.ip=<%= @labs_keystone_ip %> anonymous read
+   by 
peername.ip=<%=scope.function_ipresolve([scope.function_hiera(['labs_keystone_host']),
 4])%> anonymous read
diff --git a/modules/role/manifests/openldap/labs.pp 
b/modules/role/manifests/openldap/labs.pp
index a16d517..ba95b10 100644
--- a/modules/role/manifests/openldap/labs.pp
+++ b/modules/role/manifests/openldap/labs.pp
@@ -7,8 +7,6 @@
 $ldapconfig = hiera_hash('labsldapconfig', {})
 $ldap_labs_hostname = $ldapconfig['hostname']
 
-$labs_keystone_ip = ipresolve(hiera('labs_keystone_host'),4)
-
 system::role { 'role::openldap::labs':
 description => 'LDAP servers for labs (based on OpenLDAP)'
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/325433
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Icd1309b407d69318ad6d143a97ac034e00e3a7a7
Gerrit-PatchSet: 3
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 
Gerrit-Reviewer: Andrew Bogott 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: prometheus: fetch storage_retention for ops from hiera

2016-12-05 Thread Filippo Giunchedi (Code Review)
Filippo Giunchedi has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325434

Change subject: prometheus: fetch storage_retention for ops from hiera
..

prometheus: fetch storage_retention for ops from hiera

Change-Id: I76b3d9ee7a0da8028074c952fe93fbfd1b842647
---
M modules/role/manifests/prometheus/ops.pp
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/34/325434/1

diff --git a/modules/role/manifests/prometheus/ops.pp 
b/modules/role/manifests/prometheus/ops.pp
index 746d022..1bf55da 100644
--- a/modules/role/manifests/prometheus/ops.pp
+++ b/modules/role/manifests/prometheus/ops.pp
@@ -5,6 +5,7 @@
 
 $targets_path = '/srv/prometheus/ops/targets'
 $rules_path = '/srv/prometheus/ops/rules'
+$storage_retention = hiera('prometheus::server::storage_retention', 
'4320h0m0s')
 
 $config_extra = {
 # All metrics will get an additional 'site' label when queried by
@@ -113,6 +114,7 @@
 prometheus::server { 'ops':
 storage_encoding => '2',
 listen_address   => '127.0.0.1:9900',
+storage_retention=> $storage_retention,
 scrape_configs_extra => array_concat($mysql_jobs, $varnish_jobs, 
$memcached_jobs),
 global_config_extra  => $config_extra,
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/325434
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I76b3d9ee7a0da8028074c952fe93fbfd1b842647
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Filippo Giunchedi 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] wikimedia...tools[deploy]: Merge master into deploy

2016-12-05 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Merge master into deploy
..


Merge master into deploy

73bd4089ac7d408cb52a0d33da69548c9e266653 Split silverpop export from upload

Change-Id: I2fd4c3ec5b88cb9759414d4e6a0c53994e71aa0b
---
0 files changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Awight: Looks good to me, approved
  jenkins-bot: Verified




-- 
To view, visit https://gerrit.wikimedia.org/r/325440
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I2fd4c3ec5b88cb9759414d4e6a0c53994e71aa0b
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/tools
Gerrit-Branch: deploy
Gerrit-Owner: Awight 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki/vagrant[master]: [WIP] Wipe out activemq

2016-12-05 Thread Awight (Code Review)
Awight has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/325441

Change subject: [WIP] Wipe out activemq
..

[WIP] Wipe out activemq

Change-Id: I70af0564badd12703a41beee5e6ae9b67f648d6b
---
D puppet/modules/activemq/lib/puppet/type/tarball.rb
D puppet/modules/activemq/manifests/init.pp
D puppet/modules/activemq/templates/activemq-upstart.conf.erb
D puppet/modules/activemq/templates/activemq.xml.erb
M puppet/modules/crm/manifests/init.pp
M puppet/modules/crm/templates/DonationInterface.settings.php.erb
M puppet/modules/payments/manifests/donation_interface.pp
M puppet/modules/role/manifests/fundraising.pp
8 files changed, 11 insertions(+), 250 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/vagrant 
refs/changes/41/325441/1

diff --git a/puppet/modules/activemq/lib/puppet/type/tarball.rb 
b/puppet/modules/activemq/lib/puppet/type/tarball.rb
deleted file mode 100644
index bec0237..000
--- a/puppet/modules/activemq/lib/puppet/type/tarball.rb
+++ /dev/null
@@ -1,63 +0,0 @@
-require 'open-uri'
-
-Puppet::Type.newtype(:tarball) do
-@doc = "Fetch and extract tarballed packages"
-
-ensurable
-
-newparam(:source) do
-desc "URL where the tarball will be found"
-end
-
-newparam(:path) do
-desc "Directory in which the tarball shall be extracted"
-end
-
-newparam(:creates) do
-desc "Will create this path when untarred"
-
-isnamevar
-end
-
-newparam(:storage) do
-desc "Directory in which to store the original tarball"
-end
-
-def create
-if not File.exists? filename
-fetch
-end
-extract
-end
-
-def creates_path
-self[:creates] || filename
-end
-
-def destroy
-File.unlink creates_path
-end
-
-def exists?
-# TODO verify signature
-File.exists? creates_path
-end
-
-def extract
-notice "Unpacking tarball #{filename} into #{self[:path]}"
-system("tar", "-C", self[:path], "-xzf", filename)
-end
-
-def fetch
-# TODO safe noclobber
-
-FileUtils.copy_stream(
-open(self[:source]),
-File.open(filename, "w+")
-)
-end
-
-def filename
-File.join(self[:storage], self[:source].split(/\//).last)
-end
-end
diff --git a/puppet/modules/activemq/manifests/init.pp 
b/puppet/modules/activemq/manifests/init.pp
deleted file mode 100644
index 4d2f4b1..000
--- a/puppet/modules/activemq/manifests/init.pp
+++ /dev/null
@@ -1,73 +0,0 @@
-# == Class: activemq
-#
-# Provisions Apache ActiveMQ
-#
-class activemq(
-$version  = '5.11.4',
-$hostname = '127.0.0.1',
-$port = '61613',
-) {
-$pkgname = "apache-activemq-${version}"
-$mirror = 
"http://mirrors.ibiblio.org/apache/activemq/${version}/${pkgname}-bin.tar.gz;
-
-$destdir = '/usr/local'
-$pkgdir = "${destdir}/${pkgname}"
-
-tarball { $pkgname:
-ensure  => present,
-source  => $mirror,
-storage => '/vagrant/cache/apt',
-path=> $destdir,
-creates => $pkgdir,
-}
-
-$config = '/etc/activemq.xml'
-
-file { $config:
-owner   => root,
-group   => root,
-content => template('activemq/activemq.xml.erb'),
-}
-
-package { 'default-jre-headless':
-ensure => present,
-}
-
-user { 'activemq':
-ensure => present,
-managehome => true,
-home   => '/home/activemq',
-}
-
-file { [ "${pkgdir}/data", "${pkgdir}/tmp" ]:
-ensure  => directory,
-owner   => 'activemq',
-group   => 'activemq',
-mode=> '0770',
-recurse => true,
-require => Tarball[$pkgname],
-}
-
-service { 'activemq':
-ensure=> running,
-enable=> true,
-provider  => 'upstart',
-require   => [
-Package['default-jre-headless'],
-Tarball[$pkgname],
-File["${pkgdir}/data"],
-User['activemq'],
-],
-subscribe => [
-File['/etc/init/activemq.conf'],
-File[$config],
-],
-}
-
-file { '/etc/init/activemq.conf':
-content => template('activemq/activemq-upstart.conf.erb'),
-owner   => 'root',
-group   => 'root',
-mode=> '0644',
-}
-}
diff --git a/puppet/modules/activemq/templates/activemq-upstart.conf.erb 
b/puppet/modules/activemq/templates/activemq-upstart.conf.erb
deleted file mode 100755
index 7aa71a0..000
--- a/puppet/modules/activemq/templates/activemq-upstart.conf.erb
+++ /dev/null
@@ -1,8 +0,0 @@
-description "ActiveMQ STOMP server"
-
-start on (local-filesystems and net-device-up IFACE!=lo)
-
-setuid activemq
-setgid activemq
-
-exec <%= @pkgdir %>/bin/activemq-admin start
diff --git a/puppet/modules/activemq/templates/activemq.xml.erb 

[MediaWiki-commits] [Gerrit] operations...gerrit[master]: gerrit (2.13.3-wmf.1) jessie-wikimedia; urgency=low

2016-12-05 Thread Filippo Giunchedi (Code Review)
Filippo Giunchedi has submitted this change and it was merged.

Change subject: gerrit (2.13.3-wmf.1) jessie-wikimedia; urgency=low
..


gerrit (2.13.3-wmf.1) jessie-wikimedia; urgency=low

  * Update gerrit core + all core plugins to 2.13.3 (includes new hooks plugin)
  * Update its-phabricator plugin to stable-2.13, built against core and
its-base stable-2.13 branches
  * All built against openjdk-8 now

Bug: T146350
Change-Id: I9d4585242faad128e8fc75f050e14e456e84b94b
---
M debian/changelog
M debian/control
M gerrit.war
M plugins/commit-message-length-validator.jar
M plugins/download-commands.jar
A plugins/hooks.jar
M plugins/its-phabricator.jar
M plugins/replication.jar
M plugins/reviewnotes.jar
M plugins/singleusergroup.jar
10 files changed, 11 insertions(+), 2 deletions(-)

Approvals:
  Filippo Giunchedi: Looks good to me, approved
  Paladox: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/debian/changelog b/debian/changelog
index bd700f4..dc878ee 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,12 @@
+gerrit (2.13.3-wmf.1) jessie-wikimedia; urgency=low
+
+  * Update gerrit core + all core plugins to 2.13.3 (includes new hooks plugin)
+  * Update its-phabricator plugin to stable-2.13, built against core and
+its-base stable-2.13 branches
+  * All built against openjdk-8 now
+
+ -- Chad Horohoe   Fri, 25 Nov 2016 16:34:32 +
+
 gerrit (2.12.5-wmf.1) jessie-wikimedia; urgency=low
 
   * Update gerrit core + all core plugins to 2.12.5
diff --git a/debian/control b/debian/control
index 06362c8..1f49004 100644
--- a/debian/control
+++ b/debian/control
@@ -6,8 +6,8 @@
 Standards-Version: 1.0
 
 Package: gerrit
-Depends: openjdk-7-jre
+Depends: openjdk-8-jre
 Recommends: libmysql-java
-Suggests: openjdk-7-jdk
+Suggests: openjdk-8-jdk
 Architecture: all
 Description: Gerrit code review system
diff --git a/gerrit.war b/gerrit.war
index 4a04c14..f595043 100644
--- a/gerrit.war
+++ b/gerrit.war
Binary files differ
diff --git a/plugins/commit-message-length-validator.jar 
b/plugins/commit-message-length-validator.jar
index 14358d6..7d3fce6 100644
--- a/plugins/commit-message-length-validator.jar
+++ b/plugins/commit-message-length-validator.jar
Binary files differ
diff --git a/plugins/download-commands.jar b/plugins/download-commands.jar
index ba696a1..bb85055 100644
--- a/plugins/download-commands.jar
+++ b/plugins/download-commands.jar
Binary files differ
diff --git a/plugins/hooks.jar b/plugins/hooks.jar
new file mode 100644
index 000..b1e3be4
--- /dev/null
+++ b/plugins/hooks.jar
Binary files differ
diff --git a/plugins/its-phabricator.jar b/plugins/its-phabricator.jar
index f8825a5..9cafaaf 100644
--- a/plugins/its-phabricator.jar
+++ b/plugins/its-phabricator.jar
Binary files differ
diff --git a/plugins/replication.jar b/plugins/replication.jar
index 05cbcd1..4f6a6fd 100644
--- a/plugins/replication.jar
+++ b/plugins/replication.jar
Binary files differ
diff --git a/plugins/reviewnotes.jar b/plugins/reviewnotes.jar
index 0049206..19ebb68 100644
--- a/plugins/reviewnotes.jar
+++ b/plugins/reviewnotes.jar
Binary files differ
diff --git a/plugins/singleusergroup.jar b/plugins/singleusergroup.jar
index 39294eb..9b35ebd 100644
--- a/plugins/singleusergroup.jar
+++ b/plugins/singleusergroup.jar
Binary files differ

-- 
To view, visit https://gerrit.wikimedia.org/r/323545
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I9d4585242faad128e8fc75f050e14e456e84b94b
Gerrit-PatchSet: 2
Gerrit-Project: operations/debs/gerrit
Gerrit-Branch: master
Gerrit-Owner: Chad 
Gerrit-Reviewer: Filippo Giunchedi 
Gerrit-Reviewer: Muehlenhoff 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] operations/puppet[production]: phabricator: Add search.elastic.host for limited elasticsear...

2016-12-05 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged.

Change subject: phabricator: Add search.elastic.host for limited elasticsearch 
testing
..


phabricator: Add search.elastic.host for limited elasticsearch testing

This does not enable elasticsearch but it allows us to test it in
a limited way.

Using https to keep search keywords private.

Bug: T146843
Change-Id: Ica13a6f4eb9c92c3436f64055bf8fe01a203d211
---
M modules/phabricator/data/fixed_settings.yaml
1 file changed, 4 insertions(+), 0 deletions(-)

Approvals:
  20after4: Looks good to me, but someone else must approve
  Dzahn: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/modules/phabricator/data/fixed_settings.yaml 
b/modules/phabricator/data/fixed_settings.yaml
index cec1952..c3e9e36 100644
--- a/modules/phabricator/data/fixed_settings.yaml
+++ b/modules/phabricator/data/fixed_settings.yaml
@@ -5,6 +5,10 @@
 # in Phabricator but only for administrators.  If you do not have the ability 
to restart the
 # associated daemons do not merge changes to this file.
 
+search.elastic.host: 'https://search.svc.eqiad.wmnet:9243'
+search.elastic.version: '2'
+search.elastic.enabled: false
+
 ui.logo:
   'logoImagePHID': 'PHID-FILE-rs3pf2brupiulr6zcnrg'
   'wordmarkText': 'Phabricator'

-- 
To view, visit https://gerrit.wikimedia.org/r/325333
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ica13a6f4eb9c92c3436f64055bf8fe01a203d211
Gerrit-PatchSet: 5
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: 20after4 
Gerrit-Reviewer: 20after4 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


  1   2   3   4   >