[MediaWiki-commits] [Gerrit] mediawiki/vagrant[jessie-migration]: Remove phantomjs package from cirrussearch role

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

Change subject: Remove phantomjs package from cirrussearch role
..


Remove phantomjs package from cirrussearch role

This was previously used to allow runnign the browser tests inside
vagrant in a semi-performant way. Unfortunately this is no longer
available with jessie. This isn't strictly required, so rather than
finding an appropriate debian-equivilant ppa remove the requirement.

Change-Id: I219fff00e71d798848f2b4177d375954572e
---
M puppet/modules/role/manifests/cirrussearch.pp
1 file changed, 0 insertions(+), 5 deletions(-)

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



diff --git a/puppet/modules/role/manifests/cirrussearch.pp 
b/puppet/modules/role/manifests/cirrussearch.pp
index c008e90..1617e1c 100644
--- a/puppet/modules/role/manifests/cirrussearch.pp
+++ b/puppet/modules/role/manifests/cirrussearch.pp
@@ -17,11 +17,6 @@
 # necessary for CirrusSearch.php.erb to point to service root dir
 require ::service
 
-# By default Vagrant sets up firefox as the global browsertest
-# runner, we want to ensure phantomjs is available for running the
-# cirrussearch tests in a headless and parallelized manner.
-require_package('phantomjs')
-
 # Elasticsearch plugins
 ## Analysis
 elasticsearch::plugin { 'analysis-icu':

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I219fff00e71d798848f2b4177d375954572e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/vagrant
Gerrit-Branch: jessie-migration
Gerrit-Owner: EBernhardson 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: Dduvall 
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...CirrusSearch[es5]: Replace reindexing with _reindex API

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

Change subject: Replace reindexing with _reindex API
..


Replace reindexing with _reindex API

Initial replacement of the internals of our Reindexer class with the
_reindex API in es 5.  This generally appears to work for the basic case
of copying an index for mapping updates, but it needs further testing.

Tested working:
* Basic mapping change and copy from old index to new on same cluster
* Delete specific fields from all documents while reindexing
* Can still vary chunk size as necessary.
* Reports progress every 30s while indexing is running
* Reindexes between clusters

Bug: T155506
Change-Id: Ifbbae065038cfe6e07a84f6a1b46dd317c3081d3
---
M autoload.php
M includes/Elastica/PooledHttp.php
A includes/Elastica/ReindexRequest.php
A includes/Elastica/ReindexResponse.php
A includes/Elastica/ReindexStatus.php
A includes/Elastica/ReindexTask.php
M includes/Maintenance/Reindexer.php
M includes/SearchConfig.php
M maintenance/copySearchIndex.php
M maintenance/updateOneSearchIndexConfig.php
A tests/unit/Elastica/ReindexRequestTest.php
A tests/unit/Elastica/ReindexTaskTest.php
A tests/unit/Maintenance/ReindexerTest.php
13 files changed, 1,165 insertions(+), 382 deletions(-)

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



diff --git a/autoload.php b/autoload.php
index 83d3506..095fbb7 100644
--- a/autoload.php
+++ b/autoload.php
@@ -40,6 +40,10 @@
'CirrusSearch\\Elastica\\MultiSearch' => __DIR__ . 
'/includes/Elastica/MultiSearch.php',
'CirrusSearch\\Elastica\\PooledHttp' => __DIR__ . 
'/includes/Elastica/PooledHttp.php',
'CirrusSearch\\Elastica\\PooledHttps' => __DIR__ . 
'/includes/Elastica/PooledHttps.php',
+   'CirrusSearch\\Elastica\\ReindexRequest' => __DIR__ . 
'/includes/Elastica/ReindexRequest.php',
+   'CirrusSearch\\Elastica\\ReindexResponse' => __DIR__ . 
'/includes/Elastica/ReindexResponse.php',
+   'CirrusSearch\\Elastica\\ReindexStatus' => __DIR__ . 
'/includes/Elastica/ReindexStatus.php',
+   'CirrusSearch\\Elastica\\ReindexTask' => __DIR__ . 
'/includes/Elastica/ReindexTask.php',
'CirrusSearch\\ElasticsearchIntermediary' => __DIR__ . 
'/includes/ElasticsearchIntermediary.php',
'CirrusSearch\\EmptyInterwikiResolver' => __DIR__ . 
'/includes/EmptyInterwikiResolver.php',
'CirrusSearch\\ExplainPrinter' => __DIR__ . 
'/includes/ExplainPrinter.php',
diff --git a/includes/Elastica/PooledHttp.php b/includes/Elastica/PooledHttp.php
index d18d100..aa35100 100644
--- a/includes/Elastica/PooledHttp.php
+++ b/includes/Elastica/PooledHttp.php
@@ -13,10 +13,12 @@
  *
  *  $wgCirrusSearchClusters = array(
  *'default' => array(
- *  'transport' => 'CirrusSearch\Elastica\PooledHttp',
- *  'port' => 12345,
- *  'host' => 'my.host.name',
- *  'config' => array( 'pool' => 'cirrus' ),
+ *  array(
+ *'transport' => 'CirrusSearch\Elastica\PooledHttp',
+ *'port' => 12345,
+ *'host' => 'my.host.name',
+ *'config' => array( 'pool' => 'cirrus' ),
+ *  )
  *)
  *  );
  *
diff --git a/includes/Elastica/ReindexRequest.php 
b/includes/Elastica/ReindexRequest.php
new file mode 100644
index 000..9fc3610
--- /dev/null
+++ b/includes/Elastica/ReindexRequest.php
@@ -0,0 +1,162 @@
+source = $this->asSourceDest( $source );
+   $this->source['size'] = $chunkSize;
+   $this->dest = $this->asSourceDest( $dest );
+   $this->client = $dest instanceof Index
+   ? $dest->getClient()
+   : $dest->getIndex()->getClient();
+   }
+
+   /**
+* @param array $remote
+* @return $this
+*/
+   public function setRemoteInfo( array $remote ) {
+   $this->source['remote'] = $remote;
+   return $this;
+   }
+
+   /**
+* @param array $script
+* @return $this
+*/
+   public function setScript( array $script ) {
+   $this->script = $script;
+   return $this;
+   }
+
+   /**
+* The number of documents to reindex
+*
+* @param int $size
+* @return $this
+*/
+   public function setSize( $size ) {
+   $this->size = $size;
+   return $this;
+   }
+
+   /**
+* @param int $rps
+* @return $this
+*/
+   public function setRequestsPerSecond( $rps ) {
+   $this->requestsPerSecond = $rps;
+   return $this;
+   }
+
+   /**
+* @param int $slices
+* @return $this
+*/
+   public function setSlices( $slices ) {
+   $this->slices = $slices;
+   return $this;
+   }
+
+   /**
+* @return ReindexTask
+*/
+   public function reindexTask() {
+   

[MediaWiki-commits] [Gerrit] integration/config[master]: Adding dependencies for current BlueSpice* repos

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

Change subject: Adding dependencies for current BlueSpice* repos
..


Adding dependencies for current BlueSpice* repos

see https://phabricator.wikimedia.org/T130811#3067775

Change-Id: Ie7ff418de037dba8d4e7af5152d9a687feb84c16
---
M zuul/parameter_functions.py
1 file changed, 8 insertions(+), 1 deletion(-)

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



diff --git a/zuul/parameter_functions.py b/zuul/parameter_functions.py
index 73ead9f..591e197 100644
--- a/zuul/parameter_functions.py
+++ b/zuul/parameter_functions.py
@@ -134,8 +134,15 @@
 'Arrays': ['Loops', 'ParserFunctions', 'Variables'],
 'ArticlePlaceholder': ['Wikibase', 'Scribunto'],
 'BlueSpiceCategoryManager': ['BlueSpiceFoundation'],
+'BlueSpiceEditNotifyConnector': ['BlueSpiceFoundation'],
+'BlueSpiceExtendedFilelist': ['BlueSpiceFoundation'],
+'BlueSpiceExtendedSearch': ['BlueSpiceFoundation'],
 'BlueSpiceExtensions': ['BlueSpiceFoundation'],
-'BSSMWConnector': ['BlueSpiceFoundation'],
+'BlueSpiceMultiUpload': ['BlueSpiceFoundation'],
+'BlueSpicePageAssignments': ['BlueSpiceFoundation'],
+'BlueSpicePageVersion': ['BlueSpiceFoundation'],
+'BlueSpiceSMWConnector': ['BlueSpiceFoundation'],
+'BlueSpiceSubPageTree': ['BlueSpiceFoundation'],
 'Capiunto': ['Scribunto'],
 'Cite': ['VisualEditor'],
 'Citoid': ['Cite', 'VisualEditor'],

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie7ff418de037dba8d4e7af5152d9a687feb84c16
Gerrit-PatchSet: 2
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Robert Vogel 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] integration/config[master]: Adding Doxygen and JSDuck postmerge jobs for CollaborationKit

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

Change subject: Adding Doxygen and JSDuck postmerge jobs for CollaborationKit
..


Adding Doxygen and JSDuck postmerge jobs for CollaborationKit

Change-Id: I4f9230089053d7b39ace00840bd8a3792d0a62c1
---
M zuul/layout.yaml
1 file changed, 3 insertions(+), 0 deletions(-)

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



diff --git a/zuul/layout.yaml b/zuul/layout.yaml
index 23a51cd..248d7e4 100644
--- a/zuul/layout.yaml
+++ b/zuul/layout.yaml
@@ -3053,6 +3053,9 @@
   - name: npm
 check:
   - jsonlint
+postmerge:
+  - mwext-doxygen-publish
+  - mwext-jsduck-publish
 
   - name: mediawiki/extensions/CollapsibleVector
 template:

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...Wikibase[master]: Plug DispatchingEntityRdfBuilder to EntityRdfBuilder

2017-03-02 Thread Ladsgroup (Code Review)
Ladsgroup has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340930 )

Change subject: Plug DispatchingEntityRdfBuilder to EntityRdfBuilder
..

Plug DispatchingEntityRdfBuilder to EntityRdfBuilder

Bug: T157311
Change-Id: Ifead033ec90a7281b5fde50eaefc0d679bdc015c
---
M repo/includes/Dumpers/RdfDumpGenerator.php
M repo/includes/LinkedData/EntityDataSerializationService.php
M repo/includes/Rdf/RdfBuilder.php
M repo/includes/Specials/SpecialEntityData.php
M repo/maintenance/dumpRdf.php
M repo/tests/phpunit/includes/Dumpers/RdfDumpGeneratorTest.php
M repo/tests/phpunit/includes/LinkedData/EntityDataRequestHandlerTest.php
M repo/tests/phpunit/includes/LinkedData/EntityDataSerializationServiceTest.php
M repo/tests/phpunit/includes/Rdf/RdfBuilderTest.php
M repo/tests/phpunit/includes/Specials/SpecialEntityDataTest.php
M repo/tests/phpunit/maintenance/dumpRdfTest.php
11 files changed, 86 insertions(+), 24 deletions(-)


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

diff --git a/repo/includes/Dumpers/RdfDumpGenerator.php 
b/repo/includes/Dumpers/RdfDumpGenerator.php
index be2dec8..381a391 100644
--- a/repo/includes/Dumpers/RdfDumpGenerator.php
+++ b/repo/includes/Dumpers/RdfDumpGenerator.php
@@ -16,6 +16,7 @@
 use Wikibase\Lib\Store\StorageException;
 use Wikibase\DataModel\Services\Lookup\RedirectResolvingEntityLookup;
 use Wikibase\Lib\Store\RevisionedUnresolvedRedirectException;
+use Wikibase\Rdf\EntityRdfBuilderFactory;
 use Wikibase\Rdf\ValueSnakRdfBuilderFactory;
 use Wikibase\Rdf\HashDedupeBag;
 use Wikibase\Rdf\RdfBuilder;
@@ -192,6 +193,7 @@
 * @param EntityRevisionLookup   $entityRevisionLookup
 * @param PropertyDataTypeLookup $propertyLookup
 * @param ValueSnakRdfBuilderFactory $valueSnakRdfBuilderFactory
+* @param EntityRdfBuilderFactory$entityRdfBuilderFactory
 * @param EntityPrefetcher   $entityPrefetcher
 * @param RdfVocabulary  $vocabulary
 * @param EntityTitleLookup  $titleLookup
@@ -205,6 +207,7 @@
EntityRevisionLookup $entityRevisionLookup,
PropertyDataTypeLookup $propertyLookup,
ValueSnakRdfBuilderFactory $valueSnakRdfBuilderFactory,
+   EntityRdfBuilderFactory $entityRdfBuilderFactory,
EntityPrefetcher $entityPrefetcher,
RdfVocabulary $vocabulary,
EntityTitleLookup $titleLookup
@@ -225,6 +228,7 @@
$vocabulary,
$valueSnakRdfBuilderFactory,
$propertyLookup,
+   $entityRdfBuilderFactory,
$flavor,
$rdfWriter,
new HashDedupeBag(),
diff --git a/repo/includes/LinkedData/EntityDataSerializationService.php 
b/repo/includes/LinkedData/EntityDataSerializationService.php
index e4a24d6..8dcbcde 100644
--- a/repo/includes/LinkedData/EntityDataSerializationService.php
+++ b/repo/includes/LinkedData/EntityDataSerializationService.php
@@ -19,6 +19,7 @@
 use Wikibase\DataModel\Services\Lookup\PropertyDataTypeLookup;
 use Wikibase\EntityRevision;
 use Wikibase\Lib\Store\EntityTitleLookup;
+use Wikibase\Rdf\EntityRdfBuilderFactory;
 use Wikibase\Rdf\ValueSnakRdfBuilderFactory;
 use Wikibase\Rdf\HashDedupeBag;
 use Wikibase\Rdf\RdfBuilder;
@@ -95,10 +96,16 @@
private $valueSnakRdfBuilderFactory;
 
/**
+* @var EntityRdfBuilderFactory
+*/
+   private $entityRdfBuilderFactory;
+
+   /**
 * @param EntityLookup $entityLookup
 * @param EntityTitleLookup $entityTitleLookup
 * @param PropertyDataTypeLookup $propertyLookup
 * @param ValueSnakRdfBuilderFactory $valueSnakRdfBuilderFactory
+* @param EntityRdfBuilderFactory $entityRdfBuilderFactory
 * @param SiteList $sites
 * @param EntityDataFormatProvider $entityDataFormatProvider
 * @param SerializerFactory $serializerFactory
@@ -110,6 +117,7 @@
EntityTitleLookup $entityTitleLookup,
PropertyDataTypeLookup $propertyLookup,
ValueSnakRdfBuilderFactory $valueSnakRdfBuilderFactory,
+   EntityRdfBuilderFactory $entityRdfBuilderFactory,
SiteList $sites,
EntityDataFormatProvider $entityDataFormatProvider,
SerializerFactory $serializerFactory,
@@ -121,6 +129,7 @@
$this->serializerFactory = $serializerFactory;
$this->propertyLookup = $propertyLookup;
$this->valueSnakRdfBuilderFactory = $valueSnakRdfBuilderFactory;
+   $this->entityRdfBuilderFactory = $entityRdfBuilderFactory;
$this->sites = $sites;
$this->entityDataFormatProvider = $entityDataFormatProvider;

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

2017-03-02 Thread Marostegui (Code Review)
Marostegui has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340929 )

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

db-codfw.php: Depool db2067

Depool db2067 for an alter table

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


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

diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php
index 9fa032f..58f3e38 100644
--- a/wmf-config/db-codfw.php
+++ b/wmf-config/db-codfw.php
@@ -140,7 +140,7 @@
'db2046' => 400, # C6 2.9TB 160GB
'db2053' => 100, # D6 2.9TB 160GB, dump (inactive), vslow
'db2060' => 100, # D6 3.3TB 160GB, api
-   'db2067' => 400, # D6 3.3TB 160GB
+#  'db2067' => 400, # D6 3.3TB 160GB #T159414
],
's7' => [
'db2029' => 0,   # B6 2.9TB  96GB, master

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifad49972691200aad24a583f7118da287df1010e
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] mediawiki...ParsoidBatchAPI[master]: Return "duration" and "size" for imageinfo requests

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

Change subject: Return "duration" and "size" for imageinfo requests
..


Return "duration" and "size" for imageinfo requests

 * Matches core commit 84d8b18b

Change-Id: I41cca6c6e2a3d96f75371f7276e00d0be52ae327
---
M includes/ApiParsoidBatch.php
1 file changed, 5 insertions(+), 1 deletion(-)

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



diff --git a/includes/ApiParsoidBatch.php b/includes/ApiParsoidBatch.php
index a8460aa..1f3cb80 100644
--- a/includes/ApiParsoidBatch.php
+++ b/includes/ApiParsoidBatch.php
@@ -275,13 +275,17 @@
$result = array(
'width' => $file->getWidth(),
'height' => $file->getHeight(),
+   'size' => $file->getSize(),
'mediatype' => $file->getMediaType(),
'mime' => $file->getMimeType(),
'url' => wfExpandUrl( $file->getFullUrl(), 
PROTO_CURRENT ),
'mustRender' => $file->mustRender(),
'badFile' => wfIsBadImage( $filename, $page ?: false ),
);
-
+   $length = $file->getLength();
+   if ( $length ) {
+   $result['duration'] = (float)$length;
+   }
$txopts = $this->makeTransformOptions( $file, $txopts );
$mto = $file->transform( $txopts );
if ( $mto ) {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I41cca6c6e2a3d96f75371f7276e00d0be52ae327
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ParsoidBatchAPI
Gerrit-Branch: master
Gerrit-Owner: Arlolra 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Subramanya Sastry 
Gerrit-Reviewer: Tim Starling 
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]: Make the parser tests' "subpage" option actually enable for ...

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

Change subject: Make the parser tests' "subpage" option actually enable for all 
subpages
..


Make the parser tests' "subpage" option actually enable for all subpages

The option says "enable subpages (disabled by default)", but it
currently just enables subpages for namespaces 0 and 2. This tripped me
up when writing some parser tests for TemplateStyles where I need
subpages enabled for namespace 10.

There's probably no reason not to have it enable subpages for all
namespaces.

Change-Id: Icf864dafc4208a76af7b3e71f5f9c97576c065b7
---
M tests/parser/ParserTestRunner.php
1 file changed, 3 insertions(+), 4 deletions(-)

Approvals:
  Tim Starling: Looks good to me, approved
  Krinkle: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/tests/parser/ParserTestRunner.php 
b/tests/parser/ParserTestRunner.php
index 7edde2a..35c2480 100644
--- a/tests/parser/ParserTestRunner.php
+++ b/tests/parser/ParserTestRunner.php
@@ -974,10 +974,9 @@
'wgEnableUploads' => self::getOptionValue( 
'wgEnableUploads', $opts, true ),
'wgLanguageCode' => $langCode,
'wgRawHtml' => self::getOptionValue( 'wgRawHtml', 
$opts, false ),
-   'wgNamespacesWithSubpages' => [
-   0 => isset( $opts['subpage'] ),
-   2 => isset( $opts['subpage'] ),
-   ],
+   'wgNamespacesWithSubpages' => array_fill_keys(
+   MWNamespace::getValidNamespaces(), isset( 
$opts['subpage'] )
+   ),
'wgMaxTocLevel' => $maxtoclevel,
'wgAllowExternalImages' => self::getOptionValue( 
'wgAllowExternalImages', $opts, true ),
'wgThumbLimits' => [ self::getOptionValue( 'thumbsize', 
$opts, 180 ) ],

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Icf864dafc4208a76af7b3e71f5f9c97576c065b7
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Anomie 
Gerrit-Reviewer: C. Scott Ananian 
Gerrit-Reviewer: Gergő Tisza 
Gerrit-Reviewer: Jackmcbarn 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Tim Starling 
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...Gadgets[master]: Code style/uniformity cleanups to GadgetDefinitionNamespaceRepo

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

Change subject: Code style/uniformity cleanups to GadgetDefinitionNamespaceRepo
..

Code style/uniformity cleanups to GadgetDefinitionNamespaceRepo

Change-Id: Ic49383ac1ef99494050005c3641aa6a758fe3e8c
---
M includes/GadgetDefinitionNamespaceRepo.php
M includes/GadgetResourceLoaderModule.php
M includes/content/GadgetDefinitionDeletionUpdate.php
M includes/content/GadgetDefinitionSecondaryDataUpdate.php
4 files changed, 47 insertions(+), 39 deletions(-)


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

diff --git a/includes/GadgetDefinitionNamespaceRepo.php 
b/includes/GadgetDefinitionNamespaceRepo.php
index e7e2201..f56873c 100644
--- a/includes/GadgetDefinitionNamespaceRepo.php
+++ b/includes/GadgetDefinitionNamespaceRepo.php
@@ -1,12 +1,13 @@
 idsKey = wfMemcKey( 'gadgets', 'namespace', 'ids' );
-   $this->wanCache = ObjectCache::getMainWANInstance();
-   }
-
-   /**
-* Purge the list of gadget ids when a page is deleted
-* or if a new page is created
-*/
-   public function purgeGadgetIdsList() {
-   $this->wanCache->touchCheckKey( $this->idsKey );
+   $this->wanCache = 
MediaWikiServices::getInstance()->getMainWANObjectCache();
}
 
/**
@@ -42,40 +29,35 @@
 * @return string[]
 */
public function getGadgetIds() {
+   $key = $this->getGadgetIdsKey();
+
return $this->wanCache->getWithSetCallback(
-   $this->idsKey,
+   $key,
self::CACHE_TTL,
-   function( $oldValue, &$ttl, array &$setOpts ) {
+   function ( $oldValue, &$ttl, array &$setOpts ) {
$dbr = wfGetDB( DB_SLAVE );
$setOpts += Database::getCacheSetOptions( $dbr 
);
+
return $dbr->selectFieldValues(
'page',
'page_title',
-   [
-   'page_namespace' => 
NS_GADGET_DEFINITION
-   ],
+   [ 'page_namespace' => 
NS_GADGET_DEFINITION ],
__METHOD__
);
},
[
-   'checkKeys' => [ $this->idsKey ],
-   'pcTTL' => 5,
-   'lockTSE' => '30',
+   'checkKeys' => [ $key ],
+   'pcTTL' => WANObjectCache::TTL_PROC_SHORT,
+   'lockTSE' => 30
]
);
}
 
/**
-* Update the cache for a specific Gadget whenever it is updated
-*
-* @param string $id
+* Purge the list of gadget ids when a page is deleted or if a new page 
is created
 */
-   public function updateGadgetObjectCache( $id ) {
-   $this->wanCache->touchCheckKey( $this->getGadgetCacheKey( $id ) 
);
-   }
-
-   private function getGadgetCacheKey( $id ) {
-   return wfMemcKey( 'gadgets', 'object', md5( $id ), 
Gadget::GADGET_CLASS_VERSION );
+   public function purgeGadgetIdsList() {
+   $this->wanCache->touchCheckKey( $this->getGadgetIdsKey() );
}
 
/**
@@ -88,13 +70,14 @@
$gadget = $this->wanCache->getWithSetCallback(
$key,
self::CACHE_TTL,
-   function( $old, &$ttl, array &$setOpts ) use ( $id ) {
+   function ( $old, &$ttl, array &$setOpts ) use ( $id ) {
$setOpts += Database::getCacheSetOptions( 
wfGetDB( DB_SLAVE ) );
$title = Title::makeTitleSafe( 
NS_GADGET_DEFINITION, $id );
if ( !$title ) {
$ttl = WANObjectCache::TTL_UNCACHEABLE;
return null;
}
+
$rev = Revision::newFromTitle( $title );
if ( !$rev ) {
$ttl = WANObjectCache::TTL_UNCACHEABLE;
@@ -112,8 +95,8 @@
},
[
'checkKeys' => [ $key ],
-   'pcTTL' => 5,
-   'lockTSE' => '30',
+   'pcTTL' => WANObjectCache::TTL_PROC_SHORT,
+   'lockTSE' => 30
   

[MediaWiki-commits] [Gerrit] mediawiki...WikibaseLexeme[master]: Add docs for ChangeOp serialization of language and lexical ...

2017-03-02 Thread Ladsgroup (Code Review)
Ladsgroup has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340927 )

Change subject: Add docs for ChangeOp serialization of language and lexical 
category
..

Add docs for ChangeOp serialization of language and lexical category

Bug: T155703
Change-Id: I1ac2681bd083052cc2470fb3ce1ea4f5164dc4ba
---
M docs/change-op-serialization.wiki
1 file changed, 21 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikibaseLexeme 
refs/changes/27/340927/1

diff --git a/docs/change-op-serialization.wiki 
b/docs/change-op-serialization.wiki
index 22e3302..60ed2f3 100644
--- a/docs/change-op-serialization.wiki
+++ b/docs/change-op-serialization.wiki
@@ -6,7 +6,17 @@
 
 === Language ===
 
-TODO
+* Language are defined by adding a "language" key to change request JSON 
array. Value should be a string containing an Q-id of an existing item. That 
item should be a about a language (for example French or Chinese) but we don't 
enforce that and constraint reports should take care of such violations:
+
+Example of a change request setting language to "Q666" can be seen below (only 
relevant parts of the request included in the example).
+
+
+{
+   ...
+   "language": "Q666"
+   ...
+}
+
 
 === Lemmas ===
 
@@ -31,5 +41,14 @@
 
 
 === Lexical category ===
+* Lexical categories are defined by adding a "lexical_category" key to change 
request JSON array. Value should be a string containing an Q-id of an existing 
item. That item should be a about a lexical category (for example verb or noun) 
but we don't enforce that and constraint reports should take care of such 
violations:
 
-TODO
\ No newline at end of file
+Example of a change request setting lexical category to "Q42" can be seen 
below (only relevant parts of the request included in the example).
+
+
+{
+   ...
+   "lexical_category": "Q42"
+   ...
+}
+

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...ContentTranslation[master]: TranslationUnit UI: Pass selection object to onSelect event ...

2017-03-02 Thread Santhosh (Code Review)
Santhosh has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340926 )

Change subject: TranslationUnit UI: Pass selection object to onSelect event 
handlers
..

TranslationUnit UI: Pass selection object to onSelect event handlers

Change-Id: I3a240b57c01e83e0bf16bc705e5bcc8895986b8f
---
M modules/tools/mw.cx.tools.DictionaryTool.js
M modules/tools/mw.cx.tools.FormatterTool.js
M modules/ui/translationunits/mw.cx.ui.TranslationUnit.js
3 files changed, 17 insertions(+), 10 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ContentTranslation 
refs/changes/26/340926/1

diff --git a/modules/tools/mw.cx.tools.DictionaryTool.js 
b/modules/tools/mw.cx.tools.DictionaryTool.js
index 312f939..fca63f9 100644
--- a/modules/tools/mw.cx.tools.DictionaryTool.js
+++ b/modules/tools/mw.cx.tools.DictionaryTool.js
@@ -31,11 +31,13 @@
 
 /**
  * Text selection handler
- * @param  {string} selection Selected text
+ * @param {Object} selectionObj Selection object
  */
-mw.cx.tools.DictionaryTool.prototype.onSelect = function ( selection ) {
-   var selectionChanged = false;
+mw.cx.tools.DictionaryTool.prototype.onSelect = function ( selectionObj ) {
+   var selection, selectionChanged = false;
+
// TODO: Sanitize content
+   selection = selectionObj.toString();
if ( selection && selection.length < 1000 ) {
if ( this.content && this.content !== selection ) {
selectionChanged = true;
diff --git a/modules/tools/mw.cx.tools.FormatterTool.js 
b/modules/tools/mw.cx.tools.FormatterTool.js
index bb8ef85..fb8cd0d 100644
--- a/modules/tools/mw.cx.tools.FormatterTool.js
+++ b/modules/tools/mw.cx.tools.FormatterTool.js
@@ -10,6 +10,7 @@
 mw.cx.tools.FormatterTool = function CXFormatterTool( ui, config ) {
config.order = 1;
config.title = 'Formatter';
+   this.selection = null;
// Parent constructor
mw.cx.tools.FormatterTool.super.call( this, ui, config );
this.ui.connect( this, {
@@ -53,13 +54,17 @@
 
 /**
  * Text selection handler
- * @param {string} selection Selected text
+ * @param {Object} selectionObj Selection object
  */
-mw.cx.tools.FormatterTool.prototype.onSelect = function ( selection ) {
-   // TODO: We need the selection object rather than selection string here
+mw.cx.tools.FormatterTool.prototype.onSelect = function ( selectionObj ) {
+   var selection;
+
+   // TODO: Sanitize content
+   selection = selectionObj.toString();
if ( selection ) {
this.showTool();
}
+   this.selection = selectionObj;
 };
 
 mw.cx.tools.FormatterTool.prototype.getContent = function () {
diff --git a/modules/ui/translationunits/mw.cx.ui.TranslationUnit.js 
b/modules/ui/translationunits/mw.cx.ui.TranslationUnit.js
index ab79e41..1c90972 100644
--- a/modules/ui/translationunits/mw.cx.ui.TranslationUnit.js
+++ b/modules/ui/translationunits/mw.cx.ui.TranslationUnit.js
@@ -55,16 +55,16 @@
 };
 
 mw.cx.ui.TranslationUnit.prototype.onMouseUp = function ( event ) {
-   var selection;
+   var selectionObj;
 
// Control or alt key press events can be ignored
if ( event.metaKey || event.ctrlKey && !event.altKey ) {
return;
}
 
-   selection = window.getSelection().toString();
-   if ( selection.trim() ) {
-   this.emit( 'select', selection );
+   selectionObj = window.getSelection();
+   if ( selectionObj && selectionObj.toString().trim() ) {
+   this.emit( 'select', selectionObj );
} else {
this.emit( 'focus' );
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3a240b57c01e83e0bf16bc705e5bcc8895986b8f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh 

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


[MediaWiki-commits] [Gerrit] mediawiki...CollaborationKit[master]: Configuration for JSDuck

2017-03-02 Thread Harej (Code Review)
Harej has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340925 )

Change subject: Configuration for JSDuck
..

Configuration for JSDuck

Change-Id: I0ee0826a2fca3e5c2ac0ebb8b141f7188dd122b6
---
A jsduck.json
M package.json
2 files changed, 13 insertions(+), 1 deletion(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CollaborationKit 
refs/changes/25/340925/1

diff --git a/jsduck.json b/jsduck.json
new file mode 100644
index 000..f0d47eb
--- /dev/null
+++ b/jsduck.json
@@ -0,0 +1,11 @@
+{
+   "--title": "TemplateData - CollaborationKit",
+   "--processes": "0",
+   "--warnings-exit-nonzero": true,
+   "--external": "OO.*",
+   "--output": "docs",
+   "--": [
+   "jsduck.external.js",
+   "modules"
+   ]
+}
\ No newline at end of file
diff --git a/package.json b/package.json
index d6d0f28..13889a8 100644
--- a/package.json
+++ b/package.json
@@ -1,7 +1,8 @@
 {
   "private": true,
   "scripts": {
-"test": "grunt test"
+"test": "grunt test",
+"doc": "jsduck"
   },
   "devDependencies": {
 "grunt": "0.4.5",

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0ee0826a2fca3e5c2ac0ebb8b141f7188dd122b6
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/CollaborationKit
Gerrit-Branch: master
Gerrit-Owner: Harej 

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


[MediaWiki-commits] [Gerrit] mediawiki...DonationInterface[master]: Remove deprecated key-value interfaces

2017-03-02 Thread Awight (Code Review)
Awight has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340924 )

Change subject: Remove deprecated key-value interfaces
..

Remove deprecated key-value interfaces

Bug: T159175
Change-Id: I34e782f5dd833de407642c39df2d1ca90a933abf
---
M tests/phpunit/includes/TestingQueue.php
1 file changed, 1 insertion(+), 20 deletions(-)


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

diff --git a/tests/phpunit/includes/TestingQueue.php 
b/tests/phpunit/includes/TestingQueue.php
index 16f64ee..0c65781 100644
--- a/tests/phpunit/includes/TestingQueue.php
+++ b/tests/phpunit/includes/TestingQueue.php
@@ -20,8 +20,6 @@
 FIXME: We can't reference the actual classes until vendor/ is provisioned for 
tests.
 
 use PHPQueue\Backend\Base;
-use PHPQueue\Interfaces\KeyValueStore;
-use PHPQueue\Interfaces\IndexedFifoQueueStore;
 */
 
 /**
@@ -29,7 +27,7 @@
  * and multiple queues, but (obviously) data is destroyed on application
  * shutdown.
  */
-class TestingQueue /* extends Base implements IndexedFifoQueueStore, 
KeyValueStore */ {
+class TestingQueue /* extends Base implements FifoQueueStore */ {
protected $queue_name;
protected $queue;
 
@@ -63,22 +61,5 @@
return null;
}
return json_decode( array_shift( $this->queue ), true );
-   }
-
-   public function set( $id, $data ) {
-   $this->queue[$id] = json_encode( $data );
-   }
-
-   public function get( $id ) {
-   if ( !array_key_exists( $id, $this->queue ) ) {
-   return null;
-   }
-   return json_decode( $this->queue[$id], true );
-   }
-
-   public function clear( $id ) {
-   if ( array_key_exists( $id, $this->queue ) ) {
-   unset( $this->queue[$id] );
-   }
}
 }

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...ContentTranslation[master]: Add OOjs UI based formatter tool

2017-03-02 Thread Santhosh (Code Review)
Santhosh has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340923 )

Change subject: Add OOjs UI based formatter tool
..

Add OOjs UI based formatter tool

In this commit, the formatter get displayed on text selection.
Clicking on buttons does nothing.

Bug: T152586
Change-Id: I5aeb737e339777af9d12330368eae3baed66e448
---
M extension.json
A modules/tools/mw.cx.tools.FormatterTool.js
A modules/tools/styles/mw.cx.tools.FormatterTool.less
3 files changed, 98 insertions(+), 1 deletion(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ContentTranslation 
refs/changes/23/340923/1

diff --git a/extension.json b/extension.json
index eef093a..672d9a6 100644
--- a/extension.json
+++ b/extension.json
@@ -1719,7 +1719,8 @@
"mw.cx.tools.InstructionsTool",
"mw.cx.tools.DictionaryTool",
"mw.cx.tools.TemplateTool",
-   "mw.cx.tools.LinkTool"
+   "mw.cx.tools.LinkTool",
+   "mw.cx.tools.FormatterTool"
]
},
"mw.cx.tools.MachineTranslationTool": {
@@ -1805,6 +1806,19 @@
"mw.cx.tools.TranslationTool"
]
},
+   "mw.cx.tools.FormatterTool": {
+   "scripts": [
+   "tools/mw.cx.tools.FormatterTool.js"
+   ],
+   "styles": [
+   "tools/styles/mw.cx.tools.FormatterTool.less"
+   ],
+   "dependencies": [
+   "mw.cx.tools.TranslationTool",
+   "oojs-ui.styles.icons-editing-styling",
+   "oojs-ui.styles.icons-editing-list"
+   ]
+   },
"mw.cx.tools.LinkTool": {
"scripts": [
"tools/mw.cx.tools.LinkTool.js"
diff --git a/modules/tools/mw.cx.tools.FormatterTool.js 
b/modules/tools/mw.cx.tools.FormatterTool.js
new file mode 100644
index 000..bb8ef85
--- /dev/null
+++ b/modules/tools/mw.cx.tools.FormatterTool.js
@@ -0,0 +1,70 @@
+/**
+ * Formatter Tool
+ *
+ * @class
+ * @extends mw.cx.tools.TranslationTool
+ * @constructor
+ * @param {mw.cx.ui.TranslationUnit} ui
+ * @param {Object} config
+ */
+mw.cx.tools.FormatterTool = function CXFormatterTool( ui, config ) {
+   config.order = 1;
+   config.title = 'Formatter';
+   // Parent constructor
+   mw.cx.tools.FormatterTool.super.call( this, ui, config );
+   this.ui.connect( this, {
+   select: 'onSelect'
+   } );
+};
+
+/* Inheritance */
+OO.inheritClass( mw.cx.tools.FormatterTool, mw.cx.tools.TranslationTool );
+
+mw.cx.tools.FormatterTool.static.name = 'formatter';
+
+/**
+ * @inheritDoc
+ */
+mw.cx.tools.FormatterTool.prototype.getActions = function () {
+   var formatterButtonGroup, undoButton, redoButton, boldButton, 
italicButton, orderedlistButton, unOrderedlistButton;
+   undoButton = new OO.ui.ButtonWidget( {
+   icon: 'undo'
+   } );
+   redoButton = new OO.ui.ButtonWidget( {
+   icon: 'redo'
+   } );
+   boldButton = new OO.ui.ButtonWidget( {
+   icon: 'bold'
+   } );
+   italicButton = new OO.ui.ButtonWidget( {
+   icon: 'italic'
+   } );
+   orderedlistButton = new OO.ui.ButtonWidget( {
+   icon: 'listBullet'
+   } );
+   unOrderedlistButton = new OO.ui.ButtonWidget( {
+   icon: 'listNumbered'
+   } );
+   formatterButtonGroup = new OO.ui.ButtonGroupWidget( {
+   items: [ undoButton, redoButton, boldButton, italicButton, 
orderedlistButton, unOrderedlistButton ]
+   } );
+   return [ formatterButtonGroup ];
+};
+
+/**
+ * Text selection handler
+ * @param {string} selection Selected text
+ */
+mw.cx.tools.FormatterTool.prototype.onSelect = function ( selection ) {
+   // TODO: We need the selection object rather than selection string here
+   if ( selection ) {
+   this.showTool();
+   }
+};
+
+mw.cx.tools.FormatterTool.prototype.getContent = function () {
+   return '';
+};
+
+/* Register */
+mw.cx.tools.translationToolFactory.register( mw.cx.tools.FormatterTool );
diff --git a/modules/tools/styles/mw.cx.tools.FormatterTool.less 
b/modules/tools/styles/mw.cx.tools.FormatterTool.less
new file mode 100644
index 000..28c49c2
--- /dev/null
+++ b/modules/tools/styles/mw.cx.tools.FormatterTool.less
@@ -0,0 +1,13 @@
+.cx-card-formatter {
+   .cx-widget-translationtool-container {
+   padding: 0;
+   }
+   .cx-widget-translationtool-header {
+   display: none;
+   }
+   

[MediaWiki-commits] [Gerrit] mediawiki...DonationInterface[master]: Use HashBag instead of EmptyBag

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

Change subject: Use HashBag instead of EmptyBag
..


Use HashBag instead of EmptyBag

If the local cluster cache is an EmptyBagOfStuff, fall back to a
HashBagOStuff to at least cache for the duration of the request.

Also logs a warning, so we can easily tell on production if we're
only pretending to cache things.

Bug: T128692
Change-Id: I570cdcc7347312bb246848b5d43d22ce1720d3f1
---
M gateway_common/LocalClusterPsr6Cache.php
1 file changed, 17 insertions(+), 2 deletions(-)

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



diff --git a/gateway_common/LocalClusterPsr6Cache.php 
b/gateway_common/LocalClusterPsr6Cache.php
index 30740d8..ed7e32e 100644
--- a/gateway_common/LocalClusterPsr6Cache.php
+++ b/gateway_common/LocalClusterPsr6Cache.php
@@ -11,8 +11,23 @@
  * (no constructor-parameters need to be specified)
  */
 class LocalClusterPsr6Cache extends BagOStuffPsrCache {
+
+   /**
+* @var BagOStuff
+*/
+   protected static $mainCache = null;
+
public function __construct() {
-   $mainCache = ObjectCache::getLocalClusterInstance();
-   parent::__construct( $mainCache );
+   if ( self::$mainCache === null ) {
+   self::$mainCache = 
ObjectCache::getLocalClusterInstance();
+   if ( self::$mainCache instanceof EmptyBagOStuff ) {
+   // FIXME: where does this go?
+   wfLogWarning(
+   'ObjectCache::getLocalClusterInstance() 
returned EmptyBagOStuff, using HashBagOStuff'
+   );
+   self::$mainCache = new HashBagOStuff();
+   }
+   }
+   parent::__construct( self::$mainCache );
}
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I570cdcc7347312bb246848b5d43d22ce1720d3f1
Gerrit-PatchSet: 5
Gerrit-Project: mediawiki/extensions/DonationInterface
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: AndyRussG 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
Gerrit-Reviewer: Eileen 
Gerrit-Reviewer: Ejegg 
Gerrit-Reviewer: Katie Horn 
Gerrit-Reviewer: Ssmith 
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] operations/puppet[production]: DHCP: Add DHCP entries for ms-be2028-msbe2039

2017-03-02 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340896 )

Change subject: DHCP: Add DHCP entries for ms-be2028-msbe2039
..


DHCP: Add DHCP entries for ms-be2028-msbe2039

Bug:T158337
Change-Id: Id0f848b00aed518256bf470df0354310a080a8f0
---
M modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
1 file changed, 60 insertions(+), 0 deletions(-)

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



diff --git a/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
index f9365bf..36baecd 100644
--- a/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -3656,6 +3656,66 @@
 fixed-address ms-be2027.codfw.wmnet;
 }
 
+host ms-be2028 {
+hardware ethernet e0:07:1b:ef:15:98;
+fixed-address ms-be2028.codfw.wmnet;
+}
+
+host ms-be2029 {
+hardware ethernet e0:07:1b:ef:55:40;
+fixed-address ms-be2029.codfw.wmnet;
+}
+
+host ms-be2030 {
+hardware ethernet e0:07:1b:ef:55:98;
+fixed-address ms-be2030.codfw.wmnet;
+}
+
+host ms-be2031 {
+hardware ethernet e0:07:1b:ef:b4:d8;
+fixed-address ms-be2031.codfw.wmnet;
+}
+
+host ms-be2032 {
+hardware ethernet e0:07:1b:ef:34:a0;
+fixed-address ms-be2032.codfw.wmnet;
+}
+
+host ms-be2033 {
+hardware ethernet e0:07:1b:ef:85:e0;
+fixed-address ms-be2033.codfw.wmnet;
+}
+
+host ms-be2034 {
+hardware ethernet e0:07:1b:ef:94:e0;
+fixed-address ms-be2034.codfw.wmnet;
+}
+
+host ms-be2035 {
+hardware ethernet e0:07:1b:ef:b4:d0;
+fixed-address ms-be2035.codfw.wmnet;
+}
+
+host ms-be2036 {
+hardware ethernet e0:07:1b:ef:54:e0;
+fixed-address ms-be2036.codfw.wmnet;
+}
+
+host ms-be2037 {
+hardware ethernet e0:07:1b:ef:b5:f8;
+fixed-address ms-be2037.codfw.wmnet;
+}
+
+host ms-be2038 {
+hardware ethernet e0:07:1b:ef:35:80;
+fixed-address ms-be2038.codfw.wmnet;
+}
+
+host ms-be2039 {
+hardware ethernet e0:07:1b:ef:26:70;
+fixed-address ms-be2039.codfw.wmnet;
+}
+
 host ms-be3001 {
 hardware ethernet 24:B6:FD:F6:13:AC;
 fixed-address ms-be3001.esams.wmnet;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id0f848b00aed518256bf470df0354310a080a8f0
Gerrit-PatchSet: 3
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Papaul 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Filippo Giunchedi 
Gerrit-Reviewer: Giuseppe Lavagetto 
Gerrit-Reviewer: RobH 
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]: mgmt: script to change mgmt password on HP servers

2017-03-02 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340567 )

Change subject: mgmt: script to change mgmt password on HP servers
..


mgmt: script to change mgmt password on HP servers

Change-Id: I5691f4c0242166813df3307914e292f3c6b0c223
---
A modules/mgmt/files/changepwhp
1 file changed, 45 insertions(+), 0 deletions(-)

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



diff --git a/modules/mgmt/files/changepwhp b/modules/mgmt/files/changepwhp
new file mode 100644
index 000..6f2e05f
--- /dev/null
+++ b/modules/mgmt/files/changepwhp
@@ -0,0 +1,45 @@
+#!/bin/bash
+# change the password of a ILO mgmt interface
+# (c) Papaul Tshibamba, Wikimedia Foundation Inc. 2016
+#sshpass needs to be installed on the host from where this script will run
+echo -n "Enter ILO root password (password will not be displayed):"
+read -s ILOPASS
+echo
+echo -n "Enter ILO root new password (password will not be displayed):"
+read -s ILO_NEW_PASS
+echo
+
+#Host ip list file location
+host_list=ip_list.txt
+
+#Logfile to keep the logs of the execution
+logfile=config.log
+ #get a list of IPs for the servers
+function getServers () {
+cat $host_list
+}
+
+#check if the file with the hosts IPs exist
+if [ ! -r $host_list ]; then
+echo "IP address file $host_list not found or cannot be read"
+exit
+#Make a log file. The logfile gets overwritten at each exection
+else echo "Starting Bash configuration of HP ILO for file 
$host_list" >$logfile
+
+fi
+for host_ip in $(getServers); do
+echo "" >> $logfile
+echo "Changing ILO password for  $host_ip " >>$logfile
+
+sshpass -p "$ILOPASS" ssh -o StrictHostKeyChecking=no -l root $host_ip 
set /map1/accounts1/root password="$ILO_NEW_PASS" | sed s/$ILO_NEW_PASS/X/g 
 >>$logfile 2>&1
+
+if [ $? -ne 0 ]; then
+echo "Failed. See logfile for details"
+else
+echo "ILO configured successfully on $host_ip"
+fi
+
+
+
+done <$host_list
+echo " complete"

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I5691f4c0242166813df3307914e292f3c6b0c223
Gerrit-PatchSet: 4
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Papaul 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Giuseppe Lavagetto 
Gerrit-Reviewer: RobH 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] integration/config[master]: Merge branch 'master' of https://gerrit.wikimedia.org/r/inte...

2017-03-02 Thread Harej (Code Review)
Harej has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340922 )

Change subject: Merge branch 'master' of 
https://gerrit.wikimedia.org/r/integration/config
..

Merge branch 'master' of https://gerrit.wikimedia.org/r/integration/config

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


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/22/340922/1


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

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

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


[MediaWiki-commits] [Gerrit] integration/config[master]: Adding Doxygen and JSDuck postmerge jobs for CollaborationKit

2017-03-02 Thread Harej (Code Review)
Harej has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340921 )

Change subject: Adding Doxygen and JSDuck postmerge jobs for CollaborationKit
..

Adding Doxygen and JSDuck postmerge jobs for CollaborationKit

Change-Id: I4f9230089053d7b39ace00840bd8a3792d0a62c1
---
M zuul/layout.yaml
1 file changed, 3 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/21/340921/1

diff --git a/zuul/layout.yaml b/zuul/layout.yaml
index c048171..e5db5f9 100644
--- a/zuul/layout.yaml
+++ b/zuul/layout.yaml
@@ -3037,6 +3037,9 @@
   - name: npm
 check:
   - jsonlint
+postmerge:
+  - mwext-doxygen-publish
+  - mwext-jsduck-publish
 
   - name: mediawiki/extensions/CollapsibleVector
 template:

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

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

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: mgmt: script to detect vendor by mgmt ssh banner

2017-03-02 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340450 )

Change subject: mgmt: script to detect vendor by mgmt ssh banner
..


mgmt: script to detect vendor by mgmt ssh banner

A script to connect to a mgmt IP and try to detect
the vendor of the device, currently Dell, HP, Juniper
or 'PDU' by looking at the SSHd banners.

This is to be used by other scripts, specifically
the one to change mgmt passwords that Papaul wrote.

So that they can be combined to detect the vendor
and then use the appropriate method to reset passwords.

Bug: T156673
Change-Id: Icd340fa0194a85853198afb4526adfcade3d6dc7
---
A modules/mgmt/files/detectvendor
1 file changed, 70 insertions(+), 0 deletions(-)

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



diff --git a/modules/mgmt/files/detectvendor b/modules/mgmt/files/detectvendor
new file mode 100755
index 000..d517f76
--- /dev/null
+++ b/modules/mgmt/files/detectvendor
@@ -0,0 +1,70 @@
+#!/bin/bash
+# Try to detect the vendor of a device
+# from the SSH banner of its mgmt interface.
+
+# Daniel Zahn - Wikimedia Foundation Inc.
+
+# input: IP address of a management interface
+# output: string "dell" or "hp" or "unknown"
+
+# example IP for each device class:
+
+# HP: 10.193.3.19
+# Dell:   10.193.2.253
+# Juniper 10.193.0.19
+# PDU:10.193.0.25
+
+
+# requirements:: netcat, tr, head
+
+if [ ! -f /bin/nc ]; then
+echo "I can't find netcat. Please make sure /bin/nc exists."
+exit 2
+fi
+
+if [ ! -f /usr/bin/tr ]; then
+echo "I can't find tr. Please make sure /usr/bin/tr exists."
+exit 2
+fi
+
+if [ ! -f /usr/bin/head ]; then
+echo "I can't find head. Please make sure /usr/bin/head exists."
+exit 2
+fi
+##
+
+mgmtip=$1
+mgmtport=22
+
+if [ -e $1 ]; then
+echo "usage: $0 "
+exit 1
+fi
+
+# send an empty echo on connect, take just the first line, filter out special 
chars
+banner=$(echo "" | /bin/nc $mgmtip $mgmtport | /usr/bin/head -n1 | /usr/bin/tr 
-dc '[:alnum:]-_.')
+
+# echo "The banner is: '${banner}'."
+
+case $banner in
+"SSH-2.0-mpSSH_0.2.1")
+vendor="HP"
+;;
+"SSH-2.0-OpenSSH_6.6")
+vendor="Dell"
+;;
+"SSH-2.0-OpenSSH_6.4")
+vendor="Juniper"
+;;
+"SSH-2.0-MocanaSSH")
+vendor="PDU"
+;;
+*)
+vendor="unknown"
+;;
+esac
+
+# echo "The vendor seems to be: '${vendor}'"
+
+echo $vendor
+

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Icd340fa0194a85853198afb4526adfcade3d6dc7
Gerrit-PatchSet: 3
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Dzahn 
Gerrit-Reviewer: Cmjohnson 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Giuseppe Lavagetto 
Gerrit-Reviewer: Papaul 
Gerrit-Reviewer: RobH 
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]: Gerrit: Fix bot so it reports the correct user merging the c...

2017-03-02 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340735 )

Change subject: Gerrit: Fix bot so it reports the correct user merging the 
change
..


Gerrit: Fix bot so it reports the correct user merging the change

Bug: T159441
Change-Id: If6c4796bb3b1ea53649bd76bf76f085a0681f36b
---
M modules/gerrit/files/etc/its/templates/PatchSetMerged.vm
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/modules/gerrit/files/etc/its/templates/PatchSetMerged.vm 
b/modules/gerrit/files/etc/its/templates/PatchSetMerged.vm
index 8d78c31..7d4da53 100644
--- a/modules/gerrit/files/etc/its/templates/PatchSetMerged.vm
+++ b/modules/gerrit/files/etc/its/templates/PatchSetMerged.vm
@@ -1,4 +1,4 @@
-Change $change-number merged by $uploader-name:
+Change $change-number merged by $submitter-name:
 [$project] $subject
 
 ${its.formatLink($change-url)}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If6c4796bb3b1ea53649bd76bf76f085a0681f36b
Gerrit-PatchSet: 5
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Paladox 
Gerrit-Reviewer: 20after4 
Gerrit-Reviewer: Bartosz Dziewoński 
Gerrit-Reviewer: Chad 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Giuseppe Lavagetto 
Gerrit-Reviewer: Hashar 
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]: Gerrit: Fix bot so that it checks against *-name and *-username

2017-03-02 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340801 )

Change subject: Gerrit: Fix bot so that it checks against *-name and *-username
..


Gerrit: Fix bot so that it checks against *-name and *-username

Bug: T76291
Change-Id: Iedc5a9a0cdf0341ba4cb4455aaf9cfca9fe1d34a
---
M modules/gerrit/files/etc/its/templates/PatchSetCreated.vm
1 file changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/modules/gerrit/files/etc/its/templates/PatchSetCreated.vm 
b/modules/gerrit/files/etc/its/templates/PatchSetCreated.vm
index 11ea80c..44c77c2 100644
--- a/modules/gerrit/files/etc/its/templates/PatchSetCreated.vm
+++ b/modules/gerrit/files/etc/its/templates/PatchSetCreated.vm
@@ -1,8 +1,8 @@
-#if ( $uploader-name != $author-name  )
-Change $change-number had a related patch set uploaded (by $uploader-name; 
owner: $author-name):
+#if ( $uploader-username != $author-username  )
+Change $change-number had a related patch set uploaded (by $uploader-username; 
owner: $author-username):
 [$project] $subject
 #else
-Change $change-number had a related patch set uploaded (by $uploader-name):
+Change $change-number had a related patch set uploaded (by $uploader-username):
 [$project] $subject
 #end
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iedc5a9a0cdf0341ba4cb4455aaf9cfca9fe1d34a
Gerrit-PatchSet: 5
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Paladox 
Gerrit-Reviewer: Chad 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Giuseppe Lavagetto 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki/core[wmf/1.29.0-wmf.14]: refreshLinks: Queue non-recursive updates

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

Change subject: refreshLinks: Queue non-recursive updates
..


refreshLinks: Queue non-recursive updates

This appears to have been an accidental change introduced in
48d0bedd7851.

Change-Id: I40a6bbead4b9966f130380fb91681a40395989a3
(cherry picked from commit 504d5582090258a217df33819f492a41c21ca766)
---
M maintenance/refreshLinks.php
1 file changed, 3 insertions(+), 1 deletion(-)

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



diff --git a/maintenance/refreshLinks.php b/maintenance/refreshLinks.php
index fb24a1d..06fcbaf 100644
--- a/maintenance/refreshLinks.php
+++ b/maintenance/refreshLinks.php
@@ -272,7 +272,9 @@
return;
}
 
-   foreach ( $content->getSecondaryDataUpdates( $page->getTitle() 
) as $update ) {
+   $updates = $content->getSecondaryDataUpdates(
+   $page->getTitle(), /* $old = */ null, /* $recursive = 
*/ false );
+   foreach ( $updates as $update ) {
DeferredUpdates::addUpdate( $update );
}
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I40a6bbead4b9966f130380fb91681a40395989a3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.29.0-wmf.14
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Parent5446 
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[wmf/1.29.0-wmf.14]: refreshLinks: Queue non-recursive updates

2017-03-02 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340920 )

Change subject: refreshLinks: Queue non-recursive updates
..

refreshLinks: Queue non-recursive updates

This appears to have been an accidental change introduced in
48d0bedd7851.

Change-Id: I40a6bbead4b9966f130380fb91681a40395989a3
(cherry picked from commit 504d5582090258a217df33819f492a41c21ca766)
---
M maintenance/refreshLinks.php
1 file changed, 3 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/20/340920/1

diff --git a/maintenance/refreshLinks.php b/maintenance/refreshLinks.php
index fb24a1d..06fcbaf 100644
--- a/maintenance/refreshLinks.php
+++ b/maintenance/refreshLinks.php
@@ -272,7 +272,9 @@
return;
}
 
-   foreach ( $content->getSecondaryDataUpdates( $page->getTitle() 
) as $update ) {
+   $updates = $content->getSecondaryDataUpdates(
+   $page->getTitle(), /* $old = */ null, /* $recursive = 
*/ false );
+   foreach ( $updates as $update ) {
DeferredUpdates::addUpdate( $update );
}
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I40a6bbead4b9966f130380fb91681a40395989a3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.29.0-wmf.14
Gerrit-Owner: Legoktm 

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


[MediaWiki-commits] [Gerrit] mediawiki...WikibaseMediaInfo[master]: Adjust MediaInfoViewTest for changes in Wikibase

2017-03-02 Thread Aude (Code Review)
Aude has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340919 )

Change subject: Adjust MediaInfoViewTest for changes in Wikibase
..

Adjust MediaInfoViewTest for changes in Wikibase

EntityTermsView now gets TermLists (labels and descriptions)
as arguments instead of LabelsProvider and DescriptionsProvider.

Bug: T159510
Change-Id: I056895a32e4aca4b4bf9ee1a2fd5c0e8853d1938
---
M tests/phpunit/mediawiki/View/MediaInfoViewTest.php
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikibaseMediaInfo 
refs/changes/19/340919/1

diff --git a/tests/phpunit/mediawiki/View/MediaInfoViewTest.php 
b/tests/phpunit/mediawiki/View/MediaInfoViewTest.php
index 09373a9..f71c08e 100644
--- a/tests/phpunit/mediawiki/View/MediaInfoViewTest.php
+++ b/tests/phpunit/mediawiki/View/MediaInfoViewTest.php
@@ -138,8 +138,8 @@
->method( 'getHtml' )
->with(
$contentLanguageCode,
-   $entity,
-   $entity,
+   $entity->getLabels(),
+   $entity->getDescriptions(),
null,
$entityId
)

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I056895a32e4aca4b4bf9ee1a2fd5c0e8853d1938
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikibaseMediaInfo
Gerrit-Branch: master
Gerrit-Owner: Aude 

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


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

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

Change subject: Merge master into deployment
..


Merge master into deployment

4a81bacf581a7b3a1d71505290461986ee510231 Use an intermediate temporary table so 
we don't step on a trigger landmine

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

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




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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic36c6e839b949fb8a20bd76b141ed98a6f9764ce
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: deployment
Gerrit-Owner: Awight 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: jenkins-bot <>

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


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

2017-03-02 Thread Awight (Code Review)
Awight has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340918 )

Change subject: Merge master into deployment
..

Merge master into deployment

4a81bacf581a7b3a1d71505290461986ee510231 Use an intermediate temporary table so 
we don't step on a trigger landmine

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


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/18/340918/1


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

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

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: Use an intermediate temporary table so we don't step on a tr...

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

Change subject: Use an intermediate temporary table so we don't step on a 
trigger landmine
..


Use an intermediate temporary table so we don't step on a trigger landmine

Bug: T159455
Change-Id: I36d0e0680392f198dba901cdbf0b8cd63bad883d
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 40 insertions(+), 12 deletions(-)

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 35dbd7a..92408b4 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2590,16 +2590,44 @@
 ");
// Some of the contacts have been touched since creation, and Civi has 
helpfully
// destroyed the sort_name. log_civicrm_contact to the rescue!
-   CRM_Core_DAO::executeQuery(
-   "UPDATE civicrm_contact c
-   INNER JOIN log_civicrm_contact l ON c.id = l.id
-   SET c.last_name = SUBSTRING_INDEX(l.sort_name, ', ', 1),
-   c.first_name = SUBSTRING_INDEX(l.sort_name, ', ', -1)
-   WHERE c.created_date BETWEEN '2017-02-28' AND '2017-03-03'
-   AND c.contact_type = 'Individual'
-   AND c.first_name IS NULL
-   AND c.last_name IS NULL
-   AND c.sort_name NOT LIKE '%, %'
-   AND l.sort_name LIKE '%, %'
-");
+   CRM_Core_DAO::executeQuery("
+create temporary table tmp_T159455
+select
+id,
+   -- Include null columns as placeholders.
+   first_name,
+   last_name
+from civicrm_contact
+where
+created_date between '2017-02-28' and '2017-03-03'
+and contact_type = 'Individual'
+and first_name is null
+and last_name is null
+   ");
+
+   CRM_Core_DAO::executeQuery("
+update tmp_T159455 t
+inner join log_civicrm_contact l
+on t.id = l.id
+set
+t.last_name = substring_index(l.sort_name, ', ', 1),
+t.first_name = substring_index(l.sort_name, ', ', -1)
+where
+l.sort_name like '%, %'
+   ");
+
+   // Set the names using the API in order to refresh calculations.
+   $query = "
+   select * from tmp_T159455
+   where first_name is not null
+   and last_name is not null
+   ";
+   $dao = CRM_Core_DAO::executeQuery($query);
+   while ($dao->fetch()) {
+   civicrm_api3('Contact', 'create', array(
+   'id' => $dao->id,
+   'first_name' => $dao->first_name,
+   'last_name' => $dao->last_name,
+   ));
+   }
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I36d0e0680392f198dba901cdbf0b8cd63bad883d
Gerrit-PatchSet: 6
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Awight 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
Gerrit-Reviewer: Eileen 
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] wikimedia...civicrm[master]: [WIP] Random fix to deprecated Civi code

2017-03-02 Thread Awight (Code Review)
Awight has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340917 )

Change subject: [WIP] Random fix to deprecated Civi code
..

[WIP] Random fix to deprecated Civi code

Backport and see if it's still needed on master.

Change-Id: Ia42af26e0b124bfea7110e7c4769fef45eee188f
---
M CRM/Utils/Mail/EmailProcessor.php
1 file changed, 2 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm/civicrm 
refs/changes/17/340917/1

diff --git a/CRM/Utils/Mail/EmailProcessor.php 
b/CRM/Utils/Mail/EmailProcessor.php
index 1224a4b..29ebc9e 100644
--- a/CRM/Utils/Mail/EmailProcessor.php
+++ b/CRM/Utils/Mail/EmailProcessor.php
@@ -252,14 +252,8 @@
 
   $result = civicrm_api3('activity', 'create', $params);
 
-  if ($result['is_error']) {
-$matches = FALSE;
-echo "Failed Processing: {$mail->subject}. Reason: 
{$result['error_message']}\n";
-  }
-  else {
-$matches = TRUE;
-echo "Processed as Activity: {$mail->subject}\n";
-  }
+ // FIXME: Use a log infrastructure?
+  echo "Processed as Activity: {$mail->subject}\n";
 
   CRM_Utils_Hook::emailProcessor('activity', $params, $mail, $result);
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia42af26e0b124bfea7110e7c4769fef45eee188f
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm/civicrm
Gerrit-Branch: master
Gerrit-Owner: Awight 

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


[MediaWiki-commits] [Gerrit] mediawiki...SiteMatrix[master]: Make SiteMatrix fit coding standards (part 2)

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

Change subject: Make SiteMatrix fit coding standards (part 2)
..


Make SiteMatrix fit coding standards (part 2)

SiteMatrix files still use long array form and have lines longer than
100 characters. This commit makes SiteMatrix use short array syntax and
shorter lines.
For easier review this changes have been splitted to only touch one
file per patch.

Bug: T150423
Change-Id: Ia3fcd74cd332288d7534c723a7a2df34075d1b98
---
M SiteMatrixApi.php
1 file changed, 32 insertions(+), 35 deletions(-)

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



diff --git a/SiteMatrixApi.php b/SiteMatrixApi.php
index d0c4141..d8ed9ef 100644
--- a/SiteMatrixApi.php
+++ b/SiteMatrixApi.php
@@ -29,7 +29,7 @@
$limit = $params['limit'];
$continue = isset( $params['continue'] )
? explode( '|', $params['continue'] )
-   : array( 'language', '' );
+   : [ 'language', '' ];
$this->dieContinueUsageIf( count( $continue ) != 2 );
 
$all = isset( $state['all'] );
@@ -49,11 +49,11 @@
$this->setContinueEnumParameter( 
'continue', "language|$langhost" );
break;
}
-   $language = array(
+   $language = [
'code' => $langhost,
'name' => isset( $langNames[$lang] ) ? 
$langNames[$lang] : null,
-   'site' => array(),
-   );
+   'site' => [],
+   ];
if ( isset( $localLanguageNames[$lang] ) ) {
$language['localname'] = 
$localLanguageNames[$lang];
}
@@ -69,12 +69,12 @@
}
 
$url = 
$matrix->getCanonicalUrl( $lang, $site );
-   $site_out = array(
+   $site_out = [
'url' => $url,
'dbname' => 
$matrix->getDBName( $lang, $site ),
'code' => $site,
'sitename' => 
$matrix->getSitename( $lang, $site ),
-   );
+   ];
$site_out = 
array_intersect_key( $site_out, $siteProp );
if ( $matrix->isClosed( 
$lang, $site ) ) {

$site_out['closed'] = '';
@@ -101,7 +101,7 @@
$result->addValue( null, "sitematrix", $matrix_out );
 
if ( isset( $type['special'] ) && $count < $limit ) {
-   $specials = array();
+   $specials = [];
foreach ( $matrix->getSpecials() as $special ) {
list( $lang, $site ) = $special;
$dbName = $matrix->getDBName( $lang, $site );
@@ -114,7 +114,7 @@
}
$url = $matrix->getCanonicalUrl( $lang, $site );
 
-   $wiki = array();
+   $wiki = [];
$wiki['url'] = $url;
$wiki['dbname'] = $dbName;
$wiki['code'] = str_replace( '_', '-', $lang ) 
. ( $site != 'wiki' ? $site : '' );
@@ -168,72 +168,69 @@
 
protected function setContinueEnumParameter( $paramName, $paramValue ) {
$paramName = $this->encodeParamName( $paramName );
-   $msg = array( $paramName => $paramValue );
+   $msg = [ $paramName => $paramValue ];
$result = $this->getResult();
$result->addValue( 'query-continue', $this->getModuleName(), 
$msg, ApiResult::NO_SIZE_CHECK );
}
 
public function getAllowedParams() {
-   return array(
-   'type' => array(
+   return [
+   'type' => [
ApiBase::PARAM_ISMULTI => true,
-   ApiBase::PARAM_TYPE => array(
+   

[MediaWiki-commits] [Gerrit] VisualEditor/VisualEditor[master]: ve.ce.Surface: Prevent horizontal scrollbars when hovering F...

2017-03-02 Thread Catrope (Code Review)
Catrope has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340916 )

Change subject: ve.ce.Surface: Prevent horizontal scrollbars when hovering 
FocusableNodes in RTL
..

ve.ce.Surface: Prevent horizontal scrollbars when hovering FocusableNodes in RTL

.ve-ce-focusableNode-highlight-selectable was making the document 3px wider,
because it contained an nbsp and was positioned in the top left corner.
This was because we neglected to put both left:0 and right:0 on
the .ve-ce-surface-highlights container. However, that container
doesn't need any positioning rules at all (because it's inside
localOverlay which is already absolutely positioned), so just remove them.

Change-Id: Ib23c56bbd072979fdebb80a6aa09df394e7ab06b
---
M src/ce/styles/ve.ce.Surface.css
1 file changed, 0 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/16/340916/1

diff --git a/src/ce/styles/ve.ce.Surface.css b/src/ce/styles/ve.ce.Surface.css
index 5f45b67..eb078e2 100644
--- a/src/ce/styles/ve.ce.Surface.css
+++ b/src/ce/styles/ve.ce.Surface.css
@@ -41,13 +41,6 @@
opacity: 0.5;
 }
 
-/* @noflip */
-.ve-ce-surface-highlights {
-   position: absolute;
-   top: 0;
-   left: 0;
-}
-
 .ve-ce-surface-dropMarker {
height: 1px;
background: #999;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib23c56bbd072979fdebb80a6aa09df394e7ab06b
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Catrope 

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


[MediaWiki-commits] [Gerrit] mediawiki...SiteMatrix[master]: Make SiteMatrix fit coding standards (part 2)

2017-03-02 Thread EddieGP (Code Review)
EddieGP has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340915 )

Change subject: Make SiteMatrix fit coding standards (part 2)
..

Make SiteMatrix fit coding standards (part 2)

SiteMatrix files still use long array form and have lines longer than
100 characters. This makes SiteMatrix use short array syntax and
shorter lines.
For easier review this changes have been splitted to only touch one
file per patch.

Bug: T150423
Change-Id: Ia3fcd74cd332288d7534c723a7a2df34075d1b98
---
M SiteMatrixApi.php
1 file changed, 32 insertions(+), 35 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/SiteMatrix 
refs/changes/15/340915/1

diff --git a/SiteMatrixApi.php b/SiteMatrixApi.php
index d0c4141..d8ed9ef 100644
--- a/SiteMatrixApi.php
+++ b/SiteMatrixApi.php
@@ -29,7 +29,7 @@
$limit = $params['limit'];
$continue = isset( $params['continue'] )
? explode( '|', $params['continue'] )
-   : array( 'language', '' );
+   : [ 'language', '' ];
$this->dieContinueUsageIf( count( $continue ) != 2 );
 
$all = isset( $state['all'] );
@@ -49,11 +49,11 @@
$this->setContinueEnumParameter( 
'continue', "language|$langhost" );
break;
}
-   $language = array(
+   $language = [
'code' => $langhost,
'name' => isset( $langNames[$lang] ) ? 
$langNames[$lang] : null,
-   'site' => array(),
-   );
+   'site' => [],
+   ];
if ( isset( $localLanguageNames[$lang] ) ) {
$language['localname'] = 
$localLanguageNames[$lang];
}
@@ -69,12 +69,12 @@
}
 
$url = 
$matrix->getCanonicalUrl( $lang, $site );
-   $site_out = array(
+   $site_out = [
'url' => $url,
'dbname' => 
$matrix->getDBName( $lang, $site ),
'code' => $site,
'sitename' => 
$matrix->getSitename( $lang, $site ),
-   );
+   ];
$site_out = 
array_intersect_key( $site_out, $siteProp );
if ( $matrix->isClosed( 
$lang, $site ) ) {

$site_out['closed'] = '';
@@ -101,7 +101,7 @@
$result->addValue( null, "sitematrix", $matrix_out );
 
if ( isset( $type['special'] ) && $count < $limit ) {
-   $specials = array();
+   $specials = [];
foreach ( $matrix->getSpecials() as $special ) {
list( $lang, $site ) = $special;
$dbName = $matrix->getDBName( $lang, $site );
@@ -114,7 +114,7 @@
}
$url = $matrix->getCanonicalUrl( $lang, $site );
 
-   $wiki = array();
+   $wiki = [];
$wiki['url'] = $url;
$wiki['dbname'] = $dbName;
$wiki['code'] = str_replace( '_', '-', $lang ) 
. ( $site != 'wiki' ? $site : '' );
@@ -168,72 +168,69 @@
 
protected function setContinueEnumParameter( $paramName, $paramValue ) {
$paramName = $this->encodeParamName( $paramName );
-   $msg = array( $paramName => $paramValue );
+   $msg = [ $paramName => $paramValue ];
$result = $this->getResult();
$result->addValue( 'query-continue', $this->getModuleName(), 
$msg, ApiResult::NO_SIZE_CHECK );
}
 
public function getAllowedParams() {
-   return array(
-   'type' => array(
+   return [
+   'type' => [
ApiBase::PARAM_ISMULTI => true,
-   ApiBase::PARAM_TYPE => array(
+   

[MediaWiki-commits] [Gerrit] mediawiki...PerformanceInspector[master]: Remove summary introduction

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

Change subject: Remove summary introduction
..


Remove summary introduction

We had a introduction message text key for the inspector without any
text. Remove the key for now and think about a good text and add that
later.

Change-Id: I3d2900ab32b069193fa287d1bce0307c01959711
---
M modules/templates/summary.mustache
1 file changed, 0 insertions(+), 3 deletions(-)

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



diff --git a/modules/templates/summary.mustache 
b/modules/templates/summary.mustache
index 3013d2b..f862ec9 100644
--- a/modules/templates/summary.mustache
+++ b/modules/templates/summary.mustache
@@ -1,8 +1,5 @@
 {{#msg}}performanceinspector-dialog-summary{{/msg}}

-   {{#msg}}performanceinspector-summary-introduction{{/msg}}
-   
-   
{{#msg}}performanceinspector-modules-summary-total-size{{/msg}} 
{{modulesSummarySize}}.

{{#imagesSummary}}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3d2900ab32b069193fa287d1bce0307c01959711
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/PerformanceInspector
Gerrit-Branch: master
Gerrit-Owner: Phedenskog 
Gerrit-Reviewer: Krinkle 
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...TheWikipediaLibrary[master]: Clean up SVG file

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

Change subject: Clean up SVG file
..


Clean up SVG file

svgo --pretty --disable=removeXMLProcInst twl-eligible.svg

Change-Id: Idfb4a9a263af32950f7ca0c74be6fdab8faf09eb
---
M modules/icons/twl-eligible.svg
1 file changed, 2 insertions(+), 10 deletions(-)

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



diff --git a/modules/icons/twl-eligible.svg b/modules/icons/twl-eligible.svg
index cd0f6e5..e4a3f98 100644
--- a/modules/icons/twl-eligible.svg
+++ b/modules/icons/twl-eligible.svg
@@ -1,12 +1,4 @@
 
-http://www.w3.org/2000/svg; xmlns:xlink="http://www.w3.org/1999/xlink;>
-
-book-green
-Created with Sketch.
-
-
-
-
-
-
+http://www.w3.org/2000/svg;>
+
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Idfb4a9a263af32950f7ca0c74be6fdab8faf09eb
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/TheWikipediaLibrary
Gerrit-Branch: master
Gerrit-Owner: Catrope 
Gerrit-Reviewer: Kmuthu 
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]: Use an intermediate temporary table so we don't step on a tr...

2017-03-02 Thread Awight (Code Review)
Awight has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340914 )

Change subject: Use an intermediate temporary table so we don't step on a 
trigger landmine
..

Use an intermediate temporary table so we don't step on a trigger landmine

Bug: T159455
Change-Id: I36d0e0680392f198dba901cdbf0b8cd63bad883d
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 26 insertions(+), 11 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/14/340914/1

diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 35dbd7a..27a5aa3 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2591,15 +2591,30 @@
// Some of the contacts have been touched since creation, and Civi has 
helpfully
// destroyed the sort_name. log_civicrm_contact to the rescue!
CRM_Core_DAO::executeQuery(
-   "UPDATE civicrm_contact c
-   INNER JOIN log_civicrm_contact l ON c.id = l.id
-   SET c.last_name = SUBSTRING_INDEX(l.sort_name, ', ', 1),
-   c.first_name = SUBSTRING_INDEX(l.sort_name, ', ', -1)
-   WHERE c.created_date BETWEEN '2017-02-28' AND '2017-03-03'
-   AND c.contact_type = 'Individual'
-   AND c.first_name IS NULL
-   AND c.last_name IS NULL
-   AND c.sort_name NOT LIKE '%, %'
-   AND l.sort_name LIKE '%, %'
-");
+   "
+create temporary table tmp_T159455
+select
+c.id,
+substring_index(l.sort_name, ', ', 1) as last_name,
+substring_index(l.sort_name, ', ', -1) as first_name
+from civicrm_contact c
+inner join log_civicrm_contact l on c.id = l.id
+where
+c.created_date between '2017-02-28' and '2017-03-03'
+and c.contact_type = 'Individual'
+and c.first_name is null
+and c.last_name is null
+and c.sort_name not like '%, %'
+and l.sort_name like '%, %'
+
+update civicrm_contact c
+inner join tmp_T159455 as t
+on c.id = t.id
+set
+c.first_name = t.first_name,
+c.last_name = t.last_name
+where
+c.first_name is null
+and c.last_name is null
+   ");
 }

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

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

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[deployment]: Just zap the comment

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

Change subject: Just zap the comment
..


Just zap the comment

Still getting an unknown DB error on prod. :(

Flail...

Change-Id: I81f081df47efe0e55a504155e5495ddd7aa136f9
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 6ac66c2..35dbd7a 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2586,7 +2586,7 @@
AND contact_type = 'Individual'
AND first_name IS NULL
AND last_name IS NULL
-   AND sort_name LIKE '%, %' /* leading % seems to be OK after all 
the other conditions */
+   AND sort_name LIKE '%, %'
 ");
// Some of the contacts have been touched since creation, and Civi has 
helpfully
// destroyed the sort_name. log_civicrm_contact to the rescue!

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I81f081df47efe0e55a504155e5495ddd7aa136f9
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: deployment
Gerrit-Owner: Awight 
Gerrit-Reviewer: Awight 
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] wikimedia...crm[deployment]: Just zap the comment

2017-03-02 Thread Awight (Code Review)
Awight has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340913 )

Change subject: Just zap the comment
..

Just zap the comment

Still getting an unknown DB error on prod. :(

Flail...

Change-Id: I81f081df47efe0e55a504155e5495ddd7aa136f9
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/13/340913/1

diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 6ac66c2..35dbd7a 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2586,7 +2586,7 @@
AND contact_type = 'Individual'
AND first_name IS NULL
AND last_name IS NULL
-   AND sort_name LIKE '%, %' /* leading % seems to be OK after all 
the other conditions */
+   AND sort_name LIKE '%, %'
 ");
// Some of the contacts have been touched since creation, and Civi has 
helpfully
// destroyed the sort_name. log_civicrm_contact to the rescue!

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

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

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: Just zap the comment

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

Change subject: Just zap the comment
..


Just zap the comment

Still getting an unknown DB error on prod. :(

Flail...

Change-Id: I81f081df47efe0e55a504155e5495ddd7aa136f9
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 6ac66c2..35dbd7a 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2586,7 +2586,7 @@
AND contact_type = 'Individual'
AND first_name IS NULL
AND last_name IS NULL
-   AND sort_name LIKE '%, %' /* leading % seems to be OK after all 
the other conditions */
+   AND sort_name LIKE '%, %'
 ");
// Some of the contacts have been touched since creation, and Civi has 
helpfully
// destroyed the sort_name. log_civicrm_contact to the rescue!

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I81f081df47efe0e55a504155e5495ddd7aa136f9
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
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]: Just zap the comment

2017-03-02 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340912 )

Change subject: Just zap the comment
..

Just zap the comment

Still getting an unknown DB error on prod. :(

Flail...

Change-Id: I81f081df47efe0e55a504155e5495ddd7aa136f9
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/12/340912/1

diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 6ac66c2..35dbd7a 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2586,7 +2586,7 @@
AND contact_type = 'Individual'
AND first_name IS NULL
AND last_name IS NULL
-   AND sort_name LIKE '%, %' /* leading % seems to be OK after all 
the other conditions */
+   AND sort_name LIKE '%, %'
 ");
// Some of the contacts have been touched since creation, and Civi has 
helpfully
// destroyed the sort_name. log_civicrm_contact to the rescue!

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I81f081df47efe0e55a504155e5495ddd7aa136f9
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
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] mediawiki/core[master]: [WIP] Apply image styling mw:Video as well

2017-03-02 Thread Arlolra (Code Review)
Arlolra has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340911 )

Change subject: [WIP] Apply image styling mw:Video as well
..

[WIP] Apply image styling mw:Video as well

 * Q: Should we rename mw-image-border to mw-media-border?

Change-Id: Icb26ffb802150c1d1f8c6e0aab05b25e503077e2
---
M resources/src/mediawiki.skinning/content.parsoid.less
1 file changed, 11 insertions(+), 3 deletions(-)


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

diff --git a/resources/src/mediawiki.skinning/content.parsoid.less 
b/resources/src/mediawiki.skinning/content.parsoid.less
index b3d1613..9ce6626 100644
--- a/resources/src/mediawiki.skinning/content.parsoid.less
+++ b/resources/src/mediawiki.skinning/content.parsoid.less
@@ -46,7 +46,8 @@
 /**
  * Block media items
  */
-figure[typeof*='mw:Image'] {
+figure[typeof*='mw:Image'],
+figure[typeof*='mw:Video'] {
margin: 0;
 
a {
@@ -109,7 +110,9 @@
 }
 
 figure[typeof~='mw:Image/Thumb'],
-figure[typeof~='mw:Image/Frame'] {
+figure[typeof~='mw:Image/Frame'],
+figure[typeof~='mw:Video/Thumb'],
+figure[typeof~='mw:Video/Frame'] {
display: table;
overflow: auto;
text-align: center;
@@ -126,7 +129,10 @@
 
 figure[typeof~='mw:Image/Thumb'] > *:first-child > img,
 figure[typeof~='mw:Image/Frame'] > *:first-child > img,
-.mw-image-border > *:first-child > img {
+figure[typeof~='mw:Video/Thumb'] > *:first-child > video,
+figure[typeof~='mw:Video/Frame'] > *:first-child > video,
+.mw-image-border > *:first-child > img,
+.mw-image-border > *:first-child > video {
border: 1px solid #ccc;
margin: 3px;
background: #fff;
@@ -134,6 +140,8 @@
 
 /* Hide the caption for frameless and plain floated images */
 figure[typeof~='mw:Image/Frameless'] > figcaption,
+figure[typeof~='mw:Video/Frameless'] > figcaption,
 figure[typeof~='mw:Image'] > figcaption {
+figure[typeof~='mw:Video'] > figcaption {
display: none;
 }

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

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

___
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-03-02 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340910 )

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


Merge branch 'master' into deployment

4cf6fcf Fix busted SQL comment

Change-Id: Ib6105da4909bb54c7aefdeb279494af22bd47ff7
---
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/340910
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib6105da4909bb54c7aefdeb279494af22bd47ff7
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] wikimedia...crm[deployment]: Merge branch 'master' into deployment

2017-03-02 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340910 )

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

Merge branch 'master' into deployment

4cf6fcf Fix busted SQL comment

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


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/10/340910/1


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib6105da4909bb54c7aefdeb279494af22bd47ff7
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] wikimedia...crm[master]: Fix busted SQL comment

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

Change subject: Fix busted SQL comment
..


Fix busted SQL comment

-- needs to be at the start of the line, oops!

Change-Id: I7e835c49613821c702210066abfd449109bef2ce
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index fc54cd9..6ac66c2 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2586,7 +2586,7 @@
AND contact_type = 'Individual'
AND first_name IS NULL
AND last_name IS NULL
-   AND sort_name LIKE '%, %' --leading % seems to be OK after all 
the other conditions
+   AND sort_name LIKE '%, %' /* leading % seems to be OK after all 
the other conditions */
 ");
// Some of the contacts have been touched since creation, and Civi has 
helpfully
// destroyed the sort_name. log_civicrm_contact to the rescue!

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7e835c49613821c702210066abfd449109bef2ce
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
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]: Move ResultWrapper subclasses to Rdbms

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

Change subject: Move ResultWrapper subclasses to Rdbms
..


Move ResultWrapper subclasses to Rdbms

Change-Id: I6f3f0e85e268b24c57c537aa6ad8016e0b4cdddb
---
M autoload.php
M includes/Revision.php
M includes/RevisionList.php
M includes/TitleArray.php
M includes/TitleArrayFromResult.php
M includes/WatchedItemQueryServiceExtension.php
M includes/actions/HistoryAction.php
M includes/api/ApiPageSet.php
M includes/api/ApiQueryBase.php
M includes/cache/BacklinkCache.php
M includes/cache/LinkBatch.php
M includes/changes/ChangesFeed.php
M includes/changes/ChangesList.php
M includes/db/DatabaseOracle.php
M includes/export/WikiExporter.php
M includes/filerepo/LocalRepo.php
M includes/libs/rdbms/database/Database.php
M includes/libs/rdbms/database/DatabaseMssql.php
M includes/libs/rdbms/database/DatabaseMysqlBase.php
M includes/libs/rdbms/database/DatabaseMysqli.php
M includes/libs/rdbms/database/DatabasePostgres.php
M includes/libs/rdbms/database/DatabaseSqlite.php
M includes/libs/rdbms/database/IDatabase.php
M includes/libs/rdbms/database/resultwrapper/FakeResultWrapper.php
M includes/libs/rdbms/database/resultwrapper/MssqlResultWrapper.php
M includes/libs/rdbms/database/resultwrapper/ResultWrapper.php
M includes/page/ImagePage.php
M includes/page/WikiFilePage.php
M includes/page/WikiPage.php
M includes/pager/IndexPager.php
M includes/revisiondelete/RevDelRevisionList.php
M includes/search/SqlSearchResultSet.php
M includes/specialpage/ChangesListSpecialPage.php
M includes/specialpage/ImageQueryPage.php
M includes/specialpage/PageQueryPage.php
M includes/specialpage/QueryPage.php
M includes/specialpage/WantedQueryPage.php
M includes/specials/SpecialBrokenRedirects.php
M includes/specials/SpecialDoubleRedirects.php
M includes/specials/SpecialLinkSearch.php
M includes/specials/SpecialListDuplicatedFiles.php
M includes/specials/SpecialListredirects.php
M includes/specials/SpecialMediaStatistics.php
M includes/specials/SpecialMostcategories.php
M includes/specials/SpecialMostinterwikis.php
M includes/specials/SpecialMostlinked.php
M includes/specials/SpecialMostlinkedcategories.php
M includes/specials/SpecialMostlinkedtemplates.php
M includes/specials/SpecialRecentchanges.php
M includes/specials/SpecialShortpages.php
M includes/specials/SpecialUndelete.php
M includes/specials/SpecialUnwatchedpages.php
M includes/specials/SpecialWatchlist.php
M includes/specials/pagers/AllMessagesTablePager.php
M includes/specials/pagers/BlockListPager.php
M includes/specials/pagers/ContribsPager.php
M includes/specials/pagers/DeletedContribsPager.php
M includes/specials/pagers/ImageListPager.php
M includes/user/UserArray.php
M includes/user/UserArrayFromResult.php
M maintenance/convertUserOptions.php
M maintenance/namespaceDupes.php
M maintenance/purgeChangedPages.php
M maintenance/sql.php
64 files changed, 141 insertions(+), 14 deletions(-)

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



diff --git a/autoload.php b/autoload.php
index ad44273..62500e4 100644
--- a/autoload.php
+++ b/autoload.php
@@ -973,7 +973,6 @@
'MovePage' => __DIR__ . '/includes/MovePage.php',
'MovePageForm' => __DIR__ . '/includes/specials/SpecialMovepage.php',
'MssqlInstaller' => __DIR__ . '/includes/installer/MssqlInstaller.php',
-   'MssqlResultWrapper' => __DIR__ . 
'/includes/libs/rdbms/database/resultwrapper/MssqlResultWrapper.php',
'MssqlUpdater' => __DIR__ . '/includes/installer/MssqlUpdater.php',
'MultiConfig' => __DIR__ . '/includes/config/MultiConfig.php',
'MultiHttpClient' => __DIR__ . '/includes/libs/MultiHttpClient.php',
@@ -1582,6 +1581,7 @@
'Wikimedia\\Rdbms\\ConnectionManager' => __DIR__ . 
'/includes/libs/rdbms/connectionmanager/ConnectionManager.php',
'Wikimedia\\Rdbms\\DBMasterPos' => __DIR__ . 
'/includes/libs/rdbms/database/position/DBMasterPos.php',
'Wikimedia\\Rdbms\\DatabaseDomain' => __DIR__ . 
'/includes/libs/rdbms/database/DatabaseDomain.php',
+   'Wikimedia\\Rdbms\\FakeResultWrapper' => __DIR__ . 
'/includes/libs/rdbms/database/resultwrapper/FakeResultWrapper.php',
'Wikimedia\\Rdbms\\Field' => __DIR__ . 
'/includes/libs/rdbms/field/Field.php',
'Wikimedia\\Rdbms\\IBlob' => __DIR__ . 
'/includes/libs/rdbms/encasing/IBlob.php',
'Wikimedia\\Rdbms\\ILBFactory' => __DIR__ . 
'/includes/libs/rdbms/lbfactory/ILBFactory.php',
@@ -1600,10 +1600,12 @@
'Wikimedia\\Rdbms\\LoadMonitorNull' => __DIR__ . 
'/includes/libs/rdbms/loadmonitor/LoadMonitorNull.php',
'Wikimedia\\Rdbms\\MssqlBlob' => __DIR__ . 
'/includes/libs/rdbms/encasing/MssqlBlob.php',
'Wikimedia\\Rdbms\\MssqlField' => __DIR__ . 
'/includes/libs/rdbms/field/MssqlField.php',
+   'Wikimedia\\Rdbms\\MssqlResultWrapper' => __DIR__ . 

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: RCFilters UI: Adopt conflict colors

2017-03-02 Thread Mooeypoo (Code Review)
Mooeypoo has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340909 )

Change subject: RCFilters UI: Adopt conflict colors
..

RCFilters UI: Adopt conflict colors

Bug: T156427
Bug: T156861
Change-Id: I8765dfb0554e6351b9cb3516a2bc979c57b20053
---
M 
resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.CapsuleItemWidget.less
M resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.CapsuleItemWidget.js
2 files changed, 34 insertions(+), 15 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/09/340909/1

diff --git 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.CapsuleItemWidget.less
 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.CapsuleItemWidget.less
index c70da38..88357ef 100644
--- 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.CapsuleItemWidget.less
+++ 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.CapsuleItemWidget.less
@@ -5,23 +5,39 @@
border-color: #979797;
color: #222;
 
-   &-muted {
-   // Muted state
-   background-color: #eaecf0;
-   border-color: #c8ccd1;
-   .oo-ui-labelElement-label {
-   color: #72777d;
+   // Background and color of the capsule widget need a bit
+   // more specificity to override ooui internals
+   // &.oo-ui-capsuleItemWidget.oo-ui-widget-enabled {
+   &-muted.oo-ui-capsuleItemWidget.oo-ui-widget-enabled {
+   // Muted state
+   background-color: #eaecf0;
+   border-color: #c8ccd1;
+
+   .oo-ui-labelElement-label {
+   color: #72777d;
+   }
+   .oo-ui-buttonWidget {
+   opacity: @muted-opacity;
+   }
}
 
-   .oo-ui-buttonWidget {
-   opacity: @muted-opacity;
-   }
-   }
+   &-conflicted.oo-ui-capsuleItemWidget.oo-ui-widget-enabled {
+   background-color: #fee7e6; // Red90 AAA
+   border-color: #b32424; // Red30 AAA
 
-   &-selected {
-   background-color: #eaf3ff;
-   border-color: #36c;
-   }
+   .oo-ui-labelElement-label {
+   color: #b32424;
+   }
+   .oo-ui-buttonWidget {
+   opacity: @muted-opacity;
+   }
+   }
+
+   &-selected.oo-ui-capsuleItemWidget.oo-ui-widget-enabled {
+   background-color: #eaf3ff;
+   border-color: #36c;
+   }
+   // }
 
&-popup-content {
padding: 0.5em;
diff --git 
a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.CapsuleItemWidget.js 
b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.CapsuleItemWidget.js
index 800e7ea..a7ad954 100644
--- a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.CapsuleItemWidget.js
+++ b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.CapsuleItemWidget.js
@@ -135,8 +135,11 @@
'mw-rcfilters-ui-capsuleItemWidget-muted',
!this.model.isSelected() ||
this.model.isIncluded() ||
-   this.model.isConflicted() ||
this.model.isFullyCovered()
+   )
+   .toggleClass(
+   'mw-rcfilters-ui-capsuleItemWidget-conflicted',
+   this.model.isConflicted()
);
};
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8765dfb0554e6351b9cb3516a2bc979c57b20053
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[wmf/1.29.0-wmf.14]: resourceloader: Add purgeModuleDeps.php maintenance script

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

Change subject: resourceloader: Add purgeModuleDeps.php maintenance script
..


resourceloader: Add purgeModuleDeps.php maintenance script

Based on cleanupRemovedModules.php. Update both to use safer batching,
based on known selection instead of recursing until the table is empty
(which may end up deleting new rows from live traffic).

Bug: T158105
Change-Id: I05f650a0cfa8ca647f143a40e1087338adbef6da
---
M autoload.php
M maintenance/cleanupRemovedModules.php
A maintenance/purgeModuleDeps.php
3 files changed, 98 insertions(+), 13 deletions(-)

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



diff --git a/autoload.php b/autoload.php
index aa4e544..61a9caf 100644
--- a/autoload.php
+++ b/autoload.php
@@ -1129,6 +1129,7 @@
'PurgeChangedPages' => __DIR__ . '/maintenance/purgeChangedPages.php',
'PurgeJobUtils' => __DIR__ . 
'/includes/jobqueue/utils/PurgeJobUtils.php',
'PurgeList' => __DIR__ . '/maintenance/purgeList.php',
+   'PurgeModuleDeps' => __DIR__ . '/maintenance/purgeModuleDeps.php',
'PurgeOldText' => __DIR__ . '/maintenance/purgeOldText.php',
'PurgeParserCache' => __DIR__ . '/maintenance/purgeParserCache.php',
'QueryPage' => __DIR__ . '/includes/specialpage/QueryPage.php',
diff --git a/maintenance/cleanupRemovedModules.php 
b/maintenance/cleanupRemovedModules.php
index 863d74a..83ab35c 100644
--- a/maintenance/cleanupRemovedModules.php
+++ b/maintenance/cleanupRemovedModules.php
@@ -38,31 +38,43 @@
parent::__construct();
$this->addDescription(
'Remove cache entries for removed ResourceLoader 
modules from the database' );
-   $this->addOption( 'batchsize', 'Delete rows in batches of this 
size. Default: 500', false, true );
+   $this->setBatchSize( 500 );
}
 
public function execute() {
+   $this->output( "Cleaning up module_deps table...\n" );
+
$dbw = $this->getDB( DB_MASTER );
$rl = new ResourceLoader( 
MediaWikiServices::getInstance()->getMainConfig() );
$moduleNames = $rl->getModuleNames();
-   $moduleList = implode( ', ', array_map( [ $dbw, 'addQuotes' ], 
$moduleNames ) );
-   $limit = max( 1, intval( $this->getOption( 'batchsize', 500 ) ) 
);
+   $res = $dbw->select( 'module_deps',
+   [ 'md_module', 'md_skin' ],
+   $moduleNames ? 'md_module NOT IN (' . $dbw->makeList( 
$moduleNames ) . ')' : '1=1',
+   __METHOD__
+   );
+   $rows = iterator_to_array( $res, false );
 
-   $this->output( "Cleaning up module_deps table...\n" );
-   $i = 1;
$modDeps = $dbw->tableName( 'module_deps' );
-   do {
-   // $dbw->delete() doesn't support LIMIT :(
-   $where = $moduleList ? "md_module NOT IN ($moduleList)" 
: '1=1';
-   $dbw->query( "DELETE FROM $modDeps WHERE $where LIMIT 
$limit", __METHOD__ );
+   $i = 1;
+   foreach ( array_chunk( $rows, $this->mBatchSize ) as $chunk ) {
+   // WHERE ( mod=A AND skin=A ) OR ( mod=A AND skin=B) ..
+   $conds = array_map( function ( stdClass $row ) use ( 
$dbw ) {
+   return $dbw->makeList( (array)$row, 
IDatabase::LIST_AND );
+   }, $chunk );
+   $conds = $dbw->makeList( $conds, IDatabase::LIST_OR );
+
+   $this->beginTransaction( $dbw, __METHOD__ );
+   $dbw->query( "DELETE FROM $modDeps WHERE $conds", 
__METHOD__ );
$numRows = $dbw->affectedRows();
$this->output( "Batch $i: $numRows rows\n" );
+   $this->commitTransaction( $dbw, __METHOD__ );
+
$i++;
-   wfWaitForSlaves();
-   } while ( $numRows > 0 );
-   $this->output( "done\n" );
+   }
+
+   $this->output( "Done\n" );
}
 }
 
-$maintClass = "CleanupRemovedModules";
+$maintClass = 'CleanupRemovedModules';
 require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/maintenance/purgeModuleDeps.php b/maintenance/purgeModuleDeps.php
new file mode 100644
index 000..3088baa
--- /dev/null
+++ b/maintenance/purgeModuleDeps.php
@@ -0,0 +1,72 @@
+http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Maintenance
+ * @author Timo Tijhof
+ */
+
+use MediaWiki\MediaWikiServices;
+
+require_once __DIR__ . '/Maintenance.php';
+
+/**
+ * Maintenance script to purge the module_deps database cache table.
+ *
+ * @ingroup Maintenance
+ */
+class PurgeModuleDeps 

[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: Fix busted SQL comment

2017-03-02 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340908 )

Change subject: Fix busted SQL comment
..

Fix busted SQL comment

-- needs to be at the start of the line, oops!

Change-Id: I7e835c49613821c702210066abfd449109bef2ce
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/08/340908/1

diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index fc54cd9..6ac66c2 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2586,7 +2586,7 @@
AND contact_type = 'Individual'
AND first_name IS NULL
AND last_name IS NULL
-   AND sort_name LIKE '%, %' --leading % seems to be OK after all 
the other conditions
+   AND sort_name LIKE '%, %' /* leading % seems to be OK after all 
the other conditions */
 ");
// Some of the contacts have been touched since creation, and Civi has 
helpfully
// destroyed the sort_name. log_civicrm_contact to the rescue!

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7e835c49613821c702210066abfd449109bef2ce
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
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] mediawiki/core[master]: ApiPageSet: Use processTitlesArray() in getRedirectTargets()

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

Change subject: ApiPageSet: Use processTitlesArray() in getRedirectTargets()
..


ApiPageSet: Use processTitlesArray() in getRedirectTargets()

Instead of trying to duplicate the code to build a LinkBatch while
handling whatever special titles might exist, let's just use
processTitlesArray() to do it for us.

To do it right we also need to add some more deduplication to
processTitlesArray().

Bug: T41492
Change-Id: I28ed0d813a026b64a42b5a2518de9b02a8543aac
---
M includes/api/ApiPageSet.php
1 file changed, 25 insertions(+), 13 deletions(-)

Approvals:
  Gergő Tisza: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/api/ApiPageSet.php b/includes/api/ApiPageSet.php
index 06019cf..8623e12 100644
--- a/includes/api/ApiPageSet.php
+++ b/includes/api/ApiPageSet.php
@@ -64,6 +64,7 @@
private $mMissingPageIDs = [];
private $mRedirectTitles = [];
private $mSpecialTitles = [];
+   private $mAllSpecials = []; // separate from mAllPages to avoid 
breaking getAllTitlesByNamespace()
private $mNormalizedTitles = [];
private $mInterwikiTitles = [];
/** @var Title[] */
@@ -1061,7 +1062,7 @@
 * @return LinkBatch
 */
private function getRedirectTargets() {
-   $lb = new LinkBatch();
+   $titlesToResolve = [];
$db = $this->getDB();
 
$res = $db->select(
@@ -1088,8 +1089,8 @@
unset( $this->mPendingRedirectIDs[$rdfrom] );
if ( $to->isExternal() ) {
$this->mInterwikiTitles[$to->getPrefixedText()] 
= $to->getInterwiki();
-   } elseif ( !isset( 
$this->mAllPages[$row->rd_namespace][$row->rd_title] ) ) {
-   $lb->add( $row->rd_namespace, $row->rd_title );
+   } elseif ( !isset( 
$this->mAllPages[$to->getNamespace()][$to->getDBkey()] ) ) {
+   $titlesToResolve[] = $to;
}
$this->mRedirectTitles[$from] = $to;
}
@@ -1104,7 +1105,11 @@
// What the hell. Let's just ignore this
continue;
}
-   $lb->addObj( $rt );
+   if ( $rt->isExternal() ) {
+   
$this->mInterwikiTitles[$rt->getPrefixedText()] = $rt->getInterwiki();
+   } elseif ( !isset( 
$this->mAllPages[$rt->getNamespace()][$rt->getDBkey()] ) ) {
+   $titlesToResolve[] = $rt;
+   }
$from = $title->getPrefixedText();
$this->mResolvedRedirectTitles[$from] = $title;
$this->mRedirectTitles[$from] = $rt;
@@ -1112,7 +1117,7 @@
}
}
 
-   return $lb;
+   return $this->processTitlesArray( $titlesToResolve );
}
 
/**
@@ -1151,12 +1156,14 @@
$titleObj = Title::newFromTextThrow( 
$title, $this->mDefaultNamespace );
} catch ( MalformedTitleException $ex ) {
// Handle invalid titles gracefully
-   $this->mAllPages[0][$title] = 
$this->mFakePageId;
-   
$this->mInvalidTitles[$this->mFakePageId] = [
-   'title' => $title,
-   'invalidreason' => 
$this->getErrorFormatter()->formatException( $ex, [ 'bc' => true ] ),
-   ];
-   $this->mFakePageId--;
+   if ( !isset( 
$this->mAllPages[0][$title] ) ) {
+   $this->mAllPages[0][$title] = 
$this->mFakePageId;
+   
$this->mInvalidTitles[$this->mFakePageId] = [
+   'title' => $title,
+   'invalidreason' => 
$this->getErrorFormatter()->formatException( $ex, [ 'bc' => true ] ),
+   ];
+   $this->mFakePageId--;
+   }
continue; // There's nothing else we 
can do
}
} else {
@@ -1184,8 +1191,13 @@
if ( $titleObj->getNamespace() < 0 ) {
   

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Revert "Test disable super_detect_noop script"

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

Change subject: Revert "Test disable super_detect_noop script"
..


Revert "Test disable super_detect_noop script"

Test is complete, everything looks like it will be ok
for a longer disable during the elasticsearch 2 -> 5
transition.

This reverts commit b9ffde9f15bacc7c3a23861ff255407ab621f1d8.

Change-Id: I0c9f634db073e0a5b8b597867c4be68bede0b513
---
M wmf-config/CirrusSearch-common.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/wmf-config/CirrusSearch-common.php 
b/wmf-config/CirrusSearch-common.php
index 34bcd73..5e860d7 100644
--- a/wmf-config/CirrusSearch-common.php
+++ b/wmf-config/CirrusSearch-common.php
@@ -80,7 +80,7 @@
'build',
'use',
],
-   //'super_detect_noop' => true,
+   'super_detect_noop' => true,
'id_hash_mod_filter' => true,
'documentVersion' => true,
 ];

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I0c9f634db073e0a5b8b597867c4be68bede0b513
Gerrit-PatchSet: 2
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: EBernhardson 
Gerrit-Reviewer: DCausse 
Gerrit-Reviewer: Florianschmidtwelzow 
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] apps...wikipedia[master]: Update: add second OkHttp cache for saved content

2017-03-02 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340906 )

Change subject: Update: add second OkHttp cache for saved content
..

Update: add second OkHttp cache for saved content

Bug: T156917
Change-Id: I45825777d18cbbc686d757a715002464cf94ae3f
---
M app/build.gradle
A app/src/main/java/okhttp3/CacheDelegate.java
A app/src/main/java/okhttp3/internal/cache/CacheDelegateInterceptor.java
M app/src/main/java/org/wikipedia/dataclient/okhttp/OkHttpConnectionFactory.java
A 
app/src/main/java/org/wikipedia/dataclient/okhttp/cache/CacheDelegateStrategy.java
A app/src/main/java/org/wikipedia/dataclient/okhttp/cache/SaveHeader.java
A app/src/test/java/okhttp3/internal/cache/CacheDelegateInterceptorTest.java
A 
app/src/test/java/org/wikipedia/dataclient/okhttp/cache/CacheDelegateStrategyTest.java
A app/src/test/java/org/wikipedia/dataclient/okhttp/cache/SaveHeaderTest.java
M gradle/src/checkstyle.gradle
10 files changed, 492 insertions(+), 4 deletions(-)


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

diff --git a/app/build.gradle b/app/build.gradle
index c0e83d2..70ad2fe 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -157,7 +157,8 @@
 // use http://gradleplease.appspot.com/ or http://search.maven.org/.
 // Debug with ./gradlew -q app:dependencies --configuration compile
 
-String okHttpVersion = '3.6.0'
+String okHttpVersion = '3.6.0' // When updating this version, resync file 
copies under
+   // app/src/main/java/okhttp3
 String retrofitVersion = '2.1.0'
 String supportVersion = '25.1.1'
 String espressoVersion = '2.2.2'
diff --git a/app/src/main/java/okhttp3/CacheDelegate.java 
b/app/src/main/java/okhttp3/CacheDelegate.java
new file mode 100644
index 000..65951d3
--- /dev/null
+++ b/app/src/main/java/okhttp3/CacheDelegate.java
@@ -0,0 +1,54 @@
+package okhttp3;
+
+import android.support.annotation.NonNull;
+
+import java.io.IOException;
+
+import okhttp3.internal.Util;
+import okhttp3.internal.cache.DiskLruCache;
+import okhttp3.internal.cache.InternalCache;
+import okio.ByteString;
+
+public class CacheDelegate {
+@NonNull public static InternalCache internalCache(@NonNull Cache cache) {
+return cache.internalCache;
+}
+
+@NonNull private final Cache cache;
+
+public CacheDelegate(@NonNull Cache cache) {
+this.cache = cache;
+}
+
+// Copy of Cache.remove(). This method performs file I/O
+public boolean remove(@NonNull String url) {
+try {
+return cache.cache.remove(key(url));
+} catch (IOException ignore) { }
+return false;
+}
+
+// Copy of Cache.get(). Calling this method modifies the Cache. If the URL 
is present, it's
+// cache entry is moved to the head of the LRU queue. This method performs 
file I/O
+public boolean isCached(@NonNull String url) {
+String key = key(url);
+DiskLruCache.Snapshot snapshot;
+try {
+snapshot = cache.cache.get(key);
+if (snapshot == null) {
+return false;
+}
+} catch (IOException e) {
+// Give up because the cache cannot be read.
+return false;
+}
+
+Util.closeQuietly(snapshot);
+return true;
+}
+
+// Copy of Cache.key()
+@NonNull private String key(@NonNull String url) {
+return ByteString.encodeUtf8(url).md5().hex();
+}
+}
diff --git 
a/app/src/main/java/okhttp3/internal/cache/CacheDelegateInterceptor.java 
b/app/src/main/java/okhttp3/internal/cache/CacheDelegateInterceptor.java
new file mode 100644
index 000..e6132ab
--- /dev/null
+++ b/app/src/main/java/okhttp3/internal/cache/CacheDelegateInterceptor.java
@@ -0,0 +1,283 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package okhttp3.internal.cache;
+
+import org.wikipedia.dataclient.okhttp.cache.CacheDelegateStrategy;
+
+import java.io.IOException;
+
+import okhttp3.Headers;
+import okhttp3.Interceptor;
+import okhttp3.Protocol;
+import okhttp3.Request;
+import okhttp3.Response;

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Remove old save page file loading

2017-03-02 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340907 )

Change subject: Remove old save page file loading
..

Remove old save page file loading

Bug: T156917

Change-Id: I51c1bd5cc6c90be5aa58ab230fdd1633eb03ddda
---
M app/src/main/assets/bundle.js
M app/src/main/java/org/wikipedia/page/PageFragment.java
M app/src/main/java/org/wikipedia/page/PageFragmentLoadState.java
M app/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java
M app/src/main/java/org/wikipedia/savedpages/ImageUrlMap.java
D app/src/main/java/org/wikipedia/savedpages/LoadSavedPageTask.java
M app/src/main/java/org/wikipedia/savedpages/SavedPage.java
M app/src/main/java/org/wikipedia/savedpages/SavedPageSyncService.java
M app/src/main/java/org/wikipedia/util/FileUtil.java
M www/js/sections.js
10 files changed, 11 insertions(+), 193 deletions(-)


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

diff --git a/app/src/main/assets/bundle.js b/app/src/main/assets/bundle.js
index 676fc1c..0cccf25 100644
--- a/app/src/main/assets/bundle.js
+++ b/app/src/main/assets/bundle.js
@@ -587,8 +587,7 @@
 }
 document.getElementById( "loading_sections").className = "";
 bridge.sendMessage( "pageLoadComplete", {
-  "sequence": payload.sequence,
-  "savedPage": payload.savedPage });
+  "sequence": payload.sequence });
 } else {
 var contentWrapper = document.getElementById( "content" );
 elementsForSection(payload.section).forEach(function (element) {
@@ -603,7 +602,7 @@
 if ( typeof payload.fragment === "string" && payload.fragment.length > 
0 && payload.section.anchor === payload.fragment) {
 scrollToSection( payload.fragment );
 }
-bridge.sendMessage( "requestSection", { "sequence": payload.sequence, 
"savedPage": payload.savedPage, "index": payload.section.id + 1 });
+bridge.sendMessage( "requestSection", { "sequence": payload.sequence, 
"index": payload.section.id + 1 });
 }
 });
 
diff --git a/app/src/main/java/org/wikipedia/page/PageFragment.java 
b/app/src/main/java/org/wikipedia/page/PageFragment.java
index 2a728cb..a9e40d9 100755
--- a/app/src/main/java/org/wikipedia/page/PageFragment.java
+++ b/app/src/main/java/org/wikipedia/page/PageFragment.java
@@ -67,8 +67,6 @@
 import org.wikipedia.readinglist.page.ReadingListPage;
 import org.wikipedia.readinglist.page.database.ReadingListDaoProxy;
 import org.wikipedia.readinglist.page.database.ReadingListPageDao;
-import org.wikipedia.savedpages.ImageUrlMap;
-import org.wikipedia.savedpages.LoadSavedPageUrlMapTask;
 import org.wikipedia.settings.Prefs;
 import org.wikipedia.tooltip.ToolTipUtil;
 import org.wikipedia.util.ActiveTimer;
@@ -898,37 +896,6 @@
 if (getPageLoadCallbacks() != null) {
 getPageLoadCallbacks().onLoadError(caught);
 }
-}
-
-/**
- * Read URL mappings from the saved page specific file
- */
-public void readUrlMappings() {
-new LoadSavedPageUrlMapTask(model.getTitle()) {
-@Override
-public void onFinish(JSONObject result) {
-// have we been unwittingly detached from our Activity?
-if (!isAdded()) {
-L.d("Detached from activity, so stopping update.");
-return;
-}
-
-ImageUrlMap.replaceImageSources(bridge, result);
-}
-
-@Override
-public void onCatch(Throwable e) {
-if (!isAdded()) {
-return;
-}
-/*
-If anything bad happens during loading of a saved page, then 
simply bounce it
-back to the online version of the page, and re-save the page 
contents locally when it's done.
- */
-L.d(e);
-refreshPage();
-}
-}.execute();
 }
 
 public void refreshPage() {
diff --git a/app/src/main/java/org/wikipedia/page/PageFragmentLoadState.java 
b/app/src/main/java/org/wikipedia/page/PageFragmentLoadState.java
index 52d7019..ef9393c 100644
--- a/app/src/main/java/org/wikipedia/page/PageFragmentLoadState.java
+++ b/app/src/main/java/org/wikipedia/page/PageFragmentLoadState.java
@@ -33,7 +33,6 @@
 import org.wikipedia.page.leadimages.LeadImagesHandler;
 import org.wikipedia.pageimages.PageImage;
 import org.wikipedia.pageimages.PageImagesTask;
-import org.wikipedia.savedpages.LoadSavedPageTask;
 import org.wikipedia.util.DeviceUtil;
 import org.wikipedia.util.DimenUtil;
 import org.wikipedia.util.L10nUtil;
@@ -69,8 +68,6 @@
 private interface ErrorCallback {
 void call(@Nullable Throwable error);
 }
-
-private static final String BRIDGE_PAYLOAD_SAVED_PAGE = "savedPage";
 
 private static final int STATE_NO_FETCH = 1;
 

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: startup: Drop JavaScript support for browsers without DOM Le...

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

Change subject: startup: Drop JavaScript support for browsers without DOM Level 
2
..


startup: Drop JavaScript support for browsers without DOM Level 2

In practice, this means nothing, as the main browsers affected
were Internet Explorer 8 and early versions of Android (before
1.6), which are already Grade C.

Change-Id: I4488402686c8b9fefa0af5fed3c9a4b83cbff798
---
M resources/Resources.php
D resources/src/dom-level2-skip.js
D resources/src/polyfill-nodeTypes.js
M tests/qunit/QUnitTestResources.php
4 files changed, 3 insertions(+), 35 deletions(-)

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



diff --git a/resources/Resources.php b/resources/Resources.php
index 5406480..ea97337 100644
--- a/resources/Resources.php
+++ b/resources/Resources.php
@@ -251,7 +251,6 @@
'scripts' => 'resources/src/jquery/jquery.highlightText.js',
'dependencies' => [
'mediawiki.RegExp',
-   'dom-level2-shim',
],
'targets' => [ 'desktop', 'mobile' ],
],
@@ -345,7 +344,6 @@
'styles' => 'resources/src/jquery/jquery.tablesorter.less',
'messages' => [ 'sort-descending', 'sort-ascending' ],
'dependencies' => [
-   'dom-level2-shim',
'mediawiki.RegExp',
'mediawiki.language.months',
],
@@ -736,7 +734,7 @@
 
// Deprecated since MediaWiki 1.29.0
'json' => [
-   'deprecated' => 'Use of the "json" MediaWiki module is 
deprecated since MediaWiki 1.29.0',
+   'deprecated' => 'Use of the "json" module is deprecated since 
MediaWiki 1.29.0',
'targets' => [ 'desktop', 'mobile' ],
],
 
@@ -937,7 +935,6 @@
'mediawiki.api.upload' => [
'scripts' => 'resources/src/mediawiki/api/upload.js',
'dependencies' => [
-   'dom-level2-shim',
'mediawiki.api',
'mediawiki.api.edit',
],
@@ -1220,7 +1217,6 @@
'mediawiki.Upload' => [
'scripts' => 'resources/src/mediawiki/mediawiki.Upload.js',
'dependencies' => [
-   'dom-level2-shim',
'mediawiki.api.upload',
],
],
@@ -1612,7 +1608,6 @@
'mediawiki.util',
'mediawiki.language',
'user.options',
-   'dom-level2-shim',
],
'targets' => [ 'desktop', 'mobile' ],
],
@@ -2490,11 +2485,10 @@
],
 
/* dom-level2-shim */
-   // IE 8
+   // Deprecated since MediaWiki 1.29.0
'dom-level2-shim' => [
-   'scripts' => 'resources/src/polyfill-nodeTypes.js',
+   'deprecated' => 'Use of the "dom-level2-shim" module is 
deprecated since MediaWiki 1.29.0',
'targets' => [ 'desktop', 'mobile' ],
-   'skipFunction' => 'resources/src/dom-level2-skip.js',
],
 
/* OOjs */
diff --git a/resources/src/dom-level2-skip.js b/resources/src/dom-level2-skip.js
deleted file mode 100644
index 484c295..000
--- a/resources/src/dom-level2-skip.js
+++ /dev/null
@@ -1,6 +0,0 @@
-/*!
- * Skip function for dom-level2-shim module.
- *
- * Tests for window.Node because that's the only thing that this shim is 
adding.
- */
-return !!window.Node;
diff --git a/resources/src/polyfill-nodeTypes.js 
b/resources/src/polyfill-nodeTypes.js
deleted file mode 100644
index c8acc86..000
--- a/resources/src/polyfill-nodeTypes.js
+++ /dev/null
@@ -1,19 +0,0 @@
-/**
- * Adds window.Node with node types according to:
- * https://www.w3.org/TR/DOM-Level-2-Core/core.html#ID-1950641247
- */
-
-window.Node = window.Node || {
-   ELEMENT_NODE: 1,
-   ATTRIBUTE_NODE: 2,
-   TEXT_NODE: 3,
-   CDATA_SECTION_NODE: 4,
-   ENTITY_REFERENCE_NODE: 5,
-   ENTITY_NODE: 6,
-   PROCESSING_INSTRUCTION_NODE: 7,
-   COMMENT_NODE: 8,
-   DOCUMENT_NODE: 9,
-   DOCUMENT_TYPE_NODE: 10,
-   DOCUMENT_FRAGMENT_NODE: 11,
-   NOTATION_NODE: 12
-};
diff --git a/tests/qunit/QUnitTestResources.php 
b/tests/qunit/QUnitTestResources.php
index 94d25ee..0bd190b 100644
--- a/tests/qunit/QUnitTestResources.php
+++ b/tests/qunit/QUnitTestResources.php
@@ -32,7 +32,6 @@
'mediawiki.page.ready',
'mediawiki.page.startup',
'test.sinonjs',
-   'dom-level2-shim',
],
'position' => 'top',
'targets' => [ 'desktop', 'mobile' ],

-- 
To view, visit 

[MediaWiki-commits] [Gerrit] wikidata...rdf[master]: Update docs

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

Change subject: Update docs
..


Update docs

Change-Id: Idd635baa1b58857cc0b4337eeb31724737f29505
---
M docs/ChangeLog
1 file changed, 1 insertion(+), 0 deletions(-)

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



diff --git a/docs/ChangeLog b/docs/ChangeLog
index 551e471..206d47f 100644
--- a/docs/ChangeLog
+++ b/docs/ChangeLog
@@ -2,6 +2,7 @@
 -
 Add LDF server
 Add external prefix configuration
+Enable external federation
 
 0.2.3
 -

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Idd635baa1b58857cc0b4337eeb31724737f29505
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/rdf
Gerrit-Branch: master
Gerrit-Owner: Smalyshev 
Gerrit-Reviewer: Smalyshev 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] wikidata...rdf[master]: Update GUI

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

Change subject: Update GUI
..


Update GUI

Change-Id: I108799978b73e11a88078ae6a9bc848046c31a1f
---
M gui
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/gui b/gui
index 6ba92b5..a6b1e9d 16
--- a/gui
+++ b/gui
@@ -1 +1 @@
-Subproject commit 6ba92b5de8bf4458c8955573e8cb959d75f1c688
+Subproject commit a6b1e9d276ee670021c2b55d290db8ba69eae179

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I108799978b73e11a88078ae6a9bc848046c31a1f
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/rdf
Gerrit-Branch: master
Gerrit-Owner: Smalyshev 
Gerrit-Reviewer: Smalyshev 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] wikimedia...SmashPig[master]: Split error check into own function

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

Change subject: Split error check into own function
..


Split error check into own function

Thanks for the best practices nudge, Scrutinizer!

Change-Id: I567da17632fe4c5b4bc479cae0cbcef30ac4ec14
---
M PaymentProviders/Ingenico/Api.php
1 file changed, 12 insertions(+), 3 deletions(-)

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



diff --git a/PaymentProviders/Ingenico/Api.php 
b/PaymentProviders/Ingenico/Api.php
index f6e4258..5da77bb 100644
--- a/PaymentProviders/Ingenico/Api.php
+++ b/PaymentProviders/Ingenico/Api.php
@@ -61,6 +61,17 @@
$response = $request->execute();
 
$decoded = json_decode( $response['body'], true );
+   $this->checkErrors( $response, $decoded );
+
+   return $decoded;
+   }
+
+   /**
+* @param array $response The CurlWrapper-formatteed response from 
Ingenico
+* @param array $decoded The decoded JSON response body. Null if bad 
JSON
+* @throws ApiException
+*/
+   protected function checkErrors( $response, $decoded ) {
if ( $decoded === null ) {
throw new ApiException( "Response body is not valid 
JSON: '{$response['body']}'" );
}
@@ -69,13 +80,11 @@
if ( !empty( $decoded['errorId'] ) ) {
$messages[] = "Ingenico error id 
{$decoded['errorId']}.";
}
-   foreach( $decoded['errors'] as $error ) {
+   foreach ( $decoded['errors'] as $error ) {
$messages[] = "Error code {$error['code']}: 
{$error['message']}.";
}
$concatenated = implode( ' ', $messages );
throw new ApiException( $concatenated );
}
-
-   return $decoded;
}
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I567da17632fe4c5b4bc479cae0cbcef30ac4ec14
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/SmashPig
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...Flow[wmf/1.29.0-wmf.14]: Fix Flow autoload data and gen-autoload.php

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

Change subject: Fix Flow autoload data and gen-autoload.php
..


Fix Flow autoload data and gen-autoload.php

Convert gen-autoload.php to standard maintenance script so it
loads autoloader (was getting P5012, not autoloaded).

Then fix the autoload data itself (regression from
9d087957aebaa28900033211936497df29f9e99a that removed
MaintenanceDebugLogger)

Change-Id: Ibbc95c2bdd0e7012cf05a6c9196869aed1e99989
(cherry picked from commit a2588a6d9b0971c59b07b699c836dfa0243834de)
---
M composer.json
M extension.json
M scripts/gen-autoload.php
3 files changed, 429 insertions(+), 415 deletions(-)

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



diff --git a/composer.json b/composer.json
index 1137f5c..f917e63 100644
--- a/composer.json
+++ b/composer.json
@@ -12,7 +12,7 @@
},
"scripts": {
"test": [
-   "parallel-lint . --exclude vendor/bin --exclude 
vendor/jakub-onderka --exclude node_modules"
+   "parallel-lint . --exclude vendor --exclude 
node_modules"
]
}
 }
diff --git a/extension.json b/extension.json
index a004a05..f3cc4ff 100644
--- a/extension.json
+++ b/extension.json
@@ -94,399 +94,6 @@
"FlowNamespaces": "Flow.namespaces.php",
"FlowAlias": "Flow.alias.php"
},
-   "AutoloadClasses": {
-   "ExternalStoreFlowMock": 
"tests/phpunit/Mock/ExternalStoreFlowMock.php",
-   "FlowHooks": "Hooks.php",
-   "Flow\\Actions\\EditAction": "includes/Actions/EditAction.php",
-   "Flow\\Actions\\FlowAction": "includes/Actions/Action.php",
-   "Flow\\Actions\\PurgeAction": 
"includes/Actions/PurgeAction.php",
-   "Flow\\Actions\\ViewAction": "includes/Actions/ViewAction.php",
-   "Flow\\Api\\ApiFlow": "includes/Api/ApiFlow.php",
-   "Flow\\Api\\ApiFlowBase": "includes/Api/ApiFlowBase.php",
-   "Flow\\Api\\ApiFlowBaseGet": "includes/Api/ApiFlowBaseGet.php",
-   "Flow\\Api\\ApiFlowBasePost": 
"includes/Api/ApiFlowBasePost.php",
-   "Flow\\Api\\ApiFlowEditHeader": 
"includes/Api/ApiFlowEditHeader.php",
-   "Flow\\Api\\ApiFlowEditPost": 
"includes/Api/ApiFlowEditPost.php",
-   "Flow\\Api\\ApiFlowEditTitle": 
"includes/Api/ApiFlowEditTitle.php",
-   "Flow\\Api\\ApiFlowEditTopicSummary": 
"includes/Api/ApiFlowEditTopicSummary.php",
-   "Flow\\Api\\ApiFlowLockTopic": 
"includes/Api/ApiFlowLockTopic.php",
-   "Flow\\Api\\ApiFlowModeratePost": 
"includes/Api/ApiFlowModeratePost.php",
-   "Flow\\Api\\ApiFlowModerateTopic": 
"includes/Api/ApiFlowModerateTopic.php",
-   "Flow\\Api\\ApiFlowNewTopic": 
"includes/Api/ApiFlowNewTopic.php",
-   "Flow\\Api\\ApiFlowReply": "includes/Api/ApiFlowReply.php",
-   "Flow\\Api\\ApiFlowSearch": "includes/Api/ApiFlowSearch.php",
-   "Flow\\Api\\ApiFlowUndoEditHeader": 
"includes/Api/ApiFlowUndoEditHeader.php",
-   "Flow\\Api\\ApiFlowUndoEditPost": 
"includes/Api/ApiFlowUndoEditPost.php",
-   "Flow\\Api\\ApiFlowUndoEditTopicSummary": 
"includes/Api/ApiFlowUndoEditTopicSummary.php",
-   "Flow\\Api\\ApiFlowViewHeader": 
"includes/Api/ApiFlowViewHeader.php",
-   "Flow\\Api\\ApiFlowViewPost": 
"includes/Api/ApiFlowViewPost.php",
-   "Flow\\Api\\ApiFlowViewPostHistory": 
"includes/Api/ApiFlowViewPostHistory.php",
-   "Flow\\Api\\ApiFlowViewTopic": 
"includes/Api/ApiFlowViewTopic.php",
-   "Flow\\Api\\ApiFlowViewTopicHistory": 
"includes/Api/ApiFlowViewTopicHistory.php",
-   "Flow\\Api\\ApiFlowViewTopicList": 
"includes/Api/ApiFlowViewTopicList.php",
-   "Flow\\Api\\ApiFlowViewTopicSummary": 
"includes/Api/ApiFlowViewTopicSummary.php",
-   "Flow\\Api\\ApiParsoidUtilsFlow": 
"includes/Api/ApiParsoidUtilsFlow.php",
-   "Flow\\Api\\ApiQueryPropFlowInfo": 
"includes/Api/ApiQueryPropFlowInfo.php",
-   "Flow\\BlockFactory": "includes/BlockFactory.php",
-   "Flow\\Block\\AbstractBlock": "includes/Block/Block.php",
-   "Flow\\Block\\Block": "includes/Block/Block.php",
-   "Flow\\Block\\BoardHistoryBlock": 
"includes/Block/BoardHistory.php",
-   "Flow\\Block\\HeaderBlock": "includes/Block/Header.php",
-   "Flow\\Block\\TopicBlock": "includes/Block/Topic.php",
-   "Flow\\Block\\TopicListBlock": "includes/Block/TopicList.php",
-   "Flow\\Block\\TopicSummaryBlock": 
"includes/Block/TopicSummary.php",
-   "Flow\\BoardMover": "includes/BoardMover.php",
-   

[MediaWiki-commits] [Gerrit] wikimedia...SmashPig[master]: Split error check into own function

2017-03-02 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340905 )

Change subject: Split error check into own function
..

Split error check into own function

Thanks for the best practices nudge, Scrutinizer!

Change-Id: I567da17632fe4c5b4bc479cae0cbcef30ac4ec14
---
M PaymentProviders/Ingenico/Api.php
1 file changed, 12 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/SmashPig 
refs/changes/05/340905/1

diff --git a/PaymentProviders/Ingenico/Api.php 
b/PaymentProviders/Ingenico/Api.php
index f6e4258..5da77bb 100644
--- a/PaymentProviders/Ingenico/Api.php
+++ b/PaymentProviders/Ingenico/Api.php
@@ -61,6 +61,17 @@
$response = $request->execute();
 
$decoded = json_decode( $response['body'], true );
+   $this->checkErrors( $response, $decoded );
+
+   return $decoded;
+   }
+
+   /**
+* @param array $response The CurlWrapper-formatteed response from 
Ingenico
+* @param array $decoded The decoded JSON response body. Null if bad 
JSON
+* @throws ApiException
+*/
+   protected function checkErrors( $response, $decoded ) {
if ( $decoded === null ) {
throw new ApiException( "Response body is not valid 
JSON: '{$response['body']}'" );
}
@@ -69,13 +80,11 @@
if ( !empty( $decoded['errorId'] ) ) {
$messages[] = "Ingenico error id 
{$decoded['errorId']}.";
}
-   foreach( $decoded['errors'] as $error ) {
+   foreach ( $decoded['errors'] as $error ) {
$messages[] = "Error code {$error['code']}: 
{$error['message']}.";
}
$concatenated = implode( ' ', $messages );
throw new ApiException( $concatenated );
}
-
-   return $decoded;
}
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I567da17632fe4c5b4bc479cae0cbcef30ac4ec14
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] mediawiki...MultimediaViewer[master]: Align to WikimediaUI style guide and code cleanup

2017-03-02 Thread VolkerE (Code Review)
VolkerE has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340903 )

Change subject: Align to WikimediaUI style guide and code cleanup
..

Align to WikimediaUI style guide and code cleanup

Aligning to WikimediaUI style guide by replacing colors with
standard color palette equivalents, merging close colors
(ex: `#E6E6E6` & `#eee` become `#eaecf0` ) and slightly increase
contrast on a few to meet WCAG 2.0 level AA criteria.
Also:
- following other code bases like MobileFrontend or OOjs UI in
using `border-radius` property instead of obsolete mixin
- removing non-existing browser vendor prefixes in mixins
- removing non-used Less variables
- bringing CSS/Less code closer to coding standards and
- simplifying Less code where applicable

Change-Id: Icb936e14ff613471ea1da6df6341ec1b0543cfaf
---
M resources/mmv/img/expand.svg
M resources/mmv/img/gear_gray.svg
M resources/mmv/img/x_gray.svg
M resources/mmv/mmv.bootstrap.less
M resources/mmv/mmv.lightboxinterface.less
M resources/mmv/mmv.mixins.less
M resources/mmv/ui/img/angle-separator.svg
M resources/mmv/ui/img/cc.svg
M resources/mmv/ui/img/commons_gray.svg
M resources/mmv/ui/img/ellipsis_darkgray.svg
M resources/mmv/ui/img/ellipsis_gray.svg
M resources/mmv/ui/img/ellipsis_lightgray.svg
M resources/mmv/ui/img/error-media-icon.svg
M resources/mmv/ui/img/file.svg
M resources/mmv/ui/img/horn_grey.svg
M resources/mmv/ui/img/icon_mmv.svg
M resources/mmv/ui/img/icon_page.svg
M resources/mmv/ui/img/license.svg
M resources/mmv/ui/img/location.svg
M resources/mmv/ui/img/pd.svg
M resources/mmv/ui/img/repo.svg
M resources/mmv/ui/img/restrict-2257.svg
M resources/mmv/ui/img/restrict-aus-reserve.svg
M resources/mmv/ui/img/restrict-communist.svg
M resources/mmv/ui/img/restrict-costume.svg
M resources/mmv/ui/img/restrict-currency.svg
M resources/mmv/ui/img/restrict-default.svg
M resources/mmv/ui/img/restrict-design.svg
M resources/mmv/ui/img/restrict-fan-art.svg
M resources/mmv/ui/img/restrict-ihl.svg
M resources/mmv/ui/img/restrict-insignia.svg
M resources/mmv/ui/img/restrict-ita-mibac.svg
M resources/mmv/ui/img/restrict-nazi.svg
M resources/mmv/ui/img/restrict-personality.svg
M resources/mmv/ui/img/time.svg
M resources/mmv/ui/img/user-ltr.svg
M resources/mmv/ui/img/user-rtl.svg
M resources/mmv/ui/mmv.ui.canvas.less
M resources/mmv/ui/mmv.ui.dialog.less
M resources/mmv/ui/mmv.ui.download.dialog.less
M resources/mmv/ui/mmv.ui.download.pane.less
M resources/mmv/ui/mmv.ui.metadataPanel.less
M resources/mmv/ui/mmv.ui.permission.less
M resources/mmv/ui/mmv.ui.reuse.dialog.less
M resources/mmv/ui/mmv.ui.reuse.embed.less
M resources/mmv/ui/mmv.ui.reuse.share.less
M resources/mmv/ui/mmv.ui.reuse.shareembed.less
M resources/mmv/ui/mmv.ui.stripeButtons.less
M resources/mmv/ui/mmv.ui.tipsyDialog.less
M resources/mmv/ui/mmv.ui.truncatableTextField.less
M resources/mmv/ui/mmv.ui.viewingOptions.less
M viewer-ltr.svg
M viewer-rtl.svg
53 files changed, 125 insertions(+), 180 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MultimediaViewer 
refs/changes/03/340903/1

diff --git a/resources/mmv/img/expand.svg b/resources/mmv/img/expand.svg
index 24750de..d83c2a9 100644
--- a/resources/mmv/img/expand.svg
+++ b/resources/mmv/img/expand.svg
@@ -1,6 +1,6 @@
 
 http://www.w3.org/2000/svg; viewBox="0 0 1024 768">
-
+
 
 
 
diff --git a/resources/mmv/img/gear_gray.svg b/resources/mmv/img/gear_gray.svg
index abc6874..6d9e656 100644
--- a/resources/mmv/img/gear_gray.svg
+++ b/resources/mmv/img/gear_gray.svg
@@ -1,4 +1,4 @@
 
 http://www.w3.org/2000/svg; viewBox="0 0 1024 768">
-
+
 
diff --git a/resources/mmv/img/x_gray.svg b/resources/mmv/img/x_gray.svg
index e1e4f73..c4f55e1 100644
--- a/resources/mmv/img/x_gray.svg
+++ b/resources/mmv/img/x_gray.svg
@@ -1,4 +1,4 @@
 
 http://www.w3.org/2000/svg; viewBox="0 0 612 792">
-
+
 
diff --git a/resources/mmv/mmv.bootstrap.less b/resources/mmv/mmv.bootstrap.less
index c6fc0c4..0fbceda 100644
--- a/resources/mmv/mmv.bootstrap.less
+++ b/resources/mmv/mmv.bootstrap.less
@@ -1,5 +1,3 @@
-@expand-link-border-color: #ddd;
-
 .mw-mmv-overlay {
position: fixed;
top: 0;
@@ -7,7 +5,7 @@
right: 0;
bottom: 0;
z-index: 1000;
-   background-color: rgb( 0, 0, 0 );
+   background-color: #000;
 }
 
 body.mw-mmv-lightbox-open {
diff --git a/resources/mmv/mmv.lightboxinterface.less 
b/resources/mmv/mmv.lightboxinterface.less
index 78baa80..77d9354 100644
--- a/resources/mmv/mmv.lightboxinterface.less
+++ b/resources/mmv/mmv.lightboxinterface.less
@@ -1,8 +1,6 @@
 @import 'mmv.globals';
 @import 'mmv.mixins';
 
-@metadata-background: rgb( 248, 248, 248 );
-
 .mw-mmv-wrapper {
top: 0;
left: 0;
@@ -54,7 +52,7 @@
width: 100%;
bottom: auto;
height: auto;
-   color: #333;
+   color: #222;
background-color: 

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Hygiene: allow PageClients requestors to specify a/synchroni...

2017-03-02 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340904 )

Change subject: Hygiene: allow PageClients requestors to specify a/synchronicity
..

Hygiene: allow PageClients requestors to specify a/synchronicity

Bug: T156917
Change-Id: I470c3ecc2c18434d89c3f6c28b3db002201452a5
---
M 
app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwMobileViewPageLead.java
M app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwPageClient.java
M app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwPageService.java
M app/src/main/java/org/wikipedia/dataclient/page/PageClient.java
M app/src/main/java/org/wikipedia/dataclient/page/PageLead.java
M app/src/main/java/org/wikipedia/dataclient/page/PageLeadProperties.java
M app/src/main/java/org/wikipedia/dataclient/page/PageRemaining.java
M app/src/main/java/org/wikipedia/dataclient/page/PageSummary.java
M app/src/main/java/org/wikipedia/dataclient/restbase/page/RbPageClient.java
M app/src/main/java/org/wikipedia/dataclient/restbase/page/RbPageLead.java
M app/src/main/java/org/wikipedia/dataclient/restbase/page/RbPageService.java
M app/src/main/java/org/wikipedia/page/PageFragmentLoadState.java
M app/src/main/java/org/wikipedia/page/PageProperties.java
M app/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java
M app/src/main/java/org/wikipedia/widgets/WidgetProviderFeaturedPage.java
M app/src/main/java/org/wikipedia/wiktionary/WiktionaryDialog.java
16 files changed, 138 insertions(+), 220 deletions(-)


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

diff --git 
a/app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwMobileViewPageLead.java
 
b/app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwMobileViewPageLead.java
index 2da5c2f..23e9344 100644
--- 
a/app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwMobileViewPageLead.java
+++ 
b/app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwMobileViewPageLead.java
@@ -75,9 +75,8 @@
 public String getLeadSectionContent() {
 if (mobileview != null) {
 return mobileview.getSections().get(0).getContent();
-} else {
-return "";
 }
+return "";
 }
 
 @Nullable
@@ -188,7 +187,7 @@
 
 @Override
 @Nullable
-public String getLeadImageUrl() {
+public String getLeadImageUrl(int leadThumbnailWidth) {
 return thumb != null ? thumb.getUrl() : null;
 }
 
diff --git 
a/app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwPageClient.java 
b/app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwPageClient.java
index 50709c6..db13a09 100644
--- a/app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwPageClient.java
+++ b/app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwPageClient.java
@@ -4,6 +4,7 @@
 
 import org.wikipedia.dataclient.ServiceError;
 import org.wikipedia.dataclient.page.PageClient;
+import org.wikipedia.dataclient.page.PageCombo;
 import org.wikipedia.dataclient.page.PageLead;
 import org.wikipedia.dataclient.page.PageRemaining;
 import org.wikipedia.dataclient.page.PageSummary;
@@ -11,7 +12,6 @@
 import java.io.IOException;
 
 import retrofit2.Call;
-import retrofit2.Callback;
 import retrofit2.Response;
 
 /**
@@ -24,61 +24,25 @@
 this.service = service;
 }
 
-@Override
-public void pageSummary(String title, final PageSummary.Callback cb) {
-Call call = service.pageSummary(title);
-call.enqueue(new Callback() {
-@Override
-public void onResponse(Call call, 
Response response) {
-cb.success(response.body());
-}
-
-/**
- * Invoked when a network exception occurred talking to the server 
or when an unexpected
- * exception occurred creating the request or processing the 
response.
- */
-@Override
-public void onFailure(Call call, Throwable t) {
-cb.failure(t);
-}
-});
+@SuppressWarnings("unchecked")
+@NonNull @Override public Call summary(@NonNull 
String title) {
+return service.summary(title);
 }
 
-@Override
-public void pageLead(String title, int leadImageThumbWidth, boolean 
noImages,
- final PageLead.Callback cb) {
-Call call = service.pageLead(title, 
leadImageThumbWidth, optional(noImages));
-call.enqueue(new Callback() {
-@Override
-public void onResponse(Call call, 
Response response) {
-cb.success(response.body());
-}
-
-@Override
-public void onFailure(Call call, Throwable 
t) {
-cb.failure(t);
-}
-});
+@SuppressWarnings("unchecked")
+@NonNull @Override public Call lead(@NonNull String 
title,
+ 

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Revert "Test disable super_detect_noop script"

2017-03-02 Thread EBernhardson (Code Review)
Hello Florianschmidtwelzow, jenkins-bot, DCausse,

I'd like you to do a code review.  Please visit

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

to review the following change.


Change subject: Revert "Test disable super_detect_noop script"
..

Revert "Test disable super_detect_noop script"

Test is complete, everything looks like it will be ok
for a longer disable during the elasticsearch 2 -> 5
transition.

This reverts commit b9ffde9f15bacc7c3a23861ff255407ab621f1d8.

Change-Id: I0c9f634db073e0a5b8b597867c4be68bede0b513
---
M wmf-config/CirrusSearch-common.php
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/wmf-config/CirrusSearch-common.php 
b/wmf-config/CirrusSearch-common.php
index c59071c..681743c 100644
--- a/wmf-config/CirrusSearch-common.php
+++ b/wmf-config/CirrusSearch-common.php
@@ -131,7 +131,7 @@
'build',
'use',
],
-   //'super_detect_noop' => true,
+   'super_detect_noop' => true,
'id_hash_mod_filter' => true,
'documentVersion' => true,
 ];

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0c9f634db073e0a5b8b597867c4be68bede0b513
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: EBernhardson 
Gerrit-Reviewer: DCausse 
Gerrit-Reviewer: Florianschmidtwelzow 
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.29.0-wmf.14]: Fix Flow autoload data and gen-autoload.php

2017-03-02 Thread Mattflaschen (Code Review)
Mattflaschen has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340901 )

Change subject: Fix Flow autoload data and gen-autoload.php
..

Fix Flow autoload data and gen-autoload.php

Convert gen-autoload.php to standard maintenance script so it
loads autoloader (was getting P5012, not autoloaded).

Then fix the autoload data itself (regression from
9d087957aebaa28900033211936497df29f9e99a that removed
MaintenanceDebugLogger)

Change-Id: Ibbc95c2bdd0e7012cf05a6c9196869aed1e99989
(cherry picked from commit a2588a6d9b0971c59b07b699c836dfa0243834de)
---
M composer.json
M extension.json
M scripts/gen-autoload.php
3 files changed, 429 insertions(+), 415 deletions(-)


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

diff --git a/composer.json b/composer.json
index 1137f5c..f917e63 100644
--- a/composer.json
+++ b/composer.json
@@ -12,7 +12,7 @@
},
"scripts": {
"test": [
-   "parallel-lint . --exclude vendor/bin --exclude 
vendor/jakub-onderka --exclude node_modules"
+   "parallel-lint . --exclude vendor --exclude 
node_modules"
]
}
 }
diff --git a/extension.json b/extension.json
index a004a05..f3cc4ff 100644
--- a/extension.json
+++ b/extension.json
@@ -94,399 +94,6 @@
"FlowNamespaces": "Flow.namespaces.php",
"FlowAlias": "Flow.alias.php"
},
-   "AutoloadClasses": {
-   "ExternalStoreFlowMock": 
"tests/phpunit/Mock/ExternalStoreFlowMock.php",
-   "FlowHooks": "Hooks.php",
-   "Flow\\Actions\\EditAction": "includes/Actions/EditAction.php",
-   "Flow\\Actions\\FlowAction": "includes/Actions/Action.php",
-   "Flow\\Actions\\PurgeAction": 
"includes/Actions/PurgeAction.php",
-   "Flow\\Actions\\ViewAction": "includes/Actions/ViewAction.php",
-   "Flow\\Api\\ApiFlow": "includes/Api/ApiFlow.php",
-   "Flow\\Api\\ApiFlowBase": "includes/Api/ApiFlowBase.php",
-   "Flow\\Api\\ApiFlowBaseGet": "includes/Api/ApiFlowBaseGet.php",
-   "Flow\\Api\\ApiFlowBasePost": 
"includes/Api/ApiFlowBasePost.php",
-   "Flow\\Api\\ApiFlowEditHeader": 
"includes/Api/ApiFlowEditHeader.php",
-   "Flow\\Api\\ApiFlowEditPost": 
"includes/Api/ApiFlowEditPost.php",
-   "Flow\\Api\\ApiFlowEditTitle": 
"includes/Api/ApiFlowEditTitle.php",
-   "Flow\\Api\\ApiFlowEditTopicSummary": 
"includes/Api/ApiFlowEditTopicSummary.php",
-   "Flow\\Api\\ApiFlowLockTopic": 
"includes/Api/ApiFlowLockTopic.php",
-   "Flow\\Api\\ApiFlowModeratePost": 
"includes/Api/ApiFlowModeratePost.php",
-   "Flow\\Api\\ApiFlowModerateTopic": 
"includes/Api/ApiFlowModerateTopic.php",
-   "Flow\\Api\\ApiFlowNewTopic": 
"includes/Api/ApiFlowNewTopic.php",
-   "Flow\\Api\\ApiFlowReply": "includes/Api/ApiFlowReply.php",
-   "Flow\\Api\\ApiFlowSearch": "includes/Api/ApiFlowSearch.php",
-   "Flow\\Api\\ApiFlowUndoEditHeader": 
"includes/Api/ApiFlowUndoEditHeader.php",
-   "Flow\\Api\\ApiFlowUndoEditPost": 
"includes/Api/ApiFlowUndoEditPost.php",
-   "Flow\\Api\\ApiFlowUndoEditTopicSummary": 
"includes/Api/ApiFlowUndoEditTopicSummary.php",
-   "Flow\\Api\\ApiFlowViewHeader": 
"includes/Api/ApiFlowViewHeader.php",
-   "Flow\\Api\\ApiFlowViewPost": 
"includes/Api/ApiFlowViewPost.php",
-   "Flow\\Api\\ApiFlowViewPostHistory": 
"includes/Api/ApiFlowViewPostHistory.php",
-   "Flow\\Api\\ApiFlowViewTopic": 
"includes/Api/ApiFlowViewTopic.php",
-   "Flow\\Api\\ApiFlowViewTopicHistory": 
"includes/Api/ApiFlowViewTopicHistory.php",
-   "Flow\\Api\\ApiFlowViewTopicList": 
"includes/Api/ApiFlowViewTopicList.php",
-   "Flow\\Api\\ApiFlowViewTopicSummary": 
"includes/Api/ApiFlowViewTopicSummary.php",
-   "Flow\\Api\\ApiParsoidUtilsFlow": 
"includes/Api/ApiParsoidUtilsFlow.php",
-   "Flow\\Api\\ApiQueryPropFlowInfo": 
"includes/Api/ApiQueryPropFlowInfo.php",
-   "Flow\\BlockFactory": "includes/BlockFactory.php",
-   "Flow\\Block\\AbstractBlock": "includes/Block/Block.php",
-   "Flow\\Block\\Block": "includes/Block/Block.php",
-   "Flow\\Block\\BoardHistoryBlock": 
"includes/Block/BoardHistory.php",
-   "Flow\\Block\\HeaderBlock": "includes/Block/Header.php",
-   "Flow\\Block\\TopicBlock": "includes/Block/Topic.php",
-   "Flow\\Block\\TopicListBlock": "includes/Block/TopicList.php",
-   "Flow\\Block\\TopicSummaryBlock": 
"includes/Block/TopicSummary.php",
-   "Flow\\BoardMover": "includes/BoardMover.php",
-   

[MediaWiki-commits] [Gerrit] operations/puppet[production]: Gerrit: Add some apache rewrite rules for polygerrit

2017-03-02 Thread Paladox (Code Review)
Paladox has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340900 )

Change subject: Gerrit: Add some apache rewrite rules for polygerrit
..

Gerrit: Add some apache rewrite rules for polygerrit

Due to this https://bugs.chromium.org/p/gerrit/issues/detail?id=3795 bug 
prefixed urls will not work without the rewrite rules.

Note: This will not break gwt. As all we are doing is moving // to 
/r//**

Tested locally and managed to get polygerrit working.

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


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


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id0f5f4a07e3dbdb8ce61840bf5e189adfa754aab
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Paladox 
Gerrit-Reviewer: jenkins-bot <>

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


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

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

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


Merge branch 'master' into deployment

07ff70d Create table of blank addresses.
361717d Fix (most) missing names
42e6650 Extend fix to contacts that have been touched

Change-Id: I9f943ea4edd6d9c411928bd9848af3adb627d779
---
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/340899
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I9f943ea4edd6d9c411928bd9848af3adb627d779
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...Flow[master]: Fix Flow autoload data and gen-autoload.php

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

Change subject: Fix Flow autoload data and gen-autoload.php
..


Fix Flow autoload data and gen-autoload.php

Convert gen-autoload.php to standard maintenance script so it
loads autoloader (was getting P5012, not autoloaded).

Then fix the autoload data itself (regression from
9d087957aebaa28900033211936497df29f9e99a that removed
MaintenanceDebugLogger)

Change-Id: Ibbc95c2bdd0e7012cf05a6c9196869aed1e99989
---
M composer.json
M extension.json
M scripts/gen-autoload.php
3 files changed, 429 insertions(+), 415 deletions(-)

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



diff --git a/composer.json b/composer.json
index 1137f5c..f917e63 100644
--- a/composer.json
+++ b/composer.json
@@ -12,7 +12,7 @@
},
"scripts": {
"test": [
-   "parallel-lint . --exclude vendor/bin --exclude 
vendor/jakub-onderka --exclude node_modules"
+   "parallel-lint . --exclude vendor --exclude 
node_modules"
]
}
 }
diff --git a/extension.json b/extension.json
index bd4e5d0..9ab75e5 100644
--- a/extension.json
+++ b/extension.json
@@ -94,399 +94,6 @@
"FlowNamespaces": "Flow.namespaces.php",
"FlowAlias": "Flow.alias.php"
},
-   "AutoloadClasses": {
-   "ExternalStoreFlowMock": 
"tests/phpunit/Mock/ExternalStoreFlowMock.php",
-   "FlowHooks": "Hooks.php",
-   "Flow\\Actions\\EditAction": "includes/Actions/EditAction.php",
-   "Flow\\Actions\\FlowAction": "includes/Actions/Action.php",
-   "Flow\\Actions\\PurgeAction": 
"includes/Actions/PurgeAction.php",
-   "Flow\\Actions\\ViewAction": "includes/Actions/ViewAction.php",
-   "Flow\\Api\\ApiFlow": "includes/Api/ApiFlow.php",
-   "Flow\\Api\\ApiFlowBase": "includes/Api/ApiFlowBase.php",
-   "Flow\\Api\\ApiFlowBaseGet": "includes/Api/ApiFlowBaseGet.php",
-   "Flow\\Api\\ApiFlowBasePost": 
"includes/Api/ApiFlowBasePost.php",
-   "Flow\\Api\\ApiFlowEditHeader": 
"includes/Api/ApiFlowEditHeader.php",
-   "Flow\\Api\\ApiFlowEditPost": 
"includes/Api/ApiFlowEditPost.php",
-   "Flow\\Api\\ApiFlowEditTitle": 
"includes/Api/ApiFlowEditTitle.php",
-   "Flow\\Api\\ApiFlowEditTopicSummary": 
"includes/Api/ApiFlowEditTopicSummary.php",
-   "Flow\\Api\\ApiFlowLockTopic": 
"includes/Api/ApiFlowLockTopic.php",
-   "Flow\\Api\\ApiFlowModeratePost": 
"includes/Api/ApiFlowModeratePost.php",
-   "Flow\\Api\\ApiFlowModerateTopic": 
"includes/Api/ApiFlowModerateTopic.php",
-   "Flow\\Api\\ApiFlowNewTopic": 
"includes/Api/ApiFlowNewTopic.php",
-   "Flow\\Api\\ApiFlowReply": "includes/Api/ApiFlowReply.php",
-   "Flow\\Api\\ApiFlowSearch": "includes/Api/ApiFlowSearch.php",
-   "Flow\\Api\\ApiFlowUndoEditHeader": 
"includes/Api/ApiFlowUndoEditHeader.php",
-   "Flow\\Api\\ApiFlowUndoEditPost": 
"includes/Api/ApiFlowUndoEditPost.php",
-   "Flow\\Api\\ApiFlowUndoEditTopicSummary": 
"includes/Api/ApiFlowUndoEditTopicSummary.php",
-   "Flow\\Api\\ApiFlowViewHeader": 
"includes/Api/ApiFlowViewHeader.php",
-   "Flow\\Api\\ApiFlowViewPost": 
"includes/Api/ApiFlowViewPost.php",
-   "Flow\\Api\\ApiFlowViewPostHistory": 
"includes/Api/ApiFlowViewPostHistory.php",
-   "Flow\\Api\\ApiFlowViewTopic": 
"includes/Api/ApiFlowViewTopic.php",
-   "Flow\\Api\\ApiFlowViewTopicHistory": 
"includes/Api/ApiFlowViewTopicHistory.php",
-   "Flow\\Api\\ApiFlowViewTopicList": 
"includes/Api/ApiFlowViewTopicList.php",
-   "Flow\\Api\\ApiFlowViewTopicSummary": 
"includes/Api/ApiFlowViewTopicSummary.php",
-   "Flow\\Api\\ApiParsoidUtilsFlow": 
"includes/Api/ApiParsoidUtilsFlow.php",
-   "Flow\\Api\\ApiQueryPropFlowInfo": 
"includes/Api/ApiQueryPropFlowInfo.php",
-   "Flow\\BlockFactory": "includes/BlockFactory.php",
-   "Flow\\Block\\AbstractBlock": "includes/Block/Block.php",
-   "Flow\\Block\\Block": "includes/Block/Block.php",
-   "Flow\\Block\\BoardHistoryBlock": 
"includes/Block/BoardHistory.php",
-   "Flow\\Block\\HeaderBlock": "includes/Block/Header.php",
-   "Flow\\Block\\TopicBlock": "includes/Block/Topic.php",
-   "Flow\\Block\\TopicListBlock": "includes/Block/TopicList.php",
-   "Flow\\Block\\TopicSummaryBlock": 
"includes/Block/TopicSummary.php",
-   "Flow\\BoardMover": "includes/BoardMover.php",
-   "Flow\\Collection\\AbstractCollection": 
"includes/Collection/AbstractCollection.php",
-   

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

2017-03-02 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340899 )

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

Merge branch 'master' into deployment

07ff70d Create table of blank addresses.
361717d Fix (most) missing names
42e6650 Extend fix to contacts that have been touched

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


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/99/340899/1


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9f943ea4edd6d9c411928bd9848af3adb627d779
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] wikimedia...crm[master]: Extend fix to contacts that have been touched

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

Change subject: Extend fix to contacts that have been touched
..


Extend fix to contacts that have been touched

Civi nukes the sort and display fields, but they're still in the
log tables.

Bug: T159455
Change-Id: I25ad26701e586610faf8f1fa23d565e3ff4c41ca
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 15 insertions(+), 1 deletion(-)

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 9310130..fc54cd9 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2577,6 +2577,7 @@
  */
 function wmf_civicrm_update_7480() {
civicrm_initialize();
+   // First the easy ones
CRM_Core_DAO::executeQuery(
"UPDATE civicrm_contact
SET last_name = SUBSTRING_INDEX(sort_name, ', ', 1),
@@ -2585,7 +2586,20 @@
AND contact_type = 'Individual'
AND first_name IS NULL
AND last_name IS NULL
-   AND is_deleted = 0
AND sort_name LIKE '%, %' --leading % seems to be OK after all 
the other conditions
 ");
+   // Some of the contacts have been touched since creation, and Civi has 
helpfully
+   // destroyed the sort_name. log_civicrm_contact to the rescue!
+   CRM_Core_DAO::executeQuery(
+   "UPDATE civicrm_contact c
+   INNER JOIN log_civicrm_contact l ON c.id = l.id
+   SET c.last_name = SUBSTRING_INDEX(l.sort_name, ', ', 1),
+   c.first_name = SUBSTRING_INDEX(l.sort_name, ', ', -1)
+   WHERE c.created_date BETWEEN '2017-02-28' AND '2017-03-03'
+   AND c.contact_type = 'Individual'
+   AND c.first_name IS NULL
+   AND c.last_name IS NULL
+   AND c.sort_name NOT LIKE '%, %'
+   AND l.sort_name LIKE '%, %'
+");
 }

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...ParsoidBatchAPI[master]: Return "duration" and "size" for imageinfo requests

2017-03-02 Thread Arlolra (Code Review)
Arlolra has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340898 )

Change subject: Return "duration" and "size" for imageinfo requests
..

Return "duration" and "size" for imageinfo requests

 * Matches core commit 84d8b18b

Change-Id: I41cca6c6e2a3d96f75371f7276e00d0be52ae327
---
M includes/ApiParsoidBatch.php
1 file changed, 5 insertions(+), 1 deletion(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ParsoidBatchAPI 
refs/changes/98/340898/1

diff --git a/includes/ApiParsoidBatch.php b/includes/ApiParsoidBatch.php
index a8460aa..1f3cb80 100644
--- a/includes/ApiParsoidBatch.php
+++ b/includes/ApiParsoidBatch.php
@@ -275,13 +275,17 @@
$result = array(
'width' => $file->getWidth(),
'height' => $file->getHeight(),
+   'size' => $file->getSize(),
'mediatype' => $file->getMediaType(),
'mime' => $file->getMimeType(),
'url' => wfExpandUrl( $file->getFullUrl(), 
PROTO_CURRENT ),
'mustRender' => $file->mustRender(),
'badFile' => wfIsBadImage( $filename, $page ?: false ),
);
-
+   $length = $file->getLength();
+   if ( $length ) {
+   $result['duration'] = (float)$length;
+   }
$txopts = $this->makeTransformOptions( $file, $txopts );
$mto = $file->transform( $txopts );
if ( $mto ) {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I41cca6c6e2a3d96f75371f7276e00d0be52ae327
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ParsoidBatchAPI
Gerrit-Branch: master
Gerrit-Owner: Arlolra 

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: Extend fix to contacts that have been touched

2017-03-02 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340897 )

Change subject: Extend fix to contacts that have been touched
..

Extend fix to contacts that have been touched

Civi nukes the sort and display fields, but they're still in the
log tables.

Bug: T159455
Change-Id: I25ad26701e586610faf8f1fa23d565e3ff4c41ca
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 15 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/97/340897/1

diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 9310130..fc54cd9 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2577,6 +2577,7 @@
  */
 function wmf_civicrm_update_7480() {
civicrm_initialize();
+   // First the easy ones
CRM_Core_DAO::executeQuery(
"UPDATE civicrm_contact
SET last_name = SUBSTRING_INDEX(sort_name, ', ', 1),
@@ -2585,7 +2586,20 @@
AND contact_type = 'Individual'
AND first_name IS NULL
AND last_name IS NULL
-   AND is_deleted = 0
AND sort_name LIKE '%, %' --leading % seems to be OK after all 
the other conditions
 ");
+   // Some of the contacts have been touched since creation, and Civi has 
helpfully
+   // destroyed the sort_name. log_civicrm_contact to the rescue!
+   CRM_Core_DAO::executeQuery(
+   "UPDATE civicrm_contact c
+   INNER JOIN log_civicrm_contact l ON c.id = l.id
+   SET c.last_name = SUBSTRING_INDEX(l.sort_name, ', ', 1),
+   c.first_name = SUBSTRING_INDEX(l.sort_name, ', ', -1)
+   WHERE c.created_date BETWEEN '2017-02-28' AND '2017-03-03'
+   AND c.contact_type = 'Individual'
+   AND c.first_name IS NULL
+   AND c.last_name IS NULL
+   AND c.sort_name NOT LIKE '%, %'
+   AND l.sort_name LIKE '%, %'
+");
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I25ad26701e586610faf8f1fa23d565e3ff4c41ca
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
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] wikimedia...crm[master]: Fix (most) missing names

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

Change subject: Fix (most) missing names
..


Fix (most) missing names

Turns out we WERE filling in the sort name field after all.

Nice to have that nonstandard SUBSTRING_INDEX for splits in MariaDB!

Bug: T159455
Change-Id: Ief4e7fe566c8e8ebdb3652c3c43f3249c171a90a
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 21 insertions(+), 0 deletions(-)

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 712a6c9..9310130 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2568,3 +2568,24 @@
   );
 
 }
+
+
+/**
+ * Fill in missing first and last names from the sort_name field
+ *
+ * Bug: T159455
+ */
+function wmf_civicrm_update_7480() {
+   civicrm_initialize();
+   CRM_Core_DAO::executeQuery(
+   "UPDATE civicrm_contact
+   SET last_name = SUBSTRING_INDEX(sort_name, ', ', 1),
+   first_name = SUBSTRING_INDEX(sort_name, ', ', -1)
+   WHERE created_date BETWEEN '2017-02-28' AND '2017-03-03'
+   AND contact_type = 'Individual'
+   AND first_name IS NULL
+   AND last_name IS NULL
+   AND is_deleted = 0
+   AND sort_name LIKE '%, %' --leading % seems to be OK after all 
the other conditions
+");
+}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ief4e7fe566c8e8ebdb3652c3c43f3249c171a90a
Gerrit-PatchSet: 2
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] oojs/ui[master]: ComboBoxInputWidget: Improve documentation example

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

Change subject: ComboBoxInputWidget: Improve documentation example
..


ComboBoxInputWidget: Improve documentation example

* Remove ComboBoxInputWidget 'label' option from the example. While
  this is technically valid (inherited from TextInputWidget), it
  doesn't display correctly right now and we should not promote it.
* Use 'options' to provide the available options. The 'menu'/'items'
  methods is mostly supported from backwards compatibility, 'options'
  was added to provide a simpler and less error-prone method.
* Add some documentation about individual options' 'label'.
* Add an example that just sets options' 'data', without 'label'.
* Shorten unnecessarily long example.

Change-Id: I085b79bc5e426bff3dece04977637ce6b746c234
---
M src/widgets/ComboBoxInputWidget.js
1 file changed, 30 insertions(+), 25 deletions(-)

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



diff --git a/src/widgets/ComboBoxInputWidget.js 
b/src/widgets/ComboBoxInputWidget.js
index 5462ed8..16bb7a9 100644
--- a/src/widgets/ComboBoxInputWidget.js
+++ b/src/widgets/ComboBoxInputWidget.js
@@ -8,6 +8,10 @@
  * - by choosing a value from the menu. The value of the chosen option will 
then appear in the text
  *   input field.
  *
+ * After the user chooses an option, its `data` will be used as a new value 
for the widget.
+ * A `label` also can be specified for each option: if given, it will be shown 
instead of the
+ * `data` in the dropdown menu.
+ *
  * This widget can be used inside an HTML form, such as a OO.ui.FormLayout.
  *
  * For more information about menus and options, please see the [OOjs UI 
documentation on MediaWiki][1].
@@ -15,32 +19,33 @@
  * @example
  * // Example: A ComboBoxInputWidget.
  * var comboBox = new OO.ui.ComboBoxInputWidget( {
- * label: 'ComboBoxInputWidget',
  * value: 'Option 1',
- * menu: {
- * items: [
- * new OO.ui.MenuOptionWidget( {
- * data: 'Option 1',
- * label: 'Option One'
- * } ),
- * new OO.ui.MenuOptionWidget( {
- * data: 'Option 2',
- * label: 'Option Two'
- * } ),
- * new OO.ui.MenuOptionWidget( {
- * data: 'Option 3',
- * label: 'Option Three'
- * } ),
- * new OO.ui.MenuOptionWidget( {
- * data: 'Option 4',
- * label: 'Option Four'
- * } ),
- * new OO.ui.MenuOptionWidget( {
- * data: 'Option 5',
- * label: 'Option Five'
- * } )
- * ]
- * }
+ * options: [
+ * { data: 'Option 1' },
+ * { data: 'Option 2' },
+ * { data: 'Option 3' }
+ * ]
+ * } );
+ * $( 'body' ).append( comboBox.$element );
+ *
+ * @example
+ * // Example: A ComboBoxInputWidget with additional option labels.
+ * var comboBox = new OO.ui.ComboBoxInputWidget( {
+ * value: 'Option 1',
+ * options: [
+ * {
+ * data: 'Option 1',
+ * label: 'Option One'
+ * },
+ * {
+ * data: 'Option 2',
+ * label: 'Option Two'
+ * },
+ * {
+ * data: 'Option 3',
+ * label: 'Option Three'
+ * }
+ * ]
  * } );
  * $( 'body' ).append( comboBox.$element );
  *

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I085b79bc5e426bff3dece04977637ce6b746c234
Gerrit-PatchSet: 3
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński 
Gerrit-Reviewer: Bartosz Dziewoński 
Gerrit-Reviewer: Esanders 
Gerrit-Reviewer: Jforrester 
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] operations/puppet[production]: DHCP: Add DHCP entries for ms-be2028-msbe2039

2017-03-02 Thread Papaul (Code Review)
Papaul has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340896 )

Change subject: DHCP: Add DHCP entries for ms-be2028-msbe2039
..

DHCP: Add DHCP entries for ms-be2028-msbe2039

Bug:T158337
Change-Id: Id0f848b00aed518256bf470df0354310a080a8f0
---
M modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
1 file changed, 60 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/96/340896/1

diff --git a/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
index f9365bf..36baecd 100644
--- a/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -3656,6 +3656,66 @@
 fixed-address ms-be2027.codfw.wmnet;
 }
 
+host ms-be2028 {
+hardware ethernet e0:07:1b:ef:15:98;
+fixed-address ms-be2028.codfw.wmnet;
+}
+
+host ms-be2029 {
+hardware ethernet e0:07:1b:ef:55:40;
+fixed-address ms-be2029.codfw.wmnet;
+}
+
+host ms-be2030 {
+hardware ethernet e0:07:1b:ef:55:98;
+fixed-address ms-be2030.codfw.wmnet;
+}
+
+host ms-be2031 {
+hardware ethernet e0:07:1b:ef:b4:d8;
+fixed-address ms-be2031.codfw.wmnet;
+}
+
+host ms-be2032 {
+hardware ethernet e0:07:1b:ef:34:a0;
+fixed-address ms-be2032.codfw.wmnet;
+}
+
+host ms-be2033 {
+hardware ethernet e0:07:1b:ef:85:e0;
+fixed-address ms-be2033.codfw.wmnet;
+}
+
+host ms-be2034 {
+hardware ethernet e0:07:1b:ef:94:e0;
+fixed-address ms-be2034.codfw.wmnet;
+}
+
+host ms-be2035 {
+hardware ethernet e0:07:1b:ef:b4:d0;
+fixed-address ms-be2035.codfw.wmnet;
+}
+
+host ms-be2036 {
+hardware ethernet e0:07:1b:ef:54:e0;
+fixed-address ms-be2036.codfw.wmnet;
+}
+
+host ms-be2037 {
+hardware ethernet e0:07:1b:ef:b5:f8;
+fixed-address ms-be2037.codfw.wmnet;
+}
+
+host ms-be2038 {
+hardware ethernet e0:07:1b:ef:35:80;
+fixed-address ms-be2038.codfw.wmnet;
+}
+
+host ms-be2039 {
+hardware ethernet e0:07:1b:ef:26:70;
+fixed-address ms-be2039.codfw.wmnet;
+}
+
 host ms-be3001 {
 hardware ethernet 24:B6:FD:F6:13:AC;
 fixed-address ms-be3001.esams.wmnet;

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Use tabs for autoloader extension.json generation

2017-03-02 Thread Mattflaschen (Code Review)
Mattflaschen has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340895 )

Change subject: Use tabs for autoloader extension.json generation
..

Use tabs for autoloader extension.json generation

Change-Id: Icea381ae44a472c3e8b4c6f623d6e4849dcfa093
---
M includes/utils/AutoloadGenerator.php
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/95/340895/1

diff --git a/includes/utils/AutoloadGenerator.php 
b/includes/utils/AutoloadGenerator.php
index d7d7a60..1dac0b1 100644
--- a/includes/utils/AutoloadGenerator.php
+++ b/includes/utils/AutoloadGenerator.php
@@ -152,7 +152,7 @@
ksort( $json[$key] );
 
// Return the whole JSON file
-   return FormatJson::encode( $json, true ) . "\n";
+   return FormatJson::encode( $json, "\t", FormatJson::ALL_OK ) . 
"\n";
}
 
/**

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: RCFilters UI: Add highlight icon

2017-03-02 Thread Mooeypoo (Code Review)
Mooeypoo has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340894 )

Change subject: RCFilters UI: Add highlight icon
..

RCFilters UI: Add highlight icon

Bug: T149467
Change-Id: I8a38fd2a07b1d3516b21911ddcf4014a9015d48e
---
A resources/src/mediawiki.rcfilters/images/marker.svg
M 
resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterItemHighlightButton.less
M 
resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FilterItemHighlightButton.js
3 files changed, 46 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/94/340894/1

diff --git a/resources/src/mediawiki.rcfilters/images/marker.svg 
b/resources/src/mediawiki.rcfilters/images/marker.svg
new file mode 100644
index 000..b05a2d5
--- /dev/null
+++ b/resources/src/mediawiki.rcfilters/images/marker.svg
@@ -0,0 +1,41 @@
+
+http://purl.org/dc/elements/1.1/;
+   xmlns:cc="http://creativecommons.org/ns#;
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#;
+   xmlns:svg="http://www.w3.org/2000/svg;
+   xmlns="http://www.w3.org/2000/svg;
+   id="svg2"
+   version="1.1"
+   viewBox="0 0 24 24"
+   height="24"
+   width="24">
+  
+
+  
+image/svg+xml
+http://purl.org/dc/dcmitype/StillImage; />
+marker
+  
+
+  
+  
+  marker
+  Created with Sketch.
+  
+  
+
+  
+
diff --git 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterItemHighlightButton.less
 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterItemHighlightButton.less
index 3f70125..8b6ef3f 100644
--- 
a/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterItemHighlightButton.less
+++ 
b/resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterItemHighlightButton.less
@@ -1,6 +1,10 @@
 @import 'mw.rcfilters.mixins';
 
 .mw-rcfilters-ui-filterItemHighlightButton {
+   .oo-ui-iconElement-icon.oo-ui-icon-highlight {
+   /* @embed */
+   background-image: url(../images/marker.svg);
+   }
 
.oo-ui-buttonWidget.oo-ui-popupButtonWidget .oo-ui-buttonElement-button 
> &-circle {
display: inline-block;
diff --git 
a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FilterItemHighlightButton.js
 
b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FilterItemHighlightButton.js
index 34fa82e..17aad51 100644
--- 
a/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FilterItemHighlightButton.js
+++ 
b/resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FilterItemHighlightButton.js
@@ -16,7 +16,7 @@
 
// Parent
mw.rcfilters.ui.FilterItemHighlightButton.parent.call( this, 
$.extend( {}, config, {
-   icon: 'edit',
+   icon: 'highlight',
indicator: 'down',
popup: {
anchor: false,

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8a38fd2a07b1d3516b21911ddcf4014a9015d48e
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] operations/puppet[production]: confd: define srv_dns at all sites

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

Change subject: confd: define srv_dns at all sites
..


confd: define srv_dns at all sites

When these aren't defined, it ends up defaulting to $::domain,
which only works for private-network hosts, but fails (by trying
to use wikimedia.org) for public-facing hosts.

Change-Id: If2061bf92860848961e78269becebfc1cf717b11
---
A hieradata/codfw/confd.yaml
A hieradata/esams/confd.yaml
A hieradata/ulsfo/confd.yaml
3 files changed, 3 insertions(+), 0 deletions(-)

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



diff --git a/hieradata/codfw/confd.yaml b/hieradata/codfw/confd.yaml
new file mode 100644
index 000..81a5d89
--- /dev/null
+++ b/hieradata/codfw/confd.yaml
@@ -0,0 +1 @@
+confd::srv_dns: 'codfw.wmnet'
diff --git a/hieradata/esams/confd.yaml b/hieradata/esams/confd.yaml
new file mode 100644
index 000..a46358a
--- /dev/null
+++ b/hieradata/esams/confd.yaml
@@ -0,0 +1 @@
+confd::srv_dns: 'esams.wmnet'
diff --git a/hieradata/ulsfo/confd.yaml b/hieradata/ulsfo/confd.yaml
new file mode 100644
index 000..0c8b1ba
--- /dev/null
+++ b/hieradata/ulsfo/confd.yaml
@@ -0,0 +1 @@
+confd::srv_dns: 'ulsfo.wmnet'

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If2061bf92860848961e78269becebfc1cf717b11
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: BBlack 
Gerrit-Reviewer: BBlack 
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] VisualEditor/VisualEditor[master]: DiffElement: Measure box-shadow borders in pixels to avoid b...

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

Change subject: DiffElement: Measure box-shadow borders in pixels to avoid 
blurring
..


DiffElement: Measure box-shadow borders in pixels to avoid blurring

Change-Id: I7217c265d8382ebc3042026124a97771e0c91159
---
M src/ui/styles/elements/ve.ui.DiffElement.css
1 file changed, 4 insertions(+), 4 deletions(-)

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



diff --git a/src/ui/styles/elements/ve.ui.DiffElement.css 
b/src/ui/styles/elements/ve.ui.DiffElement.css
index 04c3688..fd7de8f 100644
--- a/src/ui/styles/elements/ve.ui.DiffElement.css
+++ b/src/ui/styles/elements/ve.ui.DiffElement.css
@@ -22,7 +22,7 @@
 table[data-diff-action='insert'] > caption,
 figure[data-diff-action='insert'] > figcaption {
background-color: #7fd7c4 !important; /* stylelint-disable-line 
declaration-no-important */
-   box-shadow: 0 0 0 0.1em #7fd7c4;
+   box-shadow: 0 0 0 1px #7fd7c4;
 }
 
 [data-diff-action='remove'],
@@ -30,12 +30,12 @@
 table[data-diff-action='remove'] > caption,
 figure[data-diff-action='remove'] > figcaption {
background-color: #e88e89 !important; /* stylelint-disable-line 
declaration-no-important */
-   box-shadow: 0 0 0 0.1em #e88e89;
+   box-shadow: 0 0 0 1px #e88e89;
 }
 
 [data-diff-action='change-insert'] {
background-color: #8ab4e8 !important; /* stylelint-disable-line 
declaration-no-important */
-   box-shadow: 0 0 0 0.1em #8ab4e8;
+   box-shadow: 0 0 0 1px #8ab4e8;
 }
 
 [data-diff-action='change-remove'] {
@@ -58,7 +58,7 @@
 [data-diff-action='insert'] + [data-diff-action='remove'],
 [data-diff-action='remove'] + [data-diff-action='change-insert'],
 [data-diff-action='insert'] + [data-diff-action='change-remove'] {
-   margin-left: 0.2em;
+   margin-left: 2px;
 }
 
 [data-diff-action='none'] {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7217c265d8382ebc3042026124a97771e0c91159
Gerrit-PatchSet: 4
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: 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]: [WIP] startup: Drop support for ES3 browsers

2017-03-02 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340893 )

Change subject: [WIP] startup: Drop support for ES3 browsers
..

[WIP] startup: Drop support for ES3 browsers

Bug: T128115
Change-Id: I95400637d1b85d2c607cd91bcb39ce21733295c8
---
M RELEASE-NOTES-1.29
M resources/Resources.php
M resources/ResourcesOOUI.php
D resources/lib/es5-shim/es5-shim.js
D resources/src/es5-skip.js
D resources/src/polyfill-object-create.js
M resources/src/startup.js
M tests/qunit/suites/resources/startup.test.js
8 files changed, 26 insertions(+), 2,154 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/93/340893/1

diff --git a/RELEASE-NOTES-1.29 b/RELEASE-NOTES-1.29
index 9883474..7116067 100644
--- a/RELEASE-NOTES-1.29
+++ b/RELEASE-NOTES-1.29
@@ -244,6 +244,8 @@
 * User::comparePasswords() (deprecated in 1.24) was removed.
 * ArchivedFile::getUserText() (deprecated in 1.23) was removed.
 * HTMLFileCache::newFromTitle() (deprecated in 1.24) was removed.
+* Browser support for non-ES5 browsers, including Android 2, Opera 12, and
+  Internet Explorer 9, was lowered from Grade A to Grade C.
 
 == Compatibility ==
 
diff --git a/resources/Resources.php b/resources/Resources.php
index bd56a10..9e0adee 100644
--- a/resources/Resources.php
+++ b/resources/Resources.php
@@ -2474,14 +2474,12 @@
'oojs-ui-core',
],
],
+
/* es5-shim */
+   // Deprecated since MediaWiki 1.29.0
'es5-shim' => [
-   'scripts' => [
-   'resources/lib/es5-shim/es5-shim.js',
-   'resources/src/polyfill-object-create.js',
-   ],
+   'deprecated' => 'Use of the "es5-shim" MediaWiki module is 
deprecated since MediaWiki 1.29.0',
'targets' => [ 'desktop', 'mobile' ],
-   'skipFunction' => 'resources/src/es5-skip.js',
],
 
/* dom-level2-shim */
@@ -2498,9 +2496,6 @@
'resources/src/oojs-global.js',
],
'targets' => [ 'desktop', 'mobile' ],
-   'dependencies' => [
-   'es5-shim',
-   ],
],
 
'mediawiki.router' => [
diff --git a/resources/ResourcesOOUI.php b/resources/ResourcesOOUI.php
index c3a287d..9339e98 100644
--- a/resources/ResourcesOOUI.php
+++ b/resources/ResourcesOOUI.php
@@ -65,7 +65,6 @@
],
'skinScripts' => $getSkinSpecific( null, 'js' ),
'dependencies' => [
-   'es5-shim',
'oojs',
'oojs-ui-core.styles',
'oojs-ui.styles.icons',
diff --git a/resources/lib/es5-shim/es5-shim.js 
b/resources/lib/es5-shim/es5-shim.js
deleted file mode 100644
index 91a7a39..000
--- a/resources/lib/es5-shim/es5-shim.js
+++ /dev/null
@@ -1,2051 +0,0 @@
-/*!
- * https://github.com/es-shims/es5-shim
- * @license es5-shim Copyright 2009-2015 by contributors, MIT License
- * see https://github.com/es-shims/es5-shim/blob/master/LICENSE
- */
-
-// vim: ts=4 sts=4 sw=4 expandtab
-
-// Add semicolon to prevent IIFE from being passed as argument to concatenated 
code.
-;
-
-// UMD (Universal Module Definition)
-// see https://github.com/umdjs/umd/blob/master/templates/returnExports.js
-(function (root, factory) {
-'use strict';
-
-/* global define, exports, module */
-if (typeof define === 'function' && define.amd) {
-// AMD. Register as an anonymous module.
-define(factory);
-} else if (typeof exports === 'object') {
-// Node. Does not work with strict CommonJS, but
-// only CommonJS-like enviroments that support module.exports,
-// like Node.
-module.exports = factory();
-} else {
-// Browser globals (root is window)
-root.returnExports = factory();
-}
-}(this, function () {
-
-/**
- * Brings an environment as close to ECMAScript 5 compliance
- * as is possible with the facilities of erstwhile engines.
- *
- * Annotated ES5: http://es5.github.com/ (specific links below)
- * ES5 Spec: 
http://www.ecma-international.org/publications/files/ECMA-ST/Ecma-262.pdf
- * Required reading: 
http://javascriptweblog.wordpress.com/2011/12/05/extending-javascript-natives/
- */
-
-// Shortcut to an often accessed properties, in order to avoid multiple
-// dereference that costs universally. This also holds a reference to 
known-good
-// functions.
-var $Array = Array;
-var ArrayPrototype = $Array.prototype;
-var $Object = Object;
-var ObjectPrototype = $Object.prototype;
-var $Function = Function;
-var FunctionPrototype = $Function.prototype;
-var $String = String;
-var StringPrototype = $String.prototype;
-var $Number = Number;
-var NumberPrototype = $Number.prototype;
-var array_slice = ArrayPrototype.slice;
-var array_splice = 

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: startup: Drop JavaScript support for browsers with DOM level 2

2017-03-02 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340892 )

Change subject: startup: Drop JavaScript support for browsers with DOM level 2
..

startup: Drop JavaScript support for browsers with DOM level 2

In practice, this means nothing, as the main browsers affected
were Internet Explorer 8 and early versions of Android (before
1.6), which are already Grade C.

Change-Id: I4488402686c8b9fefa0af5fed3c9a4b83cbff798
---
M resources/Resources.php
D resources/src/dom-level2-skip.js
D resources/src/polyfill-nodeTypes.js
M tests/qunit/QUnitTestResources.php
4 files changed, 2 insertions(+), 34 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/92/340892/1

diff --git a/resources/Resources.php b/resources/Resources.php
index 5406480..bd56a10 100644
--- a/resources/Resources.php
+++ b/resources/Resources.php
@@ -251,7 +251,6 @@
'scripts' => 'resources/src/jquery/jquery.highlightText.js',
'dependencies' => [
'mediawiki.RegExp',
-   'dom-level2-shim',
],
'targets' => [ 'desktop', 'mobile' ],
],
@@ -345,7 +344,6 @@
'styles' => 'resources/src/jquery/jquery.tablesorter.less',
'messages' => [ 'sort-descending', 'sort-ascending' ],
'dependencies' => [
-   'dom-level2-shim',
'mediawiki.RegExp',
'mediawiki.language.months',
],
@@ -937,7 +935,6 @@
'mediawiki.api.upload' => [
'scripts' => 'resources/src/mediawiki/api/upload.js',
'dependencies' => [
-   'dom-level2-shim',
'mediawiki.api',
'mediawiki.api.edit',
],
@@ -1220,7 +1217,6 @@
'mediawiki.Upload' => [
'scripts' => 'resources/src/mediawiki/mediawiki.Upload.js',
'dependencies' => [
-   'dom-level2-shim',
'mediawiki.api.upload',
],
],
@@ -1612,7 +1608,6 @@
'mediawiki.util',
'mediawiki.language',
'user.options',
-   'dom-level2-shim',
],
'targets' => [ 'desktop', 'mobile' ],
],
@@ -2490,11 +2485,10 @@
],
 
/* dom-level2-shim */
-   // IE 8
+   // Deprecated since MediaWiki 1.29.0
'dom-level2-shim' => [
-   'scripts' => 'resources/src/polyfill-nodeTypes.js',
+   'deprecated' => 'Use of the "dom-level2-shim" MediaWiki module 
is deprecated since MediaWiki 1.29.0',
'targets' => [ 'desktop', 'mobile' ],
-   'skipFunction' => 'resources/src/dom-level2-skip.js',
],
 
/* OOjs */
diff --git a/resources/src/dom-level2-skip.js b/resources/src/dom-level2-skip.js
deleted file mode 100644
index 484c295..000
--- a/resources/src/dom-level2-skip.js
+++ /dev/null
@@ -1,6 +0,0 @@
-/*!
- * Skip function for dom-level2-shim module.
- *
- * Tests for window.Node because that's the only thing that this shim is 
adding.
- */
-return !!window.Node;
diff --git a/resources/src/polyfill-nodeTypes.js 
b/resources/src/polyfill-nodeTypes.js
deleted file mode 100644
index c8acc86..000
--- a/resources/src/polyfill-nodeTypes.js
+++ /dev/null
@@ -1,19 +0,0 @@
-/**
- * Adds window.Node with node types according to:
- * https://www.w3.org/TR/DOM-Level-2-Core/core.html#ID-1950641247
- */
-
-window.Node = window.Node || {
-   ELEMENT_NODE: 1,
-   ATTRIBUTE_NODE: 2,
-   TEXT_NODE: 3,
-   CDATA_SECTION_NODE: 4,
-   ENTITY_REFERENCE_NODE: 5,
-   ENTITY_NODE: 6,
-   PROCESSING_INSTRUCTION_NODE: 7,
-   COMMENT_NODE: 8,
-   DOCUMENT_NODE: 9,
-   DOCUMENT_TYPE_NODE: 10,
-   DOCUMENT_FRAGMENT_NODE: 11,
-   NOTATION_NODE: 12
-};
diff --git a/tests/qunit/QUnitTestResources.php 
b/tests/qunit/QUnitTestResources.php
index 94d25ee..0bd190b 100644
--- a/tests/qunit/QUnitTestResources.php
+++ b/tests/qunit/QUnitTestResources.php
@@ -32,7 +32,6 @@
'mediawiki.page.ready',
'mediawiki.page.startup',
'test.sinonjs',
-   'dom-level2-shim',
],
'position' => 'top',
'targets' => [ 'desktop', 'mobile' ],

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

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

___
MediaWiki-commits mailing 

[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: Fix missing names

2017-03-02 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340891 )

Change subject: Fix missing names
..

Fix missing names

Turns out we WERE filling in the sort name field after all.

Nice to have that nonstandard SUBSTRING_INDEX for splits in MariaDB!

Bug: T159455
Change-Id: Ief4e7fe566c8e8ebdb3652c3c43f3249c171a90a
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 19 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/91/340891/1

diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 712a6c9..393b51e 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -2568,3 +2568,22 @@
   );
 
 }
+
+
+/**
+ * Fill in missing first and last names from the sort_name field
+ *
+ * Bug: T159455
+ */
+function wmf_civicrm_update_7480() {
+   civicrm_initialize();
+   CRM_Core_DAO::executeQuery(
+   "UPDATE civicrm_contact
+   SET last_name = SUBSTRING_INDEX(sort_name, ', ', 1),
+   first_name = SUBSTRING_INDEX(sort_name, ', ', -1)
+   WHERE created_date BETWEEN '2017-02-28' AND '2017-03-03'
+   AND contact_type = 'Individual'
+   AND first_name IS NULL
+   AND last_name IS NULL
+");
+}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ief4e7fe566c8e8ebdb3652c3c43f3249c171a90a
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
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] operations/puppet[production]: confd: define srv_dns at all sites

2017-03-02 Thread BBlack (Code Review)
BBlack has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340890 )

Change subject: confd: define srv_dns at all sites
..

confd: define srv_dns at all sites

When these aren't defined, it ends up defaulting to $::domain,
which only works for private-network hosts, but fails (by trying
to use wikimedia.org) for public-facing hosts.

Change-Id: If2061bf92860848961e78269becebfc1cf717b11
---
A hieradata/codfw/confd.yaml
A hieradata/esams/confd.yaml
A hieradata/ulsfo/confd.yaml
3 files changed, 3 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/90/340890/1

diff --git a/hieradata/codfw/confd.yaml b/hieradata/codfw/confd.yaml
new file mode 100644
index 000..81a5d89
--- /dev/null
+++ b/hieradata/codfw/confd.yaml
@@ -0,0 +1 @@
+confd::srv_dns: 'codfw.wmnet'
diff --git a/hieradata/esams/confd.yaml b/hieradata/esams/confd.yaml
new file mode 100644
index 000..a46358a
--- /dev/null
+++ b/hieradata/esams/confd.yaml
@@ -0,0 +1 @@
+confd::srv_dns: 'esams.wmnet'
diff --git a/hieradata/ulsfo/confd.yaml b/hieradata/ulsfo/confd.yaml
new file mode 100644
index 000..0c8b1ba
--- /dev/null
+++ b/hieradata/ulsfo/confd.yaml
@@ -0,0 +1 @@
+confd::srv_dns: 'ulsfo.wmnet'

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: If2061bf92860848961e78269becebfc1cf717b11
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] operations/puppet[production]: Linting fixes (multiple modules)

2017-03-02 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/334317 )

Change subject: Linting fixes (multiple modules)
..


Linting fixes (multiple modules)

Fixes for aptrepo beta calico camus cassandra cgred changeprop clush
confluent

Fix ${$mirror_name} variable references

Use full names for class names, as relative names are not allowed in
future Puppet versions

Add trailing commas to abide by the Coding Style guidelines

Bug: T93645
Change-Id: I1fa5f6dd28bd02b818c27778353aa5823e2a19fd
---
M modules/beta/manifests/autoupdater.pp
M modules/calico/manifests/init.pp
M modules/camus/manifests/job.pp
M modules/cassandra/manifests/instance.pp
M modules/cgred/manifests/group.pp
M modules/changeprop/manifests/init.pp
M modules/clush/manifests/master.pp
M modules/confluent/manifests/kafka/broker.pp
M modules/confluent/manifests/kafka/mirror/instance.pp
9 files changed, 11 insertions(+), 11 deletions(-)

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



diff --git a/modules/beta/manifests/autoupdater.pp 
b/modules/beta/manifests/autoupdater.pp
index c5fb195..e39c42b 100644
--- a/modules/beta/manifests/autoupdater.pp
+++ b/modules/beta/manifests/autoupdater.pp
@@ -4,7 +4,7 @@
 # cluster. This is the lame way to automatically pull any code merged in master
 # branches.
 class beta::autoupdater {
-require scap::scripts
+require ::scap::scripts
 
 $stage_dir = '/srv/mediawiki-staging'
 
@@ -59,7 +59,7 @@
 
 file { "${stage_dir}/docroot/wwwportal/portal-master":
 ensure => 'link',
-target => '../../portal-master/prod'
+target => '../../portal-master/prod',
 }
 
 file { "${stage_dir}/php-master/LocalSettings.php":
diff --git a/modules/calico/manifests/init.pp b/modules/calico/manifests/init.pp
index c885cce..d66dc9e 100644
--- a/modules/calico/manifests/init.pp
+++ b/modules/calico/manifests/init.pp
@@ -52,6 +52,6 @@
 base::service_unit { 'calico-node':
 ensure  => present,
 systemd => true,
-require => Package["${registry}/calico/node"]
+require => Package["${registry}/calico/node"],
 }
 }
diff --git a/modules/camus/manifests/job.pp b/modules/camus/manifests/job.pp
index 24be30f..84d7ef3 100644
--- a/modules/camus/manifests/job.pp
+++ b/modules/camus/manifests/job.pp
@@ -65,7 +65,7 @@
 $weekday= undef,
 )
 {
-require camus
+require ::camus
 
 $properties_file = "${camus::config_directory}/${title}.properties"
 $log_file= "${camus::log_directory}/${title}.log"
diff --git a/modules/cassandra/manifests/instance.pp 
b/modules/cassandra/manifests/instance.pp
index d82a0a1..d130c24 100644
--- a/modules/cassandra/manifests/instance.pp
+++ b/modules/cassandra/manifests/instance.pp
@@ -53,7 +53,7 @@
 interface::ip { "cassandra-${instance_name}_rpc_${rpc_interface}":
 interface => $rpc_interface,
 address   => $rpc_address,
-prefixlen => '32'
+prefixlen => '32',
 }
 }
 
diff --git a/modules/cgred/manifests/group.pp b/modules/cgred/manifests/group.pp
index 5a1d237..760cd24 100644
--- a/modules/cgred/manifests/group.pp
+++ b/modules/cgred/manifests/group.pp
@@ -46,7 +46,7 @@
 )
 {
 
-include cgred
+include ::cgred
 file {"/etc/cgconfig.d/${name}.conf":
 ensure  => $ensure,
 mode=> '0444',
diff --git a/modules/changeprop/manifests/init.pp 
b/modules/changeprop/manifests/init.pp
index 94ef5e7..dde12c4 100644
--- a/modules/changeprop/manifests/init.pp
+++ b/modules/changeprop/manifests/init.pp
@@ -55,7 +55,7 @@
 auto_refresh  => false,
 init_restart  => false,
 environment   => {
-'UV_THREADPOOL_SIZE' => 128
+'UV_THREADPOOL_SIZE' => 128,
 },
 }
 
diff --git a/modules/clush/manifests/master.pp 
b/modules/clush/manifests/master.pp
index 9585b2e..8d57e6e 100644
--- a/modules/clush/manifests/master.pp
+++ b/modules/clush/manifests/master.pp
@@ -59,7 +59,7 @@
 # someone can MITM us here we are screwed
 # anyway.
 'ssh_options' => "-i /root/.ssh/${username} 
-oStrictHostKeyChecking=no",
-}
+},
 }
 
 file { '/etc/clustershell/clush.conf':
diff --git a/modules/confluent/manifests/kafka/broker.pp 
b/modules/confluent/manifests/kafka/broker.pp
index 54cd4b5..6716ea9 100644
--- a/modules/confluent/manifests/kafka/broker.pp
+++ b/modules/confluent/manifests/kafka/broker.pp
@@ -258,7 +258,7 @@
 group { 'kafka':
 ensure  => 'present',
 system  => true,
-require => Class['confluent::kafka::client']
+require => Class['confluent::kafka::client'],
 }
 # Kafka system user
 user { 'kafka':
diff --git a/modules/confluent/manifests/kafka/mirror/instance.pp 
b/modules/confluent/manifests/kafka/mirror/instance.pp
index 

[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Remove Flow from Meta-Wiki

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

Change subject: Remove Flow from Meta-Wiki
..


Remove Flow from Meta-Wiki

Bug: T63729
Change-Id: I470ea3bd98b0b5dbac5c4252928f856baa0658fc
---
M dblists/flow.dblist
M dblists/nonflow.dblist
2 files changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/dblists/flow.dblist b/dblists/flow.dblist
index 884dbbe..b24583d 100644
--- a/dblists/flow.dblist
+++ b/dblists/flow.dblist
@@ -450,7 +450,6 @@
 map_bmswiki
 mdfwiki
 mediawikiwiki
-metawiki
 mgwiki
 mgwikibooks
 mgwiktionary
diff --git a/dblists/nonflow.dblist b/dblists/nonflow.dblist
index 9aad73e..e1069d1 100644
--- a/dblists/nonflow.dblist
+++ b/dblists/nonflow.dblist
@@ -4,7 +4,8 @@
 enwiki
 enwikiversity
 jawikiversity
-loginwiki
-votewiki
 labswiki
 labtestwiki
+loginwiki
+metawiki
+votewiki
\ No newline at end of file

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I470ea3bd98b0b5dbac5c4252928f856baa0658fc
Gerrit-PatchSet: 4
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: MarcoAurelio 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: Dereckson 
Gerrit-Reviewer: MZMcBride 
Gerrit-Reviewer: Nemo bis 
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]: Add current license hashes to repo to ensure auto-downloadin...

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

Change subject: Add current license hashes to repo to ensure auto-downloading 
in CI
..


Add current license hashes to repo to ensure auto-downloading in CI

Gradle will automatically download missing SDK packages when a build is
run, but only provided the relevant licenses are accepted.  We can avoid
the need for manual intervention for license acceptance by keeping an up-
to-date copy of a /licenses directory that can be symlinked from the SDK
/licenses directory on integration-slave-jessie-android.[1]

Example update command:
rm -rf licenses/ && cp -a $ANDROID_HOME/licenses .

[1] https://code.google.com/p/android/issues/detail?id=212128#c21

Bug: T147099
Change-Id: I1cad5f62404096d59ad3b37672c2405730b97226
---
A licenses/android-sdk-license
A licenses/android-sdk-preview-license
A licenses/intel-android-extra-license
3 files changed, 4 insertions(+), 0 deletions(-)

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



diff --git a/licenses/android-sdk-license b/licenses/android-sdk-license
new file mode 100644
index 000..e7327c5
--- /dev/null
+++ b/licenses/android-sdk-license
@@ -0,0 +1 @@
+8933bad161af4178b1185d1a37fbf41ea5269c55
\ No newline at end of file
diff --git a/licenses/android-sdk-preview-license 
b/licenses/android-sdk-preview-license
new file mode 100644
index 000..da4552d
--- /dev/null
+++ b/licenses/android-sdk-preview-license
@@ -0,0 +1,2 @@
+
+84831b9409646a918e30573bab4c9c91346d8abd
\ No newline at end of file
diff --git a/licenses/intel-android-extra-license 
b/licenses/intel-android-extra-license
new file mode 100644
index 000..206e5a9
--- /dev/null
+++ b/licenses/intel-android-extra-license
@@ -0,0 +1 @@
+d975f751698a77b662f1254ddbeed3901e976f5a
\ No newline at end of file

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

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

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


[MediaWiki-commits] [Gerrit] wikimedia...crm[master]: WIP Test more fields on import

2017-03-02 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340885 )

Change subject: WIP Test more fields on import
..

WIP Test more fields on import

Errr, dang. I thought this would fail without being rebased on top of
awight's fix

Change-Id: I4d595f751866b3eb135d421ac21018b30a998d14
---
M sites/all/modules/queue2civicrm/tests/phpunit/ProcessMessageTest.php
1 file changed, 32 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/85/340885/1

diff --git 
a/sites/all/modules/queue2civicrm/tests/phpunit/ProcessMessageTest.php 
b/sites/all/modules/queue2civicrm/tests/phpunit/ProcessMessageTest.php
index c1d2284..7df0dd4 100644
--- a/sites/all/modules/queue2civicrm/tests/phpunit/ProcessMessageTest.php
+++ b/sites/all/modules/queue2civicrm/tests/phpunit/ProcessMessageTest.php
@@ -81,17 +81,46 @@
 
 $contribution = civicrm_api3('Contribution', 'getsingle', array(
   wmf_civicrm_get_custom_field_name('gateway_txn_id') => 
$message->getGatewayTxnId(),
-  'return' => array(wmf_civicrm_get_custom_field_name('Campaign'), 
'total_amount'),
 ));
 
$this->assertEmpty($contribution[wmf_civicrm_get_custom_field_name('campaign')] 
);
+$expected = array(
+  'contact_type' => 'Individual',
+  'sort_name' => 'laast, firrst',
+  'display_name' => 'firrst laast',
+  'currency' => 'USD',
+  'total_amount' => '400.00',
+  'fee_amount' => '0.00',
+  'net_amount' => '400.00',
+  'trxn_id' => 'GLOBALCOLLECT ' . $message->getGatewayTxnId(),
+  'contribution_source' => 'USD 400',
+  'financial_type' => 'Cash',
+  'accounting_code' => 'CASH',
+  'contribution_status' => 'Completed',
+  'payment_instrument' => 'Credit Card: Visa'
+);
+$this->assertArraySubset( $expected, $contribution );
 
 $contribution2 = civicrm_api3('Contribution', 'getsingle', array(
   wmf_civicrm_get_custom_field_name('gateway_txn_id') => 
$message2->getGatewayTxnId(),
-  'return' => array(wmf_civicrm_get_custom_field_name('Campaign'), 
'total_amount'),
 ));
 
 $this->assertEquals('Benefactor Gift', 
$contribution2[wmf_civicrm_get_custom_field_name('campaign')] );
-
+$expected = array(
+  'contact_type' => 'Individual',
+  'sort_name' => 'laast, firrst',
+  'display_name' => 'firrst laast',
+  'currency' => 'USD',
+  'total_amount' => '2857.02',
+  'fee_amount' => '0.00',
+  'net_amount' => '2857.02',
+  'trxn_id' => 'GLOBALCOLLECT ' . $message2->getGatewayTxnId(),
+  'contribution_source' => 'PLN 952.34',
+  'financial_type' => 'Cash',
+  'accounting_code' => 'CASH',
+  'contribution_status' => 'Completed',
+  'payment_instrument' => 'Credit Card: Visa'
+);
+$this->assertArraySubset( $expected, $contribution2 );
 $this->assertNotEquals( $contribution['contact_id'], 
$contribution2['contact_id'] );
 }
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4d595f751866b3eb135d421ac21018b30a998d14
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
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]: Hygiene: remove duplicate method in WidgetProviderFeaturedPage

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

Change subject: Hygiene: remove duplicate method in WidgetProviderFeaturedPage
..


Hygiene: remove duplicate method in WidgetProviderFeaturedPage

Bug: T156917
Change-Id: Ifd56396118d2103635a58ed81bee622cc3e6c9ef
---
M app/src/main/java/org/wikipedia/widgets/WidgetProviderFeaturedPage.java
1 file changed, 1 insertion(+), 7 deletions(-)

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



diff --git 
a/app/src/main/java/org/wikipedia/widgets/WidgetProviderFeaturedPage.java 
b/app/src/main/java/org/wikipedia/widgets/WidgetProviderFeaturedPage.java
index f991505..7ca5dc6 100644
--- a/app/src/main/java/org/wikipedia/widgets/WidgetProviderFeaturedPage.java
+++ b/app/src/main/java/org/wikipedia/widgets/WidgetProviderFeaturedPage.java
@@ -6,7 +6,6 @@
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
-import android.content.res.Resources;
 import android.text.Spanned;
 import android.text.TextUtils;
 import android.text.style.URLSpan;
@@ -76,7 +75,7 @@
 MainPageNameData.valueFor(app.getAppOrSystemLanguageCode()),
 app.getWikiSite());
 
-getApiService(title).pageLead(title.getPrefixedText(), 
calculateLeadImageWidth(),
+getApiService(title).pageLead(title.getPrefixedText(), 
DimenUtil.calculateLeadImageWidth(),
 !app.isImageDownloadEnabled(), new PageLead.Callback() {
 @Override
 public void success(PageLead pageLead) {
@@ -119,11 +118,6 @@
 }
 }
 return titleText;
-}
-
-private int calculateLeadImageWidth() {
-Resources res = WikipediaApp.getInstance().getResources();
-return (int) (res.getDimension(R.dimen.leadImageWidth) / 
DimenUtil.getDensityScalar());
 }
 
 private PageService getApiService(PageTitle title) {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ifd56396118d2103635a58ed81bee622cc3e6c9ef
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Niedzielski 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Sniedzielski 
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]: resourceloader: Add purgeModuleDeps.php maintenance script

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

Change subject: resourceloader: Add purgeModuleDeps.php maintenance script
..


resourceloader: Add purgeModuleDeps.php maintenance script

Based on cleanupRemovedModules.php. Update both to use safer batching,
based on known selection instead of recursing until the table is empty
(which may end up deleting new rows from live traffic).

Bug: T158105
Change-Id: I05f650a0cfa8ca647f143a40e1087338adbef6da
---
M autoload.php
M maintenance/cleanupRemovedModules.php
A maintenance/purgeModuleDeps.php
3 files changed, 98 insertions(+), 13 deletions(-)

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



diff --git a/autoload.php b/autoload.php
index e5879d9..ad44273 100644
--- a/autoload.php
+++ b/autoload.php
@@ -1128,6 +1128,7 @@
'PurgeChangedPages' => __DIR__ . '/maintenance/purgeChangedPages.php',
'PurgeJobUtils' => __DIR__ . 
'/includes/jobqueue/utils/PurgeJobUtils.php',
'PurgeList' => __DIR__ . '/maintenance/purgeList.php',
+   'PurgeModuleDeps' => __DIR__ . '/maintenance/purgeModuleDeps.php',
'PurgeOldText' => __DIR__ . '/maintenance/purgeOldText.php',
'PurgeParserCache' => __DIR__ . '/maintenance/purgeParserCache.php',
'QueryPage' => __DIR__ . '/includes/specialpage/QueryPage.php',
diff --git a/maintenance/cleanupRemovedModules.php 
b/maintenance/cleanupRemovedModules.php
index 863d74a..83ab35c 100644
--- a/maintenance/cleanupRemovedModules.php
+++ b/maintenance/cleanupRemovedModules.php
@@ -38,31 +38,43 @@
parent::__construct();
$this->addDescription(
'Remove cache entries for removed ResourceLoader 
modules from the database' );
-   $this->addOption( 'batchsize', 'Delete rows in batches of this 
size. Default: 500', false, true );
+   $this->setBatchSize( 500 );
}
 
public function execute() {
+   $this->output( "Cleaning up module_deps table...\n" );
+
$dbw = $this->getDB( DB_MASTER );
$rl = new ResourceLoader( 
MediaWikiServices::getInstance()->getMainConfig() );
$moduleNames = $rl->getModuleNames();
-   $moduleList = implode( ', ', array_map( [ $dbw, 'addQuotes' ], 
$moduleNames ) );
-   $limit = max( 1, intval( $this->getOption( 'batchsize', 500 ) ) 
);
+   $res = $dbw->select( 'module_deps',
+   [ 'md_module', 'md_skin' ],
+   $moduleNames ? 'md_module NOT IN (' . $dbw->makeList( 
$moduleNames ) . ')' : '1=1',
+   __METHOD__
+   );
+   $rows = iterator_to_array( $res, false );
 
-   $this->output( "Cleaning up module_deps table...\n" );
-   $i = 1;
$modDeps = $dbw->tableName( 'module_deps' );
-   do {
-   // $dbw->delete() doesn't support LIMIT :(
-   $where = $moduleList ? "md_module NOT IN ($moduleList)" 
: '1=1';
-   $dbw->query( "DELETE FROM $modDeps WHERE $where LIMIT 
$limit", __METHOD__ );
+   $i = 1;
+   foreach ( array_chunk( $rows, $this->mBatchSize ) as $chunk ) {
+   // WHERE ( mod=A AND skin=A ) OR ( mod=A AND skin=B) ..
+   $conds = array_map( function ( stdClass $row ) use ( 
$dbw ) {
+   return $dbw->makeList( (array)$row, 
IDatabase::LIST_AND );
+   }, $chunk );
+   $conds = $dbw->makeList( $conds, IDatabase::LIST_OR );
+
+   $this->beginTransaction( $dbw, __METHOD__ );
+   $dbw->query( "DELETE FROM $modDeps WHERE $conds", 
__METHOD__ );
$numRows = $dbw->affectedRows();
$this->output( "Batch $i: $numRows rows\n" );
+   $this->commitTransaction( $dbw, __METHOD__ );
+
$i++;
-   wfWaitForSlaves();
-   } while ( $numRows > 0 );
-   $this->output( "done\n" );
+   }
+
+   $this->output( "Done\n" );
}
 }
 
-$maintClass = "CleanupRemovedModules";
+$maintClass = 'CleanupRemovedModules';
 require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/maintenance/purgeModuleDeps.php b/maintenance/purgeModuleDeps.php
new file mode 100644
index 000..3088baa
--- /dev/null
+++ b/maintenance/purgeModuleDeps.php
@@ -0,0 +1,72 @@
+http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Maintenance
+ * @author Timo Tijhof
+ */
+
+use MediaWiki\MediaWikiServices;
+
+require_once __DIR__ . '/Maintenance.php';
+
+/**
+ * Maintenance script to purge the module_deps database cache table.
+ *
+ * @ingroup Maintenance
+ */
+class PurgeModuleDeps 

[MediaWiki-commits] [Gerrit] mediawiki/core[wmf/1.29.0-wmf.14]: resourceloader: Add purgeModuleDeps.php maintenance script

2017-03-02 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340860 )

Change subject: resourceloader: Add purgeModuleDeps.php maintenance script
..

resourceloader: Add purgeModuleDeps.php maintenance script

Based on cleanupRemovedModules.php. Update both to use safer batching,
based on known selection instead of recursing until the table is empty
(which may end up deleting new rows from live traffic).

Bug: T158105
Change-Id: I05f650a0cfa8ca647f143a40e1087338adbef6da
---
M autoload.php
M maintenance/cleanupRemovedModules.php
A maintenance/purgeModuleDeps.php
3 files changed, 98 insertions(+), 13 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/60/340860/1

diff --git a/autoload.php b/autoload.php
index aa4e544..61a9caf 100644
--- a/autoload.php
+++ b/autoload.php
@@ -1129,6 +1129,7 @@
'PurgeChangedPages' => __DIR__ . '/maintenance/purgeChangedPages.php',
'PurgeJobUtils' => __DIR__ . 
'/includes/jobqueue/utils/PurgeJobUtils.php',
'PurgeList' => __DIR__ . '/maintenance/purgeList.php',
+   'PurgeModuleDeps' => __DIR__ . '/maintenance/purgeModuleDeps.php',
'PurgeOldText' => __DIR__ . '/maintenance/purgeOldText.php',
'PurgeParserCache' => __DIR__ . '/maintenance/purgeParserCache.php',
'QueryPage' => __DIR__ . '/includes/specialpage/QueryPage.php',
diff --git a/maintenance/cleanupRemovedModules.php 
b/maintenance/cleanupRemovedModules.php
index 863d74a..83ab35c 100644
--- a/maintenance/cleanupRemovedModules.php
+++ b/maintenance/cleanupRemovedModules.php
@@ -38,31 +38,43 @@
parent::__construct();
$this->addDescription(
'Remove cache entries for removed ResourceLoader 
modules from the database' );
-   $this->addOption( 'batchsize', 'Delete rows in batches of this 
size. Default: 500', false, true );
+   $this->setBatchSize( 500 );
}
 
public function execute() {
+   $this->output( "Cleaning up module_deps table...\n" );
+
$dbw = $this->getDB( DB_MASTER );
$rl = new ResourceLoader( 
MediaWikiServices::getInstance()->getMainConfig() );
$moduleNames = $rl->getModuleNames();
-   $moduleList = implode( ', ', array_map( [ $dbw, 'addQuotes' ], 
$moduleNames ) );
-   $limit = max( 1, intval( $this->getOption( 'batchsize', 500 ) ) 
);
+   $res = $dbw->select( 'module_deps',
+   [ 'md_module', 'md_skin' ],
+   $moduleNames ? 'md_module NOT IN (' . $dbw->makeList( 
$moduleNames ) . ')' : '1=1',
+   __METHOD__
+   );
+   $rows = iterator_to_array( $res, false );
 
-   $this->output( "Cleaning up module_deps table...\n" );
-   $i = 1;
$modDeps = $dbw->tableName( 'module_deps' );
-   do {
-   // $dbw->delete() doesn't support LIMIT :(
-   $where = $moduleList ? "md_module NOT IN ($moduleList)" 
: '1=1';
-   $dbw->query( "DELETE FROM $modDeps WHERE $where LIMIT 
$limit", __METHOD__ );
+   $i = 1;
+   foreach ( array_chunk( $rows, $this->mBatchSize ) as $chunk ) {
+   // WHERE ( mod=A AND skin=A ) OR ( mod=A AND skin=B) ..
+   $conds = array_map( function ( stdClass $row ) use ( 
$dbw ) {
+   return $dbw->makeList( (array)$row, 
IDatabase::LIST_AND );
+   }, $chunk );
+   $conds = $dbw->makeList( $conds, IDatabase::LIST_OR );
+
+   $this->beginTransaction( $dbw, __METHOD__ );
+   $dbw->query( "DELETE FROM $modDeps WHERE $conds", 
__METHOD__ );
$numRows = $dbw->affectedRows();
$this->output( "Batch $i: $numRows rows\n" );
+   $this->commitTransaction( $dbw, __METHOD__ );
+
$i++;
-   wfWaitForSlaves();
-   } while ( $numRows > 0 );
-   $this->output( "done\n" );
+   }
+
+   $this->output( "Done\n" );
}
 }
 
-$maintClass = "CleanupRemovedModules";
+$maintClass = 'CleanupRemovedModules';
 require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/maintenance/purgeModuleDeps.php b/maintenance/purgeModuleDeps.php
new file mode 100644
index 000..3088baa
--- /dev/null
+++ b/maintenance/purgeModuleDeps.php
@@ -0,0 +1,72 @@
+http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Maintenance
+ * @author Timo Tijhof
+ */
+
+use MediaWiki\MediaWikiServices;
+
+require_once __DIR__ . '/Maintenance.php';
+
+/**
+ * Maintenance script to purge the module_deps database cache table.
+ *
+ * @ingroup Maintenance
+ */
+class PurgeModuleDeps extends 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: scb2005 & scb2006 install params

2017-03-02 Thread RobH (Code Review)
RobH has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340856 )

Change subject: scb2005 & scb2006 install params
..


scb2005 & scb2006 install params

updates for mac addrss and partition info for scb2005 and scb2006

Bug:T159486
Change-Id: I9cca5efb488f3d17365cbdaae89b017b4db06b0e
---
M modules/install_server/files/autoinstall/netboot.cfg
M modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
2 files changed, 11 insertions(+), 1 deletion(-)

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



diff --git a/modules/install_server/files/autoinstall/netboot.cfg 
b/modules/install_server/files/autoinstall/netboot.cfg
index 4110d1b..61d9f30 100755
--- a/modules/install_server/files/autoinstall/netboot.cfg
+++ b/modules/install_server/files/autoinstall/netboot.cfg
@@ -71,7 +71,7 @@
 elastic101[7-9]|elastic102[0-9]|elastic103[0-1]) echo 
partman/elasticsearch-raid0.cfg ;; \
 elastic103[2-9]|elastic104[0-9]|elastic105[0-2]) echo 
partman/raid1-lvm-ext4-srv.cfg ;; \
 elastic20[0-2][0-9]|elastic203[0-6]) echo 
partman/raid1-lvm-ext4-srv.cfg ;; \
-labmon1001|mwlog[12]001|relforge100[12]|scb200[1-4]) echo 
partman/raid10-gpt-srv-lvm-ext4.cfg ;; \
+labmon1001|mwlog[12]001|relforge100[12]|scb200[1-6]) echo 
partman/raid10-gpt-srv-lvm-ext4.cfg ;; \
 analytics1003|cobalt|thorium) echo partman/raid10-gpt-srv-lvm-ext4.cfg 
;; \
 
aluminium|argon|chlorine|bromine|bohrium|darmstadtium|dbmonitor[12]001|dubnium|etcd100[1-6]|etherpad[12]001|fermium|hassaleh|hassium|krypton|meitnerium|mendelevium|mwdebug100[12]|nihal|nitrogen|planet[12]001|pollux|rutherfordium|sca[12]00[34]|seaborgium|serpens|alsafi|kraz|install[12]00[12]|ununpentium|zosma)
 echo partman/flat.cfg virtual.cfg ;; \
 eventlog[1-2]001|ocg100[1-2]|scb100[1-4]) echo partman/raid1.cfg ;; \
diff --git a/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
index 776522c..f9365bf 100644
--- a/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -5879,6 +5879,16 @@
 fixed-address scb2004.codfw.wmnet;
 }
 
+host scb2005 {
+hardware ethernet 18:66:DA:7D:AC:B2;
+fixed-address scb2005.codfw.wmnet;
+}
+
+host scb2006 {
+hardware ethernet 18:66:DA:7D:BD:8C;
+fixed-address scb2006.codfw.wmnet;
+}
+
 host silver {
 hardware ethernet 18:03:73:f1:58:67;
 fixed-address silver.wikimedia.org;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I9cca5efb488f3d17365cbdaae89b017b4db06b0e
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: RobH 
Gerrit-Reviewer: Giuseppe Lavagetto 
Gerrit-Reviewer: RobH 
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]: scb2005 & scb2006 install params

2017-03-02 Thread RobH (Code Review)
RobH has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340856 )

Change subject: scb2005 & scb2006 install params
..

scb2005 & scb2006 install params

updates for mac addrss and partition info for scb2005 and scb2006

Bug:T159486
Change-Id: I9cca5efb488f3d17365cbdaae89b017b4db06b0e
---
M modules/install_server/files/autoinstall/netboot.cfg
M modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
2 files changed, 11 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/56/340856/1

diff --git a/modules/install_server/files/autoinstall/netboot.cfg 
b/modules/install_server/files/autoinstall/netboot.cfg
index 4110d1b..61d9f30 100755
--- a/modules/install_server/files/autoinstall/netboot.cfg
+++ b/modules/install_server/files/autoinstall/netboot.cfg
@@ -71,7 +71,7 @@
 elastic101[7-9]|elastic102[0-9]|elastic103[0-1]) echo 
partman/elasticsearch-raid0.cfg ;; \
 elastic103[2-9]|elastic104[0-9]|elastic105[0-2]) echo 
partman/raid1-lvm-ext4-srv.cfg ;; \
 elastic20[0-2][0-9]|elastic203[0-6]) echo 
partman/raid1-lvm-ext4-srv.cfg ;; \
-labmon1001|mwlog[12]001|relforge100[12]|scb200[1-4]) echo 
partman/raid10-gpt-srv-lvm-ext4.cfg ;; \
+labmon1001|mwlog[12]001|relforge100[12]|scb200[1-6]) echo 
partman/raid10-gpt-srv-lvm-ext4.cfg ;; \
 analytics1003|cobalt|thorium) echo partman/raid10-gpt-srv-lvm-ext4.cfg 
;; \
 
aluminium|argon|chlorine|bromine|bohrium|darmstadtium|dbmonitor[12]001|dubnium|etcd100[1-6]|etherpad[12]001|fermium|hassaleh|hassium|krypton|meitnerium|mendelevium|mwdebug100[12]|nihal|nitrogen|planet[12]001|pollux|rutherfordium|sca[12]00[34]|seaborgium|serpens|alsafi|kraz|install[12]00[12]|ununpentium|zosma)
 echo partman/flat.cfg virtual.cfg ;; \
 eventlog[1-2]001|ocg100[1-2]|scb100[1-4]) echo partman/raid1.cfg ;; \
diff --git a/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
index 776522c..f9365bf 100644
--- a/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install_server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -5879,6 +5879,16 @@
 fixed-address scb2004.codfw.wmnet;
 }
 
+host scb2005 {
+hardware ethernet 18:66:DA:7D:AC:B2;
+fixed-address scb2005.codfw.wmnet;
+}
+
+host scb2006 {
+hardware ethernet 18:66:DA:7D:BD:8C;
+fixed-address scb2006.codfw.wmnet;
+}
+
 host silver {
 hardware ethernet 18:03:73:f1:58:67;
 fixed-address silver.wikimedia.org;

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

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

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: bast3002: remove bastionhost::migration role

2017-03-02 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340842 )

Change subject: bast3002: remove bastionhost::migration role
..


bast3002: remove bastionhost::migration role

Not needed anymore after rsync is done once.

Bug: T156506
Change-Id: I8f96fc4fce876754c393dc4653085188a2e370cd
---
M manifests/site.pp
1 file changed, 0 insertions(+), 1 deletion(-)

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



diff --git a/manifests/site.pp b/manifests/site.pp
index 12acf52..8a7ec17 100644
--- a/manifests/site.pp
+++ b/manifests/site.pp
@@ -172,7 +172,6 @@
 # Bastion in the Netherlands
 node 'bast3002.wikimedia.org' {
 role(bastionhost::general,
-bastionhost::migration,
 installserver::tftp,
 prometheus::ops)
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8f96fc4fce876754c393dc4653085188a2e370cd
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Dzahn 
Gerrit-Reviewer: Dzahn 
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]: bast3002: remove bastionhost::migration role

2017-03-02 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340842 )

Change subject: bast3002: remove bastionhost::migration role
..

bast3002: remove bastionhost::migration role

Not needed anymore after rsync is done once.

Change-Id: I8f96fc4fce876754c393dc4653085188a2e370cd
---
M manifests/site.pp
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/42/340842/1

diff --git a/manifests/site.pp b/manifests/site.pp
index 12acf52..8a7ec17 100644
--- a/manifests/site.pp
+++ b/manifests/site.pp
@@ -172,7 +172,6 @@
 # Bastion in the Netherlands
 node 'bast3002.wikimedia.org' {
 role(bastionhost::general,
-bastionhost::migration,
 installserver::tftp,
 prometheus::ops)
 

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

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

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Hygiene: replace all Response.isSuccessful() calls with inte...

2017-03-02 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340834 )

Change subject: Hygiene: replace all Response.isSuccessful() calls with 
interceptor
..

Hygiene: replace all Response.isSuccessful() calls with interceptor

Bug: T156917
Change-Id: I845fa6bc1c1e0ad5a8f38f0ca132285b8930809f
---
M app/src/main/java/org/wikipedia/captcha/CaptchaClient.java
M app/src/main/java/org/wikipedia/createaccount/CreateAccountClient.java
M app/src/main/java/org/wikipedia/createaccount/CreateAccountInfoClient.java
M app/src/main/java/org/wikipedia/csrf/CsrfTokenClient.java
M app/src/main/java/org/wikipedia/dataclient/mwapi/page/MwPageClient.java
M app/src/main/java/org/wikipedia/dataclient/okhttp/CacheIfErrorInterceptor.java
A app/src/main/java/org/wikipedia/dataclient/okhttp/HttpStatusException.java
M app/src/main/java/org/wikipedia/dataclient/okhttp/OkHttpConnectionFactory.java
M 
app/src/main/java/org/wikipedia/dataclient/okhttp/StatusResponseInterceptor.java
A 
app/src/main/java/org/wikipedia/dataclient/okhttp/UnsuccessfulResponseInterceptor.java
M 
app/src/main/java/org/wikipedia/dataclient/okhttp/WikipediaZeroResponseInterceptor.java
M app/src/main/java/org/wikipedia/dataclient/restbase/page/RbPageClient.java
M app/src/main/java/org/wikipedia/descriptions/DescriptionEditClient.java
M app/src/main/java/org/wikipedia/edit/EditClient.java
M app/src/main/java/org/wikipedia/edit/preview/EditPreviewClient.java
M app/src/main/java/org/wikipedia/edit/wikitext/WikitextClient.java
M 
app/src/main/java/org/wikipedia/feed/aggregated/AggregatedFeedContentClient.java
M app/src/main/java/org/wikipedia/feed/announcement/AnnouncementClient.java
M app/src/main/java/org/wikipedia/feed/becauseyouread/BecauseYouReadClient.java
M app/src/main/java/org/wikipedia/language/LangLinksClient.java
M app/src/main/java/org/wikipedia/login/LoginClient.java
M app/src/main/java/org/wikipedia/login/UserExtendedInfoClient.java
M app/src/main/java/org/wikipedia/login/UserIdClient.java
M app/src/main/java/org/wikipedia/nearby/NearbyClient.java
M app/src/main/java/org/wikipedia/random/RandomSummaryClient.java
M app/src/main/java/org/wikipedia/savedpages/SavedPageSyncService.java
M app/src/main/java/org/wikipedia/settings/RbSwitch.java
M 
app/src/main/java/org/wikipedia/useroption/dataclient/DefaultUserOptionDataClient.java
M app/src/main/java/org/wikipedia/zero/ZeroConfigClient.java
M app/src/test/java/org/wikipedia/captcha/CaptchaClientTest.java
M app/src/test/java/org/wikipedia/createaccount/CreateAccountClientTest.java
M app/src/test/java/org/wikipedia/createaccount/CreateAccountInfoClientTest.java
M app/src/test/java/org/wikipedia/csrf/CsrfTokenClientTest.java
M app/src/test/java/org/wikipedia/edit/EditClientTest.java
M app/src/test/java/org/wikipedia/edit/preview/EditPreviewClientTest.java
M app/src/test/java/org/wikipedia/edit/wikitext/WikitextClientTest.java
M app/src/test/java/org/wikipedia/language/LangLinksClientTest.java
M app/src/test/java/org/wikipedia/login/UserExtendedInfoClientTest.java
M app/src/test/java/org/wikipedia/login/UserIdClientTest.java
M app/src/test/java/org/wikipedia/nearby/NearbyClientTest.java
M app/src/test/java/org/wikipedia/test/MockWebServerTest.java
41 files changed, 255 insertions(+), 369 deletions(-)


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

diff --git a/app/src/main/java/org/wikipedia/captcha/CaptchaClient.java 
b/app/src/main/java/org/wikipedia/captcha/CaptchaClient.java
index 8b2c653..5c2db70 100644
--- a/app/src/main/java/org/wikipedia/captcha/CaptchaClient.java
+++ b/app/src/main/java/org/wikipedia/captcha/CaptchaClient.java
@@ -7,7 +7,6 @@
 import org.wikipedia.dataclient.WikiSite;
 import org.wikipedia.dataclient.mwapi.MwException;
 import org.wikipedia.dataclient.retrofit.MwCachedService;
-import org.wikipedia.dataclient.retrofit.RetrofitException;
 import org.wikipedia.dataclient.retrofit.WikiCachedService;
 
 import java.io.IOException;
@@ -29,17 +28,13 @@
 call.enqueue(new retrofit2.Callback() {
 @Override
 public void onResponse(Call call, Response 
response) {
-if (response.isSuccessful()) {
-if (response.body().success()) {
-cb.success(call, new 
CaptchaResult(response.body().captchaId()));
-} else if (response.body().hasError()) {
-// noinspection ConstantConditions
-cb.failure(call, new 
MwException(response.body().getError()));
-} else {
-cb.failure(call, new IOException("An unknown error 
occurred."));
-}
+if (response.body().success()) {
+cb.success(call, new 
CaptchaResult(response.body().captchaId()));
+} else if (response.body().hasError()) {
+// 

[MediaWiki-commits] [Gerrit] operations/dns[master]: setting scb200[56] dns entries

2017-03-02 Thread RobH (Code Review)
RobH has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340835 )

Change subject: setting scb200[56] dns entries
..


setting scb200[56] dns entries

setting both mgmt and production dns entries for scb2005 and scb2006

Bug:T159486
Change-Id: I66fe6769d12e12a132c87d57c13256ffe786ae2e
---
M templates/10.in-addr.arpa
M templates/wmnet
2 files changed, 8 insertions(+), 0 deletions(-)

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



diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa
index 7fb5014..1027f77 100644
--- a/templates/10.in-addr.arpa
+++ b/templates/10.in-addr.arpa
@@ -2544,6 +2544,7 @@
 31  1H IN PTR   heze.codfw.wmnet.
 32  1H IN PTR   dbstore2001.codfw.wmnet.
 33  1H IN PTR   scb2003.codfw.wmnet.
+34  1H IN PTR   scb2005.codfw.wmnet.
 
 40  1H IN PTR   mw2215.codfw.wmnet.
 41  1H IN PTR   mw2216.codfw.wmnet.
@@ -2884,6 +2885,7 @@
 17  1H IN PTR   ms-be2012.codfw.wmnet.
 18  1H IN PTR   ms-be2015.codfw.wmnet.
 19  1H IN PTR   dbstore2002.codfw.wmnet.
+20  1H IN PTR   scb2006.codfw.wmnet.
 
 24  1H IN PTR   mc2017.codfw.wmnet.
 25  1H IN PTR   mc2018.codfw.wmnet.
@@ -3485,9 +3487,11 @@
 147 1H IN PTR  wmf6464.mgmt.codfw.wmnet.
 148 1H IN PTR  puppetmaster2002.mgmt.codfw.wmnet.
 148 1H IN PTR  wmf6465.mgmt.codfw.wmnet.
+149 1H IN PTR  scb2005.mgmt.codfw.wmnet.
 149 1H IN PTR  wmf6466.mgmt.codfw.wmnet.
 150 1H IN PTR  kafka2003.mgmt.codfw.wmnet.
 150 1H IN PTR  wmf6467.mgmt.codfw.wmnet.
+151 1H IN PTR  scb2006.mgmt.codfw.wmnet.
 151 1H IN PTR  wmf6468.mgmt.codfw.wmnet.
 152 1H IN PTR  wmf6469.mgmt.codfw.wmnet.
 153 1H IN PTR  restbase2010.mgmt.codfw.wmnet.
diff --git a/templates/wmnet b/templates/wmnet
index d86ed7b..113c6a8 100644
--- a/templates/wmnet
+++ b/templates/wmnet
@@ -2800,6 +2800,8 @@
 scb2002 1H  IN A10.192.48.43
 scb2003 1H  IN A10.192.0.33
 scb2004 1H  IN A10.192.16.36
+scb2005 1H  IN A10.192.0.34
+scb2006 1H  IN A10.192.32.20
 subra   1H  IN A10.192.16.124
 suhail  1H  IN A10.192.0.121
 wasat   1H  IN A10.192.48.45
@@ -3466,6 +3468,8 @@
 scb2002 1H  IN A10.193.2.230
 scb2003 1H  IN A10.193.1.24
 scb2004 1H  IN A10.193.1.26
+scb2005 1H  IN A10.193.1.149
+scb2006 1H  IN A10.193.1.151
 stat20011H  IN A10.193.2.13
 subra   1H  IN A10.193.2.163
 suhail  1H  IN A10.193.2.164

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I66fe6769d12e12a132c87d57c13256ffe786ae2e
Gerrit-PatchSet: 1
Gerrit-Project: operations/dns
Gerrit-Branch: master
Gerrit-Owner: RobH 
Gerrit-Reviewer: RobH 
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/dns[master]: setting scb200[56] dns entries

2017-03-02 Thread RobH (Code Review)
RobH has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340835 )

Change subject: setting scb200[56] dns entries
..

setting scb200[56] dns entries

setting both mgmt and production dns entries for scb2005 and scb2006

Bug:T159486
Change-Id: I66fe6769d12e12a132c87d57c13256ffe786ae2e
---
M templates/10.in-addr.arpa
M templates/wmnet
2 files changed, 8 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/dns 
refs/changes/35/340835/1

diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa
index 7fb5014..1027f77 100644
--- a/templates/10.in-addr.arpa
+++ b/templates/10.in-addr.arpa
@@ -2544,6 +2544,7 @@
 31  1H IN PTR   heze.codfw.wmnet.
 32  1H IN PTR   dbstore2001.codfw.wmnet.
 33  1H IN PTR   scb2003.codfw.wmnet.
+34  1H IN PTR   scb2005.codfw.wmnet.
 
 40  1H IN PTR   mw2215.codfw.wmnet.
 41  1H IN PTR   mw2216.codfw.wmnet.
@@ -2884,6 +2885,7 @@
 17  1H IN PTR   ms-be2012.codfw.wmnet.
 18  1H IN PTR   ms-be2015.codfw.wmnet.
 19  1H IN PTR   dbstore2002.codfw.wmnet.
+20  1H IN PTR   scb2006.codfw.wmnet.
 
 24  1H IN PTR   mc2017.codfw.wmnet.
 25  1H IN PTR   mc2018.codfw.wmnet.
@@ -3485,9 +3487,11 @@
 147 1H IN PTR  wmf6464.mgmt.codfw.wmnet.
 148 1H IN PTR  puppetmaster2002.mgmt.codfw.wmnet.
 148 1H IN PTR  wmf6465.mgmt.codfw.wmnet.
+149 1H IN PTR  scb2005.mgmt.codfw.wmnet.
 149 1H IN PTR  wmf6466.mgmt.codfw.wmnet.
 150 1H IN PTR  kafka2003.mgmt.codfw.wmnet.
 150 1H IN PTR  wmf6467.mgmt.codfw.wmnet.
+151 1H IN PTR  scb2006.mgmt.codfw.wmnet.
 151 1H IN PTR  wmf6468.mgmt.codfw.wmnet.
 152 1H IN PTR  wmf6469.mgmt.codfw.wmnet.
 153 1H IN PTR  restbase2010.mgmt.codfw.wmnet.
diff --git a/templates/wmnet b/templates/wmnet
index d86ed7b..113c6a8 100644
--- a/templates/wmnet
+++ b/templates/wmnet
@@ -2800,6 +2800,8 @@
 scb2002 1H  IN A10.192.48.43
 scb2003 1H  IN A10.192.0.33
 scb2004 1H  IN A10.192.16.36
+scb2005 1H  IN A10.192.0.34
+scb2006 1H  IN A10.192.32.20
 subra   1H  IN A10.192.16.124
 suhail  1H  IN A10.192.0.121
 wasat   1H  IN A10.192.48.45
@@ -3466,6 +3468,8 @@
 scb2002 1H  IN A10.193.2.230
 scb2003 1H  IN A10.193.1.24
 scb2004 1H  IN A10.193.1.26
+scb2005 1H  IN A10.193.1.149
+scb2006 1H  IN A10.193.1.151
 stat20011H  IN A10.193.2.13
 subra   1H  IN A10.193.2.163
 suhail  1H  IN A10.193.2.164

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I66fe6769d12e12a132c87d57c13256ffe786ae2e
Gerrit-PatchSet: 1
Gerrit-Project: operations/dns
Gerrit-Branch: master
Gerrit-Owner: RobH 

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: bastion: rsync home dir data bast3001->bast3002

2017-03-02 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/340833 )

Change subject: bastion: rsync home dir data bast3001->bast3002
..


bastion: rsync home dir data bast3001->bast3002

Bug: T156506
Change-Id: I2301b5e65b612ecbb9e5ac47707d6fc12c1ef5d3
---
M manifests/site.pp
M modules/role/manifests/bastionhost/migration.pp
2 files changed, 4 insertions(+), 3 deletions(-)

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



diff --git a/manifests/site.pp b/manifests/site.pp
index 8a7ec17..12acf52 100644
--- a/manifests/site.pp
+++ b/manifests/site.pp
@@ -172,6 +172,7 @@
 # Bastion in the Netherlands
 node 'bast3002.wikimedia.org' {
 role(bastionhost::general,
+bastionhost::migration,
 installserver::tftp,
 prometheus::ops)
 
diff --git a/modules/role/manifests/bastionhost/migration.pp 
b/modules/role/manifests/bastionhost/migration.pp
index 54c0675..2ad1fc5 100644
--- a/modules/role/manifests/bastionhost/migration.pp
+++ b/modules/role/manifests/bastionhost/migration.pp
@@ -1,7 +1,7 @@
 # setup rsync to copy home dirs for server upgrade
 class role::bastionhost::migration {
 
-$sourceip='10.64.0.22' # tungsten
+$sourceip='91.198.174.112' # bast3001
 
 ferm::service { 'bast-home-rsync':
 proto  => 'tcp',
@@ -11,12 +11,12 @@
 
 include ::rsync::server
 
-file { [ '/srv/bast1001', '/srv/bast1001/home' ]:
+file { [ '/srv/bast3001', '/srv/bast3001/home' ]:
 ensure => 'directory',
 }
 
 rsync::server::module { 'home':
-path=> '/srv/bast1001/home',
+path=> '/srv/bast3001/home',
 read_only   => 'no',
 hosts_allow => $sourceip,
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2301b5e65b612ecbb9e5ac47707d6fc12c1ef5d3
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Dzahn 
Gerrit-Reviewer: Dzahn 
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]: bastion: rsync home dir data bast3001->bast3002

2017-03-02 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340833 )

Change subject: bastion: rsync home dir data bast3001->bast3002
..

bastion: rsync home dir data bast3001->bast3002

Bug: T156506
Change-Id: I2301b5e65b612ecbb9e5ac47707d6fc12c1ef5d3
---
M manifests/site.pp
M modules/role/manifests/bastionhost/migration.pp
2 files changed, 4 insertions(+), 3 deletions(-)


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

diff --git a/manifests/site.pp b/manifests/site.pp
index 8a7ec17..12acf52 100644
--- a/manifests/site.pp
+++ b/manifests/site.pp
@@ -172,6 +172,7 @@
 # Bastion in the Netherlands
 node 'bast3002.wikimedia.org' {
 role(bastionhost::general,
+bastionhost::migration,
 installserver::tftp,
 prometheus::ops)
 
diff --git a/modules/role/manifests/bastionhost/migration.pp 
b/modules/role/manifests/bastionhost/migration.pp
index 54c0675..2ad1fc5 100644
--- a/modules/role/manifests/bastionhost/migration.pp
+++ b/modules/role/manifests/bastionhost/migration.pp
@@ -1,7 +1,7 @@
 # setup rsync to copy home dirs for server upgrade
 class role::bastionhost::migration {
 
-$sourceip='10.64.0.22' # tungsten
+$sourceip='91.198.174.112' # bast3001
 
 ferm::service { 'bast-home-rsync':
 proto  => 'tcp',
@@ -11,12 +11,12 @@
 
 include ::rsync::server
 
-file { [ '/srv/bast1001', '/srv/bast1001/home' ]:
+file { [ '/srv/bast3001', '/srv/bast3001/home' ]:
 ensure => 'directory',
 }
 
 rsync::server::module { 'home':
-path=> '/srv/bast1001/home',
+path=> '/srv/bast3001/home',
 read_only   => 'no',
 hosts_allow => $sourceip,
 }

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: RCFilters UI: Ajaxify everything

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

Change subject: RCFilters UI: Ajaxify everything
..


RCFilters UI: Ajaxify everything

Make sure all links and 'show' button form information uses the
ajax method rather than reloading the page.

Bug: T157594
Change-Id: I97a452082e2d06f78cbec2235e2ed07a2eb6bca0
---
M includes/specials/SpecialRecentchanges.php
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/mw.rcfilters.init.js
M resources/src/mediawiki.rcfilters/styles/mw.rcfilters.less
M resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FormWrapperWidget.js
6 files changed, 177 insertions(+), 27 deletions(-)

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



diff --git a/includes/specials/SpecialRecentchanges.php 
b/includes/specials/SpecialRecentchanges.php
index 73a209b..1505308 100644
--- a/includes/specials/SpecialRecentchanges.php
+++ b/includes/specials/SpecialRecentchanges.php
@@ -697,7 +697,10 @@
$title = new HtmlArmor( '' . htmlspecialchars( 
$title ) . '' );
}
 
-   return $this->getLinkRenderer()->makeKnownLink( 
$this->getPageTitle(), $title, [], $params );
+   return $this->getLinkRenderer()->makeKnownLink( 
$this->getPageTitle(), $title, [
+   'data-params' => json_encode( $override ),
+   'data-keys' => implode( ',', array_keys( $override ) ),
+   ], $params );
}
 
/**
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 edb6744..d6ce734 100644
--- 
a/resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.ChangesListViewModel.js
+++ 
b/resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.ChangesListViewModel.js
@@ -50,10 +50,11 @@
 * Update the model with an updated list of changes
 *
 * @param {jQuery|string} changesListContent
+* @param {jQuery} $fieldset
 */
-   mw.rcfilters.dm.ChangesListViewModel.prototype.update = function ( 
changesListContent ) {
+   mw.rcfilters.dm.ChangesListViewModel.prototype.update = function ( 
changesListContent, $fieldset ) {
this.valid = true;
-   this.emit( 'update', changesListContent );
+   this.emit( 'update', changesListContent, $fieldset );
};
 
 }( mediaWiki ) );
diff --git a/resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js 
b/resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js
index 1df31a2..c0f453c 100644
--- a/resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js
+++ b/resources/src/mediawiki.rcfilters/mw.rcfilters.Controller.js
@@ -62,7 +62,6 @@
// Check all filter interactions
this.filtersModel.reassessFilterInteractions();
 
-   this.updateURL();
this.updateChangesList();
};
 
@@ -75,7 +74,6 @@
// Check all filter interactions
this.filtersModel.reassessFilterInteractions();
 
-   this.updateURL();
this.updateChangesList();
};
 
@@ -93,7 +91,6 @@
obj[ filterName ] = isSelected;
this.filtersModel.updateFilters( obj );
 
-   this.updateURL();
this.updateChangesList();
 
// Check filter interactions
@@ -103,9 +100,23 @@
 
/**
 * Update the URL of the page to reflect current filters
+*
+* This should not be called directly from outside the controller.
+* If an action requires changing the URL, it should either use the
+* highlighting actions below, or call #updateChangesList which does
+* the uri corrections already.
+*
+* @private
+* @param {Object} [params] Extra parameters to add to the API call
 */
-   mw.rcfilters.Controller.prototype.updateURL = function () {
-   var uri = this.getUpdatedUri();
+   mw.rcfilters.Controller.prototype.updateURL = function ( params ) {
+   var uri;
+
+   params = params || {};
+
+   uri = this.getUpdatedUri();
+   uri.extend( params );
+
window.history.pushState( { tag: 'rcfilters' }, document.title, 
uri.toString() );
};
 
@@ -140,6 +151,7 @@
 * Fetch the list of changes from the server for the current filters
 *
 * @return {jQuery.Promise} Promise object that will resolve with the 
changes list
+*  or with a string denoting no results.
 */
mw.rcfilters.Controller.prototype.fetchChangesList = 

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Rephrase enotif_lastdiff and enotif_lastvisited

2017-03-02 Thread Huji (Code Review)
Huji has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340832 )

Change subject: Rephrase enotif_lastdiff and enotif_lastvisited
..

Rephrase enotif_lastdiff and enotif_lastvisited

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/32/340832/1

diff --git a/languages/i18n/en.json b/languages/i18n/en.json
index 098adb6..af13fb7 100644
--- a/languages/i18n/en.json
+++ b/languages/i18n/en.json
@@ -2193,8 +2193,8 @@
"enotif_body_intro_moved": "The {{SITENAME}} page $1 has been 
{{GENDER:$2|moved}} on $PAGEEDITDATE by $2, see $3 for the current revision.",
"enotif_body_intro_restored": "The {{SITENAME}} page $1 has been 
{{GENDER:$2|restored}} on $PAGEEDITDATE by $2, see $3 for the current 
revision.",
"enotif_body_intro_changed": "The {{SITENAME}} page $1 has been 
{{GENDER:$2|changed}} on $PAGEEDITDATE by $2, see $3 for the current revision.",
-   "enotif_lastvisited": "See $1 for all changes since your last visit.",
-   "enotif_lastdiff": "See $1 to view this change.",
+   "enotif_lastvisited": "For all changes since your last visit, see $1",
+   "enotif_lastdiff": "To view this change, see $1",
"enotif_anon_editor": "anonymous user $1",
"enotif_body": "Dear $WATCHINGUSERNAME,\n\n$PAGEINTRO 
$NEWPAGE\n\nEditor's summary: $PAGESUMMARY $PAGEMINOREDIT\n\nContact the 
editor:\nmail: $PAGEEDITOR_EMAIL\nwiki: $PAGEEDITOR_WIKI\n\nThere will be no 
other notifications in case of further activity unless you visit this page 
while logged in. You could also reset the notification flags for all your 
watched pages on your watchlist.\n\nYour friendly {{SITENAME}} notification 
system\n\n--\nTo change your email notification settings, 
visit\n{{canonicalurl:{{#special:Preferences\n\nTo change your watchlist 
settings, visit\n{{canonicalurl:{{#special:EditWatchlist\n\nTo delete the 
page from your watchlist, visit\n$UNWATCHURL\n\nFeedback and further 
assistance:\n$HELPPAGE",
"created": "created",

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Change 'history-show-deleted' message to 'Revision deleted o...

2017-03-02 Thread MusikAnimal (Code Review)
MusikAnimal has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340831 )

Change subject: Change 'history-show-deleted' message to 'Revision deleted 
only' for clarity
..

Change 'history-show-deleted' message to 'Revision deleted only' for clarity

Bug: T159483
Change-Id: I1cde02e34e3dba042e566d77490e76223b6c2bb1
---
M languages/i18n/en.json
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/31/340831/1

diff --git a/languages/i18n/en.json b/languages/i18n/en.json
index 098adb6..a19b6f2 100644
--- a/languages/i18n/en.json
+++ b/languages/i18n/en.json
@@ -838,7 +838,7 @@
"page_last": "last",
"histlegend": "Diff selection: Mark the radio boxes of the revisions to 
compare and hit enter or the button at the bottom.\nLegend: 
({{int:cur}}) = difference with latest revision, 
({{int:last}}) = difference with preceding revision, 
{{int:minoreditletter}} = minor edit.",
"history-fieldset-title": "Browse history",
-   "history-show-deleted": "Deleted only",
+   "history-show-deleted": "Revision deleted only",
"history_copyright": "-",
"histfirst": "oldest",
"histlast": "newest",

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...SecurePoll[master]: Disregard expired user groups when populating the voter list

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

Change subject: Disregard expired user groups when populating the voter list
..


Disregard expired user groups when populating the voter list

I didn't touch cli/wm-scripts/bv2013/doSpam.php, as it is an old archived
script.

Bug: T157018
Change-Id: I67632761d0bbb2bf7f7f170ae7cff019f10e668e
---
M includes/jobs/PopulateVoterListJob.php
1 file changed, 8 insertions(+), 1 deletion(-)

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



diff --git a/includes/jobs/PopulateVoterListJob.php 
b/includes/jobs/PopulateVoterListJob.php
index 03d380e..d3fe3c8 100644
--- a/includes/jobs/PopulateVoterListJob.php
+++ b/includes/jobs/PopulateVoterListJob.php
@@ -265,6 +265,7 @@
}
 
// Criterion 3: Not in a listed group
+   global $wgDisableUserGroupExpiry;
if ( $this->params['list_exclude-groups'] ) {
$res = $dbr->select(
array( 'user', 'user_groups' ),
@@ -280,6 +281,9 @@
'user_groups' => array( 'LEFT 
OUTER JOIN', array(
'ug_user = 
user_id',
'ug_group' => 
$this->params['list_exclude-groups'],
+   ( !isset( 
$wgDisableUserGroupExpiry ) || $wgDisableUserGroupExpiry ) ?
+   '1' :
+   
'ug_expiry IS NULL OR ug_expiry >= ' . $dbr->addQuotes( $dbr->timestamp() ),
)
),
)
@@ -304,7 +308,10 @@
array(
"ug_user >= $min",
"ug_user < $max",
-   'ug_group' => 
$this->params['list_include-groups']
+   'ug_group' => 
$this->params['list_include-groups'],
+   ( !isset( 
$wgDisableUserGroupExpiry ) || $wgDisableUserGroupExpiry ) ?
+   '1' :
+   'ug_expiry IS NULL OR 
ug_expiry >= ' . $dbr->addQuotes( $dbr->timestamp() ),
)
);
$list = array();

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I67632761d0bbb2bf7f7f170ae7cff019f10e668e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/SecurePoll
Gerrit-Branch: master
Gerrit-Owner: TTO 
Gerrit-Reviewer: Anomie 
Gerrit-Reviewer: Huji 
Gerrit-Reviewer: Tim Starling 
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]: Return "timedtext" in getAPIData too

2017-03-02 Thread Arlolra (Code Review)
Arlolra has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/340830 )

Change subject: Return "timedtext" in getAPIData too
..

Return "timedtext" in getAPIData too

 * Also, fix a pass by reference error.

Change-Id: Ia679c5a00bc758636ae04412a7379c29469e4819
---
M ApiQueryVideoInfo.php
M TimedMediaTransformOutput.php
2 files changed, 10 insertions(+), 2 deletions(-)


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

diff --git a/ApiQueryVideoInfo.php b/ApiQueryVideoInfo.php
index 595f94e..4bd77b8 100644
--- a/ApiQueryVideoInfo.php
+++ b/ApiQueryVideoInfo.php
@@ -36,7 +36,7 @@
if ( $file->getHandler() && $file->getHandler() 
instanceof TimedMediaHandler ) {
$handler = new TextHandler( $file );
$vals['timedtext'] = $handler->getTracks();
-   foreach ( $vals['timedtext'] as $track ) {
+   foreach ( $vals['timedtext'] as &$track ) {
$track['src'] = wfExpandUrl( 
$track['src'], PROTO_CURRENT );
}
$result->setIndexedTagName( $vals['timedtext'], 
"timedtext" );
diff --git a/TimedMediaTransformOutput.php b/TimedMediaTransformOutput.php
index a1e4c95..c16ef24 100644
--- a/TimedMediaTransformOutput.php
+++ b/TimedMediaTransformOutput.php
@@ -555,6 +555,14 @@
 * @return array
 */
public function getAPIData() {
-   return [ 'derivatives' => WebVideoTranscode::getSources( 
$this->file, [ 'fullurl' ] ) ];
+   $handler = new TextHandler( $this->file );
+   $vals = [
+   'derivatives' => WebVideoTranscode::getSources( 
$this->file, [ 'fullurl' ] ),
+   'timedtext' => $handler->getTracks(),
+   ];
+   foreach ( $vals['timedtext'] as &$track ) {
+   $track['src'] = wfExpandUrl( $track['src'], 
PROTO_CURRENT );
+   }
+   return $vals;
}
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia679c5a00bc758636ae04412a7379c29469e4819
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TimedMediaHandler
Gerrit-Branch: master
Gerrit-Owner: Arlolra 

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


  1   2   3   4   >