[MediaWiki-commits] [Gerrit] operations...debdeploy[master]: Fine-tune display of check_restart and deploy commands

2017-08-24 Thread Muehlenhoff (Code Review)
Muehlenhoff has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373283 )

Change subject: Fine-tune display of check_restart and deploy commands
..


Fine-tune display of check_restart and deploy commands

- Remove the apt log by default, it introduced too many differences into the
  node sets, making them disperse
- Use specific flags to indicate known conditions when not to update
- Use a common function to display unreachable hosts
- Adapt execution of deployment tool to recent Cumin changes and use
  JSON by default

Change-Id: If660cae959254d19abb9f4baed180d44cf30cdb7
---
M clients/debdeploy-deploy
M server/debdeploy.py
2 files changed, 67 insertions(+), 65 deletions(-)

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



diff --git a/clients/debdeploy-deploy b/clients/debdeploy-deploy
index 64e85e3..a51bb6a 100755
--- a/clients/debdeploy-deploy
+++ b/clients/debdeploy-deploy
@@ -189,7 +189,7 @@
 return update
 
 
-def result(status, updated_packages, log, json_output):
+def result(status, updated_packages, json_output):
 """Generates a data set to return to Cumin.
 
 status: OK | ERROR: foo
@@ -197,11 +197,11 @@
 previous and the new version
 log: the complete apt log
 """
-ret = [status, updated_packages, log]
+
 if json_output:
-return json.dumps(ret)
+return status + " " + json.dumps(updated_packages)
 else:
-return ret
+return status + " " + str(updated_packages)
 
 
 def main():
@@ -221,11 +221,11 @@
 
 installed_distro = get_os_version()
 if installed_distro == 'invalid':
-return result('ERROR: Could not parse installed distros', {}, '', 
args.json)
+return result('ERROR Could not parse installed distros', {}, args.json)
 
 if versions.get(installed_distro, None) is None:
 logger.info("Update doesn't apply to the installed distribution (" + 
str(installed_distro))
-return result("OK", {}, '', args.json)
+return result("OK OSDIFFERS", {}, args.json)
 
 installed_binary_packages = get_installed_binary_packages(args.source)
 logger.debug('Installed binary packages for ' + args.source +
@@ -233,7 +233,7 @@
 
 if len(installed_binary_packages) == 0:
 logger.info('No binary packages installed for source package ' + 
args.source)
-return result('OK', {}, '', args.json)
+return result("OK NOBINARY", {}, args.json)
 
 if args.run_apt_update:
 try:
@@ -254,10 +254,10 @@
 
 logger.info('Modified packages: ' + str(modified))
 
-if args.verbose:
-return result('OK', modified, apt_output, args.json)
-else:
-return result('OK', modified, '', args.json)
+if not modified:
+return result('OK NOCHANGE', modified, args.json)
+
+return result('OK', modified, args.json)
 
 
 if __name__ == '__main__':
diff --git a/server/debdeploy.py b/server/debdeploy.py
index ec01c00..fdfc598 100755
--- a/server/debdeploy.py
+++ b/server/debdeploy.py
@@ -65,6 +65,18 @@
 print self.buf
 
 
+def show_unreachable_hosts(worker):
+unreachable_hosts = []
+for node in worker._handler_instance.nodes.itervalues():
+if node.state.is_failed:
+unreachable_hosts.append(node.name)
+
+if unreachable_hosts:
+print
+print "The following hosts were unreachable:"
+for host in unreachable_hosts:
+print host
+
 def run_cumin(cmd):
 '''
 Run Cumin and discard the output shown by the transport
@@ -111,86 +123,76 @@
 
 print "Rolling out", source, ":",
 print update_desc[update_type]
+print
 
-worker = transport.Transport.new(cumin_config, logging)
-hosts = query.Query(cumin_config).execute('A:all')
-
-cmd = '/usr/bin/debdeploy-deploy --source ' + source + ' --updatespec '
-
+cmd = '/usr/bin/debdeploy-deploy --json --source ' + source + ' 
--updatespec '
 for distro in fixes:
 if fixes[distro]:
-cmd += str(supported_distros[distro][0][0]) + "_" + 
str(supported_distros[distro][0][1])
-+ "_" + str(fixes[distro]) + " "
+cmd += str(supported_distros[distro][0][0]) + "_" + 
str(supported_distros[distro][0][1]) + "_" + str(fixes[distro]) + " "
 
-worker.target = transports.Target(hosts, batch_size=100, batch_sleep=None, 
logger=logging)
-worker.commands = [cmd]
+worker = run_cumin(cmd)
 
-worker.timeout = None
-worker.handler = 'sync'
-worker.success_threshold = 0.1
-worker.batch_size = 100
-worker.batch_sleep = None
-
-# with open('/dev/null', 'w') as discard_output:
-# oldstdout = sys.stdout
-# sys.stdout = discard_output
-# exit_code = worker.execute()
-# sys.stdout = oldstdout
-
-exit_code = worker.execute()
-
-out = {}
 for n

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: mariadb: Retire db1033, pool db1069 with its copy and low we...

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373673 )

Change subject: mariadb: Retire db1033, pool db1069 with its copy and low weight
..


mariadb: Retire db1033, pool db1069 with its copy and low weight

db1069 will retire db1033 and db1028, we can retire directly db1033
but we will have to pool db1069 slowly before retiring currently in
use db1028.

Bug: T174076
Change-Id: Ie93c99489bf50ea8d065c05981e3617f1d0e6089
---
M wmf-config/db-codfw.php
M wmf-config/db-eqiad.php
2 files changed, 7 insertions(+), 5 deletions(-)

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



diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index 5aa7ffc..6ae5059 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -452,7 +452,6 @@
'db1026' => '10.64.16.15', # do not remove or comment out
'db1028' => '10.64.16.17', # do not remove or comment out
'db1030' => '10.64.16.19', # do not remove or comment out
-   'db1033' => '10.64.16.22', # do not remove or comment out
'db1034' => '10.64.16.23', # do not remove or comment out
'db1035' => '10.64.16.24', # do not remove or comment out
'db1036' => '10.64.16.25', # do not remove or comment out
@@ -481,6 +480,7 @@
'db1066' => '10.64.48.21', # do not remove or comment out
'db1067' => '10.64.48.22', # do not remove or comment out
'db1068' => '10.64.48.23', # do not remove or comment out
+   'db1069' => '10.64.48.24', # do not remove or comment out
'db1070' => '10.64.48.25', # do not remove or comment out
'db1071' => '10.64.48.26', # do not remove or comment out
'db1072' => '10.64.16.39', # do not remove or comment out
diff --git a/wmf-config/db-eqiad.php b/wmf-config/db-eqiad.php
index b7ebd67..9536df2 100644
--- a/wmf-config/db-eqiad.php
+++ b/wmf-config/db-eqiad.php
@@ -166,10 +166,10 @@
],
's7' => [
'db1062' => 0,   # D4 2.8TB 128GB, master
-   # 'db1033' => 0,   # B2 1.4TB  64GB, old master
'db1028' => 0,   # B1 1.4TB  64GB, vslow, dump
'db1034' => 1,   # B2 1.4TB  64GB, watchlist, recentchanges, 
contributions, logpager
# 'db1039' => 0,   # B2 1.4TB  64GB
+   'db1069' => 0,   # D1 2.8TB 160GB, vslow, dump, old master
'db1079' => 300, # A2 3.6TB 512GB, api #master for db1102 
(sanitarium 3)
'db1086' => 500, # B3 3.6TB 512GB, api
'db1094' => 500, # D2 3.6TB 512GB
@@ -432,10 +432,12 @@
],
's7' => [
'vslow' => [
-   'db1028' => 1,
+   'db1028' => 10,
+   'db1069' => 1,
],
'dump' => [
-   'db1028' => 1,
+   'db1028' => 10,
+   'db1069' => 1,
],
'api' => [
'db1079' => 100,
@@ -475,7 +477,6 @@
'db1026' => '10.64.16.15', # do not remove or comment out
'db1028' => '10.64.16.17', # do not remove or comment out
'db1030' => '10.64.16.19', # do not remove or comment out
-   'db1033' => '10.64.16.22', # do not remove or comment out
'db1034' => '10.64.16.23', # do not remove or comment out
'db1035' => '10.64.16.24', # do not remove or comment out
'db1036' => '10.64.16.25', # do not remove or comment out
@@ -504,6 +505,7 @@
'db1066' => '10.64.48.21', # do not remove or comment out
'db1067' => '10.64.48.22', # do not remove or comment out
'db1068' => '10.64.48.23', # do not remove or comment out
+   'db1069' => '10.64.48.24', # do not remove or comment out
'db1070' => '10.64.48.25', # do not remove or comment out
'db1071' => '10.64.48.26', # do not remove or comment out
'db1072' => '10.64.16.39', # do not remove or comment out

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie93c99489bf50ea8d065c05981e3617f1d0e6089
Gerrit-PatchSet: 3
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Jcrespo 
Gerrit-Reviewer: Florianschmidtwelzow 
Gerrit-Reviewer: Jcrespo 
Gerrit-Reviewer: Marostegui 
Gerrit-Reviewer: Urbanecm 
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]: Improve the New Translation dialog

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/371473 )

Change subject: Improve the New Translation dialog
..


Improve the New Translation dialog

Make New translation dialog show in-place, closable by click outside.
Make selection status clearly differentiable from the search one.

Bug: T111094
Change-Id: I222a29f56786a59f97e03d631b05c37cc9678b15
---
M modules/dashboard/ext.cx.dashboard.js
M modules/dashboard/styles/ext.cx.suggestionlist.less
M modules/source/ext.cx.source.selector.js
M modules/source/styles/ext.cx.source.selector.less
M modules/ui/widgets/mw.cx.ui.PageSelectorWidget.js
M modules/widgets/overlay/ext.cx.overlay.js
M modules/widgets/overlay/ext.cx.overlay.less
7 files changed, 526 insertions(+), 103 deletions(-)

Approvals:
  jenkins-bot: Verified
  Nikerabbit: Checked; Looks good to me, approved



diff --git a/modules/dashboard/ext.cx.dashboard.js 
b/modules/dashboard/ext.cx.dashboard.js
index d3ee47d..817319b 100644
--- a/modules/dashboard/ext.cx.dashboard.js
+++ b/modules/dashboard/ext.cx.dashboard.js
@@ -26,6 +26,7 @@
this.$filter = null;
this.$listHeader = null;
this.$cta = null;
+   this.$sourceSelector = null;
}
 
CXDashboard.prototype.init = function () {
@@ -254,9 +255,12 @@
this.$filter
);
 
+   this.$sourceSelector = $( '' )
+   .addClass( 'cx-sourceselector-embedded' );
+
return $( '' )
.addClass( 'cx-translationlist-container' )
-   .append( this.$listHeader );
+   .append( this.$listHeader, this.$sourceSelector );
};
 
CXDashboard.prototype.setActiveList = function ( type ) {
@@ -282,7 +286,8 @@
};
 
CXDashboard.prototype.listen = function () {
-   var self = this;
+   var self = this,
+   onVisibleCallback;
 
this.$filter.click( '.cx-filter', function ( e ) {
var $filter = $( e.target );
@@ -307,6 +312,16 @@
}
} );
 
+   onVisibleCallback = function () {
+   if ( $( 'html' ).prop( 'dir' ) === 'rtl' ) {
+   this.left = this.$element.offset().left + 
this.$element.parent().width() - this.$menu.width();
+   } else {
+   this.left = this.$element.offset().left;
+   }
+
+   this.$menu.css( this.position() );
+   };
+
$.each( this.lists, function ( name, list ) {
var setFilter = self.setFilter.bind( self );
 
@@ -314,10 +329,7 @@
onSelect: function ( language ) {
setFilter( 'sourceLanguage', language );
},
-   onVisible: function () {
-   this.left = 
list.languageFilter.$sourceLanguageFilter.offset().left;
-   this.$menu.css( 'left', this.left );
-   },
+   onVisible: onVisibleCallback,
menuWidth: 'medium',
left: 
list.languageFilter.$sourceLanguageFilter.offset().left,
quickList: function () {
@@ -330,10 +342,7 @@
onSelect: function ( language ) {
setFilter( 'targetLanguage', language );
},
-   onVisible: function () {
-   this.left = 
list.languageFilter.$targetLanguageFilter.offset().left;
-   this.$menu.css( 'left', this.left );
-   },
+   onVisible: onVisibleCallback,
menuWidth: 'medium',
left: 
list.languageFilter.$targetLanguageFilter.offset().left,
quickList: function () {
@@ -344,8 +353,14 @@
} );
 
this.initSourceSelector();
+   this.$newTranslationButton.on( 'click', function ( e ) {
+   self.$listHeader.hide();
+   e.stopPropagation();
+
+   $( window ).scrollTop( 0 );
+   } );
// Scroll handler
-   $( window ).scroll( $.throttle( 250, $.proxy( this.scroll, this 
) ) );
+   $( window ).scroll( $.throttle( 250, this.scroll.bind( this ) ) 
);
};
 
CXDashboard.prototype.setFilter = function ( type, value ) {
@@ -364,7 +

[MediaWiki-commits] [Gerrit] mediawiki...CreateRedirect[master]: Convert CreateRedirect to use extension registration

2017-08-24 Thread Reception123 (Code Review)
Reception123 has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373736 )

Change subject: Convert CreateRedirect to use extension registration
..

Convert CreateRedirect to use extension registration

Bug: T174131
Change-Id: I697d2973fbed517801213827fca69472faf1fbfe
---
M CreateRedirect.body.php
M CreateRedirect.php
A extension.json
3 files changed, 65 insertions(+), 51 deletions(-)


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

diff --git a/CreateRedirect.body.php b/CreateRedirect.body.php
index f959a54..79da848 100644
--- a/CreateRedirect.body.php
+++ b/CreateRedirect.body.php
@@ -206,6 +206,34 @@
 END
);
}
+   
+   /**
+ * Adds a shortcut link pointing to Special:CreateRedirect to the "toolbox" 
menu.
+ * If applicable, also adds a reference to the current title as a GET param.
+ *
+ * @return Boolean: true
+ */
+function createRedirect_AddToolboxLink( &$tpl ) {
+   global $wgRequest;
+
+   // 1. Determine whether to actually add the link at all.
+   // There are certain cases, e.g. in the edit dialog, in a special page,
+   // where it's inappropriate for the link to appear.
+   // 2. Check the title. Is it a "Special:" page? Don't display the link.
+   $action = $wgRequest->getText( 'action', 'view' );
+   $title = $tpl->getSkin()->getTitle();
+
+   if( $action != 'view' && $action != 'purge' && !$title->isSpecialPage() 
) {
+   return true;
+   }
+
+   // 3. Add the link!
+   $href = SpecialPage::getTitleFor( 'CreateRedirect', 
$title->getPrefixedText() )->getLocalURL();
+   echo Html::rawElement( 'li', null, Html::element( 'a', array( 'href' => 
$href ), wfMessage( 'createredirect' )->text() ) );
+
+   return true;
+}
+
 
protected function getGroupName() {
return 'pagetools';
diff --git a/CreateRedirect.php b/CreateRedirect.php
index f9b8cc6..b19d219 100644
--- a/CreateRedirect.php
+++ b/CreateRedirect.php
@@ -29,55 +29,14 @@
  * along with CreateRedirect.  If not, see .
  */
 
-if( !defined( 'MEDIAWIKI' ) ) {
-   echo( "This file is an extension to the MediaWiki software and cannot 
be used standalone.\n" );
-   die( 1 );
-}
-
-// Add this extension to Special:Credits.
-$wgExtensionCredits['specialpage'][] = array(
-   'path'  => __FILE__,
-   'name' => 'CreateRedirect',
-   'author' => 'Marco Zafra',
-   'version' => '1.1.0',
-   'url' => 'https://www.mediawiki.org/wiki/Extension:CreateRedirect',
-   'descriptionmsg' => 'createredirect-desc',
-);
-
-// Set up the actual extension functionality.
-$dir = dirname( __FILE__ ) . '/';
-$wgAutoloadClasses['SpecialCreateRedirect'] = $dir . 'CreateRedirect.body.php';
-$wgSpecialPages['CreateRedirect'] = 'SpecialCreateRedirect';
-$wgMessagesDirs['CreateRedirect'] = __DIR__ . '/i18n';
-$wgExtensionMessagesFiles['CreateRedirect'] = $dir . 'CreateRedirect.i18n.php';
-$wgExtensionMessagesFiles['CreateRedirectAlias'] = $dir . 
'CreateRedirect.alias.php';
-
-// Add a shortcut link to the toolbox.
-$wgHooks['SkinTemplateToolboxEnd'][] = 'createRedirect_addToolboxLink';
-
-/**
- * Adds a shortcut link pointing to Special:CreateRedirect to the "toolbox" 
menu.
- * If applicable, also adds a reference to the current title as a GET param.
- *
- * @return Boolean: true
- */
-function createRedirect_AddToolboxLink( &$tpl ) {
-   global $wgRequest;
-
-   // 1. Determine whether to actually add the link at all.
-   // There are certain cases, e.g. in the edit dialog, in a special page,
-   // where it's inappropriate for the link to appear.
-   // 2. Check the title. Is it a "Special:" page? Don't display the link.
-   $action = $wgRequest->getText( 'action', 'view' );
-   $title = $tpl->getSkin()->getTitle();
-
-   if( $action != 'view' && $action != 'purge' && !$title->isSpecialPage() 
) {
-   return true;
-   }
-
-   // 3. Add the link!
-   $href = SpecialPage::getTitleFor( 'CreateRedirect', 
$title->getPrefixedText() )->getLocalURL();
-   echo Html::rawElement( 'li', null, Html::element( 'a', array( 'href' => 
$href ), wfMessage( 'createredirect' )->text() ) );
-
-   return true;
+if ( function_exists( 'wfLoadExtension' ) ) {
+   wfLoadExtension( 'CreateRedirect' );
+   $wgMessageDirs['CreateRedirect'] = __DIR__ . '/i18n';
+   wfWarn(
+   'Deprecated PHP entry point used for CreateRedirect extension. 
' .
+   'Please use wfLoadExtension instead, ' .
+   'see https://www.mediawiki.org/wiki/Extension_registration for 
more details.'
+   );
+} else {
+   die( 'This version of the CreateRedirect extension requires MediaWiki 
1.29+' );
 }
diff --git a/extension.json b/extension.json
new file mode 100644
index 000..1ee955a
-

[MediaWiki-commits] [Gerrit] mediawiki...GraphViz[master]: Convert GraphViz to use extension registration

2017-08-24 Thread Reception123 (Code Review)
Reception123 has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373735 )

Change subject: Convert GraphViz to use extension registration
..

Convert GraphViz to use extension registration

Bug: T173209
Change-Id: I8c8a47b13ca79be5789f796fe77e2b4fff28cb03
---
M GraphViz.php
M GraphViz_body.php
A extension.json
3 files changed, 111 insertions(+), 93 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/GraphViz 
refs/changes/35/373735/1

diff --git a/GraphViz.php b/GraphViz.php
index 77acb12..7e1b59d 100644
--- a/GraphViz.php
+++ b/GraphViz.php
@@ -30,97 +30,14 @@
  * @file
  * @ingroup Extensions
  */
-
-define( 'GraphViz_VERSION', '2.1.0' );
-
-/**
- * The GraphViz settings class.
- */
-class GraphVizSettings {
-   /**
-* dot executable path
-* Windows Default: C:/Programme/ATT/Graphviz/bin/
-* Other Platform : /usr/local/bin/dot
-*
-* '/' will be converted to '\\' later on, so feel free how to write 
your path C:/ or C:\\
-*
-* @var string $execPath
-*/
-   public $execPath;
-
-   /**
-* mscgen executable path
-* Commonly '/usr/bin/', '/usr/local/bin/' or (if set) '$DOT_PATH/'.
-*
-* '/' will be converted to '\\' later on, so feel free how to write 
your path C:/ or C:\\
-*
-* @var string $mscgenPath
-*/
-   public $mscgenPath;
-
-   /**
-* default image type for the output of dot or mscgen
-* The "default default" is png.
-*
-* @var string $defaultImageType
-*/
-   public $defaultImageType;
-
-   /**
-* Whether or not to automatically create category pages for images 
created by this extension.
-* yes|no (case insensitive). The default is no.
-*
-* @var string $createCategoryPages
-*/
-   public $createCategoryPages;
-
-   /**
-* Constructor for setting configuration variable defaults.
-*/
-   public function __construct() {
-   // Set execution path
-   if ( stristr( PHP_OS, 'WIN' ) && !stristr( PHP_OS, 'Darwin' ) ) 
{
-   $this->execPath = 'C:/Program Files/Graphviz/bin/';
-   } else {
-   $this->execPath = '/usr/bin/';
-   }
-
-   $this->mscgenPath = '';
-   $this->defaultImageType = 'png';
-   $this->createCategoryPages = 'no';
-   }
-};
-
-if ( defined( 'MEDIAWIKI' ) ) {
-   $GLOBALS['wgGraphVizSettings'] = new GraphVizSettings();
-
-   // self executing anonymous function to prevent global scope assumptions
-   call_user_func( function () {
-   $dir = __DIR__ . '/';
-
-   $GLOBALS['wgMessagesDirs']['GraphViz'] = $dir . 'i18n';
-   $GLOBALS['wgAutoloadClasses']['GraphViz'] = $dir . 
"GraphViz_body.php";
-   $GLOBALS['wgAutoloadClasses']['GraphRenderParms'] = $dir . 
"GraphRenderParms.php";
-   $GLOBALS['wgAutoloadClasses']['UploadLocalFile'] = $dir . 
"UploadLocalFile.php";
-   $GLOBALS['wgAutoloadClasses']['UploadFromLocalFile'] = $dir . 
"UploadLocalFile.php";
-   $GLOBALS['wgHooks']['ParserFirstCallInit'][] = 
'GraphViz::onParserInit';
-   $GLOBALS['wgHooks']['ArticleDeleteComplete'][] = 
'GraphViz::onArticleDeleteComplete';
-   $GLOBALS['wgHooks']['UnitTestsList'][] = 
'GraphViz::onUnitTestsList';
-   $GLOBALS['wgHooks']['PageContentSave'][] = 
'GraphViz::onPageContentSave';
-   $GLOBALS['wgHooks']['RejectParserCacheValue'][] = 
'GraphViz::onRejectParserCacheValue';
-   $GLOBALS['wgExtensionCredits']['parserhook'][] = [
-   'name' => 'Graphviz',
-   'path' => __FILE__,
-   'version' => GraphViz_VERSION,
-   'author' => [
-   '[http://wickle.com CoffMan]',
-   '[mailto://arno.ven...@gmail.com 
MasterOfDesaster]',
-   '[http://hummel-universe.net Thomas Hummel]',
-   '[mailto://welt...@gmail.com Keith Welter]'
-   ],
-   'url' => 
'https://www.mediawiki.org/wiki/Extension:GraphViz',
-   'descriptionmsg' => 'graphviz-desc',
-   'license-name' => 'GPL-2.0+'
-   ];
-   } );
+if ( function_exists( 'wfLoadExtension' ) ) {
+   wfLoadExtension( 'GraphViz' );
+   $wgMessageDirs['GraphViz'] = __DIR__ . '/i18n';
+   wfWarn(
+   'Deprecated PHP entry point used for GraphViz extension. ' .
+   'Please use wfLoadExtension instead, ' .
+   'see https://www.mediawiki.org/wiki/Extension_registration for 
more details.'
+   );
+} else {
+

[MediaWiki-commits] [Gerrit] operations/puppet[production]: mariadb: Update db2058 socket location

2017-08-24 Thread Marostegui (Code Review)
Marostegui has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373734 )

Change subject: mariadb: Update db2058 socket location
..


mariadb: Update db2058 socket location

Bug: T148507
Change-Id: I1980a0b292cefde7d5fc0dcdb322427601fd6efb
---
M hieradata/hosts/db2058.yaml
1 file changed, 0 insertions(+), 1 deletion(-)

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



diff --git a/hieradata/hosts/db2058.yaml b/hieradata/hosts/db2058.yaml
index 958da0b..7db8adb 100644
--- a/hieradata/hosts/db2058.yaml
+++ b/hieradata/hosts/db2058.yaml
@@ -1,2 +1 @@
 mariadb::shard: 's4'
-mariadb::socket: '/tmp/mysql.sock'

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1980a0b292cefde7d5fc0dcdb322427601fd6efb
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Marostegui 
Gerrit-Reviewer: Giuseppe Lavagetto 
Gerrit-Reviewer: Jcrespo 
Gerrit-Reviewer: Marostegui 
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]: mariadb: Repool es2013 after maintenance

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373524 )

Change subject: mariadb: Repool es2013 after maintenance
..


mariadb: Repool es2013 after maintenance

Bug: T172265
Change-Id: Ia4eb119da87810894eb917103db23c72912606e7
---
M wmf-config/db-codfw.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index 5421e9b..5aa7ffc 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -16,7 +16,7 @@
 $wmgOldExtTemplate = [
'10.192.16.171' => 1, # es2011, B1 11TB 128GB
'10.192.32.129' => 1, # es2012, C1 11TB 128GB
-   # '10.192.48.40'  => 1, # es2013, D1 11TB 128GB # BBU issues T172265
+   '10.192.48.40'  => 1, # es2013, D1 11TB 128GB
 ];
 
 $wgLBFactoryConf = [

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia4eb119da87810894eb917103db23c72912606e7
Gerrit-PatchSet: 3
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Jcrespo 
Gerrit-Reviewer: Florianschmidtwelzow 
Gerrit-Reviewer: Jcrespo 
Gerrit-Reviewer: Marostegui 
Gerrit-Reviewer: Urbanecm 
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]: mariadb: Adding rack allocations, some formatting fixes, rea...

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/371444 )

Change subject: mariadb: Adding rack allocations, some formatting fixes, 
read-only
..


mariadb: Adding rack allocations, some formatting fixes, read-only

Adding row and rack numbers to all hosts, not only the metadata ones.

Codfw is currently a passive datacenter and it should not be publicly
reachable. Removing references to a failover. Not giving explicitly
a way to report the issue because it traditionally puts the irc network
or the phabricator site down, but at least not referencing the dc
failover. Also, these should not be shown right now to anyone but
internal monitoring.

This is scheduled to be moved to etcd soon, so not wasting much time
on it.

Also apparently, db1051 is in B3, according to racktables.

Bug: T172459
Change-Id: I9eee9a9cebbeb94072361dff73c72e7c8759ab27
---
M wmf-config/db-codfw.php
M wmf-config/db-eqiad.php
2 files changed, 153 insertions(+), 127 deletions(-)

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



diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index 0ec51e5..5421e9b 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -8,15 +8,15 @@
 # $wgReadOnly = "Wikimedia Sites are currently read-only during maintenance, 
please try again soon.";
 
 $wmgParserCacheDBs = [
-   '10.64.0.12'   => '10.192.16.170', # pc2004
-   '10.64.32.72'  => '10.192.32.128', # pc2005
-   '10.64.48.128' => '10.192.48.39',  # pc2006
+   '10.64.0.12'   => '10.192.16.170', # pc2004, B5 2.4TB 256GB
+   '10.64.32.72'  => '10.192.32.128', # pc2005, C5 2.4TB 256GB
+   '10.64.48.128' => '10.192.48.39',  # pc2006, D5 2.4TB 256GB
 ];
 
 $wmgOldExtTemplate = [
-   '10.192.16.171' => 1, # es2011
-   '10.192.32.129' => 1, # es2012
-   # '10.192.48.40'  => 1, # es2013 # BBU issues T172265
+   '10.192.16.171' => 1, # es2011, B1 11TB 128GB
+   '10.192.32.129' => 1, # es2012, C1 11TB 128GB
+   # '10.192.48.40'  => 1, # es2013, D1 11TB 128GB # BBU issues T172265
 ];
 
 $wgLBFactoryConf = [
@@ -24,52 +24,60 @@
 'class' => 'LBFactoryMulti',
 
 'sectionsByDB' => [
-   'enwiki' => 's1',
+   # s1: enwiki
+   'enwiki'   => 's1',
 
-   # New master
-   'bgwiki' => 's2',
+   # s2: large wikis
+   'bgwiki'   => 's2',
'bgwiktionary' => 's2',
-   'cswiki' => 's2',
-   'enwikiquote' => 's2',
+   'cswiki'   => 's2',
+   'enwikiquote'  => 's2',
'enwiktionary' => 's2',
-   'eowiki' => 's2',
-   'fiwiki' => 's2',
-   'idwiki' => 's2',
-   'itwiki' => 's2',
-   'nlwiki' => 's2',
-   'nowiki' => 's2',
-   'plwiki' => 's2',
-   'ptwiki' => 's2',
-   'svwiki' => 's2',
-   'thwiki' => 's2',
-   'trwiki' => 's2',
-   'zhwiki' => 's2',
+   'eowiki'   => 's2',
+   'fiwiki'   => 's2',
+   'idwiki'   => 's2',
+   'itwiki'   => 's2',
+   'nlwiki'   => 's2',
+   'nowiki'   => 's2',
+   'plwiki'   => 's2',
+   'ptwiki'   => 's2',
+   'svwiki'   => 's2',
+   'thwiki'   => 's2',
+   'trwiki'   => 's2',
+   'zhwiki'   => 's2',
 
-   'commonswiki' => 's4',
+   # s3 (default)
 
-   'dewiki' => 's5',
+   # s4: commons
+   'commonswiki'  => 's4',
+
+   # s5: dewiki and wikidata
+   'dewiki'   => 's5',
'wikidatawiki' => 's5',
 
-   'frwiki' => 's6',
-   'jawiki' => 's6',
-   'ruwiki' => 's6',
+   # s6: large wikis
+   'frwiki'   => 's6',
+   'jawiki'   => 's6',
+   'ruwiki'   => 's6',
 
-   'eswiki' => 's7',
-   'huwiki' => 's7',
-   'hewiki' => 's7',
-   'ukwiki' => 's7',
+   # s7: large wikis, centralauth
+   'eswiki'   => 's7',
+   'huwiki'   => 's7',
+   'hewiki'   => 's7',
+   'ukwiki'   => 's7',
'frwiktionary' => 's7',
-   'metawiki' => 's7',
-   'arwiki' => 's7',
-   'centralauth' => 's7',
-   'cawiki' => 's7',
-   'viwiki' => 's7',
-   'fawiki' => 's7',
-   'rowiki' => 's7',
-   'kowiki' => 's7',
+   'metawiki' => 's7',
+   'arwiki'   => 's7',
+   'centralauth'  => 's7',
+   'cawiki'   => 's7',
+   'viwiki'   => 's7',
+   'fawiki'   => 's7',
+   'rowiki'   => 's7',
+   'kowiki'   => 's7',
 
-   'labswiki' => 'silver',
-   'labtestwiki' => 'labtestweb2001',
+   # labs-related wikis
+   'labswiki' => 'silver',
+   'labtestwiki'  => 'labtestweb2001',
 ],
 
 # Load lists
@@ -158,10 +166,10 @@
'db2077' => 400, # C1 3.3TB 512GB
],
'silver' => [
-   'silver' => 100,   # I have no idea if this is right
+  

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: db-codfw.php: Depool db2058 for a MariaDB upgrade

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373732 )

Change subject: db-codfw.php: Depool db2058 for a MariaDB upgrade
..


db-codfw.php: Depool db2058 for a MariaDB upgrade

Upgrade its version to 10.0.32

Bug: T168661
Change-Id: I920183c7bbd9a3e91bd0714c300e13d5e2e589c9
---
M wmf-config/db-codfw.php
1 file changed, 4 insertions(+), 4 deletions(-)

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



diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index becd43f..0ec51e5 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -126,9 +126,9 @@
# 'db2019' => 0, # B6 2.9TB  96GB, old master
'db2037' => 50,  # C6 2.9TB 160GB, rc, log
'db2044' => 50,  # C6 2.9TB 160GB, rc, log
-   'db2058' => 50,  # D6 3.3TB 160GB, dump (inactive), vslow
+   # 'db2058' => 50,  # D6 3.3TB 160GB, dump (inactive), vslow 
#T168661
'db2065' => 200, # D6 3.3TB 160GB, api
-   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB
+   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB 
#temporary vslow
],
's5' => [
'db2023' => 0,   # B6 2.9TB  96GB, master
@@ -339,10 +339,10 @@
'db2044' => 1,
],
'dump' => [
-   'db2058' => 1,
+   'db2073' => 1,
],
'vslow' => [
-   'db2058' => 1,
+   'db2073' => 1,
],
'api' => [
'db2065' => 1,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I920183c7bbd9a3e91bd0714c300e13d5e2e589c9
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Marostegui 
Gerrit-Reviewer: Jcrespo 
Gerrit-Reviewer: Marostegui 
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]: mariadb: Update db2058 socket location

2017-08-24 Thread Marostegui (Code Review)
Marostegui has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373734 )

Change subject: mariadb: Update db2058 socket location
..

mariadb: Update db2058 socket location

Bug: T148507
Change-Id: I1980a0b292cefde7d5fc0dcdb322427601fd6efb
---
M hieradata/hosts/db2058.yaml
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/34/373734/1

diff --git a/hieradata/hosts/db2058.yaml b/hieradata/hosts/db2058.yaml
index 958da0b..7db8adb 100644
--- a/hieradata/hosts/db2058.yaml
+++ b/hieradata/hosts/db2058.yaml
@@ -1,2 +1 @@
 mariadb::shard: 's4'
-mariadb::socket: '/tmp/mysql.sock'

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1980a0b292cefde7d5fc0dcdb322427601fd6efb
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Marostegui 

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Remove ffmpeg2theora from package list

2017-08-24 Thread Muehlenhoff (Code Review)
Muehlenhoff has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373733 )

Change subject: Remove ffmpeg2theora from package list
..

Remove ffmpeg2theora from package list

Theora support has been disabled, so we can remove the package as well.
Also drop the explicit configuration for libtheora0, it's still pulled
in as a dependency of ffmpeg, but no need to specify a particular package
name.

Bug: T172445

Change-Id: Ibce4521807708232b9bc0acb9a20f7a9b066bc81
---
M modules/mediawiki/manifests/packages/multimedia.pp
1 file changed, 0 insertions(+), 2 deletions(-)


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

diff --git a/modules/mediawiki/manifests/packages/multimedia.pp 
b/modules/mediawiki/manifests/packages/multimedia.pp
index 4638244..4b76785 100644
--- a/modules/mediawiki/manifests/packages/multimedia.pp
+++ b/modules/mediawiki/manifests/packages/multimedia.pp
@@ -5,13 +5,11 @@
 class mediawiki::packages::multimedia {
 package { [
 'ffmpeg',
-'ffmpeg2theora',
 'fontconfig-config',
 'ghostscript',
 'libimage-exiftool-perl',
 'libjpeg-turbo-progs',
 'libogg0',
-'libtheora0',
 'libvips-tools',
 'libvorbisenc2',
 'netpbm',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ibce4521807708232b9bc0acb9a20f7a9b066bc81
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Muehlenhoff 

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


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: db-codfw.php: Depool db2058 for a MariaDB upgrade

2017-08-24 Thread Marostegui (Code Review)
Marostegui has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373732 )

Change subject: db-codfw.php: Depool db2058 for a MariaDB upgrade
..

db-codfw.php: Depool db2058 for a MariaDB upgrade

Upgrade its version to 10.0.32

Bug: T168661
Change-Id: I920183c7bbd9a3e91bd0714c300e13d5e2e589c9
---
M wmf-config/db-codfw.php
1 file changed, 4 insertions(+), 4 deletions(-)


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

diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index becd43f..0ec51e5 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -126,9 +126,9 @@
# 'db2019' => 0, # B6 2.9TB  96GB, old master
'db2037' => 50,  # C6 2.9TB 160GB, rc, log
'db2044' => 50,  # C6 2.9TB 160GB, rc, log
-   'db2058' => 50,  # D6 3.3TB 160GB, dump (inactive), vslow
+   # 'db2058' => 50,  # D6 3.3TB 160GB, dump (inactive), vslow 
#T168661
'db2065' => 200, # D6 3.3TB 160GB, api
-   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB
+   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB 
#temporary vslow
],
's5' => [
'db2023' => 0,   # B6 2.9TB  96GB, master
@@ -339,10 +339,10 @@
'db2044' => 1,
],
'dump' => [
-   'db2058' => 1,
+   'db2073' => 1,
],
'vslow' => [
-   'db2058' => 1,
+   'db2073' => 1,
],
'api' => [
'db2065' => 1,

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

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

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Remove access for psinger

2017-08-24 Thread Muehlenhoff (Code Review)
Muehlenhoff has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373731 )

Change subject: Remove access for psinger
..


Remove access for psinger

MOU is not being renewed.

Change-Id: I3473f92907239fb3a4d8e01d09cb75b570f7f005
---
M modules/admin/data/data.yaml
1 file changed, 5 insertions(+), 8 deletions(-)

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



diff --git a/modules/admin/data/data.yaml b/modules/admin/data/data.yaml
index c8460d5..fa23da1 100644
--- a/modules/admin/data/data.yaml
+++ b/modules/admin/data/data.yaml
@@ -7,7 +7,8 @@
   johnflewis, marc, jkrauska, akumar, mnoushad, spage, tnegrin, 
msyed, kleduc,
   manybubbles, haithams, jzerebecki, ashwinpp, robla, asherman,
   laner, declerambaul, srijan, junikowski, krenair, springle, 
jhobs, vbaranetsky,
-  yurik, bsimmers, bcohn, hjiang, tomasz, csteipp, zareen, 
jgirault, ellery]
+  yurik, bsimmers, bcohn, hjiang, tomasz, csteipp, zareen, 
jgirault, ellery,
+  psinger]
   absent_ldap:
 description: meta group for absented users which had privileged LDAP 
access in the past
 members: [siddharth11, adavenport]
@@ -240,7 +241,7 @@
   dcausse, bd808, tjones, mobrovac, jdrewniak, ejegg, jdcc, ori,
   bmansurov, atgomez, amire80, kartik, pcoombe, foks, mpany, 
jsamra,
   jdlrobson, chelsyx, ovasileva, mtizzoni, panisson, paolotti, 
ciro,
-  psinger, flemmerich, mkroetzsch, akrausetud, filippo, nschaaf, 
pmiazga, faidon,
+  flemmerich, mkroetzsch, akrausetud, filippo, nschaaf, pmiazga, 
faidon,
   piccardi, fdans, eevans, anomie, demon, ladsgroup, musikanimal, 
joewalsh,
   kaldari, goransm, ema, dworley, ironholds, diego]
   analytics-admins:
@@ -2276,16 +2277,12 @@
 expiry_date: 2018-01-26
 expiry_contact: da...@wikimedia.org, dandree...@wikimedia.org
   psinger:
-ensure: present
+ensure: absent
 gid: 500
 name: psinger
 realname: Philipp Singer
-ssh_keys:
-  - ssh-rsa 
B3NzaC1yc2EDAQABAAABAQDoA+dwV71A3HjSLT1LjxjtXv0fb4/ycQGhqIdqPtulshi5/PZlG3tncFSQpwcOtgbwbRIMUnxhezHdQSUQONTOD02lKOk93dVma4TN6FAkb/ZIK6c9eRU/TQwy3OCXqj6O1CQohVj60kRKBvTKMUpw/oRM9lgTT3USc6UE3Uy8/0eHPiR37nhrA3E5uZ9KgEyIY6z+WCT6inghxEFE+uDFowY/8wwd2Rq4Nsa2F88I7488G1lmZpkye/BtbNbjt3QtLt9Qk8yfJqj8Rpniroxaj1Z+MNvVAXJFK+c4ziwjjAvNHcN9ngsJCURIOlOKgpLahNYofv8OmQ2PpQwGHDj/
 psinger@gobbo
+ssh_keys: []
 uid: 15296
-email: philipp.sin...@gesis.org
-expiry_date: 2017-08-24
-expiry_contact: le...@wikimedia.org
   flemmerich:
 ensure: present
 gid: 500

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3473f92907239fb3a4d8e01d09cb75b570f7f005
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Muehlenhoff 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: Muehlenhoff 
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 access for psinger

2017-08-24 Thread Muehlenhoff (Code Review)
Muehlenhoff has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373731 )

Change subject: Remove access for psinger
..

Remove access for psinger

MOU is not being renewed.

Change-Id: I3473f92907239fb3a4d8e01d09cb75b570f7f005
---
M modules/admin/data/data.yaml
1 file changed, 5 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/31/373731/1

diff --git a/modules/admin/data/data.yaml b/modules/admin/data/data.yaml
index c8460d5..fa23da1 100644
--- a/modules/admin/data/data.yaml
+++ b/modules/admin/data/data.yaml
@@ -7,7 +7,8 @@
   johnflewis, marc, jkrauska, akumar, mnoushad, spage, tnegrin, 
msyed, kleduc,
   manybubbles, haithams, jzerebecki, ashwinpp, robla, asherman,
   laner, declerambaul, srijan, junikowski, krenair, springle, 
jhobs, vbaranetsky,
-  yurik, bsimmers, bcohn, hjiang, tomasz, csteipp, zareen, 
jgirault, ellery]
+  yurik, bsimmers, bcohn, hjiang, tomasz, csteipp, zareen, 
jgirault, ellery,
+  psinger]
   absent_ldap:
 description: meta group for absented users which had privileged LDAP 
access in the past
 members: [siddharth11, adavenport]
@@ -240,7 +241,7 @@
   dcausse, bd808, tjones, mobrovac, jdrewniak, ejegg, jdcc, ori,
   bmansurov, atgomez, amire80, kartik, pcoombe, foks, mpany, 
jsamra,
   jdlrobson, chelsyx, ovasileva, mtizzoni, panisson, paolotti, 
ciro,
-  psinger, flemmerich, mkroetzsch, akrausetud, filippo, nschaaf, 
pmiazga, faidon,
+  flemmerich, mkroetzsch, akrausetud, filippo, nschaaf, pmiazga, 
faidon,
   piccardi, fdans, eevans, anomie, demon, ladsgroup, musikanimal, 
joewalsh,
   kaldari, goransm, ema, dworley, ironholds, diego]
   analytics-admins:
@@ -2276,16 +2277,12 @@
 expiry_date: 2018-01-26
 expiry_contact: da...@wikimedia.org, dandree...@wikimedia.org
   psinger:
-ensure: present
+ensure: absent
 gid: 500
 name: psinger
 realname: Philipp Singer
-ssh_keys:
-  - ssh-rsa 
B3NzaC1yc2EDAQABAAABAQDoA+dwV71A3HjSLT1LjxjtXv0fb4/ycQGhqIdqPtulshi5/PZlG3tncFSQpwcOtgbwbRIMUnxhezHdQSUQONTOD02lKOk93dVma4TN6FAkb/ZIK6c9eRU/TQwy3OCXqj6O1CQohVj60kRKBvTKMUpw/oRM9lgTT3USc6UE3Uy8/0eHPiR37nhrA3E5uZ9KgEyIY6z+WCT6inghxEFE+uDFowY/8wwd2Rq4Nsa2F88I7488G1lmZpkye/BtbNbjt3QtLt9Qk8yfJqj8Rpniroxaj1Z+MNvVAXJFK+c4ziwjjAvNHcN9ngsJCURIOlOKgpLahNYofv8OmQ2PpQwGHDj/
 psinger@gobbo
+ssh_keys: []
 uid: 15296
-email: philipp.sin...@gesis.org
-expiry_date: 2017-08-24
-expiry_contact: le...@wikimedia.org
   flemmerich:
 ensure: present
 gid: 500

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3473f92907239fb3a4d8e01d09cb75b570f7f005
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Muehlenhoff 

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


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: db-codfw.php: Repool db2065

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373730 )

Change subject: db-codfw.php: Repool db2065
..


db-codfw.php: Repool db2065

db2065 has been upgrade, so repool it

Bug: T168661
Change-Id: I2de6c5c2e40cb34d61899b314ea0950ee6aa19bd
---
M wmf-config/db-codfw.php
1 file changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index 91203a6..becd43f 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -127,8 +127,8 @@
'db2037' => 50,  # C6 2.9TB 160GB, rc, log
'db2044' => 50,  # C6 2.9TB 160GB, rc, log
'db2058' => 50,  # D6 3.3TB 160GB, dump (inactive), vslow
-   # 'db2065' => 200, # D6 3.3TB 160GB, api # #T168661
-   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB # 
temporary API
+   'db2065' => 200, # D6 3.3TB 160GB, api
+   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB
],
's5' => [
'db2023' => 0,   # B6 2.9TB  96GB, master
@@ -345,7 +345,7 @@
'db2058' => 1,
],
'api' => [
-   'db2073' => 1,
+   'db2065' => 1,
],
],
's5' => [

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2de6c5c2e40cb34d61899b314ea0950ee6aa19bd
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Marostegui 
Gerrit-Reviewer: Jcrespo 
Gerrit-Reviewer: Marostegui 
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]: db-codfw.php: Repool db2065

2017-08-24 Thread Marostegui (Code Review)
Marostegui has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373730 )

Change subject: db-codfw.php: Repool db2065
..

db-codfw.php: Repool db2065

db2065 has been upgrade, so repool it

Bug: T168661
Change-Id: I2de6c5c2e40cb34d61899b314ea0950ee6aa19bd
---
M wmf-config/db-codfw.php
1 file changed, 3 insertions(+), 3 deletions(-)


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

diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index 91203a6..becd43f 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -127,8 +127,8 @@
'db2037' => 50,  # C6 2.9TB 160GB, rc, log
'db2044' => 50,  # C6 2.9TB 160GB, rc, log
'db2058' => 50,  # D6 3.3TB 160GB, dump (inactive), vslow
-   # 'db2065' => 200, # D6 3.3TB 160GB, api # #T168661
-   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB # 
temporary API
+   'db2065' => 200, # D6 3.3TB 160GB, api
+   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB
],
's5' => [
'db2023' => 0,   # B6 2.9TB  96GB, master
@@ -345,7 +345,7 @@
'db2058' => 1,
],
'api' => [
-   'db2073' => 1,
+   'db2065' => 1,
],
],
's5' => [

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

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

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: mariadb: Update socket location for db2065

2017-08-24 Thread Marostegui (Code Review)
Marostegui has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373729 )

Change subject: mariadb: Update socket location for db2065
..


mariadb: Update socket location for db2065

As db2065 needs to be stopped, take the opportunity to update its socket path

Bug: T148507
Change-Id: I9447bb0e175e1f96337a52c4c3f3ae0f03664c79
---
M hieradata/hosts/db2065.yaml
1 file changed, 0 insertions(+), 1 deletion(-)

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



diff --git a/hieradata/hosts/db2065.yaml b/hieradata/hosts/db2065.yaml
index 958da0b..7db8adb 100644
--- a/hieradata/hosts/db2065.yaml
+++ b/hieradata/hosts/db2065.yaml
@@ -1,2 +1 @@
 mariadb::shard: 's4'
-mariadb::socket: '/tmp/mysql.sock'

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I9447bb0e175e1f96337a52c4c3f3ae0f03664c79
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Marostegui 
Gerrit-Reviewer: Giuseppe Lavagetto 
Gerrit-Reviewer: Jcrespo 
Gerrit-Reviewer: Marostegui 
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]: mariadb: Update socket location

2017-08-24 Thread Marostegui (Code Review)
Marostegui has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373729 )

Change subject: mariadb: Update socket location
..

mariadb: Update socket location

As db2065 needs to be stopped, take the opportunity to update its socket path

Bug: T148507
Change-Id: I9447bb0e175e1f96337a52c4c3f3ae0f03664c79
---
M hieradata/hosts/db2065.yaml
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/29/373729/1

diff --git a/hieradata/hosts/db2065.yaml b/hieradata/hosts/db2065.yaml
index 958da0b..7db8adb 100644
--- a/hieradata/hosts/db2065.yaml
+++ b/hieradata/hosts/db2065.yaml
@@ -1,2 +1 @@
 mariadb::shard: 's4'
-mariadb::socket: '/tmp/mysql.sock'

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9447bb0e175e1f96337a52c4c3f3ae0f03664c79
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Marostegui 

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


[MediaWiki-commits] [Gerrit] wikidata...rdf[master]: remove duplicate key in RWStore props

2017-08-24 Thread Yurik (Code Review)
Yurik has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373728 )

Change subject: remove duplicate key in RWStore props
..

remove duplicate key in RWStore props

Change-Id: I4f5a581a497f846e2addb492dcafb5a19e0ef83e
---
M dist/src/script/RWStore.properties
1 file changed, 0 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikidata/query/rdf 
refs/changes/28/373728/1

diff --git a/dist/src/script/RWStore.properties 
b/dist/src/script/RWStore.properties
index 2a44870..c76cde1 100644
--- a/dist/src/script/RWStore.properties
+++ b/dist/src/script/RWStore.properties
@@ -2,8 +2,6 @@
 com.bigdata.journal.AbstractJournal.file=wikidata.jnl
 com.bigdata.journal.AbstractJournal.bufferMode=DiskRW
 com.bigdata.service.AbstractTransactionService.minReleaseAge=1
-com.bigdata.btree.writeRetentionQueue.capacity=4000
-com.bigdata.btree.BTree.branchingFactor=128
 
 com.bigdata.rdf.store.AbstractTripleStore.quads=false
 com.bigdata.rdf.store.AbstractTripleStore.statementIdentifiers=false

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4f5a581a497f846e2addb492dcafb5a19e0ef83e
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/rdf
Gerrit-Branch: master
Gerrit-Owner: Yurik 

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


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: db-codfw.php: Depool db2065

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373727 )

Change subject: db-codfw.php: Depool db2065
..


db-codfw.php: Depool db2065

Going to upgrade db2065 to 10.0.32

Bug: T168661
Change-Id: Icf6489b060cf64a05f062b7385cceec43acdb114
---
M wmf-config/db-codfw.php
1 file changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index 6409e4c..91203a6 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -127,8 +127,8 @@
'db2037' => 50,  # C6 2.9TB 160GB, rc, log
'db2044' => 50,  # C6 2.9TB 160GB, rc, log
'db2058' => 50,  # D6 3.3TB 160GB, dump (inactive), vslow
-   'db2065' => 200, # D6 3.3TB 160GB, api
-   # 'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB #T168661
+   # 'db2065' => 200, # D6 3.3TB 160GB, api # #T168661
+   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB # 
temporary API
],
's5' => [
'db2023' => 0,   # B6 2.9TB  96GB, master
@@ -345,7 +345,7 @@
'db2058' => 1,
],
'api' => [
-   'db2065' => 1,
+   'db2073' => 1,
],
],
's5' => [

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Icf6489b060cf64a05f062b7385cceec43acdb114
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Marostegui 
Gerrit-Reviewer: Florianschmidtwelzow 
Gerrit-Reviewer: Jcrespo 
Gerrit-Reviewer: Marostegui 
Gerrit-Reviewer: Urbanecm 
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]: db-codfw.php: Depool db2065

2017-08-24 Thread Marostegui (Code Review)
Marostegui has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373727 )

Change subject: db-codfw.php: Depool db2065
..

db-codfw.php: Depool db2065

Going to upgrade db2065 to 10.0.32

Bug: T168661
Change-Id: Icf6489b060cf64a05f062b7385cceec43acdb114
---
M wmf-config/db-codfw.php
1 file changed, 3 insertions(+), 3 deletions(-)


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

diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index 6409e4c..91203a6 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -127,8 +127,8 @@
'db2037' => 50,  # C6 2.9TB 160GB, rc, log
'db2044' => 50,  # C6 2.9TB 160GB, rc, log
'db2058' => 50,  # D6 3.3TB 160GB, dump (inactive), vslow
-   'db2065' => 200, # D6 3.3TB 160GB, api
-   # 'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB #T168661
+   # 'db2065' => 200, # D6 3.3TB 160GB, api # #T168661
+   'db2073' => 400, # C6 3.3TB 512GB # Compressed InnoDB # 
temporary API
],
's5' => [
'db2023' => 0,   # B6 2.9TB  96GB, master
@@ -345,7 +345,7 @@
'db2058' => 1,
],
'api' => [
-   'db2065' => 1,
+   'db2073' => 1,
],
],
's5' => [

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

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

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: Deprecation of 3DES: bump to 8%

2017-08-24 Thread BBlack (Code Review)
BBlack has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373726 )

Change subject: Deprecation of 3DES: bump to 8%
..


Deprecation of 3DES: bump to 8%

Bug: T163251
Change-Id: I6c03990d3d03ef780038c21f42e9880b63b160b4
---
M modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb 
b/modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb
index b0483c4..3d8d097 100644
--- a/modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb
+++ b/modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb
@@ -297,7 +297,7 @@
<%- if scope.function_hiera(['cache::cluster']) == "text" -%>
   && req.url ~ "^/wiki/" && req.url !~ ":"
<%- end -%>
-  && std.random(0,100) < 5.0)) {
+  && std.random(0,100) < 8.0)) {
return (synth(418, "Browser Connection Security Warning"));
}
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6c03990d3d03ef780038c21f42e9880b63b160b4
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: BBlack 
Gerrit-Reviewer: BBlack 
Gerrit-Reviewer: Ema 
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]: 3DES Deprecation: bump to 8%

2017-08-24 Thread BBlack (Code Review)
BBlack has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373726 )

Change subject: 3DES Deprecation: bump to 8%
..

3DES Deprecation: bump to 8%

Bug: T163251
Change-Id: I6c03990d3d03ef780038c21f42e9880b63b160b4
---
M modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/26/373726/1

diff --git a/modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb 
b/modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb
index b0483c4..3d8d097 100644
--- a/modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb
+++ b/modules/varnish/templates/vcl/wikimedia-frontend.vcl.erb
@@ -297,7 +297,7 @@
<%- if scope.function_hiera(['cache::cluster']) == "text" -%>
   && req.url ~ "^/wiki/" && req.url !~ ":"
<%- end -%>
-  && std.random(0,100) < 5.0)) {
+  && std.random(0,100) < 8.0)) {
return (synth(418, "Browser Connection Security Warning"));
}
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6c03990d3d03ef780038c21f42e9880b63b160b4
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: BBlack 

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


[MediaWiki-commits] [Gerrit] wikidata...rdf[master]: allow unit tests to override store props

2017-08-24 Thread Yurik (Code Review)
Yurik has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373725 )

Change subject: allow unit tests to override store props
..

allow unit tests to override store props

Change-Id: I21219c91bf475b6721a5254f79f91c23b1c7992c
---
M 
blazegraph/src/test/java/org/wikidata/query/rdf/blazegraph/AbstractRandomizedBlazegraphStorageTestCase.java
1 file changed, 13 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikidata/query/rdf 
refs/changes/25/373725/1

diff --git 
a/blazegraph/src/test/java/org/wikidata/query/rdf/blazegraph/AbstractRandomizedBlazegraphStorageTestCase.java
 
b/blazegraph/src/test/java/org/wikidata/query/rdf/blazegraph/AbstractRandomizedBlazegraphStorageTestCase.java
index 230d7f4..77d01f6 100644
--- 
a/blazegraph/src/test/java/org/wikidata/query/rdf/blazegraph/AbstractRandomizedBlazegraphStorageTestCase.java
+++ 
b/blazegraph/src/test/java/org/wikidata/query/rdf/blazegraph/AbstractRandomizedBlazegraphStorageTestCase.java
@@ -75,7 +75,17 @@
 if (store != null) {
 return store;
 }
-Properties properties = new Properties();
+store = new TempTripleStore(temporaryStore(), initStoreProperties(new 
Properties()), null);
+return store;
+}
+
+/**
+ * Initialize store properties.
+ * Allows property override by either updating properties object, or 
returning a new one.
+ * @param properties Properties that have been set so far
+ * @return Properties object after updating it
+ */
+protected Properties initStoreProperties(Properties properties) {
 
properties.setProperty("com.bigdata.rdf.store.AbstractTripleStore.vocabularyClass",
 WikibaseVocabulary.VOCABULARY_CLASS.getName());
 
properties.setProperty("com.bigdata.rdf.store.AbstractTripleStore.inlineURIFactory",
@@ -94,8 +104,8 @@
 + "{ \"valueType\": \"DOUBLE\", \"multiplier\": 
\"10\", \"serviceMapping\": \"LATITUDE\" }, "
 + "{ \"valueType\": \"LONG\", 
\"multiplier\":\"1\",\"minValue\":\"0\", \"serviceMapping\": \"COORD_SYSTEM\" } 
"
 + "]}}");
-store = new TempTripleStore(temporaryStore(), properties, null);
-return store;
+
+return properties;
 }
 
 /**

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I21219c91bf475b6721a5254f79f91c23b1c7992c
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/rdf
Gerrit-Branch: master
Gerrit-Owner: Yurik 

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


[MediaWiki-commits] [Gerrit] pywikibot/core[master]: login.py: Unpack entry into variables instead of overwriting...

2017-08-24 Thread Dalba (Code Review)
Dalba has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373724 )

Change subject: login.py: Unpack entry into variables instead of overwriting 
itself
..

login.py: Unpack entry into variables instead of overwriting itself

This makes the code easier to follow and developers won't need to remember
what each entry item means when examining the code.

Change-Id: Ide50f0fd7d1baaa875907a17ed1e25801b6d472a
---
M pywikibot/login.py
1 file changed, 10 insertions(+), 14 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/24/373724/1

diff --git a/pywikibot/login.py b/pywikibot/login.py
index fefbda7..836d385 100644
--- a/pywikibot/login.py
+++ b/pywikibot/login.py
@@ -265,20 +265,16 @@
  'given)'.format(line_nr, entry), _PasswordFileWarning)
 continue
 
-# When the tuple is inverted the default family and code can be
-# easily appended which makes the next condition easier as it does
-# not need to know if it's using the default value or not.
-entry = list(entry[::-1]) + [self.site.family.name,
- self.site.code][len(entry) - 2:]
-
-if (normalize_username(entry[1]) == self.username and
-entry[2] == self.site.family.name and
-entry[3] == self.site.code):
-if isinstance(entry[0], basestring):
-self.password = entry[0]
-elif isinstance(entry[0], BotPassword):
-self.password = entry[0].password
-self.login_name = entry[0].login_name(self.username)
+password, username, family, code = list(entry[::-1]) + [
+self.site.family.name, self.site.code][len(entry) - 2:]
+if (normalize_username(username) == self.username and
+family == self.site.family.name and
+code == self.site.code):
+if isinstance(password, basestring):
+self.password = password
+elif isinstance(password, BotPassword):
+self.password = password.password
+self.login_name = password.login_name(self.username)
 else:
 warn('Invalid password format', _PasswordFileWarning)
 password_f.close()

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ide50f0fd7d1baaa875907a17ed1e25801b6d472a
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
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] marvin[master]: Chore: use TypeScript for types instead of JSDocs

2017-08-24 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373723 )

Change subject: Chore: use TypeScript for types instead of JSDocs
..

Chore: use TypeScript for types instead of JSDocs

JSDocs may become outdated so don't require them to specify typing.

Change-Id: I7f0f44671addbd9fb3d24cef49d423a1504964f0
---
M .eslintrc.json
M src/server/templates/page.ts
2 files changed, 6 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/marvin refs/changes/23/373723/1

diff --git a/.eslintrc.json b/.eslintrc.json
index 7cb9105..25c8bbd 100644
--- a/.eslintrc.json
+++ b/.eslintrc.json
@@ -34,6 +34,9 @@
 {
   "files": [ "*.ts", "*.tsx" ],
   "rules": {
+// Unnecessary for a typed language.
+"jsdoc/require-returns-type": 0,
+
 // Disable rules with known issues.
 // https://github.com/eslint/typescript-eslint-parser#known-issues
 "no-undef": 0,
diff --git a/src/server/templates/page.ts b/src/server/templates/page.ts
index 7f3e8c2..8f86db1 100644
--- a/src/server/templates/page.ts
+++ b/src/server/templates/page.ts
@@ -10,9 +10,9 @@
 }
 
 /**
- * @return {!string} The path to the asset identified by entry and extension
- *   (e.g., index.js); either a URL (development) or a
- *   filesystem path (production).
+ * @return The path to the asset identified by entry and extension (e.g.,
+ * index.js); either a URL (development) or a filesystem path
+ * (production).
  */
 const asset = (assets: Assets | string, entry: string, extension: string) =>
   typeof assets === "string"

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7f0f44671addbd9fb3d24cef49d423a1504964f0
Gerrit-PatchSet: 1
Gerrit-Project: marvin
Gerrit-Branch: master
Gerrit-Owner: Niedzielski 
Gerrit-Reviewer: Sniedzielski 

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


[MediaWiki-commits] [Gerrit] marvin[master]: Chore: apply typing convention

2017-08-24 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373722 )

Change subject: Chore: apply typing convention
..

Chore: apply typing convention

Note: although @types/assets-webpack-plugin is no longer explicitly
imported, this typing is implied and required for compilation.

Change-Id: I69c7cdfcf1c11c0d78aee6839dd9bd917c885e81
---
M src/server/index.ts
M src/server/templates/page.ts
2 files changed, 6 insertions(+), 11 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/marvin refs/changes/22/373722/1

diff --git a/src/server/index.ts b/src/server/index.ts
index c7f7c69..bd9d8b1 100644
--- a/src/server/index.ts
+++ b/src/server/index.ts
@@ -2,7 +2,6 @@
 import "ignore-styles";
 
 import * as express from "express";
-import { Assets } from "assets-webpack-plugin";
 import app from "../common/components/app";
 import page from "./templates/page";
 import { render } from "preact-render-to-string";
@@ -11,7 +10,7 @@
 
 // The asset manifest built or the webpack-dev-server URL (which has no
 // manifest).
-const assets: Assets | string = isProd
+const assets = isProd
   ? require("../../dist/public/assets-manifest.json")
   : "http://localhost:8080";;
 
@@ -20,11 +19,11 @@
 
 server.use(express.static("dist/public"));
 
-server.get("/", (_req: express.Request, res: express.Response) => {
+server.get("/", (_req, res) => {
   res.status(200).send(page({ title: "", body: render(app()), assets }));
 });
 
-server.get("*", (_req: express.Request, res: express.Response) => {
+server.get("*", (_req, res) => {
   res.status(404).send("Not found");
 });
 
diff --git a/src/server/templates/page.ts b/src/server/templates/page.ts
index 70985ec..7f3e8c2 100644
--- a/src/server/templates/page.ts
+++ b/src/server/templates/page.ts
@@ -14,18 +14,14 @@
  *   (e.g., index.js); either a URL (development) or a
  *   filesystem path (production).
  */
-const asset = (
-  assets: Assets | string,
-  entry: string,
-  extension: string
-): string =>
+const asset = (assets: Assets | string, entry: string, extension: string) =>
   typeof assets === "string"
 ? `${assets}/${entry}.${extension}`
 : assets[entry][extension];
 
 export default function page({ title, body = "", assets }: PageParams): string 
{
-  const script: string = asset(assets, "index", "js");
-  const style: string = asset(assets, "index", "css");
+  const script = asset(assets, "index", "js");
+  const style = asset(assets, "index", "css");
   return `
 
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I69c7cdfcf1c11c0d78aee6839dd9bd917c885e81
Gerrit-PatchSet: 1
Gerrit-Project: marvin
Gerrit-Branch: master
Gerrit-Owner: Niedzielski 
Gerrit-Reviewer: Sniedzielski 

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


[MediaWiki-commits] [Gerrit] wikidata...rdf[master]: removed duplicate xsd: namespace

2017-08-24 Thread Yurik (Code Review)
Yurik has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373721 )

Change subject: removed duplicate xsd: namespace
..

removed duplicate xsd: namespace

Change-Id: I1e92ca233d4a60862dccf7fbb18b15738fbabd58
---
M dist/src/script/ldf-config.json
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikidata/query/rdf 
refs/changes/21/373721/1

diff --git a/dist/src/script/ldf-config.json b/dist/src/script/ldf-config.json
index 62c72ea..b59801b 100644
--- a/dist/src/script/ldf-config.json
+++ b/dist/src/script/ldf-config.json
@@ -15,7 +15,6 @@
   "prefixes": {
 "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#";,
 "rdfs":"http://www.w3.org/2000/01/rdf-schema#";,
-"xsd": "http://www.w3.org/2001/XMLSchema#";,
 "dc":  "http://purl.org/dc/terms/";,
 "foaf":"http://xmlns.com/foaf/0.1/";,
 "void":"http://rdfs.org/ns/void#";,

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1e92ca233d4a60862dccf7fbb18b15738fbabd58
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/rdf
Gerrit-Branch: master
Gerrit-Owner: Yurik 

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


[MediaWiki-commits] [Gerrit] labs/striker[master]: Handle invalid ssh keys in LDAP

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373720 )

Change subject: Handle invalid ssh keys in LDAP
..


Handle invalid ssh keys in LDAP

Deal gracefully with invalid ssh keys that have been allowed into the
LDAP directory. Prior to this fix any invalid key encountered would
cause a fatal error when displaying the ssh-key management screen.

Bug: T174112
Change-Id: I4722104bca30b097060a737dad58c1aa3fb03387
---
M striker/profile/forms.py
M striker/profile/utils.py
M striker/profile/views.py
3 files changed, 50 insertions(+), 9 deletions(-)

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



diff --git a/striker/profile/forms.py b/striker/profile/forms.py
index 6a878a7..9356623 100644
--- a/striker/profile/forms.py
+++ b/striker/profile/forms.py
@@ -28,7 +28,7 @@
 
 class SshKeyDeleteForm(forms.Form):
 key_hash = forms.CharField(
-label=_('SHA512 hash of ssh key'),
+label=_('SHA256 hash of ssh key'),
 widget=forms.HiddenInput(),
 required=True,
 )
diff --git a/striker/profile/utils.py b/striker/profile/utils.py
index 4548f8a..eb670d3 100644
--- a/striker/profile/utils.py
+++ b/striker/profile/utils.py
@@ -18,7 +18,10 @@
 # You should have received a copy of the GNU General Public License
 # along with Striker.  If not, see .
 
+import base64
+import hashlib
 import logging
+
 import sshpubkeys
 
 
@@ -54,8 +57,19 @@
 return key
 
 
+def invalid_key_hash(key):
+"""Generate a hash for an invalid ssh public key."""
+return 'INVALID:{}'.format(base64.b85encode(
+hashlib.sha256(key.encode('utf-8')).digest()).decode('utf-8'))
+
+
 def ssh_keys_by_hash(user):
-return {
-parse_ssh_key(key).hash_sha256(): key
-for key in user.ldapuser.ssh_keys
-}
+ret = {}
+for key in user.ldapuser.ssh_keys:
+pkey = parse_ssh_key(key)
+if pkey:
+ret[pkey.hash_sha256()] = key
+else:
+# T174112: handle invalid keys
+ret[invalid_key_hash(key)] = key
+return ret
diff --git a/striker/profile/views.py b/striker/profile/views.py
index 93bb5ed..6e67e52 100644
--- a/striker/profile/views.py
+++ b/striker/profile/views.py
@@ -28,6 +28,7 @@
 from django.db.utils import DatabaseError
 from django.views.decorators.debug import sensitive_post_parameters
 from django.utils.translation import ugettext_lazy as _
+from django.utils.translation import ungettext
 
 import ldap
 
@@ -83,12 +84,38 @@
 def ssh_keys(req):
 ldapuser = req.user.ldapuser
 ctx = {
-'ssh_keys': [utils.parse_ssh_key(key) for key in ldapuser.ssh_keys],
+'ssh_keys': [],
 'new_key': forms.SshKeyForm(),
 }
-for key in ctx['ssh_keys']:
-key.form = forms.SshKeyDeleteForm(
-initial={'key_hash': key.hash_sha256()})
+invalids = 0
+for key in ldapuser.ssh_keys:
+pkey = utils.parse_ssh_key(key)
+if pkey:
+pkey.form = forms.SshKeyDeleteForm(
+initial={'key_hash': pkey.hash_sha256()})
+else:
+# T174112: handle invalid keys
+invalids += 1
+khash = utils.invalid_key_hash(key)
+pkey = {
+'comment': _('Invalid key'),
+'bits': _('0'),
+'type_name': _('UNKNOWN'),
+'hash_md5': khash,
+'hash_sha256': '',
+'keydata': key,
+'form': forms.SshKeyDeleteForm(initial={'key_hash': khash}),
+}
+ctx['ssh_keys'].append(pkey)
+if invalids:
+messages.error(
+req,
+ungettext(
+"Invalid ssh key detected.",
+"{count} invalid ssh keys detected.",
+invalids
+).format(count=invalids)
+)
 return shortcuts.render(req, 'profile/settings/ssh-keys.html', ctx)
 
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I4722104bca30b097060a737dad58c1aa3fb03387
Gerrit-PatchSet: 1
Gerrit-Project: labs/striker
Gerrit-Branch: master
Gerrit-Owner: BryanDavis 
Gerrit-Reviewer: BryanDavis 
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]: Fix logrotate permissions

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/361429 )

Change subject: Fix logrotate permissions
..


Fix logrotate permissions

/vagrant/logs/ is owned by vagrant:vagrant (has to be as it's shared
with the host machine) which results in errors like
  error: skipping "/vagrant/logs/foo.log" because parent directory
  has insecure permissions (It's world writable or writable by group
  which is not "root") Set "su" directive in config file to tell
  logrotate which user/group should be used for rotation.
Ownership of the log directory needs to be specified manually
to avoid that.

Change-Id: I74907dc696e05cb3db23441056e30ade25b73e9c
---
M puppet/modules/mediawiki/files/wiki/logrotate.d-mediawiki-shared-log-groups
M puppet/modules/mediawiki/templates/logrotate.d-mediawiki-debug-log.erb
M puppet/modules/role/files/flow/logrotate.d-mediawiki-Flow
M puppet/modules/service/templates/logrotate.erb
M puppet/modules/statsd/templates/logrotate.erb
5 files changed, 5 insertions(+), 0 deletions(-)

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



diff --git 
a/puppet/modules/mediawiki/files/wiki/logrotate.d-mediawiki-shared-log-groups 
b/puppet/modules/mediawiki/files/wiki/logrotate.d-mediawiki-shared-log-groups
index f67cdd5..c65bfa5 100644
--- 
a/puppet/modules/mediawiki/files/wiki/logrotate.d-mediawiki-shared-log-groups
+++ 
b/puppet/modules/mediawiki/files/wiki/logrotate.d-mediawiki-shared-log-groups
@@ -3,6 +3,7 @@
 # This file is managed by Puppet
 
 /vagrant/logs/mediawiki-exception.log /vagrant/logs/mediawiki-runJobs.log 
/vagrant/logs/mediawiki-JobQueueRedis.log {
+su vagrant vagrant
 daily
 missingok
 rotate 7
diff --git 
a/puppet/modules/mediawiki/templates/logrotate.d-mediawiki-debug-log.erb 
b/puppet/modules/mediawiki/templates/logrotate.d-mediawiki-debug-log.erb
index 49fdafa..21e405c 100644
--- a/puppet/modules/mediawiki/templates/logrotate.d-mediawiki-debug-log.erb
+++ b/puppet/modules/mediawiki/templates/logrotate.d-mediawiki-debug-log.erb
@@ -2,6 +2,7 @@
 # This file is managed by Puppet
 
 <%= @debug_log_file %> {
+su vagrant vagrant
 daily
 missingok
 rotate 7
diff --git a/puppet/modules/role/files/flow/logrotate.d-mediawiki-Flow 
b/puppet/modules/role/files/flow/logrotate.d-mediawiki-Flow
index 8fc92c0..e4a7129 100644
--- a/puppet/modules/role/files/flow/logrotate.d-mediawiki-Flow
+++ b/puppet/modules/role/files/flow/logrotate.d-mediawiki-Flow
@@ -1,6 +1,7 @@
 # This file is managed by Puppet
 
 /vagrant/logs/mediawiki-Flow.log {
+su vagrant vagrant
 daily
 missingok
 rotate 7
diff --git a/puppet/modules/service/templates/logrotate.erb 
b/puppet/modules/service/templates/logrotate.erb
index 70a0f9a..4f267a3 100644
--- a/puppet/modules/service/templates/logrotate.erb
+++ b/puppet/modules/service/templates/logrotate.erb
@@ -1,6 +1,7 @@
 # logrotate(8) config for <%= @title %>
 
 <%= @log_file %> {
+su vagrant vagrant
 daily
 copytruncate
 missingok
diff --git a/puppet/modules/statsd/templates/logrotate.erb 
b/puppet/modules/statsd/templates/logrotate.erb
index 8d93413..44d4c97 100644
--- a/puppet/modules/statsd/templates/logrotate.erb
+++ b/puppet/modules/statsd/templates/logrotate.erb
@@ -1,6 +1,7 @@
 # logrotate(8) config for statsd
 
 "<%= @logdir %>/statsd.log" {
+su vagrant vagrant
 daily
 copytruncate
 missingok

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I74907dc696e05cb3db23441056e30ade25b73e9c
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/vagrant
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: Dduvall 
Gerrit-Reviewer: Mattflaschen 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] labs/striker[master]: Handle invalid ssh keys in LDAP

2017-08-24 Thread BryanDavis (Code Review)
BryanDavis has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373720 )

Change subject: Handle invalid ssh keys in LDAP
..

Handle invalid ssh keys in LDAP

Deal gracefully with invalid ssh keys that have been allowed into the
LDAP directory. Prior to this fix any invalid key encountered would
cause a fatal error when displaying the ssh-key management screen.

Bug: T174112
Change-Id: I4722104bca30b097060a737dad58c1aa3fb03387
---
M striker/profile/forms.py
M striker/profile/utils.py
M striker/profile/views.py
3 files changed, 50 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/striker 
refs/changes/20/373720/1

diff --git a/striker/profile/forms.py b/striker/profile/forms.py
index 6a878a7..9356623 100644
--- a/striker/profile/forms.py
+++ b/striker/profile/forms.py
@@ -28,7 +28,7 @@
 
 class SshKeyDeleteForm(forms.Form):
 key_hash = forms.CharField(
-label=_('SHA512 hash of ssh key'),
+label=_('SHA256 hash of ssh key'),
 widget=forms.HiddenInput(),
 required=True,
 )
diff --git a/striker/profile/utils.py b/striker/profile/utils.py
index 4548f8a..eb670d3 100644
--- a/striker/profile/utils.py
+++ b/striker/profile/utils.py
@@ -18,7 +18,10 @@
 # You should have received a copy of the GNU General Public License
 # along with Striker.  If not, see .
 
+import base64
+import hashlib
 import logging
+
 import sshpubkeys
 
 
@@ -54,8 +57,19 @@
 return key
 
 
+def invalid_key_hash(key):
+"""Generate a hash for an invalid ssh public key."""
+return 'INVALID:{}'.format(base64.b85encode(
+hashlib.sha256(key.encode('utf-8')).digest()).decode('utf-8'))
+
+
 def ssh_keys_by_hash(user):
-return {
-parse_ssh_key(key).hash_sha256(): key
-for key in user.ldapuser.ssh_keys
-}
+ret = {}
+for key in user.ldapuser.ssh_keys:
+pkey = parse_ssh_key(key)
+if pkey:
+ret[pkey.hash_sha256()] = key
+else:
+# T174112: handle invalid keys
+ret[invalid_key_hash(key)] = key
+return ret
diff --git a/striker/profile/views.py b/striker/profile/views.py
index 93bb5ed..6e67e52 100644
--- a/striker/profile/views.py
+++ b/striker/profile/views.py
@@ -28,6 +28,7 @@
 from django.db.utils import DatabaseError
 from django.views.decorators.debug import sensitive_post_parameters
 from django.utils.translation import ugettext_lazy as _
+from django.utils.translation import ungettext
 
 import ldap
 
@@ -83,12 +84,38 @@
 def ssh_keys(req):
 ldapuser = req.user.ldapuser
 ctx = {
-'ssh_keys': [utils.parse_ssh_key(key) for key in ldapuser.ssh_keys],
+'ssh_keys': [],
 'new_key': forms.SshKeyForm(),
 }
-for key in ctx['ssh_keys']:
-key.form = forms.SshKeyDeleteForm(
-initial={'key_hash': key.hash_sha256()})
+invalids = 0
+for key in ldapuser.ssh_keys:
+pkey = utils.parse_ssh_key(key)
+if pkey:
+pkey.form = forms.SshKeyDeleteForm(
+initial={'key_hash': pkey.hash_sha256()})
+else:
+# T174112: handle invalid keys
+invalids += 1
+khash = utils.invalid_key_hash(key)
+pkey = {
+'comment': _('Invalid key'),
+'bits': _('0'),
+'type_name': _('UNKNOWN'),
+'hash_md5': khash,
+'hash_sha256': '',
+'keydata': key,
+'form': forms.SshKeyDeleteForm(initial={'key_hash': khash}),
+}
+ctx['ssh_keys'].append(pkey)
+if invalids:
+messages.error(
+req,
+ungettext(
+"Invalid ssh key detected.",
+"{count} invalid ssh keys detected.",
+invalids
+).format(count=invalids)
+)
 return shortcuts.render(req, 'profile/settings/ssh-keys.html', ctx)
 
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4722104bca30b097060a737dad58c1aa3fb03387
Gerrit-PatchSet: 1
Gerrit-Project: labs/striker
Gerrit-Branch: master
Gerrit-Owner: BryanDavis 

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


[MediaWiki-commits] [Gerrit] marvin[master]: Doc: add typing convention

2017-08-24 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373719 )

Change subject: Doc: add typing convention
..

Doc: add typing convention

Change-Id: I80907347a3da67986ea7055b156faa2ab807b0b5
---
M docs/development.md
1 file changed, 57 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/marvin refs/changes/19/373719/1

diff --git a/docs/development.md b/docs/development.md
index 8c6a327..be3f58c 100644
--- a/docs/development.md
+++ b/docs/development.md
@@ -41,7 +41,6 @@
 * To automatically format source code and fix linting errors, you can run:
   * `npm run format`
 
-
 ## Running the production version
 
 If you want to run the production version, then:
@@ -50,3 +49,60 @@
   * `npm run build`
 * Run the production server with:
   * `NODE_ENV=production node dist/server/index.js`
+
+## Coding conventions
+
+### Typing
+
+In TypeScript, data types may be explicitly specified or (often) inferred by 
the
+compiler. Marvin's coding convention is to favor inference except for module
+exports. Another way to phrase this is: write concisely except for APIs. The
+reasoning is that the brevity of inferred code is preferred but APIs are seams
+and their types should be both fixed and documented.
+
+The following examples are possible module implementations but the second or
+third are preferred:
+
+1. Explicitly over-typed (right-hand typing is internal):
+```js
+const app: FunctionalComponent = (_props: any): JSX.Element =>
+  Hello world;
+
+export default app
+```
+
+2. Explicitly typed (declared syntax):
+```js
+const app: FunctionalComponent = () =>
+  Hello world;
+
+export default app
+```
+
+3. Explicitly typed (inline syntax):
+```js
+export default (_props: any): JSX.Element =>
+  Hello world;
+```
+
+4. Implicitly typed:
+```js
+export default () =>
+  Hello world;
+```
+
+The following are possible internal implementations but the second is 
preferred:
+
+1. Explicitly typed:
+```js
+server.get("*", (_request: express.Request, response: express.Response) => 
{
+  response.status(404).send("Not found");
+});
+```
+
+2. Implicitly typed:
+```js
+server.get("*", (_request, response) => {
+  response.status(404).send("Not found");
+});
+```

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I80907347a3da67986ea7055b156faa2ab807b0b5
Gerrit-PatchSet: 1
Gerrit-Project: marvin
Gerrit-Branch: master
Gerrit-Owner: Niedzielski 
Gerrit-Reviewer: Sniedzielski 

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: widgets.TitleWidget: Use mediawiki.mixins `.box-sizing()`

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373718 )

Change subject: widgets.TitleWidget: Use mediawiki.mixins `.box-sizing()`
..


widgets.TitleWidget: Use mediawiki.mixins `.box-sizing()`

Using general `box-sizing()` mixin from mediawiki.mixins instead of
decentral vendor prefixes.

Change-Id: I844dc28a627dc984540e9a013dae188187c4f151
---
M resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
1 file changed, 2 insertions(+), 3 deletions(-)

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



diff --git a/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less 
b/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
index bbffe28..2ac5d45 100644
--- a/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
+++ b/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
@@ -4,6 +4,7 @@
  * @copyright 2011-2015 MediaWiki Widgets Team and others; see AUTHORS.txt
  * @license The MIT License (MIT); see LICENSE.txt
  */
+@import 'mediawiki.mixins';
 
 .mw-widget-titleWidget-menu {
.mw-widget-titleOptionWidget {
@@ -16,9 +17,7 @@
 
&-withImages {
.mw-widget-titleOptionWidget {
-   -webkit-box-sizing: border-box;
-   -moz-box-sizing: border-box;
-   box-sizing: border-box;
+   .box-sizing( border-box );
min-height: 3.75em;
padding-left: 4.75em;
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I844dc28a627dc984540e9a013dae188187c4f151
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: VolkerE 
Gerrit-Reviewer: Jack Phoenix 
Gerrit-Reviewer: Jforrester 
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]: widgets.TitleWidget: Use mediawiki.mixins `.box-sizing()`

2017-08-24 Thread VolkerE (Code Review)
VolkerE has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373718 )

Change subject: widgets.TitleWidget: Use mediawiki.mixins `.box-sizing()`
..

widgets.TitleWidget: Use mediawiki.mixins `.box-sizing()`

Using general `box-sizing()` mixin from mediawiki.mixins instead of
decentral vendor prefixes.

Change-Id: I844dc28a627dc984540e9a013dae188187c4f151
---
M resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
1 file changed, 2 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/18/373718/1

diff --git a/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less 
b/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
index bbffe28..2ac5d45 100644
--- a/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
+++ b/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
@@ -4,6 +4,7 @@
  * @copyright 2011-2015 MediaWiki Widgets Team and others; see AUTHORS.txt
  * @license The MIT License (MIT); see LICENSE.txt
  */
+@import 'mediawiki.mixins';
 
 .mw-widget-titleWidget-menu {
.mw-widget-titleOptionWidget {
@@ -16,9 +17,7 @@
 
&-withImages {
.mw-widget-titleOptionWidget {
-   -webkit-box-sizing: border-box;
-   -moz-box-sizing: border-box;
-   box-sizing: border-box;
+   .box-sizing( border-box );
min-height: 3.75em;
padding-left: 4.75em;
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I844dc28a627dc984540e9a013dae188187c4f151
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: VolkerE 

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: widgets.StashedFileWidget: Simplify and reduce LESS code

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373717 )

Change subject: widgets.StashedFileWidget: Simplify and reduce LESS code
..


widgets.StashedFileWidget: Simplify and reduce LESS code

Simplifying and reducing LESS code where applicable.

Change-Id: Ic0f138d33064b4c8f2bb6253a20012a3b577372b
---
M resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
1 file changed, 3 insertions(+), 10 deletions(-)

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



diff --git a/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less 
b/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
index 4a59dae..ea62075 100644
--- a/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
+++ b/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
@@ -57,22 +57,19 @@
> .oo-ui-indicatorElement-indicator,
> .oo-ui-iconElement-icon {
position: absolute;
+   top: 0;
+   height: 2.3em;
}
 
> .oo-ui-indicatorElement-indicator {
right: 0;
-   top: 0;
width: 0.9375em;
-   height: 2.3em;
margin-right: 0.775em;
}
 
> .oo-ui-iconElement-icon {
-   top: 0;
width: 1.875em;
-   height: 2.3em;
margin-left: 0.5em;
-   left: 0;
}
 
&.oo-ui-widget-disabled {
@@ -132,11 +129,7 @@
> .mw-widgets-stashedFileWidget-label {
position: relative;
 
-   > .mw-widgets-stashedFileWidget-fileName {
-   display: block;
-   float: none;
-   }
-
+   > .mw-widgets-stashedFileWidget-fileName,
> .mw-widgets-stashedFileWidget-fileType {
display: block;
float: none;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic0f138d33064b4c8f2bb6253a20012a3b577372b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: VolkerE 
Gerrit-Reviewer: Jack Phoenix 
Gerrit-Reviewer: Jforrester 
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]: Add sslCAFile option to DatabaseMysqli

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373715 )

Change subject: Add sslCAFile option to DatabaseMysqli
..


Add sslCAFile option to DatabaseMysqli

This makes all arguments to the mysqli::set_ssl() call be controllable.

Change-Id: I67ed742add633a77e97d08b812e420a73cd83a52
---
M includes/libs/rdbms/database/DatabaseMysqlBase.php
M includes/libs/rdbms/database/DatabaseMysqli.php
2 files changed, 6 insertions(+), 3 deletions(-)

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



diff --git a/includes/libs/rdbms/database/DatabaseMysqlBase.php 
b/includes/libs/rdbms/database/DatabaseMysqlBase.php
index 692ddb7..3c4cda5 100644
--- a/includes/libs/rdbms/database/DatabaseMysqlBase.php
+++ b/includes/libs/rdbms/database/DatabaseMysqlBase.php
@@ -51,6 +51,8 @@
/** @var string|null */
protected $sslCertPath;
/** @var string|null */
+   protected $sslCAFile;
+   /** @var string|null */
protected $sslCAPath;
/** @var string[]|null */
protected $sslCiphers;
@@ -75,7 +77,8 @@
 *   - useGTIDs : use GTID methods like MASTER_GTID_WAIT() when 
possible.
 *   - sslKeyPath : path to key file [default: null]
 *   - sslCertPath : path to certificate file [default: null]
-*   - sslCAPath : parth to certificate authority PEM files [default: 
null]
+*   - sslCAFile: path to a single certificate authority PEM file 
[default: null]
+*   - sslCAPath : parth to certificate authority PEM directory 
[default: null]
 *   - sslCiphers : array list of allowable ciphers [default: null]
 * @param array $params
 */
@@ -87,7 +90,7 @@
? $params['lagDetectionOptions']
: [];
$this->useGTIDs = !empty( $params['useGTIDs' ] );
-   foreach ( [ 'KeyPath', 'CertPath', 'CAPath', 'Ciphers' ] as 
$name ) {
+   foreach ( [ 'KeyPath', 'CertPath', 'CAFile', 'CAPath', 
'Ciphers' ] as $name ) {
$var = "ssl{$name}";
if ( isset( $params[$var] ) ) {
$this->$var = $params[$var];
diff --git a/includes/libs/rdbms/database/DatabaseMysqli.php 
b/includes/libs/rdbms/database/DatabaseMysqli.php
index 4d1b87b..b925e2c 100644
--- a/includes/libs/rdbms/database/DatabaseMysqli.php
+++ b/includes/libs/rdbms/database/DatabaseMysqli.php
@@ -91,7 +91,7 @@
$mysqli->ssl_set(
$this->sslKeyPath,
$this->sslCertPath,
-   null,
+   $this->sslCAFile,
$this->sslCAPath,
$this->sslCiphers
);

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I67ed742add633a77e97d08b812e420a73cd83a52
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 
Gerrit-Reviewer: EBernhardson 
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]: widgets.StashedFileWidget: Simplify and reduce LESS code

2017-08-24 Thread VolkerE (Code Review)
VolkerE has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373717 )

Change subject: widgets.StashedFileWidget: Simplify and reduce LESS code
..

widgets.StashedFileWidget: Simplify and reduce LESS code

Simplifying and reducing LESS code where applicable.

Change-Id: Ic0f138d33064b4c8f2bb6253a20012a3b577372b
---
M resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
1 file changed, 3 insertions(+), 10 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/17/373717/1

diff --git a/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less 
b/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
index 4a59dae..ea62075 100644
--- a/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
+++ b/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
@@ -57,22 +57,19 @@
> .oo-ui-indicatorElement-indicator,
> .oo-ui-iconElement-icon {
position: absolute;
+   top: 0;
+   height: 2.3em;
}
 
> .oo-ui-indicatorElement-indicator {
right: 0;
-   top: 0;
width: 0.9375em;
-   height: 2.3em;
margin-right: 0.775em;
}
 
> .oo-ui-iconElement-icon {
-   top: 0;
width: 1.875em;
-   height: 2.3em;
margin-left: 0.5em;
-   left: 0;
}
 
&.oo-ui-widget-disabled {
@@ -132,11 +129,7 @@
> .mw-widgets-stashedFileWidget-label {
position: relative;
 
-   > .mw-widgets-stashedFileWidget-fileName {
-   display: block;
-   float: none;
-   }
-
+   > .mw-widgets-stashedFileWidget-fileName,
> .mw-widgets-stashedFileWidget-fileType {
display: block;
float: none;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic0f138d33064b4c8f2bb6253a20012a3b577372b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: VolkerE 

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


[MediaWiki-commits] [Gerrit] labs/striker[master]: Guard against LDAP modify with no changes for maintainers

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373709 )

Change subject: Guard against LDAP modify with no changes for maintainers
..


Guard against LDAP modify with no changes for maintainers

LDAP gets angry when you tell it that you are updating a collection but
the collection actually does not change. Check to ensure that the list
of maintainers for a tool has actually changed before saving to the
directory.

Change-Id: I06758d77f86fa14ffcb1f56aebe8ac9c2153122b
---
M striker/tools/views/tool.py
1 file changed, 11 insertions(+), 4 deletions(-)

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



diff --git a/striker/tools/views/tool.py b/striker/tools/views/tool.py
index 8cc44ba..bf2e309 100644
--- a/striker/tools/views/tool.py
+++ b/striker/tools/views/tool.py
@@ -168,6 +168,13 @@
 form.cleaned_data['tools']
 )
 )
+
+# LDAP doesn't like it when we change the list to be the same
+# list, so make sure there is some delta before saving
+if old_members == new_members:
+messages.warning(req, _('Maintainers unchanged'))
+return shortcuts.redirect(tool.get_absolute_url())
+
 tool.members = new_members
 tool.save()
 
@@ -186,8 +193,8 @@
 else:
 # Add user to the mirrored group
 added.groups.add(maintainers.id)
-# Do not set tool as the notification target because the
-# framework does not understand LDAP models.
+# Do not set tool as the notification target because
+# the framework does not understand LDAP models.
 notify.send(
 recipient=added,
 sender=req.user,
@@ -216,8 +223,8 @@
 else:
 # Add user to the mirrored group
 removed.groups.remove(maintainers.id)
-# Do not set tool as the notification target because the
-# framework does not understand LDAP models.
+# Do not set tool as the notification target because
+# the framework does not understand LDAP models.
 notify.send(
 recipient=removed,
 sender=req.user,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I06758d77f86fa14ffcb1f56aebe8ac9c2153122b
Gerrit-PatchSet: 1
Gerrit-Project: labs/striker
Gerrit-Branch: master
Gerrit-Owner: BryanDavis 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] labs/striker[master]: Break in-process cache of model choice fields

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373708 )

Change subject: Break in-process cache of model choice fields
..


Break in-process cache of model choice fields

ChoiceFields which are initial as class variables will (may?) cache
results for the lifetime of the python execution environment. To break
this cache, use the __init__ method of the form instance to reset the
queryset used for validation.

Bug: T173963
Change-Id: Ia795114642328e8958f18c79c3d7c0dbfd9348af
---
M striker/tools/forms.py
1 file changed, 13 insertions(+), 5 deletions(-)

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



diff --git a/striker/tools/forms.py b/striker/tools/forms.py
index 3e7d496..97c946f 100644
--- a/striker/tools/forms.py
+++ b/striker/tools/forms.py
@@ -266,8 +266,7 @@
 ),
 )
 license = forms.ModelChoiceField(
-queryset=SoftwareLicense.objects.filter(
-osi_approved=True).order_by('-recommended', 'slug'),
+queryset=SoftwareLicense.objects.none(),
 empty_label=_('-- Choose your software license --'),
 label=_('Default software license'),
 help_text=_(
@@ -276,12 +275,19 @@
 ).format(choose_a_license='https://choosealicense.com/'),
 )
 tags = forms.ModelMultipleChoiceField(
-queryset=ToolInfoTag.objects.all().order_by('name'),
+queryset=ToolInfoTag.objects.none(),
 widget=autocomplete.ModelSelect2Multiple(
 url='tools:tags_autocomplete',
 ),
 required=False,
 )
+
+def __init__(self, *args, **kwargs):
+super(ToolCreateForm, self).__init__(*args, **kwargs)
+self.fields['license'].queryset = SoftwareLicense.objects.filter(
+osi_approved=True).order_by('-recommended', 'slug')
+self.fields['tags'].queryset = ToolInfoTag.objects.all().order_by(
+'name')
 
 def clean_name(self):
 """Validate that name is available."""
@@ -305,13 +311,13 @@
 @parsleyfy
 class MaintainersForm(forms.Form):
 maintainers = MaintainerChoiceField(
-queryset=Maintainer.objects.all(),
+queryset=Maintainer.objects.none(),
 widget=autocomplete.ModelSelect2Multiple(
 url='tools:api:maintainer',
 ),
 )
 tools = forms.ModelMultipleChoiceField(
-queryset=ToolUser.objects.all(),
+queryset=ToolUser.objects.none(),
 widget=autocomplete.ModelSelect2Multiple(
 url='tools:api:tooluser',
 ),
@@ -332,3 +338,5 @@
 initial['tools'] = tool.tool_member_ids()
 kwargs['initial'] = initial
 super(MaintainersForm, self).__init__(*args, **kwargs)
+self.fields['maintainers'].queryset = Maintainer.objects.all()
+self.fields['tools'].queryset = ToolUser.objects.all()

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia795114642328e8958f18c79c3d7c0dbfd9348af
Gerrit-PatchSet: 1
Gerrit-Project: labs/striker
Gerrit-Branch: master
Gerrit-Owner: BryanDavis 
Gerrit-Reviewer: BryanDavis 
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...Flow[wmf/1.30.0-wmf.15]: Fix infinite scroll

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373713 )

Change subject: Fix infinite scroll
..


Fix infinite scroll

Bug: T173807
Change-Id: I1c4be9438710cd0c7295ca8ea418c6f2352d468f
(cherry picked from commit 7792033aa9cd9dc0376346bce6041844f0a0d295)
---
M modules/engine/components/board/features/flow-board-loadmore.js
1 file changed, 3 insertions(+), 4 deletions(-)

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



diff --git a/modules/engine/components/board/features/flow-board-loadmore.js 
b/modules/engine/components/board/features/flow-board-loadmore.js
index 900fc3e..32e6545 100644
--- a/modules/engine/components/board/features/flow-board-loadmore.js
+++ b/modules/engine/components/board/features/flow-board-loadmore.js
@@ -420,7 +420,7 @@
 * @param {jQuery} $calculationContainer Container to do scroll 
calculations on (height, scrollTop, offset, etc.)
 */
function _flowBoardComponentLoadMoreFeatureInfiniteScrollCheck( 
$searchContainer, $calculationContainer ) {
-   var calculationContainerHeight, calculationContainerScroll, 
calculationContainerThreshold;
+   var calculationContainerHeight, calculationContainerScroll;
if ( this.infiniteScrollDisabled ) {
// This happens when the topic navigation is used to 
jump to a topic
// We should not infinite-load anything when we are 
scrolling to a topic
@@ -429,7 +429,6 @@
 
calculationContainerHeight = $calculationContainer.height();
calculationContainerScroll = $calculationContainer.scrollTop();
-   calculationContainerThreshold = ( 
$calculationContainer.offset() || { top: calculationContainerScroll } ).top;
 
// Find load more buttons within our search container, and they 
must be visible
$searchContainer.find( this.$loadMoreNodes ).filter( ':visible' 
).each( function () {
@@ -438,7 +437,7 @@
nodeHeight = $this.outerHeight( true );
 
// First, is this element above or below us?
-   if ( nodeOffset <= calculationContainerThreshold ) {
+   if ( nodeOffset <= calculationContainerScroll ) {
// Top of element is above the viewport; don't 
use it.
return;
}
@@ -447,7 +446,7 @@
// also shouldn't be triggered if it's still behind TOC!
 
// Is this element in the viewport?
-   if ( nodeOffset - nodeHeight <= 
calculationContainerThreshold + calculationContainerHeight ) {
+   if ( nodeOffset - nodeHeight <= 
calculationContainerScroll + calculationContainerHeight ) {
// Element is almost in viewport, click it.
$( this ).trigger( 'click' );
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1c4be9438710cd0c7295ca8ea418c6f2352d468f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: wmf/1.30.0-wmf.15
Gerrit-Owner: Mattflaschen 
Gerrit-Reviewer: Mattflaschen 
Gerrit-Reviewer: Sbisson 
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]: RCFilters: Minimize vertical spacing; get rid of legend and ...

2017-08-24 Thread Mooeypoo (Code Review)
Mooeypoo has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373716 )

Change subject: RCFilters: Minimize vertical spacing; get rid of legend and 
s
..

RCFilters: Minimize vertical spacing; get rid of legend and s

Bug: T174121
Change-Id: I2249bf3d313232fe2f0dff6e34c5140885a13735
---
M resources/src/mediawiki.rcfilters/styles/mw.rcfilters.less
M resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
2 files changed, 17 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/16/373716/1

diff --git a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.less 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.less
index c667bac..ec5ea3a 100644
--- a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.less
+++ b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.less
@@ -41,6 +41,14 @@
display: none;
}
}
+
+   fieldset.rcoptions {
+   padding: 0;
+
+   .rcshowhide span {
+   display: block;
+   }
+   }
}
 
.rcfilters-container {
diff --git 
a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js 
b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
index ad99e22..1b85503 100644
--- a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
+++ b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
@@ -142,17 +142,23 @@
this.$element.find( 'hr' ).detach();
}
 
+   // Get rid of all s, which are inside rcshowhide
+   // If we still have content in rcshowhide, the s are
+   // gone. Instead, the CSS now has a rule to mark all s
+   // inside .rcshowhide with display:block; to simulate newlines
+   // where they're actually needed.
+   this.$element.find( 'br' ).detach();
if ( !this.$element.find( '.rcshowhide' ).contents().length ) {
this.$element.find( '.rcshowhide' ).detach();
-   // If we're hiding rcshowhide, the ''s are around 
it,
-   // there's no need for them either.
-   this.$element.find( 'br' ).detach();
}
 
if ( this.$element.find( '.cloption' ).text().trim() === '' ) {
this.$element.find( '.cloption-submit' ).detach();
}
 
+   // Get rid of the legend
+   this.$element.find( 'legend' ).detach();
+
this.$element.find(
'.rclistfrom, .rcnotefrom, .rcoptions-listfromreset'
).detach();

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2249bf3d313232fe2f0dff6e34c5140885a13735
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Mooeypoo 

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Add sslCAFile option to DatabaseMysqli

2017-08-24 Thread Aaron Schulz (Code Review)
Aaron Schulz has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373715 )

Change subject: Add sslCAFile option to DatabaseMysqli
..

Add sslCAFile option to DatabaseMysqli

This makes all arguments to the mysqli::set_ssl() call be controllable.

Change-Id: I67ed742add633a77e97d08b812e420a73cd83a52
---
M includes/libs/rdbms/database/DatabaseMysqlBase.php
M includes/libs/rdbms/database/DatabaseMysqli.php
2 files changed, 6 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/15/373715/1

diff --git a/includes/libs/rdbms/database/DatabaseMysqlBase.php 
b/includes/libs/rdbms/database/DatabaseMysqlBase.php
index 692ddb7..3c4cda5 100644
--- a/includes/libs/rdbms/database/DatabaseMysqlBase.php
+++ b/includes/libs/rdbms/database/DatabaseMysqlBase.php
@@ -51,6 +51,8 @@
/** @var string|null */
protected $sslCertPath;
/** @var string|null */
+   protected $sslCAFile;
+   /** @var string|null */
protected $sslCAPath;
/** @var string[]|null */
protected $sslCiphers;
@@ -75,7 +77,8 @@
 *   - useGTIDs : use GTID methods like MASTER_GTID_WAIT() when 
possible.
 *   - sslKeyPath : path to key file [default: null]
 *   - sslCertPath : path to certificate file [default: null]
-*   - sslCAPath : parth to certificate authority PEM files [default: 
null]
+*   - sslCAFile: path to a single certificate authority PEM file 
[default: null]
+*   - sslCAPath : parth to certificate authority PEM directory 
[default: null]
 *   - sslCiphers : array list of allowable ciphers [default: null]
 * @param array $params
 */
@@ -87,7 +90,7 @@
? $params['lagDetectionOptions']
: [];
$this->useGTIDs = !empty( $params['useGTIDs' ] );
-   foreach ( [ 'KeyPath', 'CertPath', 'CAPath', 'Ciphers' ] as 
$name ) {
+   foreach ( [ 'KeyPath', 'CertPath', 'CAFile', 'CAPath', 
'Ciphers' ] as $name ) {
$var = "ssl{$name}";
if ( isset( $params[$var] ) ) {
$this->$var = $params[$var];
diff --git a/includes/libs/rdbms/database/DatabaseMysqli.php 
b/includes/libs/rdbms/database/DatabaseMysqli.php
index 4d1b87b..b925e2c 100644
--- a/includes/libs/rdbms/database/DatabaseMysqli.php
+++ b/includes/libs/rdbms/database/DatabaseMysqli.php
@@ -91,7 +91,7 @@
$mysqli->ssl_set(
$this->sslKeyPath,
$this->sslCertPath,
-   null,
+   $this->sslCAFile,
$this->sslCAPath,
$this->sslCiphers
);

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I67ed742add633a77e97d08b812e420a73cd83a52
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Fix error text color in dark mode

2017-08-24 Thread Cooltey (Code Review)
Cooltey has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373714 )

Change subject: Fix error text color in dark mode
..

Fix error text color in dark mode

In this update
 - Add Red75-Sunset Red to colors.xml
 - Add two styles for light mode and dark mode theme
 - Check current theme to give matched text appearance for the error text.

Bug: T173091
Change-Id: Ia8ea096f86d2a7063cc200fa2d36deae7a7516dd
---
M app/src/main/java/org/wikipedia/views/TextInputDialog.java
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/app/src/main/java/org/wikipedia/views/TextInputDialog.java 
b/app/src/main/java/org/wikipedia/views/TextInputDialog.java
index f676bdc..a24998f 100644
--- a/app/src/main/java/org/wikipedia/views/TextInputDialog.java
+++ b/app/src/main/java/org/wikipedia/views/TextInputDialog.java
@@ -52,7 +52,7 @@
 
 if (WikipediaApp.getInstance().getCurrentTheme().isLight()) {
 
editTextContainer.setErrorTextAppearance(R.style.TextInputLayout_LightThemeErrorTextAppearance);
-}else{
+} else {
 
editTextContainer.setErrorTextAppearance(R.style.TextInputLayout_DarkThemeErrorTextAppearance);
 }
 

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...Flow[wmf/1.30.0-wmf.15]: Fix infinite scroll

2017-08-24 Thread Mattflaschen (Code Review)
Mattflaschen has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373713 )

Change subject: Fix infinite scroll
..

Fix infinite scroll

Bug: T173807
Change-Id: I1c4be9438710cd0c7295ca8ea418c6f2352d468f
(cherry picked from commit 7792033aa9cd9dc0376346bce6041844f0a0d295)
---
M modules/engine/components/board/features/flow-board-loadmore.js
1 file changed, 3 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Flow 
refs/changes/13/373713/1

diff --git a/modules/engine/components/board/features/flow-board-loadmore.js 
b/modules/engine/components/board/features/flow-board-loadmore.js
index 900fc3e..32e6545 100644
--- a/modules/engine/components/board/features/flow-board-loadmore.js
+++ b/modules/engine/components/board/features/flow-board-loadmore.js
@@ -420,7 +420,7 @@
 * @param {jQuery} $calculationContainer Container to do scroll 
calculations on (height, scrollTop, offset, etc.)
 */
function _flowBoardComponentLoadMoreFeatureInfiniteScrollCheck( 
$searchContainer, $calculationContainer ) {
-   var calculationContainerHeight, calculationContainerScroll, 
calculationContainerThreshold;
+   var calculationContainerHeight, calculationContainerScroll;
if ( this.infiniteScrollDisabled ) {
// This happens when the topic navigation is used to 
jump to a topic
// We should not infinite-load anything when we are 
scrolling to a topic
@@ -429,7 +429,6 @@
 
calculationContainerHeight = $calculationContainer.height();
calculationContainerScroll = $calculationContainer.scrollTop();
-   calculationContainerThreshold = ( 
$calculationContainer.offset() || { top: calculationContainerScroll } ).top;
 
// Find load more buttons within our search container, and they 
must be visible
$searchContainer.find( this.$loadMoreNodes ).filter( ':visible' 
).each( function () {
@@ -438,7 +437,7 @@
nodeHeight = $this.outerHeight( true );
 
// First, is this element above or below us?
-   if ( nodeOffset <= calculationContainerThreshold ) {
+   if ( nodeOffset <= calculationContainerScroll ) {
// Top of element is above the viewport; don't 
use it.
return;
}
@@ -447,7 +446,7 @@
// also shouldn't be triggered if it's still behind TOC!
 
// Is this element in the viewport?
-   if ( nodeOffset - nodeHeight <= 
calculationContainerThreshold + calculationContainerHeight ) {
+   if ( nodeOffset - nodeHeight <= 
calculationContainerScroll + calculationContainerHeight ) {
// Element is almost in viewport, click it.
$( this ).trigger( 'click' );
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1c4be9438710cd0c7295ca8ea418c6f2352d468f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: wmf/1.30.0-wmf.15
Gerrit-Owner: Mattflaschen 
Gerrit-Reviewer: Sbisson 

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


[MediaWiki-commits] [Gerrit] mediawiki...Flow[master]: Fix infinite scroll

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373566 )

Change subject: Fix infinite scroll
..


Fix infinite scroll

Bug: T173807
Change-Id: I1c4be9438710cd0c7295ca8ea418c6f2352d468f
---
M modules/engine/components/board/features/flow-board-loadmore.js
1 file changed, 3 insertions(+), 4 deletions(-)

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



diff --git a/modules/engine/components/board/features/flow-board-loadmore.js 
b/modules/engine/components/board/features/flow-board-loadmore.js
index 900fc3e..32e6545 100644
--- a/modules/engine/components/board/features/flow-board-loadmore.js
+++ b/modules/engine/components/board/features/flow-board-loadmore.js
@@ -420,7 +420,7 @@
 * @param {jQuery} $calculationContainer Container to do scroll 
calculations on (height, scrollTop, offset, etc.)
 */
function _flowBoardComponentLoadMoreFeatureInfiniteScrollCheck( 
$searchContainer, $calculationContainer ) {
-   var calculationContainerHeight, calculationContainerScroll, 
calculationContainerThreshold;
+   var calculationContainerHeight, calculationContainerScroll;
if ( this.infiniteScrollDisabled ) {
// This happens when the topic navigation is used to 
jump to a topic
// We should not infinite-load anything when we are 
scrolling to a topic
@@ -429,7 +429,6 @@
 
calculationContainerHeight = $calculationContainer.height();
calculationContainerScroll = $calculationContainer.scrollTop();
-   calculationContainerThreshold = ( 
$calculationContainer.offset() || { top: calculationContainerScroll } ).top;
 
// Find load more buttons within our search container, and they 
must be visible
$searchContainer.find( this.$loadMoreNodes ).filter( ':visible' 
).each( function () {
@@ -438,7 +437,7 @@
nodeHeight = $this.outerHeight( true );
 
// First, is this element above or below us?
-   if ( nodeOffset <= calculationContainerThreshold ) {
+   if ( nodeOffset <= calculationContainerScroll ) {
// Top of element is above the viewport; don't 
use it.
return;
}
@@ -447,7 +446,7 @@
// also shouldn't be triggered if it's still behind TOC!
 
// Is this element in the viewport?
-   if ( nodeOffset - nodeHeight <= 
calculationContainerThreshold + calculationContainerHeight ) {
+   if ( nodeOffset - nodeHeight <= 
calculationContainerScroll + calculationContainerHeight ) {
// Element is almost in viewport, click it.
$( this ).trigger( 'click' );
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1c4be9438710cd0c7295ca8ea418c6f2352d468f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: Sbisson 
Gerrit-Reviewer: Mattflaschen 
Gerrit-Reviewer: Mooeypoo 
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 Portuguese to on this day endpoint.

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373159 )

Change subject: Add Portuguese to on this day endpoint.
..


Add Portuguese to on this day endpoint.

Bug: T169274
Change-Id: Ifc3716e80f8ddb2d30a2778b84a30c9cd5672501
---
M lib/feed/on-this-day.languages.js
1 file changed, 24 insertions(+), 0 deletions(-)

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



diff --git a/lib/feed/on-this-day.languages.js 
b/lib/feed/on-this-day.languages.js
index 499e506..06226a9 100644
--- a/lib/feed/on-this-day.languages.js
+++ b/lib/feed/on-this-day.languages.js
@@ -106,6 +106,30 @@
 listElementSelector: 'body > ul li'
 },
 yearListElementRegEx : /^\s*(\d+)\s*(f\.Kr\.)?\s*–\s(.+)/i
+},
+
+pt: {
+monthNames : [
+'de janeiro', 'de fevereiro', 'de março', 'de abril', 'de maio', 
'de junho',
+'de julho', 'de agosto', 'de setembro', 'de outubro', 'de 
novembro', 'de dezembro'
+],
+dayPage : {
+// https://pt.wikipedia.org/wiki/15_de_maio
+nameFormatter : (monthName, dayNumber) => 
`${dayNumber}_${monthName}`,
+headingIds: {
+births: ['Nascimentos'],
+deaths: ['Mortes', 'Falecimentos'],
+events: ['Eventos', 'Eventos_hist.C3.B3ricos'],
+holidays: ['Feriados_e_eventos_c.C3.ADclicos']
+}
+},
+selectedPage : {
+// https://pt.wikipedia.org/wiki/Wikipédia:Efemérides/15_de_maio
+nameFormatter : (monthName, dayNumber) =>
+`Wikipédia:Efemérides/${dayNumber}_${monthName}`,
+listElementSelector: 'body > ul li'
+},
+yearListElementRegEx : 
/^\s*(\d+)\s*(a\.C\.)?\s*[\u002D\u2013\u2014\u2212]\s(.+)/i
 }
 };
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ifc3716e80f8ddb2d30a2778b84a30c9cd5672501
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/services/mobileapps
Gerrit-Branch: master
Gerrit-Owner: Mhurd 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Fjalapeno 
Gerrit-Reviewer: GWicke 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Jhernandez 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Mobrovac 
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...WikimediaMessages[master]: MetaContactPages: Remove *s, required step moved to code

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373371 )

Change subject: MetaContactPages: Remove *s, required step moved to code
..


MetaContactPages: Remove *s, required step moved to code

Change-Id: Ie50f656e1dec2ceef0b0bd64b1ac959e76870c8f
---
M i18n/contactpage/en.json
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/i18n/contactpage/en.json b/i18n/contactpage/en.json
index 05289fc..ba60fa6 100644
--- a/i18n/contactpage/en.json
+++ b/i18n/contactpage/en.json
@@ -7,9 +7,9 @@
"contactpage-title-requestlicense": "Request a license form",
"contactpage-pagetext-requestlicense": "Please use the form below to 
contact us about using a Wikimedia trademark.",
"contactpage-subject-requestlicense": "Request to use a Wikimedia 
trademark",
-   "contactpage-license-request-username": "Username *",
+   "contactpage-license-request-username": "Username",
"contactpage-license-request-relevantsite": "Relevant Wikimedia site 
(if any)",
-   "contactpage-license-request-group": "Wikimedia chapter, thematic 
organization, or user group & title (if any) *",
+   "contactpage-license-request-group": "Wikimedia chapter, thematic 
organization, or user group & title (if any)",
"contactpage-license-request-title": "Title (if applicable)",
"contactpage-license-request-organization": "Organization (if 
applicable)",
"contactpage-license-request-organization-type": "Organization type (if 
applicable)",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie50f656e1dec2ceef0b0bd64b1ac959e76870c8f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikimediaMessages
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Bartosz Dziewoński 
Gerrit-Reviewer: Deskana 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Fix error text color in dark mode

2017-08-24 Thread Cooltey (Code Review)
Cooltey has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373712 )

Change subject: Fix error text color in dark mode
..

Fix error text color in dark mode

In this update
 - Add Red75-Sunset Red to colors.xml
 - Add two styles for light mode and dark mode theme
 - Check current theme to give matched text appearance for the error text.

Bug: T173091
Change-Id: I3d5030f4fe173e0e50904a5ec771e876082a5e57
---
M app/src/main/java/org/wikipedia/views/TextInputDialog.java
M app/src/main/res/values/colors.xml
M app/src/main/res/values/styles.xml
3 files changed, 17 insertions(+), 0 deletions(-)


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

diff --git a/app/src/main/java/org/wikipedia/views/TextInputDialog.java 
b/app/src/main/java/org/wikipedia/views/TextInputDialog.java
index f7e44d6..f676bdc 100644
--- a/app/src/main/java/org/wikipedia/views/TextInputDialog.java
+++ b/app/src/main/java/org/wikipedia/views/TextInputDialog.java
@@ -15,6 +15,7 @@
 import android.widget.EditText;
 
 import org.wikipedia.R;
+import org.wikipedia.WikipediaApp;
 import org.wikipedia.util.DeviceUtil;
 
 public final class TextInputDialog extends AlertDialog {
@@ -49,6 +50,12 @@
 editTextContainer = (TextInputLayout) 
rootView.findViewById(R.id.text_input_container);
 super.setView(rootView);
 
+if (WikipediaApp.getInstance().getCurrentTheme().isLight()) {
+
editTextContainer.setErrorTextAppearance(R.style.TextInputLayout_LightThemeErrorTextAppearance);
+}else{
+
editTextContainer.setErrorTextAppearance(R.style.TextInputLayout_DarkThemeErrorTextAppearance);
+}
+
 editTextContainer.setErrorEnabled(true);
 return this;
 }
diff --git a/app/src/main/res/values/colors.xml 
b/app/src/main/res/values/colors.xml
index 07b569f..9072c79 100644
--- a/app/src/main/res/values/colors.xml
+++ b/app/src/main/res/values/colors.xml
@@ -22,6 +22,7 @@
 #2a4b8d 
 #223966
 #fee7e6 
+#FF6E6E 
 #d33 
 #b32424 
 
diff --git a/app/src/main/res/values/styles.xml 
b/app/src/main/res/values/styles.xml
index fa75205..7377ea3 100644
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -255,4 +255,13 @@
 @dimen/popup_menu_drop_down_horizontal_offset
 @dimen/popup_menu_drop_down_vertical_offset
 
+
+
+@color/red75
+
+
+
+@color/red50
+
+
 

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: widgets: Replace outdated colors with WikimediaUI palette ones

2017-08-24 Thread VolkerE (Code Review)
VolkerE has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373711 )

Change subject: widgets: Replace outdated colors with WikimediaUI palette ones
..

widgets: Replace outdated colors with WikimediaUI palette ones

Replacing outdated colors in core widgets with WikimediaUI color
palette ones. Also increasing contrast in one case ensuring
WCAG 2.0 level AA conformance.

Bug: T172850
Change-Id: Ic7cf0842275529372cdfbfddad4eb63fec4847ce
---
M resources/src/mediawiki.widgets/MediaSearch/mw.widgets.MediaResultWidget.css
M resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
M resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
3 files changed, 18 insertions(+), 14 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/11/373711/1

diff --git 
a/resources/src/mediawiki.widgets/MediaSearch/mw.widgets.MediaResultWidget.css 
b/resources/src/mediawiki.widgets/MediaSearch/mw.widgets.MediaResultWidget.css
index 2a47fa2..abd0f53 100644
--- 
a/resources/src/mediawiki.widgets/MediaSearch/mw.widgets.MediaResultWidget.css
+++ 
b/resources/src/mediawiki.widgets/MediaSearch/mw.widgets.MediaResultWidget.css
@@ -16,7 +16,7 @@
 }
 
 .mw-widget-mediaResultWidget-error {
-   background-color: #f3f3f3;
+   background-color: #f8f9fa;
 }
 
 .mw-widget-mediaResultWidget-thumbnail {
@@ -43,12 +43,16 @@
bottom: 0;
left: 0;
right: 0;
-   box-shadow: inset 0 0 0 1px #ccc;
+   box-shadow: inset 0 0 0 1px #c8ccd1;
 }
 
 .mw-widget-mediaResultWidget.oo-ui-optionWidget-highlighted,
 .mw-widget-mediaResultWidget.oo-ui-optionWidget-selected {
-   box-shadow: 0 0 0.3em #a7dcff, 0 0 0 #fff;
+   box-shadow: 0 0 2px #36c;
+
+   .mw-widget-mediaResultWidget-overlay {
+   box-shadow: inset 0 0 0 1px #36c;
+   }
 }
 
 .mw-widget-mediaResultWidget-error .mw-widget-mediaResultWidget-thumbnail {
diff --git a/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less 
b/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
index 4a59dae..3d59f67 100644
--- a/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
+++ b/resources/src/mediawiki.widgets/mw.widgets.StashedFileWidget.less
@@ -23,7 +23,7 @@
 .mw-widgets-stashedFileWidget-info {
height: 2.4em;
background-color: #fff;
-   border: 1px solid #ccc;
+   border: 1px solid #c8ccd1;
border-radius: 2px;
width: 100%;
display: table-cell;
@@ -49,7 +49,7 @@
float: left;
}
> .mw-widgets-stashedFileWidget-fileType {
-   color: #888;
+   color: #72777d;
float: right;
}
}
@@ -77,14 +77,14 @@
 
&.oo-ui-widget-disabled {
.mw-widgets-stashedFileWidget-info {
-   color: #ccc;
+   background-color: #eaecf0;
+   color: #72777d;
+   border-color: #c8ccd1;
text-shadow: 0 1px 1px #fff;
-   border-color: #ddd;
-   background-color: #f3f3f3;
 
> .oo-ui-iconElement-icon,
> .oo-ui-indicatorElement-indicator {
-   opacity: 0.2;
+   opacity: 0.15;
}
}
}
@@ -96,7 +96,7 @@
text-align: left;
padding: 0;
background-color: #fff;
-   border: 1px solid #ccc;
+   border: 1px solid #c8ccd1;
margin-bottom: 0.5em;
vertical-align: middle;
overflow: hidden;
@@ -115,7 +115,7 @@
 
> .mw-widgets-stashedFileWidget-noThumbnail-icon {
opacity: 0.4;
-   background-color: #ccc;
+   background-color: #c8ccd1;
height: 5.5em;
width: 5.5em;
}
@@ -157,7 +157,7 @@
}
 
.mw-widgets-stashedFileWidget-label {
-   color: #ccc;
+   color: #c8ccd1;
right: 0.5em;
}
 
diff --git a/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less 
b/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
index bbffe28..c47cc60 100644
--- a/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
+++ b/resources/src/mediawiki.widgets/mw.widgets.TitleWidget.less
@@ -10,7 +10,7 @@
line-height: normal;
 
&-description {
-   color: #888;
+   color: #72777d;
}
}
 
@@ -37,7 +37,7 @@
height: 3.75em;
left: 0;
&:not( 
.mw-widget-titleOptionWidget-hasImage ) {
-

[MediaWiki-commits] [Gerrit] mediawiki...TimedMediaHandler[wmf/1.30.0-wmf.15]: Disable Ogg Theora video transcodes in default config

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373692 )

Change subject: Disable Ogg Theora video transcodes in default config
..


Disable Ogg Theora video transcodes in default config

With WebM playback enabled via ogv.js, there's less reason to keep
the Ogg Theora video transcodes on Wikimedia or other sites.
Removing them by default in favor of just generating WebM.

This speeds encoding time and saves disk space, at the cost of
the WebM videos requiring more CPU in Safari/IE/Edge with the ogv.js
player shim.

Prep for removing them from Wikimedia due to ongoing tooling issues
with ffmpeg2theora.

Safe to merge after I68f22d7c goes out fully.

Bug: T172445
Change-Id: I2ffd2c6d0f87c53c0addc69515fdad803e192199
(cherry picked from commit 7437bb4c8e4d8caa683fcae4b61d9ef46d670385)
---
M TimedMediaHandler.php
1 file changed, 6 insertions(+), 2 deletions(-)

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



diff --git a/TimedMediaHandler.php b/TimedMediaHandler.php
index 80ac0ee..0cade78 100644
--- a/TimedMediaHandler.php
+++ b/TimedMediaHandler.php
@@ -135,7 +135,8 @@
 
// WebM VP8/Vorbis
// primary free/open video format
-   // supported by Chrome/Firefox/Opera but not Safari/IE/Edge
+   // supported by Chrome/Firefox/Opera natively
+   // plays back in Safari/IE/Edge via ogv.js
 
// Very low-bitrate web streamable WebM video
WebVideoTranscode::ENC_WEBM_160P,
@@ -158,8 +159,10 @@
// A 4K full high quality WebM stream
// WebVideoTranscode::ENC_WEBM_2160P,
 
+/*
// Ogg Theora/Vorbis
-   // Fallback for Safari/IE/Edge with ogv.js
+   // Optional fallback for Safari/IE/Edge with ogv.js
+   // Faster to encode & play back than WebM but less efficient.
 
// Requires twice the bitrate for same quality as VP8,
// and JS decoder can be slow, so shift to smaller sizes.
@@ -183,6 +186,7 @@
// Variable-bitrate HD Ogg stream
// for ogv.js on reasonably speedy machines
WebVideoTranscode::ENC_OGV_1080P,
+*/
 
 /*
// MP4 H.264/AAC

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2ffd2c6d0f87c53c0addc69515fdad803e192199
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TimedMediaHandler
Gerrit-Branch: wmf/1.30.0-wmf.15
Gerrit-Owner: Brion VIBBER 
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]: labs puppetmaster: get allowed servers from hiera rather tha...

2017-08-24 Thread Andrew Bogott (Code Review)
Andrew Bogott has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373710 )

Change subject: labs puppetmaster: get allowed servers from hiera rather than 
hard-coding
..


labs puppetmaster: get allowed servers from hiera rather than hard-coding

I finally figured out how to do this!

Change-Id: I6a45b68a6535b19af8c278979ca6b2214b21bd4d
---
M modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb
1 file changed, 3 insertions(+), 5 deletions(-)

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



diff --git a/modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb 
b/modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb
index 202af5a..ea303da 100644
--- a/modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb
+++ b/modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb
@@ -2,8 +2,6 @@
 path /resource_type
 auth any
 allow <%= @horizon_host %>
-
-# This should come from 
scope.function_hiera(['puppetmaster::servers']).values.flatten(1).map
-# but I absolutely can't make erb work properly
-allow labpuppetmaster1001.wikimedia.org
-allow labpuppetmaster1002.wikimedia.org
+<% scope.function_hiera(['puppetmaster::servers']).values.flatten(1).map { |p| 
p['worker'] }.sort.each do |server| -%>
+allow <%= server %>
+<% end -%>

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6a45b68a6535b19af8c278979ca6b2214b21bd4d
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott 
Gerrit-Reviewer: Andrew Bogott 
Gerrit-Reviewer: Giuseppe Lavagetto 
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]: labs puppetmaster: get allowed servers from hiera rather tha...

2017-08-24 Thread Andrew Bogott (Code Review)
Andrew Bogott has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373710 )

Change subject: labs puppetmaster: get allowed servers from hiera rather than 
hard-coding
..

labs puppetmaster: get allowed servers from hiera rather than hard-coding

I finally figured out how to do this!

Change-Id: I6a45b68a6535b19af8c278979ca6b2214b21bd4d
---
M modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb
1 file changed, 3 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/10/373710/1

diff --git a/modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb 
b/modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb
index 202af5a..83c0465 100644
--- a/modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb
+++ b/modules/role/templates/labs/puppetmaster/extra_auth_rules.conf.erb
@@ -2,8 +2,6 @@
 path /resource_type
 auth any
 allow <%= @horizon_host %>
-
-# This should come from 
scope.function_hiera(['puppetmaster::servers']).values.flatten(1).map
-# but I absolutely can't make erb work properly
-allow labpuppetmaster1001.wikimedia.org
-allow labpuppetmaster1002.wikimedia.org
+<% scope.function_hiera(['puppetmaster::servers']).values.flatten(1).map { |p| 
p['worker'] }.sort.each do |server| -%>
+allow = <%= server %>
+<% end -%>

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6a45b68a6535b19af8c278979ca6b2214b21bd4d
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]: Onboarding per-screen backgrounds follow-up.

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373707 )

Change subject: Onboarding per-screen backgrounds follow-up.
..


Onboarding per-screen backgrounds follow-up.

Change-Id: I1c33b18f94bb3aecbef41d4fc1549cf503e3b554
---
M 
app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
M app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml
M app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml
M app/src/main/res/layout/inflate_initial_onboarding_page_one.xml
M app/src/main/res/layout/inflate_initial_onboarding_page_three.xml
M app/src/main/res/layout/inflate_initial_onboarding_page_two.xml
6 files changed, 10 insertions(+), 17 deletions(-)

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



diff --git 
a/app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
 
b/app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
index 62dfb59..cdc8b60 100644
--- 
a/app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
+++ 
b/app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
@@ -1,12 +1,7 @@
 package org.wikipedia.descriptions;
 
-import android.os.Bundle;
 import android.support.annotation.NonNull;
-import android.support.v4.content.ContextCompat;
 import android.support.v4.view.PagerAdapter;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
 
 import org.wikipedia.R;
 import org.wikipedia.onboarding.OnboardingFragment;
@@ -15,13 +10,6 @@
 
 @NonNull public static DescriptionEditTutorialFragment newInstance() {
 return new DescriptionEditTutorialFragment();
-}
-
-@Override
-public View onCreateView(LayoutInflater inflater, ViewGroup container, 
Bundle savedInstanceState) {
-View view = super.onCreateView(inflater, container, 
savedInstanceState);
-view.setBackground(ContextCompat.getDrawable(getContext(), 
R.drawable.onboarding_gradient_background_90));
-return view;
 }
 
 @Override
diff --git 
a/app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml 
b/app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml
index 2125d85..99e41c7 100644
--- a/app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml
+++ b/app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml
@@ -7,4 +7,5 @@
 app:centeredImage="@drawable/illustration_description_onboard_1"
 app:imageSize="260dp"
 app:primaryText="@string/description_edit_tutorial_title_descriptions"
-
app:secondaryText="@string/description_edit_tutorial_title_descriptions_summary"
 />
\ No newline at end of file
+
app:secondaryText="@string/description_edit_tutorial_title_descriptions_summary"
+app:background="@drawable/onboarding_gradient_background_90"/>
\ No newline at end of file
diff --git 
a/app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml 
b/app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml
index 9ae200d..3d264e7 100644
--- a/app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml
+++ b/app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml
@@ -8,4 +8,5 @@
 app:imageSize="260dp"
 app:primaryText="@string/description_edit_tutorial_keep_it_short"
 
app:secondaryText="@string/description_edit_tutorial_keep_it_short_instructions"
-app:tertiaryText="@string/description_edit_tutorial_promise" />
\ No newline at end of file
+app:tertiaryText="@string/description_edit_tutorial_promise"
+app:background="@drawable/onboarding_gradient_background_90"/>
\ No newline at end of file
diff --git a/app/src/main/res/layout/inflate_initial_onboarding_page_one.xml 
b/app/src/main/res/layout/inflate_initial_onboarding_page_one.xml
index be998d3..44818a6 100644
--- a/app/src/main/res/layout/inflate_initial_onboarding_page_one.xml
+++ b/app/src/main/res/layout/inflate_initial_onboarding_page_one.xml
@@ -8,4 +8,5 @@
 app:centeredImage="@drawable/illustration_onboarding_explore"
 app:imageSize="160dp"
 app:primaryText="@string/onboarding_explore_title"
-app:secondaryText="@string/onboarding_explore_text" />
\ No newline at end of file
+app:secondaryText="@string/onboarding_explore_text"
+app:background="@drawable/onboarding_gradient_background_135"/>
\ No newline at end of file
diff --git a/app/src/main/res/layout/inflate_initial_onboarding_page_three.xml 
b/app/src/main/res/layout/inflate_initial_onboarding_page_three.xml
index 3cdef26..343dfdf 100644
--- a/app/src/main/res/layout/inflate_initial_onboarding_page_three.xml
+++ b/app/src/main/res/layout/inflate_initial_onboarding_page_three.xml
@@ -9,4 +9,5 @@
 app:imageSize="160dp"
 app:primaryText="@string/onboarding_analytics_title"

[MediaWiki-commits] [Gerrit] labs/striker[master]: Break in-process cache of model choice fields

2017-08-24 Thread BryanDavis (Code Review)
BryanDavis has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373708 )

Change subject: Break in-process cache of model choice fields
..

Break in-process cache of model choice fields

ChoiceFields which are initial as class variables will (may?) cache
results for the lifetime of the python execution environment. To break
this cache, use the __init__ method of the form instance to reset the
queryset used for validation.

Bug: T173963
Change-Id: Ia795114642328e8958f18c79c3d7c0dbfd9348af
---
M striker/tools/forms.py
1 file changed, 13 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/striker 
refs/changes/08/373708/1

diff --git a/striker/tools/forms.py b/striker/tools/forms.py
index 3e7d496..97c946f 100644
--- a/striker/tools/forms.py
+++ b/striker/tools/forms.py
@@ -266,8 +266,7 @@
 ),
 )
 license = forms.ModelChoiceField(
-queryset=SoftwareLicense.objects.filter(
-osi_approved=True).order_by('-recommended', 'slug'),
+queryset=SoftwareLicense.objects.none(),
 empty_label=_('-- Choose your software license --'),
 label=_('Default software license'),
 help_text=_(
@@ -276,12 +275,19 @@
 ).format(choose_a_license='https://choosealicense.com/'),
 )
 tags = forms.ModelMultipleChoiceField(
-queryset=ToolInfoTag.objects.all().order_by('name'),
+queryset=ToolInfoTag.objects.none(),
 widget=autocomplete.ModelSelect2Multiple(
 url='tools:tags_autocomplete',
 ),
 required=False,
 )
+
+def __init__(self, *args, **kwargs):
+super(ToolCreateForm, self).__init__(*args, **kwargs)
+self.fields['license'].queryset = SoftwareLicense.objects.filter(
+osi_approved=True).order_by('-recommended', 'slug')
+self.fields['tags'].queryset = ToolInfoTag.objects.all().order_by(
+'name')
 
 def clean_name(self):
 """Validate that name is available."""
@@ -305,13 +311,13 @@
 @parsleyfy
 class MaintainersForm(forms.Form):
 maintainers = MaintainerChoiceField(
-queryset=Maintainer.objects.all(),
+queryset=Maintainer.objects.none(),
 widget=autocomplete.ModelSelect2Multiple(
 url='tools:api:maintainer',
 ),
 )
 tools = forms.ModelMultipleChoiceField(
-queryset=ToolUser.objects.all(),
+queryset=ToolUser.objects.none(),
 widget=autocomplete.ModelSelect2Multiple(
 url='tools:api:tooluser',
 ),
@@ -332,3 +338,5 @@
 initial['tools'] = tool.tool_member_ids()
 kwargs['initial'] = initial
 super(MaintainersForm, self).__init__(*args, **kwargs)
+self.fields['maintainers'].queryset = Maintainer.objects.all()
+self.fields['tools'].queryset = ToolUser.objects.all()

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia795114642328e8958f18c79c3d7c0dbfd9348af
Gerrit-PatchSet: 1
Gerrit-Project: labs/striker
Gerrit-Branch: master
Gerrit-Owner: BryanDavis 

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


[MediaWiki-commits] [Gerrit] labs/striker[master]: Guard against LDAP modify with no changes for maintainers

2017-08-24 Thread BryanDavis (Code Review)
BryanDavis has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373709 )

Change subject: Guard against LDAP modify with no changes for maintainers
..

Guard against LDAP modify with no changes for maintainers

LDAP gets angry when you tell it that you are updating a collection but
the collection actually does not change. Check to ensure that the list
of maintainers for a tool has actually changed before saving to the
directory.

Change-Id: I06758d77f86fa14ffcb1f56aebe8ac9c2153122b
---
M striker/tools/views/tool.py
1 file changed, 11 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/striker 
refs/changes/09/373709/1

diff --git a/striker/tools/views/tool.py b/striker/tools/views/tool.py
index 8cc44ba..bf2e309 100644
--- a/striker/tools/views/tool.py
+++ b/striker/tools/views/tool.py
@@ -168,6 +168,13 @@
 form.cleaned_data['tools']
 )
 )
+
+# LDAP doesn't like it when we change the list to be the same
+# list, so make sure there is some delta before saving
+if old_members == new_members:
+messages.warning(req, _('Maintainers unchanged'))
+return shortcuts.redirect(tool.get_absolute_url())
+
 tool.members = new_members
 tool.save()
 
@@ -186,8 +193,8 @@
 else:
 # Add user to the mirrored group
 added.groups.add(maintainers.id)
-# Do not set tool as the notification target because the
-# framework does not understand LDAP models.
+# Do not set tool as the notification target because
+# the framework does not understand LDAP models.
 notify.send(
 recipient=added,
 sender=req.user,
@@ -216,8 +223,8 @@
 else:
 # Add user to the mirrored group
 removed.groups.remove(maintainers.id)
-# Do not set tool as the notification target because the
-# framework does not understand LDAP models.
+# Do not set tool as the notification target because
+# the framework does not understand LDAP models.
 notify.send(
 recipient=removed,
 sender=req.user,

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I06758d77f86fa14ffcb1f56aebe8ac9c2153122b
Gerrit-PatchSet: 1
Gerrit-Project: labs/striker
Gerrit-Branch: master
Gerrit-Owner: BryanDavis 

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Onboarding per-screen backgrounds follow-up.

2017-08-24 Thread Dbrant (Code Review)
Dbrant has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373707 )

Change subject: Onboarding per-screen backgrounds follow-up.
..

Onboarding per-screen backgrounds follow-up.

Change-Id: I1c33b18f94bb3aecbef41d4fc1549cf503e3b554
---
M 
app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
M app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml
M app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml
M app/src/main/res/layout/inflate_initial_onboarding_page_one.xml
M app/src/main/res/layout/inflate_initial_onboarding_page_three.xml
M app/src/main/res/layout/inflate_initial_onboarding_page_two.xml
6 files changed, 10 insertions(+), 17 deletions(-)


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

diff --git 
a/app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
 
b/app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
index 62dfb59..cdc8b60 100644
--- 
a/app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
+++ 
b/app/src/main/java/org/wikipedia/descriptions/DescriptionEditTutorialFragment.java
@@ -1,12 +1,7 @@
 package org.wikipedia.descriptions;
 
-import android.os.Bundle;
 import android.support.annotation.NonNull;
-import android.support.v4.content.ContextCompat;
 import android.support.v4.view.PagerAdapter;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
 
 import org.wikipedia.R;
 import org.wikipedia.onboarding.OnboardingFragment;
@@ -15,13 +10,6 @@
 
 @NonNull public static DescriptionEditTutorialFragment newInstance() {
 return new DescriptionEditTutorialFragment();
-}
-
-@Override
-public View onCreateView(LayoutInflater inflater, ViewGroup container, 
Bundle savedInstanceState) {
-View view = super.onCreateView(inflater, container, 
savedInstanceState);
-view.setBackground(ContextCompat.getDrawable(getContext(), 
R.drawable.onboarding_gradient_background_90));
-return view;
 }
 
 @Override
diff --git 
a/app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml 
b/app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml
index 2125d85..99e41c7 100644
--- a/app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml
+++ b/app/src/main/res/layout/inflate_description_edit_tutorial_page_one.xml
@@ -7,4 +7,5 @@
 app:centeredImage="@drawable/illustration_description_onboard_1"
 app:imageSize="260dp"
 app:primaryText="@string/description_edit_tutorial_title_descriptions"
-
app:secondaryText="@string/description_edit_tutorial_title_descriptions_summary"
 />
\ No newline at end of file
+
app:secondaryText="@string/description_edit_tutorial_title_descriptions_summary"
+app:background="@drawable/onboarding_gradient_background_90"/>
\ No newline at end of file
diff --git 
a/app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml 
b/app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml
index 9ae200d..3d264e7 100644
--- a/app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml
+++ b/app/src/main/res/layout/inflate_description_edit_tutorial_page_two.xml
@@ -8,4 +8,5 @@
 app:imageSize="260dp"
 app:primaryText="@string/description_edit_tutorial_keep_it_short"
 
app:secondaryText="@string/description_edit_tutorial_keep_it_short_instructions"
-app:tertiaryText="@string/description_edit_tutorial_promise" />
\ No newline at end of file
+app:tertiaryText="@string/description_edit_tutorial_promise"
+app:background="@drawable/onboarding_gradient_background_90"/>
\ No newline at end of file
diff --git a/app/src/main/res/layout/inflate_initial_onboarding_page_one.xml 
b/app/src/main/res/layout/inflate_initial_onboarding_page_one.xml
index be998d3..44818a6 100644
--- a/app/src/main/res/layout/inflate_initial_onboarding_page_one.xml
+++ b/app/src/main/res/layout/inflate_initial_onboarding_page_one.xml
@@ -8,4 +8,5 @@
 app:centeredImage="@drawable/illustration_onboarding_explore"
 app:imageSize="160dp"
 app:primaryText="@string/onboarding_explore_title"
-app:secondaryText="@string/onboarding_explore_text" />
\ No newline at end of file
+app:secondaryText="@string/onboarding_explore_text"
+app:background="@drawable/onboarding_gradient_background_135"/>
\ No newline at end of file
diff --git a/app/src/main/res/layout/inflate_initial_onboarding_page_three.xml 
b/app/src/main/res/layout/inflate_initial_onboarding_page_three.xml
index 3cdef26..343dfdf 100644
--- a/app/src/main/res/layout/inflate_initial_onboarding_page_three.xml
+++ b/app/src/main/res/layout/inflate_initial_onboarding_page_three.xml
@@ -9,4 +9,5 @@
 app:imageSize="160dp"
 app:primaryText="@string/onboarding_analytics_titl

[MediaWiki-commits] [Gerrit] VisualEditor/VisualEditor[master]: DiffElement: Fix insert/delete-to-end loops

2017-08-24 Thread Esanders (Code Review)
Esanders has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373706 )

Change subject: DiffElement: Fix insert/delete-to-end loops
..

DiffElement: Fix insert/delete-to-end loops

Bug: T173860
Change-Id: Ic1c2d997e3295d0cc4d5445c2ef10daa0e9abd54
---
M src/ui/elements/ve.ui.DiffElement.js
M tests/ui/ve.ui.DiffElement.test.js
2 files changed, 37 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/06/373706/1

diff --git a/src/ui/elements/ve.ui.DiffElement.js 
b/src/ui/elements/ve.ui.DiffElement.js
index 3a877e7..ea6a12e 100644
--- a/src/ui/elements/ve.ui.DiffElement.js
+++ b/src/ui/elements/ve.ui.DiffElement.js
@@ -194,7 +194,7 @@
  * Render the diff
  */
 ve.ui.DiffElement.prototype.renderDiff = function () {
-   var i, j, k, ilen, jlen, klen, nodes, move, documentSpacerNode, 
internalListSpacerNode, li, groupName,
+   var i, j, ilen, jlen, move, documentSpacerNode, internalListSpacerNode, 
li, groupName,
noChanges, group, headingNode, names, category, 
internalListGroup,
internalListDiffDiv, anyInternalListChanges, internalListItem,
documentNode = this.$document[ 0 ],
@@ -306,17 +306,17 @@
if ( this.oldDocChildren[ i ] === undefined ) {
 
// Everything else in the new doc is an insert
-   nodes = this.newDocChildren.slice( j );
-   for ( k = 0, klen = nodes.length; k < klen; k++ ) {
-   diffQueue.push( [ 'getNodeElements', nodes[ k 
], 'insert' ] );
+   while ( j < this.newDocChildren.length ) {
+   diffQueue.push( [ 'getNodeElements', 
this.newDocChildren[ j ], 'insert' ] );
+   j++;
}
 
} else if ( this.newDocChildren[ j ] === undefined ) {
 
// Everything else in the old doc is a remove
-   nodes = this.oldDocChildren.slice( i );
-   for ( k = 0, klen = nodes.length; k < klen; k++ ) {
-   diffQueue.push( [ 'getNodeElements', nodes[ k 
], 'remove' ] );
+   while ( i < this.oldDocChildren.length ) {
+   diffQueue.push( [ 'getNodeElements', 
this.oldDocChildren[ i ], 'remove' ] );
+   i++;
}
 
} else if ( this.remove.indexOf( i ) !== -1 ) {
diff --git a/tests/ui/ve.ui.DiffElement.test.js 
b/tests/ui/ve.ui.DiffElement.test.js
index befa3d3..d3e66dc 100644
--- a/tests/ui/ve.ui.DiffElement.test.js
+++ b/tests/ui/ve.ui.DiffElement.test.js
@@ -191,6 +191,36 @@
''
},
{
+   msg: 'Multi-node insert',
+   oldDoc: '',
+   newDoc: 'foobar',
+   expected:
+   '' +
+   '' +
+   '' +
+   '' +
+   'foo' +
+   '' +
+   '' +
+   'bar' +
+   ''
+   },
+   {
+   msg: 'Multi-node remove',
+   oldDoc: 'foobar',
+   newDoc: '',
+   expected:
+   '' +
+   'foo' +
+   '' +
+   '' +
+   'bar' +
+   '' +
+   '' +
+   '' +
+   ''
+   },
+   {
msg: 'Inline node inserted',
oldDoc: 'foo bar baz quux',
newDoc: 'foo bar  baz quux',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic1c2d997e3295d0cc4d5445c2ef10daa0e9abd54
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders 

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


[MediaWiki-commits] [Gerrit] mediawiki...mobileapps[master]: Fix 'year page' identification bug.

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/372909 )

Change subject: Fix 'year page' identification bug.
..


Fix 'year page' identification bug.

Fixes issue causing some events to appear without any associated pages.

Bug: T169277
Change-Id: Ia8e824c43995ce478679ade0ee94359f48ecce3b
---
M routes/on-this-day.js
M test/features/onthisday/on-this-day.js
2 files changed, 47 insertions(+), 8 deletions(-)

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



diff --git a/routes/on-this-day.js b/routes/on-this-day.js
index 6ef9f10..99e06e3 100644
--- a/routes/on-this-day.js
+++ b/routes/on-this-day.js
@@ -122,6 +122,17 @@
 }
 
 /**
+ * Determines whether anchor is for specific year page.
+ * @param  {!AnchorElement}  anchor
+ * @param  {!Integer}  year
+ * @param  {!String}  era
+ * @return {!boolean}
+ */
+function isAnchorForYear(anchor, year, era) {
+return new RegExp(`^${Math.abs(year)}\\s*${era}$`, 'i').test(anchor.title);
+}
+
+/**
  * Converts document list element to WMFEvent model.
  * A regular expression determines valid "year list elements" and separating 
their components.
  *  For example:'399 BC - Death of Socrates'
@@ -146,21 +157,20 @@
 }
 
 let year = parseInt(match[1], 10);
-
-// Negate BC years so they sort correctly
 const isBC = (match[2] !== undefined);
+let era = '';
 if (isBC) {
+// Negate BC years so they sort correctly
 year = -year;
+era = match[2];
 }
 
 const textAfterYear = match[3].trim();
 
-function isAnchorNotForYear(anchor) {
-return Math.abs(parseInt(anchor.title, 10)) !== Math.abs(year);
-}
-
 const pages = Array.from(listElement.querySelectorAll('a'))
-.filter(isAnchorNotForYear)
+.filter((anchor) => {
+return !isAnchorForYear(anchor, year, era);
+})
 .map(wmfPageFromAnchorElement);
 
 return new WMFEvent(textAfterYear, pages, year);
@@ -539,7 +549,8 @@
 eventsForYearListElements,
 reverseChronologicalWMFEventComparator,
 hydrateAllTitles,
-listElementsByHeadingID
+listElementsByHeadingID,
+isAnchorForYear
 }
 };
 };
diff --git a/test/features/onthisday/on-this-day.js 
b/test/features/onthisday/on-this-day.js
index 5c7232d..faf4f7a 100644
--- a/test/features/onthisday/on-this-day.js
+++ b/test/features/onthisday/on-this-day.js
@@ -450,4 +450,32 @@
 const listElements = 
onThisDay.testing.listElementsByHeadingID(document, ['Births']);
 assert.ok(listElements.length === 208);
 });
+
+describe('isAnchorForYear', () => {
+const a = domino.createDocument().createElement('A');
+it('correctly identifies anchor linking to year article', () => {
+a.title = '2008';
+assert.ok(onThisDay.testing.isAnchorForYear(a, 2008, ''));
+});
+it('correctly rejects anchor linking article starting with a year', () 
=> {
+a.title = '2008 Something something';
+assert.ok(!onThisDay.testing.isAnchorForYear(a, 2008, ''));
+});
+it('correctly rejects anchor linking article starting with a number', 
() => {
+a.title = '123456 Something something';
+assert.ok(!onThisDay.testing.isAnchorForYear(a, 2008, ''));
+});
+it('correctly rejects anchor linking article not starting with a 
year', () => {
+a.title = 'Something something';
+assert.ok(!onThisDay.testing.isAnchorForYear(a, 2008, ''));
+});
+it('correctly identifies anchor linking to year article with an era 
string', () => {
+a.title = '2008 BC';
+assert.ok(onThisDay.testing.isAnchorForYear(a, 2008, 'BC'));
+});
+it('correctly identifies anchor linking to year article with era 
string w/o space', () => {
+a.title = '55BC';
+assert.ok(onThisDay.testing.isAnchorForYear(a, 55, 'BC'));
+});
+});
 });

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia8e824c43995ce478679ade0ee94359f48ecce3b
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/services/mobileapps
Gerrit-Branch: master
Gerrit-Owner: Mhurd 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Fjalapeno 
Gerrit-Reviewer: GWicke 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Jhernandez 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Mobrovac 
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/core[master]: Disable rebound CDN purges for backlinks in HTMLCacheUpdateJob

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373705 )

Change subject: Disable rebound CDN purges for backlinks in HTMLCacheUpdateJob
..


Disable rebound CDN purges for backlinks in HTMLCacheUpdateJob

These are there to handle regeneration race conditions due to
replication lag. If there happens to already be a huge amount
of purges, the cost of this can be too high. Also, if the queue
is backlogged, then it is already delayed, so extra delayed jobs
do not help and just add to the backlog in that scenario.

Bug: T173710
Change-Id: Ida0bf44233072e1356a9fe63866d522e4bb2d0ca
---
M includes/jobqueue/jobs/HTMLCacheUpdateJob.php
1 file changed, 7 insertions(+), 3 deletions(-)

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



diff --git a/includes/jobqueue/jobs/HTMLCacheUpdateJob.php 
b/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
index 07d68e7..9d0f87c 100644
--- a/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
+++ b/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
@@ -139,9 +139,13 @@
__METHOD__
) );
 
-   // Update CDN
-   $u = CdnCacheUpdate::newFromTitles( $titleArray );
-   $u->doUpdate();
+   // Update CDN; call purge() directly so as to not bother with 
secondary purges
+   $urls = [];
+   foreach ( $titleArray as $title ) {
+   /** @var Title $title */
+   $urls = array_merge( $urls, $title->getCdnUrls() );
+   }
+   CdnCacheUpdate::purge( $urls );
 
// Update file cache
if ( $wgUseFileCache ) {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ida0bf44233072e1356a9fe63866d522e4bb2d0ca
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 
Gerrit-Reviewer: EBernhardson 
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]: RCFilters: Align remaining outdated greys to WikimediaUI pal...

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373677 )

Change subject: RCFilters: Align remaining outdated greys to WikimediaUI 
palette ones
..


RCFilters: Align remaining outdated greys to WikimediaUI palette ones

Replacing abandoned grey colors with appropriate colors from WikimediaUI
color palette.

Additional changes:
* Also simplified selector specificity in one case as OOUI code has already
changed.

Bug: T172850
Change-Id: I01e84d9a4d03ba894cbb67114821036b0ffe1ddb
---
M resources/src/mediawiki.rcfilters/styles/mw.rcfilters.mixins.less
M 
resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterMenuSectionOptionWidget.less
M 
resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.HighlightColorPickerWidget.less
M 
resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.ItemMenuOptionWidget.less
M resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.MenuSelectWidget.less
M resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.TagItemWidget.less
6 files changed, 15 insertions(+), 17 deletions(-)

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



diff --git a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.mixins.less 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.mixins.less
index 3b90f06..5a885ec 100644
--- a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.mixins.less
+++ b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.mixins.less
@@ -8,19 +8,18 @@
 }
 
 // This is a general mixin for a color circle
-.mw-rcfilters-mixin-circle( @color: white, @diameter: 2em, @padding: 0.5em, 
@border: false ) {
-   border-radius: 50%;
+.mw-rcfilters-mixin-circle( @color: #fff, @diameter: 2em, @padding: 0.5em, 
@border: false ) {
+   background-color: @color;
+   .box-sizing( border-box );
min-width: @diameter;
width: @diameter;
min-height: @diameter;
height: @diameter;
margin: @padding;
-   .box-sizing( border-box );
+   border-radius: 50%;
 
-   background-color: @color;
-
-   & when (@border = true) {
-   border: 1px solid #565656;
+   & when ( @border = true ) {
+   border: 1px solid #54595d;
}
 }
 
diff --git 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterMenuSectionOptionWidget.less
 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterMenuSectionOptionWidget.less
index 964f27e..c09ca1e 100644
--- 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterMenuSectionOptionWidget.less
+++ 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterMenuSectionOptionWidget.less
@@ -8,8 +8,7 @@
padding: 0 0.75em;
// Use a high specificity to override OOUI
.oo-ui-optionWidget.oo-ui-labelElement 
&-title.oo-ui-labelElement-label {
-   // TODO: Unify colors with official design palette
-   color: #555a5d;
+   color: #54595d;
.box-sizing( border-box );
display: inline-block;
line-height: normal;
diff --git 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.HighlightColorPickerWidget.less
 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.HighlightColorPickerWidget.less
index 667f528..0adec46 100644
--- 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.HighlightColorPickerWidget.less
+++ 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.HighlightColorPickerWidget.less
@@ -38,7 +38,7 @@
 
.mw-rcfilters-mixin-circle( @highlight-none, 
2em, 0.5em, true );
// Override border to dashed
-   border: 1px dashed #565656;
+   border: 1px dashed #54595d;
 

&.oo-ui-buttonOptionWidget.oo-ui-buttonElement-active,

&.oo-ui-buttonOptionWidget.oo-ui-optionWidget-pressed,
diff --git 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.ItemMenuOptionWidget.less
 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.ItemMenuOptionWidget.less
index 86bfafb..75ea061 100644
--- 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.ItemMenuOptionWidget.less
+++ 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.ItemMenuOptionWidget.less
@@ -6,11 +6,11 @@
.box-sizing( border-box );
 
&:not( :last-child ) {
-   border-bottom: solid 1px #eaecf0; // Base 80 AAA
+   border-bottom: 1px solid #eaecf0; // Base80 AAA
}
 
&-view-namespaces {
-   border-top: 5px solid #ccc;
+   border-top: 5px solid #c8ccd1;
 
&:first-child,
&.mw-rcfilters-ui-itemMenuOptionWidget-identifier-subject + 
&.mw-

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: RCFilters: Enable 'View newest'

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373679 )

Change subject: RCFilters: Enable 'View newest'
..


RCFilters: Enable 'View newest'

Keep the feature flag for 'live update'
but enable 'view newest' by default on RC.

Bug: T163426
Change-Id: I733cf99bbeb6d90d3aa21e87507c513354b81791
---
M resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.ChangesListViewModel.js
M resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js
M 
resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.ChangesListWrapperWidget.js
M resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
4 files changed, 8 insertions(+), 13 deletions(-)

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



diff --git 
a/resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.ChangesListViewModel.js 
b/resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.ChangesListViewModel.js
index d7042ff..0155a58 100644
--- 
a/resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.ChangesListViewModel.js
+++ 
b/resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.ChangesListViewModel.js
@@ -79,9 +79,7 @@
mw.rcfilters.dm.ChangesListViewModel.prototype.update = function ( 
changesListContent, $fieldset, isInitialDOM, separateOldAndNew ) {
var from = this.nextFrom;
this.valid = true;
-   if ( mw.rcfilters.featureFlags.liveUpdate ) {
-   this.extractNextFrom( $fieldset );
-   }
+   this.extractNextFrom( $fieldset );
this.checkForUnseenWatchedChanges( changesListContent );
this.emit( 'update', changesListContent, $fieldset, 
isInitialDOM, separateOldAndNew ? from : null );
};
@@ -112,7 +110,8 @@
 * @param {jQuery} $fieldset
 */
mw.rcfilters.dm.ChangesListViewModel.prototype.extractNextFrom = 
function ( $fieldset ) {
-   this.nextFrom = $fieldset.find( '.rclistfrom > a' ).data( 
'params' ).from;
+   var data = $fieldset.find( '.rclistfrom > a' ).data( 'params' );
+   this.nextFrom = data ? data.from : null;
};
 
/**
diff --git a/resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js 
b/resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js
index 9906119..a0e60d5 100644
--- a/resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js
+++ b/resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js
@@ -550,7 +550,7 @@
!this.filtersModel.hasConflict() &&
!this.changesListModel.getNewChangesExist() &&
!this.updatingChangesList &&
-   mw.rcfilters.featureFlags.liveUpdate;
+   this.changesListModel.getNextFrom();
};
 
/**
diff --git 
a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.ChangesListWrapperWidget.js
 
b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.ChangesListWrapperWidget.js
index 955e01d..a97ffe9 100644
--- 
a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.ChangesListWrapperWidget.js
+++ 
b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.ChangesListWrapperWidget.js
@@ -48,9 +48,7 @@
// Set up highlight containers
this.setupHighlightContainers( this.$element );
 
-   if ( mw.rcfilters.featureFlags.liveUpdate ) {
-   this.setupNewChangesButtonContainer( this.$element );
-   }
+   this.setupNewChangesButtonContainer( this.$element );
};
 
/* Initialization */
diff --git 
a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js 
b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
index 5a64edd..ad99e22 100644
--- a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
+++ b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
@@ -153,11 +153,9 @@
this.$element.find( '.cloption-submit' ).detach();
}
 
-   if ( mw.rcfilters.featureFlags.liveUpdate ) {
-   this.$element.find(
-   '.rclistfrom, .rcnotefrom, 
.rcoptions-listfromreset'
-   ).detach();
-   }
+   this.$element.find(
+   '.rclistfrom, .rcnotefrom, .rcoptions-listfromreset'
+   ).detach();
 
if ( this.$element.text().trim() === this.$element.find( 
'legend' ).text() ) {
this.$element.detach();

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I733cf99bbeb6d90d3aa21e87507c513354b81791
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner:

[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: Update DonationInterface lib

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/368848 )

Change subject: Update DonationInterface lib
..


Update DonationInterface lib

Gets the unified queue message handling from SmashPig. Now we don't
have to pass those settings through in the $wg variables!

Also gets some stricter country validation. This patch adds a lame
default.

Along the way, I'm fixing a misplaced Civi initialization. We should
do that at the outset, not rely on it happening in the next_date validation.

Bug: T95647
Change-Id: I379e7e9a37487696e8f1a44cf085f9a7e81b154e
---
M composer.lock
M sites/all/modules/recurring_globalcollect/recurring_globalcollect.drush.inc
M sites/all/modules/recurring_globalcollect/recurring_globalcollect.module
M sites/all/modules/wmf_audit/ingenico/orphan_rectify.drush.inc
M sites/all/modules/wmf_civicrm/DonationInterfaceFactory.php
5 files changed, 13 insertions(+), 12 deletions(-)

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



diff --git a/composer.lock b/composer.lock
index 1756b73..75c9d60 100644
--- a/composer.lock
+++ b/composer.lock
@@ -1793,7 +1793,7 @@
 "source": {
 "type": "git",
 "url": 
"https://gerrit.wikimedia.org/r/mediawiki/extensions/DonationInterface.git";,
-"reference": "b6eb7d3c689fd2a612f522d43cfd7d6b68218d02"
+"reference": "de827ca5d01b688c01b328810f7e323841fe2abb"
 },
 "require": {
 "addshore/psr-6-mediawiki-bagostuff-adapter": "0.1",
@@ -1834,7 +1834,7 @@
 "GPL-2.0"
 ],
 "description": "Wikimedia Foundation payment processing library",
-"time": "2017-07-12T20:59:10+00:00"
+"time": "2017-08-14T07:04:04+00:00"
 },
 {
 "name": "wikimedia/omnimail-silverpop",
diff --git 
a/sites/all/modules/recurring_globalcollect/recurring_globalcollect.drush.inc 
b/sites/all/modules/recurring_globalcollect/recurring_globalcollect.drush.inc
index 337562e..4c72709 100644
--- 
a/sites/all/modules/recurring_globalcollect/recurring_globalcollect.drush.inc
+++ 
b/sites/all/modules/recurring_globalcollect/recurring_globalcollect.drush.inc
@@ -52,6 +52,7 @@
  *
  */
 function drush_recurring_globalcollect() {
+  civicrm_initialize();
   wmf_common_create_smashpig_context( 'ingenico_recurring', 'ingenico' );
   wmf_common_set_smashpig_message_source( 'direct', 'Recurring GlobalCollect' 
);
   $date = drush_get_option('date');
diff --git 
a/sites/all/modules/recurring_globalcollect/recurring_globalcollect.module 
b/sites/all/modules/recurring_globalcollect/recurring_globalcollect.module
index ada9ee3..b3aa5f8 100644
--- a/sites/all/modules/recurring_globalcollect/recurring_globalcollect.module
+++ b/sites/all/modules/recurring_globalcollect/recurring_globalcollect.module
@@ -472,7 +472,6 @@
  * @return bool
  */
 function is_found_globalcollect_invalid_next_sched_dates() {
-  civicrm_initialize();
   $query = "
   SELECT count(*) FROM (
 SELECT
diff --git a/sites/all/modules/wmf_audit/ingenico/orphan_rectify.drush.inc 
b/sites/all/modules/wmf_audit/ingenico/orphan_rectify.drush.inc
index f357a63..8b25d07 100644
--- a/sites/all/modules/wmf_audit/ingenico/orphan_rectify.drush.inc
+++ b/sites/all/modules/wmf_audit/ingenico/orphan_rectify.drush.inc
@@ -36,10 +36,6 @@
  * Note: You'll need to include a bunch of exciting MediaWiki globals in your
  * Drupal settings.local.php, including default values that would normally be
  * read from extension.json.
- * $wgDonationInterfaceDefaultQueueServer
- * $wgDonationInterfaceQueues
- * $wgDonationInterfaceEnableQueue
- * $wgDonationInterfaceQueueMirrors
  * $wgDonationInterfaceOrphanCron
  * $wgDonationInterfaceGatewayAdapters
  * $wgDonationInterfaceForbiddenCountries
diff --git a/sites/all/modules/wmf_civicrm/DonationInterfaceFactory.php 
b/sites/all/modules/wmf_civicrm/DonationInterfaceFactory.php
index 251e87d..bb30f96 100644
--- a/sites/all/modules/wmf_civicrm/DonationInterfaceFactory.php
+++ b/sites/all/modules/wmf_civicrm/DonationInterfaceFactory.php
@@ -1,13 +1,18 @@
  true,
 'external_data' => $data,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I379e7e9a37487696e8f1a44cf085f9a7e81b154e
Gerrit-PatchSet: 4
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: XenoRyet 
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...VisualEditor[master]: Create wrapper paragraph when converting block image to inline

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373557 )

Change subject: Create wrapper paragraph when converting block image to inline
..


Create wrapper paragraph when converting block image to inline

This prevents the image jumping into another paragraph,
e.g. in a different table cell.

Move the logic for removing the old image out of MWMediaDialog
and into MWImageModel#insertImageNode.

Bug: T121449
Change-Id: Ibd7c92f3f90c382ceffd3e0defb12ba36a3786d2
---
M modules/ve-mw/dm/models/ve.dm.MWImageModel.js
M modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
2 files changed, 17 insertions(+), 13 deletions(-)

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



diff --git a/modules/ve-mw/dm/models/ve.dm.MWImageModel.js 
b/modules/ve-mw/dm/models/ve.dm.MWImageModel.js
index e7c0e9f..cdcf1a6 100644
--- a/modules/ve-mw/dm/models/ve.dm.MWImageModel.js
+++ b/modules/ve-mw/dm/models/ve.dm.MWImageModel.js
@@ -438,7 +438,7 @@
  * @throws {Error} Unknown image node type
  */
 ve.dm.MWImageModel.prototype.insertImageNode = function ( fragment ) {
-   var captionDoc, offset, contentToInsert,
+   var captionDoc, offset, contentToInsert, selectedNode,
nodeType = this.getImageNodeType(),
surfaceModel = fragment.getSurface();
 
@@ -446,12 +446,26 @@
return fragment;
}
 
+   selectedNode = fragment.getSelectedNode();
+
+   // If there was a previous node, remove it first
+   if ( selectedNode ) {
+   // Remove the old image
+   fragment.removeContent();
+   }
+
contentToInsert = this.getData();
 
switch ( nodeType ) {
case 'mwInlineImage':
-   // Try to put the image inside the nearest content node
-   offset = 
fragment.getDocument().data.getNearestContentOffset( 
fragment.getSelection().getRange().start );
+   if ( selectedNode.type === 'mwBlockImage' ) {
+   // If converting from a block image, create a 
wrapper paragraph for the inline image to go in.
+   fragment.insertContent( [ { type: 'paragraph', 
internal: { generated: 'wrapper' } }, { type: '/paragraph' } ] );
+   offset = 
fragment.getSelection().getRange().start + 1;
+   } else {
+   // Try to put the image inside the nearest 
content node
+   offset = 
fragment.getDocument().data.getNearestContentOffset( 
fragment.getSelection().getRange().start );
+   }
if ( offset > -1 ) {
fragment = fragment.clone( new 
ve.dm.LinearSelection( fragment.getDocument(), new ve.Range( offset ) ) );
}
diff --git a/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js 
b/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
index 36ca56d..0f15028 100644
--- a/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
+++ b/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
@@ -1393,16 +1393,6 @@
this.imageModel.updateImageNode( 
this.selectedNode, surfaceModel );
} else {
// Replacing an image or inserting a 
brand new one
-
-   // If there was a previous node, remove 
it first
-   if ( this.selectedNode ) {
-   // Remove the old image
-   this.fragment = 
this.getFragment().clone(
-   new 
ve.dm.LinearSelection( this.fragment.getDocument(), 
this.selectedNode.getOuterRange() )
-   );
-   this.fragment.removeContent();
-   }
-   // Insert the new image
this.fragment = 
this.imageModel.insertImageNode( this.getFragment() );
}
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibd7c92f3f90c382ceffd3e0defb12ba36a3786d2
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders 
Gerrit-Reviewer: DLynch 
Gerrit-Reviewer: Esanders 
Gerrit-Reviewer: Jforrester 
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]: Disable rebound CDN purges for backlinks in HTMLCacheUpdateJob

2017-08-24 Thread Aaron Schulz (Code Review)
Aaron Schulz has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373705 )

Change subject: Disable rebound CDN purges for backlinks in HTMLCacheUpdateJob
..

Disable rebound CDN purges for backlinks in HTMLCacheUpdateJob

These are there to handle regeneration race conditions due to
replication lag. If there happens to already be a huge amount
of purges, the cost of this can be too high. Also, if the queue
is backlogged, then it is already delayed, so extra delayed jobs
do not help and just add to the backlog in that scenario.

Bug: T173710
Change-Id: Ida0bf44233072e1356a9fe63866d522e4bb2d0ca
---
M includes/jobqueue/jobs/HTMLCacheUpdateJob.php
1 file changed, 7 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/05/373705/1

diff --git a/includes/jobqueue/jobs/HTMLCacheUpdateJob.php 
b/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
index 07d68e7..9d0f87c 100644
--- a/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
+++ b/includes/jobqueue/jobs/HTMLCacheUpdateJob.php
@@ -139,9 +139,13 @@
__METHOD__
) );
 
-   // Update CDN
-   $u = CdnCacheUpdate::newFromTitles( $titleArray );
-   $u->doUpdate();
+   // Update CDN; call purge() directly so as to not bother with 
secondary purges
+   $urls = [];
+   foreach ( $titleArray as $title ) {
+   /** @var Title $title */
+   $urls = array_merge( $urls, $title->getCdnUrls() );
+   }
+   CdnCacheUpdate::purge( $urls );
 
// Update file cache
if ( $wgUseFileCache ) {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ida0bf44233072e1356a9fe63866d522e4bb2d0ca
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[deployment]: Merge branch 'master' into deployment

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373703 )

Change subject: Merge branch 'master' into deployment
..


Merge branch 'master' into deployment

103c9598c Update list of processors in Gateway Reconciliation report
38e11771d Thank you generator fixes
7b15776f0 TY generator: add another replacement pattern for $date
13b39802e Update ja and pt-br thank you letters

Change-Id: Ie0cde0bf42acb1aec854d21f5b7909f9465cb59f
---
0 files changed, 0 insertions(+), 0 deletions(-)

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




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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie0cde0bf42acb1aec854d21f5b7909f9465cb59f
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: deployment
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: Ejegg 
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...DonationInterface[master]: Don't select a submethod if there are errors in personal info

2017-08-24 Thread Pcoombe (Code Review)
Pcoombe has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373704 )

Change subject: Don't select a submethod if there are errors in personal info
..

Don't select a submethod if there are errors in personal info

If there are errors in the personal info fields and the user tries
to select a submethod, do nothing other than highlight the errors.
This removes the confusing situation where there could be two
continue buttons on screen (from this, and from the iframe).

Bug: T149366
Change-Id: If7405408659f588e506179781ed7ab5874c0a04a
---
M modules/js/ext.donationInterface.forms.js
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/DonationInterface 
refs/changes/04/373704/1

diff --git a/modules/js/ext.donationInterface.forms.js 
b/modules/js/ext.donationInterface.forms.js
index 5b72dd3..edd1d43 100644
--- a/modules/js/ext.donationInterface.forms.js
+++ b/modules/js/ext.donationInterface.forms.js
@@ -129,12 +129,12 @@
$( '#paymentContinue' ).show();
}
 
-   // Submit on submethod click if valid, otherwise show continue 
button.
+   // Submit on submethod click if valid, otherwise do nothing.
$( 'input[name="payment_submethod"]' ).on( 'click', function () 
{
if ( di.validation.validate() ) {
di.forms.submit();
} else {
-   $( '#paymentContinue' ).show();
+   return false;
}
} );
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: If7405408659f588e506179781ed7ab5874c0a04a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/DonationInterface
Gerrit-Branch: master
Gerrit-Owner: Pcoombe 

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[deployment]: Merge branch 'master' into deployment

2017-08-24 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373703 )

Change subject: Merge branch 'master' into deployment
..

Merge branch 'master' into deployment

103c9598c Update list of processors in Gateway Reconciliation report
38e11771d Thank you generator fixes
7b15776f0 TY generator: add another replacement pattern for $date
13b39802e Update ja and pt-br thank you letters

Change-Id: Ie0cde0bf42acb1aec854d21f5b7909f9465cb59f
---
0 files changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/03/373703/1


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie0cde0bf42acb1aec854d21f5b7909f9465cb59f
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: deployment
Gerrit-Owner: Ejegg 

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Update Offline Library tutorial to have per-screen backgrounds

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373693 )

Change subject: Update Offline Library tutorial to have per-screen backgrounds
..


Update Offline Library tutorial to have per-screen backgrounds

Updates the generic onboarding activity components as needed to
implement the current design.  Adds an optional styleable declaration for
an onboarding screen background drawable.  Adds per-screen background
gradients as specified on the ticket.

Bug: T172185
Change-Id: I5aa8e76b0884f0e7a9a25376ac93e1283b580116
---
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testFocus-480dp-en-ltr-font1.0x-dark-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testFocus-480dp-en-ltr-font1.0x-dark-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testFocus-480dp-en-ltr-font1.0x-light-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testFocus-480dp-en-ltr-font1.0x-light-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testLayoutDirection-480dp-en-ltr-font1.0x-light-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testLayoutDirection-480dp-en-ltr-font1.0x-light-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testLayoutDirection-480dp-en-rtl-font1.0x-light-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testLayoutDirection-480dp-en-rtl-font1.0x-light-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testTheme-480dp-en-ltr-font1.0x-dark-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testTheme-480dp-en-ltr-font1.0x-dark-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testTheme-480dp-en-ltr-font1.0x-light-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testTheme-480dp-en-ltr-font1.0x-light-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testWidth-480dp-en-ltr-font1.0x-light-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testWidth-480dp-en-ltr-font1.0x-light-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testWidth-480dp-en-ltr-font1.5x-light-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testWidth-480dp-en-ltr-font1.5x-light-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testWidth-720dp-en-ltr-font1.0x-light-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testWidth-720dp-en-ltr-font1.0x-light-PAGE_TWO.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testWidth-720dp-en-ltr-font1.5x-light-PAGE_ONE.png
M 
app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testWidth-720dp-en-ltr-font1.5x-light-PAGE_TWO.png
M app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
M app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java
M app/src/main/java/org/wikipedia/onboarding/OnboardingPageView.java
A app/src/main/res/drawable/onboarding_gradient_background_offline_one.xml
A app/src/main/res/drawable/onboarding_gradient_background_offline_three.xml
A app/src/main/res/drawable/onboarding_gradient_background_offline_two.xml
M app/src/main/res/layout/fragment_onboarding_pager.xml
M app/src/main/res/layout/inflate_offline_tutorial_page_one.xml
M app/src/main/res/layout/inflate_offline_tutorial_page_three.xml
M app/src/main/res/layout/inflate_offline_tutorial_page_two.xml
M app/src/main/res/layout/view_onboarding_page.xml
M app/src/main/res/values/attrs.xml
32 files changed, 102 insertions(+), 65 deletions(-)

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



diff --git 
a/app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testFocus-480dp-en-ltr-font1.0x-dark-PAGE_ONE.png
 
b/app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testFocus-480dp-en-ltr-font1.0x-dark-PAGE_ONE.png
index bf7cf48..1b81a91 100644
--- 
a/app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testFocus-480dp-en-ltr-font1.0x-dark-PAGE_ONE.png
+++ 
b/app/screenshots-ref/org.wikipedia.descriptions.DescriptionEditTutorialPageViewTest.testFocus-480dp-en-ltr-font1.0x-dark-PAGE_ONE.png
Binary files differ
diff --git 
a/app/screenshots-ref/org.wikipedia.descriptions.Descriptio

[MediaWiki-commits] [Gerrit] wikimedia...SmashPig[master]: WX audit files: get at least date from sparse refunds

2017-08-24 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373702 )

Change subject: WX audit files: get at least date from sparse refunds
..

WX audit files: get at least date from sparse refunds

We'll need to do more work in the CRM layer to find the order ID by
contribution_tracking_id.

Bug: T173875
Change-Id: I0b27295a245f50eb96356c33d16173a4559a9566
---
M PaymentProviders/Ingenico/Audit/IngenicoAudit.php
A PaymentProviders/Ingenico/Tests/Data/sparseRefund.xml.gz
M PaymentProviders/Ingenico/Tests/phpunit/AuditTest.php
3 files changed, 25 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/SmashPig 
refs/changes/02/373702/1

diff --git a/PaymentProviders/Ingenico/Audit/IngenicoAudit.php 
b/PaymentProviders/Ingenico/Audit/IngenicoAudit.php
index 0ec05d2..09000ec 100644
--- a/PaymentProviders/Ingenico/Audit/IngenicoAudit.php
+++ b/PaymentProviders/Ingenico/Audit/IngenicoAudit.php
@@ -40,6 +40,8 @@
'OrderID' => 'gateway_parent_id',
'EffortID' => 'installment',
'DebitedCurrency' => 'gross_currency',
+   'DateDue' => 'date',
+   // Order matters. Prefer TransactionDateTime if it is present.
'TransactionDateTime' => 'date',
);
 
diff --git a/PaymentProviders/Ingenico/Tests/Data/sparseRefund.xml.gz 
b/PaymentProviders/Ingenico/Tests/Data/sparseRefund.xml.gz
new file mode 100644
index 000..0b29176
--- /dev/null
+++ b/PaymentProviders/Ingenico/Tests/Data/sparseRefund.xml.gz
Binary files differ
diff --git a/PaymentProviders/Ingenico/Tests/phpunit/AuditTest.php 
b/PaymentProviders/Ingenico/Tests/phpunit/AuditTest.php
index e63f1a3..3ef 100644
--- a/PaymentProviders/Ingenico/Tests/phpunit/AuditTest.php
+++ b/PaymentProviders/Ingenico/Tests/phpunit/AuditTest.php
@@ -114,4 +114,27 @@
);
$this->assertEquals( $expected, $actual, 'Did not parse 
chargeback correctly' );
}
+
+   /**
+* We get some refunds in a weird sparse format with OrderID zero and no
+* TransactionDateTime. At least get the ct_id and a date out of them.
+*/
+   public function testProcessSparseRefund() {
+   $processor = new IngenicoAudit();
+   $output = $processor->parseFile( __DIR__ . 
'/../Data/sparseRefund.xml.gz' );
+   $this->assertEquals( 1, count( $output ), 'Should have found 
one refund' );
+   $actual = $output[0];
+   $expected = array(
+   'gateway' => 'globalcollect', // TODO: switch to 
ingenico for Connect
+   'contribution_tracking_id' => '48987654',
+   'date' => 1503964800,
+   'gross' => 15,
+   'gateway_parent_id' => '0', // We'll need to find it by 
ct_id
+   'gateway_refund_id' => '0', // And we'll need to fill 
in this field
+   'installment' => '', // EffortID came in blank too
+   'gross_currency' => 'EUR',
+   'type' => 'refund',
+   );
+   $this->assertEquals( $expected, $actual, 'Did not parse refund 
correctly' );
+   }
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0b27295a245f50eb96356c33d16173a4559a9566
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/SmashPig
Gerrit-Branch: master
Gerrit-Owner: Ejegg 

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Offline Library onboarding follow-up.

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373697 )

Change subject: Offline Library onboarding follow-up.
..


Offline Library onboarding follow-up.

Change-Id: Ifa177a994d9ace313c75109e1695d80df30f3c6d
---
M app/src/main/java/org/wikipedia/feed/FeedFragment.java
M app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
M app/src/main/java/org/wikipedia/settings/Prefs.java
3 files changed, 20 insertions(+), 4 deletions(-)

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



diff --git a/app/src/main/java/org/wikipedia/feed/FeedFragment.java 
b/app/src/main/java/org/wikipedia/feed/FeedFragment.java
index 9c8e612..d612688 100644
--- a/app/src/main/java/org/wikipedia/feed/FeedFragment.java
+++ b/app/src/main/java/org/wikipedia/feed/FeedFragment.java
@@ -435,14 +435,18 @@
 }
 
 public void onViewCompilations() {
-startActivity(LocalCompilationsActivity.newIntent(getContext()));
+if (Prefs.isOfflineTutorialCardEnabled()) {
+
startActivityForResult(OfflineTutorialActivity.newIntent(getContext()),
+ACTIVITY_REQUEST_OFFLINE_TUTORIAL);
+} else {
+
startActivity(LocalCompilationsActivity.newIntent(getContext()));
+}
 }
 
 @Override
 public void onOnboardingPositiveAction(@NonNull Card card, @NonNull 
OnboardingCard.OnboardingAction action) {
 if (action == OnboardingCard.OnboardingAction.OFFLINE_LIBRARY) {
-
startActivityForResult(OfflineTutorialActivity.newIntent(getContext()),
-ACTIVITY_REQUEST_OFFLINE_TUTORIAL);
+onViewCompilations();
 }
 }
 }
@@ -515,7 +519,7 @@
 
 @Override
 public void compilationsClick() {
-startActivity(LocalCompilationsActivity.newIntent(getContext()));
+feedCallback.onViewCompilations();
 }
 }
 }
diff --git 
a/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java 
b/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
index d531b87..a7c0446 100644
--- a/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
+++ b/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
@@ -31,4 +31,12 @@
 setResult(RESULT_OK);
 finish();
 }
+
+@Override
+public void onBackPressed() {
+if (getFragment().onBackPressed()) {
+return;
+}
+finish();
+}
 }
diff --git a/app/src/main/java/org/wikipedia/settings/Prefs.java 
b/app/src/main/java/org/wikipedia/settings/Prefs.java
index 6c9c671..7f775c8 100644
--- a/app/src/main/java/org/wikipedia/settings/Prefs.java
+++ b/app/src/main/java/org/wikipedia/settings/Prefs.java
@@ -549,6 +549,10 @@
 setString(R.string.preference_key_compilation_cache, 
GsonMarshaller.marshal(compilations));
 }
 
+public static boolean isOfflineTutorialCardEnabled() {
+return 
getBoolean(R.string.preference_key_offline_onboarding_card_enabled, true);
+}
+
 public static void setOfflineTutorialCardEnabled(boolean enabled) {
 setBoolean(R.string.preference_key_offline_onboarding_card_enabled, 
enabled);
 }

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

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

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: TY generator: add another replacement pattern for $date

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373684 )

Change subject: TY generator: add another replacement pattern for $date
..


TY generator: add another replacement pattern for $date

Maybe this is too forgiving?

Change-Id: I6fab96de49fe8cf6d5d9c186be643f7408202ef4
---
M sites/all/modules/thank_you/generators/ThankYou.php
1 file changed, 2 insertions(+), 0 deletions(-)

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



diff --git a/sites/all/modules/thank_you/generators/ThankYou.php 
b/sites/all/modules/thank_you/generators/ThankYou.php
index 9eb26cd..742c4ea 100644
--- a/sites/all/modules/thank_you/generators/ThankYou.php
+++ b/sites/all/modules/thank_you/generators/ThankYou.php
@@ -21,6 +21,8 @@
'/\[last name\]/' => '{{ last_name }}',
 
'/\[date\]/' => '{{ receive_date }}',
+
+   '/\$date/' => '{{ receive_date }}',
'/\[amount\]/' => '{{ (currency ~ " " ~ amount) | 
l10n_currency(locale) }}',
'/\[contributionId\]/' => '{{ transaction_id }}',
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6fab96de49fe8cf6d5d9c186be643f7408202ef4
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: XenoRyet 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: Thank you generator fixes

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373681 )

Change subject: Thank you generator fixes
..


Thank you generator fixes

MW parser output now wraps everything in a div, so we don't need the
 tags. Also, add an omitted 'use' statement.

Change-Id: I483bc7937ca7b082c8192bfc8236c7d146c2636d
---
M sites/all/modules/thank_you/generators/RenderTranslatedPage.php
1 file changed, 6 insertions(+), 5 deletions(-)

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



diff --git a/sites/all/modules/thank_you/generators/RenderTranslatedPage.php 
b/sites/all/modules/thank_you/generators/RenderTranslatedPage.php
index 68de60a..f13922c 100644
--- a/sites/all/modules/thank_you/generators/RenderTranslatedPage.php
+++ b/sites/all/modules/thank_you/generators/RenderTranslatedPage.php
@@ -1,4 +1,5 @@
  tags (so there is only
-   // one top level node) and doing a multibyte conversion from 
whatever PHP is running under
-   // into UTF-8 (so that loadXML() doesn't throw a bitch fit and 
fail to load)
+   // Load the partial DOM into a document doing a multibyte 
conversion
+   // from whatever PHP is running under into UTF-8 (so that 
loadXML()
+   // doesn't throw a bitch fit and fail to load)
$dom = new \DOMDocument( '1.0', 'UTF-8' );
$dom->preserveWhiteSpace = false;
-   $dom->loadXML( '' . $j['parse']['text']['*'] . 
'' );
+   $dom->loadXML( $j['parse']['text']['*'] );
$dom->encoding = 'UTF-8';
$xpath = new \DOMXPath( $dom );
 
@@ -324,7 +325,7 @@
$node->parentNode->removeChild( $node );
}
 
-   // Save it, not outputting the freaking  header and 
 tags
+   // Save it, not outputting the freaking  header and 
wrapper div
$result = array();
$dom->formatOutput = true;
foreach( $dom->firstChild->childNodes as $node ) {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I483bc7937ca7b082c8192bfc8236c7d146c2636d
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: XenoRyet 
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...LoginNotify[wmf/1.30.0-wmf.15]: Fix check

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373701 )

Change subject: Fix check
..


Fix check

Bug: T173888
Change-Id: I2643f7cbcdf6c9ad8dff8b6369a5ba6e402684b3
(cherry picked from commit 8acdeae44d231cd7672f1800aac04d67b276bc27)
---
M includes/LoginNotify.php
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/includes/LoginNotify.php b/includes/LoginNotify.php
index 99c46cf..df2ddc2 100644
--- a/includes/LoginNotify.php
+++ b/includes/LoginNotify.php
@@ -289,9 +289,9 @@
$dbrLocal
);
 
-   if ( $res ) {
+   if ( $res === self::USER_KNOWN ) {
$lb->reuseConnection( $dbrLocal 
);
-   return self::USER_KNOWN;
+   return $res;
}
if ( $result === self::USER_NO_INFO
 && 
$this->userHasCheckUserData( $user->getId(), $dbr )

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2643f7cbcdf6c9ad8dff8b6369a5ba6e402684b3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/LoginNotify
Gerrit-Branch: wmf/1.30.0-wmf.15
Gerrit-Owner: MaxSem 
Gerrit-Reviewer: MaxSem 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: Update ja and pt-br thank you letters

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373683 )

Change subject: Update ja and pt-br thank you letters
..


Update ja and pt-br thank you letters

Bug: T173809
Change-Id: Ie3e8dba2b83855a67ddf935e4d805e2625302c8d
---
M sites/all/modules/thank_you/templates/html/thank_you.ja.html
M sites/all/modules/thank_you/templates/html/thank_you.pt-br.html
2 files changed, 52 insertions(+), 28 deletions(-)

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



diff --git a/sites/all/modules/thank_you/templates/html/thank_you.ja.html 
b/sites/all/modules/thank_you/templates/html/thank_you.ja.html
index 24a26b2..e91c212 100644
--- a/sites/all/modules/thank_you/templates/html/thank_you.ja.html
+++ b/sites/all/modules/thank_you/templates/html/thank_you.ja.html
@@ -5,30 +5,43 @@
 ご寄付くださったみなさまへ
 {%endif%}
 
-ウィキメディア財団に{{ (currency ~ " " ~ amount) | l10n_currency(locale) 
}}の寄附をお寄せ頂き、ありがとうございました。ウィキメディア財団は非営利組織で、ウィキペディアをはじめ、その他の自由な知識を無料で提供するプロジェクトをサポートしています。私たちの使命は、世界中で最もアクセスできる包括的で自由な知識の源を構築することです。
+このたびは、ウィキペディアとウィキメディア財団へのご支援を頂きありがとうございました。あなたの {{ (currency ~ " " ~ 
amount) | l10n_currency(locale) }} 
ご寄付はウィキペディアを支え、誰もがアクセスできる自由な知識の未来の確保のために役立ちます。
 
-{% if "RecurringRestarted" in contribution_tags %} 
毎月の定期寄付が引き落されないという技術的な問題が発生しておりましたが、先般これを解決いたしました。これからの寄付につきましては通常通り引き落とされます。停止期間の引き落としを改めて行うことは御座いません。皆様の辛抱とご支援に深く感謝致します。もし何かご質問がございましたら、どうぞ遠慮なく
 don...@wikimedia.org までお寄せください。 {%endif%}
+{% if "RecurringRestarted" in contribution_tags %}
+毎月の定期寄付が引き落されないという技術的な問題が発生しておりましたが、先般これを解決いたしました。これからの寄付につきましては通常通り引き落とされます。停止期間の引き落としを改めて行うことは御座いません。皆様の辛抱とご支援に深く感謝致します。もし何かご質問がございましたら、どうぞ遠慮なく
 don...@wikimedia.org までお寄せください。
+{%endif%}
 
-{% if "UnrecordedCharge" in contribution_tags %} 
一部の支援者様におきまして、お寄せいただきました寄付の確認をお受け取り頂けないという技術的な問題が発生しておりましたが、先ごろ解決致しました。このメールは 
$date にお寄せ下さいました寄付への感謝の手紙としてお受け取りください。皆様の辛抱とご支援に感謝いたします。もし何かご質問がございましたら、どうぞ遠慮なく 
don...@wikimedia.org までお寄せください。 {%endif%}
+{% if "UnrecordedCharge" in contribution_tags %}
+一部の支援者様におきまして、お寄せいただきました寄付の確認をお受け取り頂けないという技術的な問題が発生しておりましたが、先ごろ解決致しました。このメールは
 {{ receive_date }} 
にお寄せ下さいました寄付への感謝の手紙としてお受け取りください。皆様の辛抱とご支援に感謝いたします。もし何かご質問がございましたら、どうぞ遠慮なく 
don...@wikimedia.org までお寄せください。
+{%endif%}
 
-知識は基本的な人権であると私たちは考えています。人類がデジタルの未来に突入していることから、私たちには、オンラインで知識にアクセスするための、オープンで、アクセス可能で、公開されたスペースが必要です。ウィキメディアこそがそのスペースなのです。ウィキメディアは、地球上の何百もの言語で、人々により、人々に対して自由な知識をお届けしているのです。
+
+  
ウィキペディアは力強い考え方のおかげで実現できています。その考え方とは、世界の知識の構築、そして誰もがどこからでもその知識に自由にアクセスできるようにする作業に、あなたや私のような人たちがに参加できるということです。
+
 
-年間を通じ、南極大陸を含めあらゆる大陸の人々がウィキペディアの編集に参加し、閲覧しています。およそ5億人の人々が、文化遺産の保護から、癌検知の改善、また宿題のリサーチまで、あらゆることを求めて、毎月ウィキペディアで調べています。皆、学ぶことが目的なのです。ウィキペディアを読み、発見するのです。
+いまあなたがウィキペディアを何時間でも読んでいられるのは、何百万人というボランティアの寄稿者や支援者のおかげです。ウィキペディアの記事数は4000万件以上、自由利用が許可された画像数は3500万以上あり、ウィキペディアはほぼどのような疑問にも答えることができ、今までに経験したことのない世界へと皆さんをいざないます。
 
-誰もが「ウィキペディアン」になれます。ウィキペディアで探しているものが見つからなければ、それは自分で作成できますhttps:///ja.wikipedia.org/wiki/Special:UserLogin?type=signup&campaign=lila2015";>自身で作成。様々な記事、言葉、画像、データは、知識を世界中で共有しようとする様々なボランティア達のコミュニティによって作成されているのです。
+皆さんの寄付は、自由な知識を現実的で実践的な方法で作成、共有するために使われます。ウィキペディアを、早く、安全に、世界中の誰もがアクセスできるようにするために。データ通信料金が高く、インターネットアクセスが難しい地域でも、無料でウィキペディアにアクセスできるように。アナログアーカイブに閉じ込められた知識のデジタル化に努力する人たちを支援するために。開かれたインターネットを脅かす脅威からウィキペディアを守り、自由な知識を守るために。
 
-私たちはいつも、どうすれば自分たちのインパクトを高められるかを考え、明日のウィキペディアと姉妹プロジェクトが、今日よりもより正確で、情報豊かで、アクセス可能になるよう努力しています。皆様からのご寄附がそれを助けてくれるのです。
+皆さんのご支援は、あなたがどこにいようとも、今必要な情報を見つけることができるようになることを意味します。例えば、ディナーパーティで友達と賭けをしてWikipediaで正解を得て決着をつけたり、私たちを囲む世界を理解するために使ったりできます。
 
-私たちがさらにもう一年成長し皆に良い影響力となるようご協力くださりありがとうございます。
+
+  Wikipediaに寄付いただくことは、この強固なアイデアを擁護していただくことです。
+
 
-ウィキメディア財団
+ウィキペディアは今後も、進化し、成長し、新しい課題に立ち向かっていきます。私たちは、こうした課題の克服に奮い立ち、さらに前進していこうと考えています。皆さんの寄付がその支えとなります。皆さんのご支援にどんなにお礼を言っても言いつくせません。私たちの将来への投資と、私たちとともに旅をしてくださる皆さんに、ウィキメディア財団を代表して感謝申し上げます。
 
-多くの会社で、従業員の寄付に対するマッチングを行っています。お勤め先がhttps://wikimediafoundation.org/wiki/Matching_Gifts/form";>法人マッチング・ギフトプログラムを実施しているかご確認ください。
+Katherine Maher
+Wikimedia財団 エグゼクティブディレクター
 
-お控え:あなたから {{ receive_date }} にいただいた寄付の金額は {{ (currency ~ " " ~ amount) | 
l10n_currency(locale) }} で、寄付番号は {{ transaction_id }} です。
+多くの雇用主の方が、寛大にも、従業員の寄付額に連動する寄付をしてくださっています。皆さんの雇用主が https://wikimediafoundation.org/wiki/Matching_Gifts/form";>コーポレートマッチングギフト制度に参画されているかご確認ください。
 寄付の記録:寄付番号{{ transaction_id }}、{{ receive_date }} {{ (currency ~ " " ~ amount) 
| l10n_currency(locale) }}.
 
-{% if recurring %} 
今回の寄付は、毎月の定期寄付の一環として承りました。停止のご連絡をいただくまで、ウィキメディア財団への寄付金引き落としが継続します。停止を希望される方は、https://wikimediafoundation.org/wiki/Special:LandingCheck?landing_page=Cancel_or_change_recurring_payments&basic=true&language={{
 locale }}">停止方法をご覧ください。 {%endif%}
+{% if recurring %}
+今回の寄付は、毎月の定期寄付の一環として承りました。停止のご連絡をいただくまで、ウィキメディア財団への寄付金引き落としが継続します。停止を希望される方は、https://wikimediafoundation.org/wiki/Special:LandingCheck?landing_page=Cancel_or_change_recurring_payments&basic=true&language={{
 locale }}">停止方法をご覧ください。
+{%endif%}
 
-この書面はお寄せいただきました寄付の記録としてご利用いただけます。この寄付に関連

[MediaWiki-commits] [Gerrit] mediawiki...LoginNotify[wmf/1.30.0-wmf.15]: Fix check

2017-08-24 Thread MaxSem (Code Review)
MaxSem has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373701 )

Change subject: Fix check
..

Fix check

Bug: T173888
Change-Id: I2643f7cbcdf6c9ad8dff8b6369a5ba6e402684b3
(cherry picked from commit 8acdeae44d231cd7672f1800aac04d67b276bc27)
---
M includes/LoginNotify.php
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/LoginNotify 
refs/changes/01/373701/1

diff --git a/includes/LoginNotify.php b/includes/LoginNotify.php
index 99c46cf..df2ddc2 100644
--- a/includes/LoginNotify.php
+++ b/includes/LoginNotify.php
@@ -289,9 +289,9 @@
$dbrLocal
);
 
-   if ( $res ) {
+   if ( $res === self::USER_KNOWN ) {
$lb->reuseConnection( $dbrLocal 
);
-   return self::USER_KNOWN;
+   return $res;
}
if ( $result === self::USER_NO_INFO
 && 
$this->userHasCheckUserData( $user->getId(), $dbr )

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2643f7cbcdf6c9ad8dff8b6369a5ba6e402684b3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/LoginNotify
Gerrit-Branch: wmf/1.30.0-wmf.15
Gerrit-Owner: MaxSem 

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


[MediaWiki-commits] [Gerrit] mediawiki...LoginNotify[master]: Fix check

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373699 )

Change subject: Fix check
..


Fix check

Bug: T173888
Change-Id: I2643f7cbcdf6c9ad8dff8b6369a5ba6e402684b3
---
M includes/LoginNotify.php
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/includes/LoginNotify.php b/includes/LoginNotify.php
index 06376f1..aa59964 100644
--- a/includes/LoginNotify.php
+++ b/includes/LoginNotify.php
@@ -292,9 +292,9 @@
$dbrLocal
);
 
-   if ( $res ) {
+   if ( $res === self::USER_KNOWN ) {
$lb->reuseConnection( $dbrLocal 
);
-   return self::USER_KNOWN;
+   return $res;
}
if ( $result === self::USER_NO_INFO
 && 
$this->userHasCheckUserData( $user->getId(), $dbr )

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2643f7cbcdf6c9ad8dff8b6369a5ba6e402684b3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/LoginNotify
Gerrit-Branch: master
Gerrit-Owner: MaxSem 
Gerrit-Reviewer: Niharika29 
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]: openstack: fix labtest wmflabsorg-domainadminenv.sh.erb

2017-08-24 Thread Rush (Code Review)
Rush has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373700 )

Change subject: openstack: fix labtest wmflabsorg-domainadminenv.sh.erb
..


openstack: fix labtest wmflabsorg-domainadminenv.sh.erb

Bug: T171494
Change-Id: I041a3b167ceac84a98b62d4a7735a5f4a2d10eaf
---
M modules/profile/manifests/openstack/labtest/keystone/service.pp
1 file changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/modules/profile/manifests/openstack/labtest/keystone/service.pp 
b/modules/profile/manifests/openstack/labtest/keystone/service.pp
index 0999378..4e2b1f1 100644
--- a/modules/profile/manifests/openstack/labtest/keystone/service.pp
+++ b/modules/profile/manifests/openstack/labtest/keystone/service.pp
@@ -16,9 +16,9 @@
 $wiki_consumer_secret = 
hiera('profile::openstack::labtest::keystone::wiki_consumer_secret'),
 $wiki_access_token = 
hiera('profile::openstack::labtest::keystone::wiki_access_token'),
 $wiki_access_secret = 
hiera('profile::openstack::labtest::keystone::wiki_access_secret'),
-$wmflabsdotorg_admin = 
hiera('profile::openstack::base::designate::wmflabsdotorg_admin'),
-$wmflabsdotorg_pass = 
hiera('profile::openstack::base::designate::wmflabsdotorg_pass'),
-$wmflabsdotorg_project = 
hiera('profile::openstack::base::designate::wmflabsdotorg_project'),
+$wmflabsdotorg_admin = 
hiera('profile::openstack::labtest::designate::wmflabsdotorg_admin'),
+$wmflabsdotorg_pass = 
hiera('profile::openstack::labtest::designate::wmflabsdotorg_pass'),
+$wmflabsdotorg_project = 
hiera('profile::openstack::labtest::designate::wmflabsdotorg_project'),
 ) {
 
 package {'mysql-server':

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I041a3b167ceac84a98b62d4a7735a5f4a2d10eaf
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Rush 
Gerrit-Reviewer: Rush 
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]: openstack: fix labtest wmflabsorg-domainadminenv.sh.erb

2017-08-24 Thread Rush (Code Review)
Rush has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373700 )

Change subject: openstack: fix labtest wmflabsorg-domainadminenv.sh.erb
..

openstack: fix labtest wmflabsorg-domainadminenv.sh.erb

Bug: T171494
Change-Id: I041a3b167ceac84a98b62d4a7735a5f4a2d10eaf
---
M modules/profile/manifests/openstack/labtest/keystone/service.pp
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/00/373700/1

diff --git a/modules/profile/manifests/openstack/labtest/keystone/service.pp 
b/modules/profile/manifests/openstack/labtest/keystone/service.pp
index 0999378..4e2b1f1 100644
--- a/modules/profile/manifests/openstack/labtest/keystone/service.pp
+++ b/modules/profile/manifests/openstack/labtest/keystone/service.pp
@@ -16,9 +16,9 @@
 $wiki_consumer_secret = 
hiera('profile::openstack::labtest::keystone::wiki_consumer_secret'),
 $wiki_access_token = 
hiera('profile::openstack::labtest::keystone::wiki_access_token'),
 $wiki_access_secret = 
hiera('profile::openstack::labtest::keystone::wiki_access_secret'),
-$wmflabsdotorg_admin = 
hiera('profile::openstack::base::designate::wmflabsdotorg_admin'),
-$wmflabsdotorg_pass = 
hiera('profile::openstack::base::designate::wmflabsdotorg_pass'),
-$wmflabsdotorg_project = 
hiera('profile::openstack::base::designate::wmflabsdotorg_project'),
+$wmflabsdotorg_admin = 
hiera('profile::openstack::labtest::designate::wmflabsdotorg_admin'),
+$wmflabsdotorg_pass = 
hiera('profile::openstack::labtest::designate::wmflabsdotorg_pass'),
+$wmflabsdotorg_project = 
hiera('profile::openstack::labtest::designate::wmflabsdotorg_project'),
 ) {
 
 package {'mysql-server':

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I041a3b167ceac84a98b62d4a7735a5f4a2d10eaf
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Rush 

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


[MediaWiki-commits] [Gerrit] mediawiki...LoginNotify[master]: Fix check

2017-08-24 Thread MaxSem (Code Review)
MaxSem has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373699 )

Change subject: Fix check
..

Fix check

Bug: T173888
Change-Id: I2643f7cbcdf6c9ad8dff8b6369a5ba6e402684b3
---
M includes/LoginNotify.php
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/LoginNotify 
refs/changes/99/373699/1

diff --git a/includes/LoginNotify.php b/includes/LoginNotify.php
index 06376f1..aa59964 100644
--- a/includes/LoginNotify.php
+++ b/includes/LoginNotify.php
@@ -292,9 +292,9 @@
$dbrLocal
);
 
-   if ( $res ) {
+   if ( $res === self::USER_KNOWN ) {
$lb->reuseConnection( $dbrLocal 
);
-   return self::USER_KNOWN;
+   return $res;
}
if ( $result === self::USER_NO_INFO
 && 
$this->userHasCheckUserData( $user->getId(), $dbr )

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2643f7cbcdf6c9ad8dff8b6369a5ba6e402684b3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/LoginNotify
Gerrit-Branch: master
Gerrit-Owner: MaxSem 

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Add Offline Library onboarding tutorial screens

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373678 )

Change subject: Add Offline Library onboarding tutorial screens
..


Add Offline Library onboarding tutorial screens

TODO (separately): add per-screen background gradients

Bug: T172185
Change-Id: Id12acd876b640cd28e85589ea61a3bae54931607
---
M app/src/main/AndroidManifest.xml
M app/src/main/java/org/wikipedia/Constants.java
M app/src/main/java/org/wikipedia/feed/FeedFragment.java
A app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
A app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java
A app/src/main/java/org/wikipedia/offline/OfflineTutorialPage.java
A app/src/main/java/org/wikipedia/offline/OfflineTutorialPagerAdapter.java
M app/src/main/java/org/wikipedia/settings/Prefs.java
A app/src/main/res/drawable/ic_illustration_offlinelib_useredu_1.xml
A app/src/main/res/drawable/ic_illustration_offlinelib_useredu_2.xml
A app/src/main/res/drawable/ic_illustration_offlinelib_useredu_3.xml
A app/src/main/res/layout/inflate_offline_tutorial_page_one.xml
A app/src/main/res/layout/inflate_offline_tutorial_page_three.xml
A app/src/main/res/layout/inflate_offline_tutorial_page_two.xml
M app/src/main/res/values-qq/strings.xml
M app/src/main/res/values/strings.xml
M app/src/main/res/xml/developer_preferences.xml
17 files changed, 627 insertions(+), 4 deletions(-)

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



diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 8ca32f2..608ffba 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -199,10 +199,14 @@
 android:name=".offline.CompilationDetailActivity"
 android:theme="@style/AppTheme"/>
 
+
+
 
+android:authorities="${applicationId}"
+android:name=".database.AppContentProvider"
+android:exported="false" />
 
 
+implements OnboardingFragment.Callback {
+@NonNull
+public static Intent newIntent(@NonNull Context context) {
+return new Intent(context, OfflineTutorialActivity.class);
+}
+
+@Override public void onCreate(Bundle savedInstanceState) {
+super.onCreate(savedInstanceState);
+setStatusBarColor(R.color.green30);
+}
+
+@Override
+protected OfflineTutorialFragment createFragment() {
+return OfflineTutorialFragment.newInstance();
+}
+
+@Override
+public void onComplete() {
+setResult(RESULT_OK);
+finish();
+}
+}
diff --git 
a/app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java 
b/app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java
new file mode 100644
index 000..d51fcfc
--- /dev/null
+++ b/app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java
@@ -0,0 +1,36 @@
+package org.wikipedia.offline;
+
+import android.os.Bundle;
+import android.support.annotation.NonNull;
+import android.support.v4.content.ContextCompat;
+import android.support.v4.view.PagerAdapter;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.ViewGroup;
+
+import org.wikipedia.R;
+import org.wikipedia.onboarding.OnboardingFragment;
+
+public class OfflineTutorialFragment extends OnboardingFragment {
+@NonNull
+public static OfflineTutorialFragment newInstance() {
+return new OfflineTutorialFragment();
+}
+
+@Override
+public View onCreateView(LayoutInflater inflater, ViewGroup container, 
Bundle savedInstanceState) {
+View view = super.onCreateView(inflater, container, 
savedInstanceState);
+view.setBackground(ContextCompat.getDrawable(getContext(), 
R.drawable.onboarding_gradient_background_90));
+return view;
+}
+
+@Override
+protected PagerAdapter getAdapter() {
+return new OfflineTutorialPagerAdapter();
+}
+
+@Override
+protected int getDoneButtonText() {
+return R.string.offline_library_onboarding_button_done;
+}
+}
diff --git a/app/src/main/java/org/wikipedia/offline/OfflineTutorialPage.java 
b/app/src/main/java/org/wikipedia/offline/OfflineTutorialPage.java
new file mode 100644
index 000..1745982
--- /dev/null
+++ b/app/src/main/java/org/wikipedia/offline/OfflineTutorialPage.java
@@ -0,0 +1,41 @@
+package org.wikipedia.offline;
+
+import android.support.annotation.LayoutRes;
+import android.support.annotation.NonNull;
+
+import org.wikipedia.R;
+import org.wikipedia.model.EnumCode;
+import org.wikipedia.model.EnumCodeMap;
+
+enum OfflineTutorialPage implements EnumCode {
+PAGE_BUILD_LIBRARY(R.layout.inflate_offline_tutorial_page_one),
+PAGE_UNINTERRUPTED_READING(R.layout.inflate_offline_tutorial_page_two),
+PAGE_STORE_KNOWLEDGE(R.layout.inflate_offline_tutorial_page_three);
+
+@LayoutRes private final int layout;
+
+private

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Automatically include commons and wikidata in $wmgThrottling...

2017-08-24 Thread Urbanecm (Code Review)
Urbanecm has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373698 )

Change subject: Automatically include commons and wikidata in 
$wmgThrottlingExceptions
..

Automatically include commons and wikidata in $wmgThrottlingExceptions

Bug: T163872
Change-Id: I14af55a548ebb5eca19312cd1eb5b80647621883
---
M wmf-config/throttle-analyze.php
1 file changed, 8 insertions(+), 0 deletions(-)


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

diff --git a/wmf-config/throttle-analyze.php b/wmf-config/throttle-analyze.php
index 1757b8e..3fd419f 100644
--- a/wmf-config/throttle-analyze.php
+++ b/wmf-config/throttle-analyze.php
@@ -35,6 +35,14 @@
continue;
}
 
+   # Ensure that dbname field contain wikidatawiki and commonswiki
+   if(gettype($options['dbname']) == 'string') {
+   $options['dbname'] = [$options['dbname']];
+   }
+   $options['dbname'][] = 'commonswiki';
+   $options['dbname'][] = 'wikidatawiki';
+   $options['dbname'] = array_unique($options['dbname']);
+
# Finally) set up the throttle value
global $wgAccountCreationThrottle, $wgRateLimits;
if ( isset( $options['value'] ) && is_numeric( 
$options['value'] ) ) {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I14af55a548ebb5eca19312cd1eb5b80647621883
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]: Offline Library onboarding follow-up.

2017-08-24 Thread Dbrant (Code Review)
Dbrant has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373697 )

Change subject: Offline Library onboarding follow-up.
..

Offline Library onboarding follow-up.

Change-Id: Ifa177a994d9ace313c75109e1695d80df30f3c6d
---
M app/src/main/java/org/wikipedia/feed/FeedFragment.java
M app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
M app/src/main/java/org/wikipedia/settings/Prefs.java
3 files changed, 20 insertions(+), 4 deletions(-)


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

diff --git a/app/src/main/java/org/wikipedia/feed/FeedFragment.java 
b/app/src/main/java/org/wikipedia/feed/FeedFragment.java
index 9c8e612..d612688 100644
--- a/app/src/main/java/org/wikipedia/feed/FeedFragment.java
+++ b/app/src/main/java/org/wikipedia/feed/FeedFragment.java
@@ -435,14 +435,18 @@
 }
 
 public void onViewCompilations() {
-startActivity(LocalCompilationsActivity.newIntent(getContext()));
+if (Prefs.isOfflineTutorialCardEnabled()) {
+
startActivityForResult(OfflineTutorialActivity.newIntent(getContext()),
+ACTIVITY_REQUEST_OFFLINE_TUTORIAL);
+} else {
+
startActivity(LocalCompilationsActivity.newIntent(getContext()));
+}
 }
 
 @Override
 public void onOnboardingPositiveAction(@NonNull Card card, @NonNull 
OnboardingCard.OnboardingAction action) {
 if (action == OnboardingCard.OnboardingAction.OFFLINE_LIBRARY) {
-
startActivityForResult(OfflineTutorialActivity.newIntent(getContext()),
-ACTIVITY_REQUEST_OFFLINE_TUTORIAL);
+onViewCompilations();
 }
 }
 }
@@ -515,7 +519,7 @@
 
 @Override
 public void compilationsClick() {
-startActivity(LocalCompilationsActivity.newIntent(getContext()));
+feedCallback.onViewCompilations();
 }
 }
 }
diff --git 
a/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java 
b/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
index d531b87..a7c0446 100644
--- a/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
+++ b/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
@@ -31,4 +31,12 @@
 setResult(RESULT_OK);
 finish();
 }
+
+@Override
+public void onBackPressed() {
+if (getFragment().onBackPressed()) {
+return;
+}
+finish();
+}
 }
diff --git a/app/src/main/java/org/wikipedia/settings/Prefs.java 
b/app/src/main/java/org/wikipedia/settings/Prefs.java
index 6c9c671..7f775c8 100644
--- a/app/src/main/java/org/wikipedia/settings/Prefs.java
+++ b/app/src/main/java/org/wikipedia/settings/Prefs.java
@@ -549,6 +549,10 @@
 setString(R.string.preference_key_compilation_cache, 
GsonMarshaller.marshal(compilations));
 }
 
+public static boolean isOfflineTutorialCardEnabled() {
+return 
getBoolean(R.string.preference_key_offline_onboarding_card_enabled, true);
+}
+
 public static void setOfflineTutorialCardEnabled(boolean enabled) {
 setBoolean(R.string.preference_key_offline_onboarding_card_enabled, 
enabled);
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifa177a994d9ace313c75109e1695d80df30f3c6d
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] operations/puppet[production]: openstack: misc components to module/role/profile

2017-08-24 Thread Rush (Code Review)
Rush has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373685 )

Change subject: openstack: misc components to module/role/profile
..


openstack: misc components to module/role/profile

* spreadcheck to openstack2/monitor
* env scripts to openstack2/util
* use admin_scripts instead of virtscripts dir for
  consistency
* remove file path specific headers for scripts
  as they are too brittle
* make file resources consistent for ordering of params
* keystone-public-uwsgi file cleanup

Bug: T171494
Change-Id: Ibc8e47e4ab670c242014807588a7bb871ee134e0
---
A hieradata/codfw/profile/openstack/labtest/designate.yaml
A hieradata/codfw/profile/openstack/labtestn/designate.yaml
A hieradata/eqiad/profile/openstack/main/designate.yaml
A hieradata/eqiad/profile/openstack/main/monitor.yaml
D modules/openstack/files/liberty/virtscripts/makedomain
M modules/openstack/files/mitaka/virtscripts/cold-migrate
M modules/openstack/files/mitaka/virtscripts/cold-nova-migrate
D modules/openstack/files/mitaka/virtscripts/live-migrate
M modules/openstack/files/mitaka/virtscripts/logstat.py
M modules/openstack/files/mitaka/virtscripts/prod.sh
D modules/openstack/manifests/envscripts.pp
M modules/openstack/manifests/horizon/service.pp
D modules/openstack/templates/novaenv.sh.erb
D modules/openstack/templates/wmflabsorg-domainadminenv.sh.erb
D modules/openstack2/files/keystone-admin-uwsgi.logrotate
D modules/openstack2/files/keystone-public-uwsgi.logrotate
R modules/openstack2/files/liberty/admin_scripts/cold-migrate
R modules/openstack2/files/liberty/admin_scripts/cold-nova-migrate
R modules/openstack2/files/liberty/admin_scripts/live-migrate
R modules/openstack2/files/liberty/admin_scripts/logstat.py
R modules/openstack2/files/liberty/admin_scripts/makedomain
R modules/openstack2/files/liberty/admin_scripts/novastats/alltrusty.py
R modules/openstack2/files/liberty/admin_scripts/novastats/diskspace.py
R modules/openstack2/files/liberty/admin_scripts/novastats/dnsleaks.py
R modules/openstack2/files/liberty/admin_scripts/novastats/flavorreport.py
R modules/openstack2/files/liberty/admin_scripts/novastats/imagestats.py
R modules/openstack2/files/liberty/admin_scripts/novastats/proxyleaks.py
R modules/openstack2/files/liberty/admin_scripts/novastats/puppetleaks.py
R modules/openstack2/files/liberty/admin_scripts/prod.sh
R modules/openstack2/files/liberty/admin_scripts/wikitech-grep.py
C modules/openstack2/files/mitaka/admin_scripts/cold-migrate
C modules/openstack2/files/mitaka/admin_scripts/cold-nova-migrate
C modules/openstack2/files/mitaka/admin_scripts/live-migrate
C modules/openstack2/files/mitaka/admin_scripts/logstat.py
C modules/openstack2/files/mitaka/admin_scripts/makedomain
C modules/openstack2/files/mitaka/admin_scripts/prod.sh
R modules/openstack2/files/monitor/spreadcheck.py
R modules/openstack2/manifests/monitor/spreadcheck.pp
R modules/openstack2/manifests/util/admin_scripts.pp
A modules/openstack2/manifests/util/envscripts.pp
R modules/openstack2/templates/monitor/spreadcheck-tools.yaml.erb
A modules/openstack2/templates/util/novaenv.sh.erb
A modules/openstack2/templates/util/wmflabsorg-domainadminenv.sh.erb
M modules/profile/manifests/openstack/base/keystone/service.pp
M modules/profile/manifests/openstack/labtest/keystone/service.pp
M modules/profile/manifests/openstack/labtestn/keystone/service.pp
M modules/profile/manifests/openstack/main/keystone/service.pp
M modules/role/manifests/horizon.pp
M modules/role/manifests/labs/openstack/nova/controller.pp
49 files changed, 167 insertions(+), 473 deletions(-)

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



diff --git a/hieradata/codfw/profile/openstack/labtest/designate.yaml 
b/hieradata/codfw/profile/openstack/labtest/designate.yaml
new file mode 100644
index 000..9087fd7
--- /dev/null
+++ b/hieradata/codfw/profile/openstack/labtest/designate.yaml
@@ -0,0 +1 @@
+profile::openstack::labtest::designate::wmflabsdotorg_project: 'wmflabsdotorg'
diff --git a/hieradata/codfw/profile/openstack/labtestn/designate.yaml 
b/hieradata/codfw/profile/openstack/labtestn/designate.yaml
new file mode 100644
index 000..e718654
--- /dev/null
+++ b/hieradata/codfw/profile/openstack/labtestn/designate.yaml
@@ -0,0 +1 @@
+profile::openstack::labtestn::designate::wmflabsdotorg_project: 'wmflabsdotorg'
diff --git a/hieradata/eqiad/profile/openstack/main/designate.yaml 
b/hieradata/eqiad/profile/openstack/main/designate.yaml
new file mode 100644
index 000..b6a217c
--- /dev/null
+++ b/hieradata/eqiad/profile/openstack/main/designate.yaml
@@ -0,0 +1 @@
+profile::openstack::main::designate::wmflabsdotorg_project: 'wmflabsdotorg'
diff --git a/hieradata/eqiad/profile/openstack/main/monitor.yaml 
b/hieradata/eqiad/profile/openstack/main/monitor.yaml
new file mode 100644
index 000..bd5223c
--- /dev/null
+++ b/hieradata/eqiad/profile/openstack/main/monitor.yaml
@@ -0,0

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Fix incorrect Special:Userlogin name in Popups blacklist

2017-08-24 Thread Pmiazga (Code Review)
Pmiazga has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373696 )

Change subject: Fix incorrect Special:Userlogin name in Popups blacklist
..

Fix incorrect Special:Userlogin name in Popups blacklist

Current $wgPopupsPageBlacklist contains incorrect canonical name
for special UserLogin page.

Changes:
 - blacklist `Special:Userlogin` page

Bug: T170169
Change-Id: Ib13ca945fe19e31f2122abeb729fb0e6be3181ea
DependsOn: I49592133eb8286eacf04fd3034df091f7ef2aa50
---
M wmf-config/InitialiseSettings.php
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index 8013276..ce58c75 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -13554,7 +13554,7 @@
'default' => [
'Special:CreateAccount',
'Special:GlobalRenameRequest',
-   'Special:UserLogin',
+   'Special:Userlogin',
'Special:MergeAccount',
'Special:ChangeCredentials',
'Special:OAuthListConsumers',

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

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

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


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: throttle.php: Separate the throttling definitions from the e...

2017-08-24 Thread Urbanecm (Code Review)
Urbanecm has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373695 )

Change subject: throttle.php: Separate the throttling definitions from the 
exception values itself
..

throttle.php: Separate the throttling definitions from the exception values 
itself

Bug: T167040
Change-Id: If97fef2b72401e50960fdecd44b95ce933635e4d
---
A wmf-config/throttle-analyze.php
M wmf-config/throttle.php
2 files changed, 47 insertions(+), 47 deletions(-)


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

diff --git a/wmf-config/throttle-analyze.php b/wmf-config/throttle-analyze.php
new file mode 100644
index 000..27860e9
--- /dev/null
+++ b/wmf-config/throttle-analyze.php
@@ -0,0 +1,47 @@
+/**
+ * Helper to easily add a throttling request.
+ */
+$wgExtensionFunctions[] = function () {
+   global $wmgThrottlingExceptions, $wgDBname, $wgRequest;
+
+   foreach ( $wmgThrottlingExceptions as $options ) {
+   # Validate entry, skip when it does not apply to our case
+
+   # 1) skip when it does not apply to our database name
+
+   if ( isset( $options['dbname'] ) && !in_array( $wgDBname, 
(array)$options['dbname'] ) ) {
+   continue;
+   }
+
+   # 2) skip expired entries
+   $inTimeWindow = time() >= strtotime( $options['from'] )
+   && time() <= strtotime( $options['to'] );
+
+   if ( !$inTimeWindow ) {
+   continue;
+   }
+
+   # 3) skip when throttle does not apply to the client IP
+   $ip = $wgRequest->getIP();
+   if ( isset ( $options['IP'] ) ) {
+   $throttleIP = $options['IP'];
+   }
+   if ( isset( $throttleIP ) && !in_array( $ip, (array)$throttleIP 
) ) {
+   continue;
+   }
+   if ( isset ( $options['range'] ) && !IP::isInRanges( $ip, 
(array)$options['range'] ) ) {
+   continue;
+   }
+
+   # Finally) set up the throttle value
+   global $wgAccountCreationThrottle, $wgRateLimits;
+   if ( isset( $options['value'] ) && is_numeric( 
$options['value'] ) ) {
+   $wgAccountCreationThrottle = $options['value'];
+   } else {
+   $wgAccountCreationThrottle = 50; // Provide some sane 
default
+   }
+   $wgRateLimits['badcaptcha']['ip'] = [ 1000, 86400 ];
+   $wgRateLimits['badcaptcha']['newbie'] = [ 1000, 86400 ];
+   return; # No point in proceeding to another entry
+   }
+};
diff --git a/wmf-config/throttle.php b/wmf-config/throttle.php
index 1954828..3579776 100644
--- a/wmf-config/throttle.php
+++ b/wmf-config/throttle.php
@@ -38,50 +38,3 @@
 
 ## Add throttling definitions above.
 
-/**
- * Helper to easily add a throttling request.
- */
-$wgExtensionFunctions[] = function () {
-   global $wmgThrottlingExceptions, $wgDBname, $wgRequest;
-
-   foreach ( $wmgThrottlingExceptions as $options ) {
-   # Validate entry, skip when it does not apply to our case
-
-   # 1) skip when it does not apply to our database name
-
-   if ( isset( $options['dbname'] ) && !in_array( $wgDBname, 
(array)$options['dbname'] ) ) {
-   continue;
-   }
-
-   # 2) skip expired entries
-   $inTimeWindow = time() >= strtotime( $options['from'] )
-   && time() <= strtotime( $options['to'] );
-
-   if ( !$inTimeWindow ) {
-   continue;
-   }
-
-   # 3) skip when throttle does not apply to the client IP
-   $ip = $wgRequest->getIP();
-   if ( isset ( $options['IP'] ) ) {
-   $throttleIP = $options['IP'];
-   }
-   if ( isset( $throttleIP ) && !in_array( $ip, (array)$throttleIP 
) ) {
-   continue;
-   }
-   if ( isset ( $options['range'] ) && !IP::isInRanges( $ip, 
(array)$options['range'] ) ) {
-   continue;
-   }
-
-   # Finally) set up the throttle value
-   global $wgAccountCreationThrottle, $wgRateLimits;
-   if ( isset( $options['value'] ) && is_numeric( 
$options['value'] ) ) {
-   $wgAccountCreationThrottle = $options['value'];
-   } else {
-   $wgAccountCreationThrottle = 50; // Provide some sane 
default
-   }
-   $wgRateLimits['badcaptcha']['ip'] = [ 1000, 86400 ];
-   $wgRateLimits['badcaptcha']['newbie'] = [ 1000, 86400 ];
-   return; # No point in proceeding to another entry
-   }
-};

-- 
To view,

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Remove non-transparent background from dty.wiki logos

2017-08-24 Thread Urbanecm (Code Review)
Urbanecm has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373694 )

Change subject: Remove non-transparent background from dty.wiki logos
..

Remove non-transparent background from dty.wiki logos

Bug: T174098
Change-Id: I382444349bd705f71c6396cdb7f71797c7782a99
---
M static/images/project-logos/dtywiki-1.5x.png
M static/images/project-logos/dtywiki-2x.png
M static/images/project-logos/dtywiki.png
3 files changed, 0 insertions(+), 0 deletions(-)


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

diff --git a/static/images/project-logos/dtywiki-1.5x.png 
b/static/images/project-logos/dtywiki-1.5x.png
index 6930c7e..ad7ff24 100644
--- a/static/images/project-logos/dtywiki-1.5x.png
+++ b/static/images/project-logos/dtywiki-1.5x.png
Binary files differ
diff --git a/static/images/project-logos/dtywiki-2x.png 
b/static/images/project-logos/dtywiki-2x.png
index 349f94f..ea69689 100644
--- a/static/images/project-logos/dtywiki-2x.png
+++ b/static/images/project-logos/dtywiki-2x.png
Binary files differ
diff --git a/static/images/project-logos/dtywiki.png 
b/static/images/project-logos/dtywiki.png
index c7aef4f..e982dff 100644
--- a/static/images/project-logos/dtywiki.png
+++ b/static/images/project-logos/dtywiki.png
Binary files differ

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I382444349bd705f71c6396cdb7f71797c7782a99
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]: Update Offline Library tutorial to have per-screen backgrounds

2017-08-24 Thread Mholloway (Code Review)
Mholloway has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373693 )

Change subject: Update Offline Library tutorial to have per-screen backgrounds
..

Update Offline Library tutorial to have per-screen backgrounds

Updates the generic onboarding activity components as needed to
implement the current design.  Adds an optional styleable declaration for
an onboarding screen background drawable.  Adds per-screen background
gradients as specified on the ticket.

Bug: T172185
Change-Id: I5aa8e76b0884f0e7a9a25376ac93e1283b580116
---
M app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
M app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java
M app/src/main/java/org/wikipedia/onboarding/OnboardingPageView.java
A app/src/main/res/drawable/onboarding_gradient_background_offline_one.xml
A app/src/main/res/drawable/onboarding_gradient_background_offline_three.xml
A app/src/main/res/drawable/onboarding_gradient_background_offline_two.xml
M app/src/main/res/layout/fragment_onboarding_pager.xml
M app/src/main/res/layout/inflate_offline_tutorial_page_one.xml
M app/src/main/res/layout/inflate_offline_tutorial_page_three.xml
M app/src/main/res/layout/inflate_offline_tutorial_page_two.xml
M app/src/main/res/layout/view_onboarding_page.xml
M app/src/main/res/values/attrs.xml
12 files changed, 102 insertions(+), 65 deletions(-)


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

diff --git 
a/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java 
b/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
index d531b87..6033b7d 100644
--- a/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
+++ b/app/src/main/java/org/wikipedia/offline/OfflineTutorialActivity.java
@@ -2,10 +2,11 @@
 
 import android.content.Context;
 import android.content.Intent;
+import android.os.Build;
 import android.os.Bundle;
 import android.support.annotation.NonNull;
+import android.view.WindowManager;
 
-import org.wikipedia.R;
 import org.wikipedia.activity.SingleFragmentActivity;
 import org.wikipedia.onboarding.OnboardingFragment;
 
@@ -18,7 +19,9 @@
 
 @Override public void onCreate(Bundle savedInstanceState) {
 super.onCreate(savedInstanceState);
-setStatusBarColor(R.color.green30);
+if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
+
getWindow().addFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);
+}
 }
 
 @Override
diff --git 
a/app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java 
b/app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java
index d51fcfc..6d689d1 100644
--- a/app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java
+++ b/app/src/main/java/org/wikipedia/offline/OfflineTutorialFragment.java
@@ -1,12 +1,7 @@
 package org.wikipedia.offline;
 
-import android.os.Bundle;
 import android.support.annotation.NonNull;
-import android.support.v4.content.ContextCompat;
 import android.support.v4.view.PagerAdapter;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
 
 import org.wikipedia.R;
 import org.wikipedia.onboarding.OnboardingFragment;
@@ -15,13 +10,6 @@
 @NonNull
 public static OfflineTutorialFragment newInstance() {
 return new OfflineTutorialFragment();
-}
-
-@Override
-public View onCreateView(LayoutInflater inflater, ViewGroup container, 
Bundle savedInstanceState) {
-View view = super.onCreateView(inflater, container, 
savedInstanceState);
-view.setBackground(ContextCompat.getDrawable(getContext(), 
R.drawable.onboarding_gradient_background_90));
-return view;
 }
 
 @Override
diff --git a/app/src/main/java/org/wikipedia/onboarding/OnboardingPageView.java 
b/app/src/main/java/org/wikipedia/onboarding/OnboardingPageView.java
index d7060ac..57347fa 100644
--- a/app/src/main/java/org/wikipedia/onboarding/OnboardingPageView.java
+++ b/app/src/main/java/org/wikipedia/onboarding/OnboardingPageView.java
@@ -99,7 +99,11 @@
 String tertiaryText = 
array.getString(R.styleable.OnboardingPageView_tertiaryText);
 String switchText = 
array.getString(R.styleable.OnboardingPageView_switchText);
 int imageSize = 
array.getDimensionPixelSize(R.styleable.OnboardingPageView_imageSize, 0);
+Drawable background = 
array.getDrawable(R.styleable.OnboardingPageView_background);
 
+if (background != null) {
+setBackground(background);
+}
 FrameLayout.LayoutParams imageParams = (FrameLayout.LayoutParams) 
imageViewCentered.getLayoutParams();
 imageParams.width = imageSize;
 imageParams.height = imageSize;
diff --git 
a/app/src/main/res/drawable/onboarding_gradient_background_offline_one.xml 
b/app/src/main/r

[MediaWiki-commits] [Gerrit] mediawiki...TimedMediaHandler[wmf/1.30.0-wmf.15]: Disable Ogg Theora video transcodes in default config

2017-08-24 Thread Brion VIBBER (Code Review)
Brion VIBBER has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373692 )

Change subject: Disable Ogg Theora video transcodes in default config
..

Disable Ogg Theora video transcodes in default config

With WebM playback enabled via ogv.js, there's less reason to keep
the Ogg Theora video transcodes on Wikimedia or other sites.
Removing them by default in favor of just generating WebM.

This speeds encoding time and saves disk space, at the cost of
the WebM videos requiring more CPU in Safari/IE/Edge with the ogv.js
player shim.

Prep for removing them from Wikimedia due to ongoing tooling issues
with ffmpeg2theora.

Safe to merge after I68f22d7c goes out fully.

Bug: T172445
Change-Id: I2ffd2c6d0f87c53c0addc69515fdad803e192199
(cherry picked from commit 7437bb4c8e4d8caa683fcae4b61d9ef46d670385)
---
M TimedMediaHandler.php
1 file changed, 6 insertions(+), 2 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TimedMediaHandler 
refs/changes/92/373692/1

diff --git a/TimedMediaHandler.php b/TimedMediaHandler.php
index 80ac0ee..0cade78 100644
--- a/TimedMediaHandler.php
+++ b/TimedMediaHandler.php
@@ -135,7 +135,8 @@
 
// WebM VP8/Vorbis
// primary free/open video format
-   // supported by Chrome/Firefox/Opera but not Safari/IE/Edge
+   // supported by Chrome/Firefox/Opera natively
+   // plays back in Safari/IE/Edge via ogv.js
 
// Very low-bitrate web streamable WebM video
WebVideoTranscode::ENC_WEBM_160P,
@@ -158,8 +159,10 @@
// A 4K full high quality WebM stream
// WebVideoTranscode::ENC_WEBM_2160P,
 
+/*
// Ogg Theora/Vorbis
-   // Fallback for Safari/IE/Edge with ogv.js
+   // Optional fallback for Safari/IE/Edge with ogv.js
+   // Faster to encode & play back than WebM but less efficient.
 
// Requires twice the bitrate for same quality as VP8,
// and JS decoder can be slow, so shift to smaller sizes.
@@ -183,6 +186,7 @@
// Variable-bitrate HD Ogg stream
// for ogv.js on reasonably speedy machines
WebVideoTranscode::ENC_OGV_1080P,
+*/
 
 /*
// MP4 H.264/AAC

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2ffd2c6d0f87c53c0addc69515fdad803e192199
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TimedMediaHandler
Gerrit-Branch: wmf/1.30.0-wmf.15
Gerrit-Owner: Brion VIBBER 

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


[MediaWiki-commits] [Gerrit] mediawiki...LoginNotify[wmf/1.30.0-wmf.15]: Even more logging

2017-08-24 Thread MaxSem (Code Review)
MaxSem has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373691 )

Change subject: Even more logging
..


Even more logging

Bug: T173888
Change-Id: I7f9f3cf0657af100c6ae3a8b2bfb5206b86514eb
(cherry picked from commit 228a2f3ee3d26d34994c34a17f0e57406728a5d9)
---
M includes/LoginNotify.php
1 file changed, 30 insertions(+), 5 deletions(-)

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



diff --git a/includes/LoginNotify.php b/includes/LoginNotify.php
index 306aa89..99c46cf 100644
--- a/includes/LoginNotify.php
+++ b/includes/LoginNotify.php
@@ -160,9 +160,16 @@
 */
private function isKnownSystemSlow( User $user, $subnet, $resultSoFar = 
null ) {
$result = $this->checkUserAllWikis( $user, $subnet );
-   if ( $result === self::USER_KNOWN ) {
-   return true;
-   }
+
+   $this->log->debug( 'Checking user {user} from {subnet} (result 
so far: {soFar}): {result}',
+   [
+   'function' => __METHOD__,
+   'user' => $user->getName(),
+   'subnet' => $subnet,
+   'result' => $result,
+   'soFar' => json_encode( $resultSoFar ),
+   ]
+   );
 
if ( $resultSoFar !== null ) {
$result = $this->mergeResults( $result, $resultSoFar );
@@ -185,7 +192,7 @@
return true;
}
 
-   return false;
+   return $result === self::USER_KNOWN;
}
 
/**
@@ -637,10 +644,20 @@
$this->config->get( 'LoginNotifyAttemptsNewIP' ),
$this->config->get( 'LoginNotifyExpiryNewIP' )
);
+   $message = '{count} failed login attempts for {user} from an 
unknown system';
if ( $count ) {
$this->incrStats( 'fail.unknown.notifications' );
$this->sendNotice( $user, 'login-fail-new', $count );
+   $message .= ', sending notification';
}
+
+   $this->log->debug( $message,
+   [
+   'function' => __METHOD__,
+   'count' => $count,
+   'user' => $user->getName(),
+   ]
+   );
}
 
/**
@@ -796,7 +813,15 @@
 */
public function sendSuccessNoticeDeferred( User $user, $subnet, 
$resultSoFar ) {
$isKnown = $this->isKnownSystemSlow( $user, $subnet, 
$resultSoFar );
-   if ( !$isKnown ) {
+   if ( $isKnown ) {
+   $this->log->debug( 'Found data for user {user} from 
{subnet}',
+   [
+   'function' => __METHOD__,
+   'user' => $user->getName(),
+   'subnet' => $subnet,
+   ]
+   );
+   } else {
$this->incrStats( 'success.notifications' );
$this->sendNotice( $user, 'login-success' );
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7f9f3cf0657af100c6ae3a8b2bfb5206b86514eb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/LoginNotify
Gerrit-Branch: wmf/1.30.0-wmf.15
Gerrit-Owner: MaxSem 
Gerrit-Reviewer: MaxSem 

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


[MediaWiki-commits] [Gerrit] mediawiki...LoginNotify[wmf/1.30.0-wmf.15]: Even more logging

2017-08-24 Thread MaxSem (Code Review)
MaxSem has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373691 )

Change subject: Even more logging
..

Even more logging

Bug: T173888
Change-Id: I7f9f3cf0657af100c6ae3a8b2bfb5206b86514eb
(cherry picked from commit 228a2f3ee3d26d34994c34a17f0e57406728a5d9)
---
M includes/LoginNotify.php
1 file changed, 30 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/LoginNotify 
refs/changes/91/373691/1

diff --git a/includes/LoginNotify.php b/includes/LoginNotify.php
index 306aa89..99c46cf 100644
--- a/includes/LoginNotify.php
+++ b/includes/LoginNotify.php
@@ -160,9 +160,16 @@
 */
private function isKnownSystemSlow( User $user, $subnet, $resultSoFar = 
null ) {
$result = $this->checkUserAllWikis( $user, $subnet );
-   if ( $result === self::USER_KNOWN ) {
-   return true;
-   }
+
+   $this->log->debug( 'Checking user {user} from {subnet} (result 
so far: {soFar}): {result}',
+   [
+   'function' => __METHOD__,
+   'user' => $user->getName(),
+   'subnet' => $subnet,
+   'result' => $result,
+   'soFar' => json_encode( $resultSoFar ),
+   ]
+   );
 
if ( $resultSoFar !== null ) {
$result = $this->mergeResults( $result, $resultSoFar );
@@ -185,7 +192,7 @@
return true;
}
 
-   return false;
+   return $result === self::USER_KNOWN;
}
 
/**
@@ -637,10 +644,20 @@
$this->config->get( 'LoginNotifyAttemptsNewIP' ),
$this->config->get( 'LoginNotifyExpiryNewIP' )
);
+   $message = '{count} failed login attempts for {user} from an 
unknown system';
if ( $count ) {
$this->incrStats( 'fail.unknown.notifications' );
$this->sendNotice( $user, 'login-fail-new', $count );
+   $message .= ', sending notification';
}
+
+   $this->log->debug( $message,
+   [
+   'function' => __METHOD__,
+   'count' => $count,
+   'user' => $user->getName(),
+   ]
+   );
}
 
/**
@@ -796,7 +813,15 @@
 */
public function sendSuccessNoticeDeferred( User $user, $subnet, 
$resultSoFar ) {
$isKnown = $this->isKnownSystemSlow( $user, $subnet, 
$resultSoFar );
-   if ( !$isKnown ) {
+   if ( $isKnown ) {
+   $this->log->debug( 'Found data for user {user} from 
{subnet}',
+   [
+   'function' => __METHOD__,
+   'user' => $user->getName(),
+   'subnet' => $subnet,
+   ]
+   );
+   } else {
$this->incrStats( 'success.notifications' );
$this->sendNotice( $user, 'login-success' );
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7f9f3cf0657af100c6ae3a8b2bfb5206b86514eb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/LoginNotify
Gerrit-Branch: wmf/1.30.0-wmf.15
Gerrit-Owner: MaxSem 

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


[MediaWiki-commits] [Gerrit] mediawiki...TestLanguageNameGrammar[master]: Remove dot at end from extension description

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373658 )

Change subject: Remove dot at end from extension description
..


Remove dot at end from extension description

Consistency tweak for extension active on translatewiki.net
Description on Special:Version does not end with a dot

Change-Id: I565ce618548ae8b6c184a22ef98351ca1e2e4bb7
---
M i18n/en.json
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/i18n/en.json b/i18n/en.json
index 42ac9e4..ab042fd 100755
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -5,7 +5,7 @@
]
},
"testlanguagenamegrammar": "Test grammar forms with language names",
-   "testlanguagenamegrammar-desc": "Adds a 
[[Special:TestLanguageNameGrammar|special page]] to test grammar forms with 
language names.",
+   "testlanguagenamegrammar-desc": "Adds a 
[[Special:TestLanguageNameGrammar|special page]] to test grammar forms with 
language names",
"testlanguagenamegrammar-language": "Language",
"testlanguagenamegrammar-grammarform": "Grammar form",
"testlanguagenamegrammar-submit": "Submit"

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I565ce618548ae8b6c184a22ef98351ca1e2e4bb7
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TestLanguageNameGrammar
Gerrit-Branch: master
Gerrit-Owner: Umherirrender 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Raimond Spekking 
Gerrit-Reviewer: Siebrand 
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...UploadsLink[master]: Remove dot at end from extension description

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373662 )

Change subject: Remove dot at end from extension description
..


Remove dot at end from extension description

Consistency tweak for extension active on translatewiki.net
Description on Special:Version does not end with a dot

Change-Id: I45a0335306e0484185cdb2740c3bb91248305c7f
---
M i18n/en.json
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/i18n/en.json b/i18n/en.json
index 0a910ed..f8cf276 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -5,7 +5,7 @@
"Rainer Rillke"
]
},
-   "uploadslink-desc": "Adds a link to the current user's uploads listing 
to the personal tools menu and a link to the relevant user's upload listing to 
the sidebar Tools menu.",
+   "uploadslink-desc": "Adds a link to the current user's uploads listing 
to the personal tools menu and a link to the relevant user's upload listing to 
the sidebar Tools menu",
"uploadslink-portlet-label": "Uploads",
"tooltip-pt-uploads": "List of files you have uploaded",
"uploadslink-toobox-label": "{{GENDER:$1|User}} uploads",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I45a0335306e0484185cdb2740c3bb91248305c7f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/UploadsLink
Gerrit-Branch: master
Gerrit-Owner: Umherirrender 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Raimond Spekking 
Gerrit-Reviewer: Siebrand 
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...LoginNotify[master]: Even more logging

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373680 )

Change subject: Even more logging
..


Even more logging

Bug: T173888
Change-Id: I7f9f3cf0657af100c6ae3a8b2bfb5206b86514eb
---
M includes/LoginNotify.php
1 file changed, 30 insertions(+), 5 deletions(-)

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



diff --git a/includes/LoginNotify.php b/includes/LoginNotify.php
index e8a527e..06376f1 100644
--- a/includes/LoginNotify.php
+++ b/includes/LoginNotify.php
@@ -161,9 +161,16 @@
 */
private function isKnownSystemSlow( User $user, $subnet, $resultSoFar = 
null ) {
$result = $this->checkUserAllWikis( $user, $subnet );
-   if ( $result === self::USER_KNOWN ) {
-   return true;
-   }
+
+   $this->log->debug( 'Checking user {user} from {subnet} (result 
so far: {soFar}): {result}',
+   [
+   'function' => __METHOD__,
+   'user' => $user->getName(),
+   'subnet' => $subnet,
+   'result' => $result,
+   'soFar' => json_encode( $resultSoFar ),
+   ]
+   );
 
if ( $resultSoFar !== null ) {
$result = $this->mergeResults( $result, $resultSoFar );
@@ -186,7 +193,7 @@
return true;
}
 
-   return false;
+   return $result === self::USER_KNOWN;
}
 
/**
@@ -640,10 +647,20 @@
$this->config->get( 'LoginNotifyAttemptsNewIP' ),
$this->config->get( 'LoginNotifyExpiryNewIP' )
);
+   $message = '{count} failed login attempts for {user} from an 
unknown system';
if ( $count ) {
$this->incrStats( 'fail.unknown.notifications' );
$this->sendNotice( $user, 'login-fail-new', $count );
+   $message .= ', sending notification';
}
+
+   $this->log->debug( $message,
+   [
+   'function' => __METHOD__,
+   'count' => $count,
+   'user' => $user->getName(),
+   ]
+   );
}
 
/**
@@ -799,7 +816,15 @@
 */
public function sendSuccessNoticeDeferred( User $user, $subnet, 
$resultSoFar ) {
$isKnown = $this->isKnownSystemSlow( $user, $subnet, 
$resultSoFar );
-   if ( !$isKnown ) {
+   if ( $isKnown ) {
+   $this->log->debug( 'Found data for user {user} from 
{subnet}',
+   [
+   'function' => __METHOD__,
+   'user' => $user->getName(),
+   'subnet' => $subnet,
+   ]
+   );
+   } else {
$this->incrStats( 'success.notifications' );
$this->sendNotice( $user, 'login-success' );
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7f9f3cf0657af100c6ae3a8b2bfb5206b86514eb
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/LoginNotify
Gerrit-Branch: master
Gerrit-Owner: MaxSem 
Gerrit-Reviewer: MaxSem 
Gerrit-Reviewer: Niharika29 
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...AbuseFilter[master]: Add runtime metrics to statsd

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373561 )

Change subject: Add runtime metrics to statsd
..


Add runtime metrics to statsd

Metrics per edit:
- Execution time of all filters
- Number of filters executed
- Number of conditions executed

Due to the current structure of abuse filter there was not
a clean way to include filter actions and abuselog creation
as part of the runtime metrics.

Bug: T161059
Change-Id: I6208b620453863133c6623aa419775f63c7d3eb1
---
M AbuseFilter.php
M extension.json
M includes/AbuseFilter.class.php
3 files changed, 49 insertions(+), 4 deletions(-)

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



diff --git a/AbuseFilter.php b/AbuseFilter.php
index 4a06b06..7f13eaf 100644
--- a/AbuseFilter.php
+++ b/AbuseFilter.php
@@ -117,3 +117,8 @@
  * Whether to record the average time taken and average number of conditions 
used by each filter.
  */
 $wgAbuseFilterProfile = false;
+
+/**
+ * Whether to record runtime metrics for all filters combined.
+ */
+$wgAbuseFilterRuntimeProfile = false;
diff --git a/extension.json b/extension.json
index f8d3abc..a043b6c 100644
--- a/extension.json
+++ b/extension.json
@@ -248,7 +248,8 @@
"_merge_strategy": "array_plus"
},
"AbuseFilterLogIPMaxAge": 7776000,
-   "AbuseFilterProfile": false
+   "AbuseFilterProfile": false,
+   "AbuseFilterRuntimeProfile": false
},
"load_composer_autoloader": true,
"manifest_version": 1
diff --git a/includes/AbuseFilter.class.php b/includes/AbuseFilter.class.php
index 4b1418f..e72c7c5 100644
--- a/includes/AbuseFilter.class.php
+++ b/includes/AbuseFilter.class.php
@@ -878,7 +878,7 @@
public static function filterAction(
$vars, $title, $group = 'default', $user = null, $mode = 
'execute'
) {
-   global $wgUser, $wgTitle, $wgRequest;
+   global $wgUser, $wgTitle, $wgRequest, 
$wgAbuseFilterRuntimeProfile;
 
$context = RequestContext::getMain();
$oldContextTitle = $context->getTitle();
@@ -905,6 +905,10 @@
$cache = ObjectCache::getLocalClusterInstance();
$stashKey = self::getStashKey( $cache, $vars, $group );
$isForEdit = ( $vars->getVar( 'action' )->toString() === 'edit' 
);
+
+   if ( $wgAbuseFilterRuntimeProfile ) {
+   $startTime = microtime( true );
+   }
 
$filter_matched = false;
if ( $mode === 'execute' && $isForEdit ) {
@@ -933,6 +937,13 @@
if ( $mode === 'stash' ) {
// Save the filter stash result and do nothing further
$cacheData = [ 'matches' => $filter_matched, 'tags' => 
self::$tagsToSet ];
+
+   // Add runtime metrics in cache for later use
+   if ( $wgAbuseFilterRuntimeProfile ) {
+   $cacheData['condCount'] = self::$condCount;
+   $cacheData['runtime'] = ( microtime( true ) - 
$startTime ) * 1000;
+   }
+
$cache->set( $stashKey, $cacheData, $cache::TTL_MINUTE 
);
$logger->debug( __METHOD__ . ": cache store for 
'$title' (key $stashKey)." );
$statsd->increment( 'abusefilter.check-stash.store' );
@@ -942,13 +953,24 @@
 
$matched_filters = array_keys( array_filter( $filter_matched ) 
);
 
+   // Save runtime metrics only on edits
+   if ( $wgAbuseFilterRuntimeProfile && $mode === 'execute' && 
$isForEdit ) {
+   if ( $cacheData ) {
+   $runtime = $cacheData['runtime'];
+   $condCount = $cacheData['condCount'];
+   } else {
+   $runtime = ( microtime( true ) - $startTime ) * 
1000;
+   $condCount = self::$condCount;
+   }
+
+   self::recordRuntimeProfilingResult( count( 
$matched_filters ), $condCount, $runtime );
+   }
+
if ( count( $matched_filters ) == 0 ) {
$status = Status::newGood();
} else {
$status = self::executeFilterActions( $matched_filters, 
$title, $vars );
-
$actions_taken = $status->getValue();
-
$action = $vars->getVar( 'ACTION' )->toString();
 
// If $wgUser isn't safe to load (e.g. a failure during
@@ -980,6 +1002,7 @@
if ( $wgTitle !== $oldWgTitle ) {
$wgTitle = $oldWgTitle;
}
+
if ( $context->getTitle() !==

[MediaWiki-commits] [Gerrit] mediawiki...Tabs[master]: Remove dot at end from extension description

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373657 )

Change subject: Remove dot at end from extension description
..


Remove dot at end from extension description

Consistency tweak for extension active on translatewiki.net
Description on Special:Version does not end with a dot

Change-Id: If5d0ed11a583eeac7cebe9482e23394b9b7cae2d
---
M i18n/en.json
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/i18n/en.json b/i18n/en.json
index 38b3551..08fcc32 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -4,7 +4,7 @@
"Pim (Joeytje50)"
]
},
-   "tabs-desc": "Adds  and 
 tags for creating tabbed layout.",
+   "tabs-desc": "Adds  and 
 tags for creating tabbed layout",
"tabs-tab-label": "Tab $1",
"tabs-toggle-open": "Show contents",
"tabs-toggle-close": "Hide contents",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If5d0ed11a583eeac7cebe9482e23394b9b7cae2d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Tabs
Gerrit-Branch: master
Gerrit-Owner: Umherirrender 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Raimond Spekking 
Gerrit-Reviewer: Siebrand 
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...SwiftCloudFiles[master]: Remove dot at end from extension description

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373656 )

Change subject: Remove dot at end from extension description
..


Remove dot at end from extension description

Consistency tweak for extension active on translatewiki.net
Description on Special:Version does not end with a dot

Change-Id: I21d4ba1cb7e793c7ae0360fcb1b5ea5a45f97cb3
---
M i18n/en.json
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/i18n/en.json b/i18n/en.json
index 5a5d15a..5ab3412 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -4,5 +4,5 @@
"Aaron Schulz"
]
},
-   "swiftcloudfiles-desc": "Includes and registers the 
[https://github.com/rackspace/php-cloudfiles ''php-cloudfiles'' API], allowing 
MediaWiki to interface with an OpenStack Swift storage backend."
-}
\ No newline at end of file
+   "swiftcloudfiles-desc": "Includes and registers the 
[https://github.com/rackspace/php-cloudfiles ''php-cloudfiles'' API], allowing 
MediaWiki to interface with an OpenStack Swift storage backend"
+}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I21d4ba1cb7e793c7ae0360fcb1b5ea5a45f97cb3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/SwiftCloudFiles
Gerrit-Branch: master
Gerrit-Owner: Umherirrender 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Raimond Spekking 
Gerrit-Reviewer: Siebrand 
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...UserGroups[master]: Remove dot at end from extension description

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373663 )

Change subject: Remove dot at end from extension description
..


Remove dot at end from extension description

Consistency tweak for extension active on translatewiki.net
Description on Special:Version does not end with a dot

Change-Id: I9e36a06ae8e21369edbfa62fe8427f02f14d23fb
---
M i18n/en.json
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/i18n/en.json b/i18n/en.json
index 17e9834..3be1e33 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -5,7 +5,7 @@
]
},
"usergroups": "User groups management",
-   "usergroups-desc": "Provides finer control over what userrights can be 
registered with which user groups.",
+   "usergroups-desc": "Provides finer control over what userrights can be 
registered with which user groups",
"usergroupnameexists-error": "You cannot create a new user group with 
this name as it already exists.",
"usergroups-createnew": "(create new...)",
"usergroups-editgroup-delete": "Delete this user group (Warning: This is 
irreversible. To recreate this class, you must [[Special:UserGroups/new|make a 
new one]].)",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I9e36a06ae8e21369edbfa62fe8427f02f14d23fb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/UserGroups
Gerrit-Branch: master
Gerrit-Owner: Umherirrender 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Raimond Spekking 
Gerrit-Reviewer: Siebrand 
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...TopTenPages[master]: Remove dot at end from extension description

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/373659 )

Change subject: Remove dot at end from extension description
..


Remove dot at end from extension description

Consistency tweak for extension active on translatewiki.net
Description on Special:Version does not end with a dot

Change-Id: I969cf39b72ec24c8c929315aa30489edfb275ad0
---
M i18n/en.json
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/i18n/en.json b/i18n/en.json
index 3e0b812..0f00477 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -6,5 +6,5 @@
},
"toptenpages": "Top Ten pages",
"toptenpages-extensionname": "TopTenPages",
-   "toptenpages-desc": "Shows most viewed pages."
+   "toptenpages-desc": "Shows most viewed pages"
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I969cf39b72ec24c8c929315aa30489edfb275ad0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TopTenPages
Gerrit-Branch: master
Gerrit-Owner: Umherirrender 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Raimond Spekking 
Gerrit-Reviewer: Siebrand 
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...TimedMediaHandler[master]: Disable Ogg Theora video transcodes in default config

2017-08-24 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/370855 )

Change subject: Disable Ogg Theora video transcodes in default config
..


Disable Ogg Theora video transcodes in default config

With WebM playback enabled via ogv.js, there's less reason to keep
the Ogg Theora video transcodes on Wikimedia or other sites.
Removing them by default in favor of just generating WebM.

This speeds encoding time and saves disk space, at the cost of
the WebM videos requiring more CPU in Safari/IE/Edge with the ogv.js
player shim.

Prep for removing them from Wikimedia due to ongoing tooling issues
with ffmpeg2theora.

Safe to merge after I68f22d7c goes out fully.

Bug: T172445
Change-Id: I2ffd2c6d0f87c53c0addc69515fdad803e192199
---
M TimedMediaHandler.php
1 file changed, 6 insertions(+), 2 deletions(-)

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



diff --git a/TimedMediaHandler.php b/TimedMediaHandler.php
index 80ac0ee..0cade78 100644
--- a/TimedMediaHandler.php
+++ b/TimedMediaHandler.php
@@ -135,7 +135,8 @@
 
// WebM VP8/Vorbis
// primary free/open video format
-   // supported by Chrome/Firefox/Opera but not Safari/IE/Edge
+   // supported by Chrome/Firefox/Opera natively
+   // plays back in Safari/IE/Edge via ogv.js
 
// Very low-bitrate web streamable WebM video
WebVideoTranscode::ENC_WEBM_160P,
@@ -158,8 +159,10 @@
// A 4K full high quality WebM stream
// WebVideoTranscode::ENC_WEBM_2160P,
 
+/*
// Ogg Theora/Vorbis
-   // Fallback for Safari/IE/Edge with ogv.js
+   // Optional fallback for Safari/IE/Edge with ogv.js
+   // Faster to encode & play back than WebM but less efficient.
 
// Requires twice the bitrate for same quality as VP8,
// and JS decoder can be slow, so shift to smaller sizes.
@@ -183,6 +186,7 @@
// Variable-bitrate HD Ogg stream
// for ogv.js on reasonably speedy machines
WebVideoTranscode::ENC_OGV_1080P,
+*/
 
 /*
// MP4 H.264/AAC

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2ffd2c6d0f87c53c0addc69515fdad803e192199
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/TimedMediaHandler
Gerrit-Branch: master
Gerrit-Owner: Brion VIBBER 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] wikimedia...SmashPig[master]: Clean up duplicate curlWrapper stuff

2017-08-24 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/373690 )

Change subject: Clean up duplicate curlWrapper stuff
..

Clean up duplicate curlWrapper stuff

Change-Id: Ifedea390459b70b788f0e964d54d675b0a8e65e5
---
M PaymentProviders/Ingenico/Tests/phpunit/ApiTest.php
M PaymentProviders/Ingenico/Tests/phpunit/BankPaymentProviderTest.php
M PaymentProviders/Ingenico/Tests/phpunit/IdealStatusProviderTest.php
M Tests/BaseSmashPigUnitTestCase.php
4 files changed, 2 insertions(+), 22 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/SmashPig 
refs/changes/90/373690/1

diff --git a/PaymentProviders/Ingenico/Tests/phpunit/ApiTest.php 
b/PaymentProviders/Ingenico/Tests/phpunit/ApiTest.php
index ed867ef..642a523 100644
--- a/PaymentProviders/Ingenico/Tests/phpunit/ApiTest.php
+++ b/PaymentProviders/Ingenico/Tests/phpunit/ApiTest.php
@@ -3,7 +3,6 @@
 namespace SmashPig\PaymentProviders\Ingenico\Tests;
 
 use DateTime;
-use PHPUnit_Framework_MockObject_MockObject;
 use SmashPig\PaymentProviders\Ingenico\Api;
 use SmashPig\PaymentProviders\Ingenico\Authenticator;
 use SmashPig\Tests\BaseSmashPigUnitTestCase;
@@ -12,11 +11,6 @@
  * @group Ingenico
  */
 class ApiTest extends BaseSmashPigUnitTestCase {
-
-   /**
-* @var PHPUnit_Framework_MockObject_MockObject
-*/
-   protected $curlWrapper;
 
/**
 * @var Authenticator
diff --git 
a/PaymentProviders/Ingenico/Tests/phpunit/BankPaymentProviderTest.php 
b/PaymentProviders/Ingenico/Tests/phpunit/BankPaymentProviderTest.php
index 749f2e9..60377b8 100644
--- a/PaymentProviders/Ingenico/Tests/phpunit/BankPaymentProviderTest.php
+++ b/PaymentProviders/Ingenico/Tests/phpunit/BankPaymentProviderTest.php
@@ -1,7 +1,6 @@
 curlWrapper = $this->getMock( 
'\SmashPig\Core\Http\CurlWrapper' );
-   // TODO: create tables for all dbs/queues.
-   // Standard issue CurlWrapper mock would be nice too
}
 
public function tearDown() {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifedea390459b70b788f0e964d54d675b0a8e65e5
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/SmashPig
Gerrit-Branch: master
Gerrit-Owner: Ejegg 

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


  1   2   3   4   5   >