[MediaWiki-commits] [Gerrit] More consistent description message - change (mediawiki...OpenLayers)

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

Change subject: More consistent description message
..


More consistent description message

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

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



diff --git a/i18n/en.json b/i18n/en.json
index db3da5b..a35603d 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -6,5 +6,5 @@
]
},
"openlayers-extensionname": "OpenLayers",
-   "openlayers-desc": "This extension is fore adding the OpenLayers 
modules to other extensions."
+   "openlayers-desc": "Makes OpenLayers module available"
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iab5d107a2bc3469c016ddb51044385d1d6af8e82
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/OpenLayers
Gerrit-Branch: master
Gerrit-Owner: Raimond Spekking 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Replace in-line style for error class in warnings - change (mediawiki...Renameuser)

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

Change subject: Replace in-line style for error class in warnings
..


Replace in-line style for error class in warnings

This commit replaces the in-line, hard-coded style used when
representing warnings when renaming users with the shared .error
CSS class. This makes it easier for end-users to modify the look
of the messages, and ensures a uniform style across MediaWiki.

The previous hard-coded style is bright red and bold, whereas the
error class is a darker shade of red, and larger instead of bold.

Change-Id: I8ecc9eb4b023b036e86ef802e69be51490ef86f0
---
M specials/SpecialRenameuser.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/specials/SpecialRenameuser.php b/specials/SpecialRenameuser.php
index 42aef35..2ed5219 100644
--- a/specials/SpecialRenameuser.php
+++ b/specials/SpecialRenameuser.php
@@ -149,7 +149,7 @@
" . $this->msg( 
'renameuserwarnings' )->escaped() . "

" .
-   '' .
+   '' .
implode( '', $warningsHtml ) . 
'' .
'
'

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8ecc9eb4b023b036e86ef802e69be51490ef86f0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Renameuser
Gerrit-Branch: master
Gerrit-Owner: Microchip08 
Gerrit-Reviewer: Aaron Schulz 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: Umherirrender 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] logrotate: Convert geoipupdate to logrotate::conf - change (operations/puppet)

2016-02-17 Thread Giuseppe Lavagetto (Code Review)
Giuseppe Lavagetto has submitted this change and it was merged.

Change subject: logrotate: Convert geoipupdate to logrotate::conf
..


logrotate: Convert geoipupdate to logrotate::conf

Bug: T127025
Change-Id: I49fa5f02899ba066dcfbb106a492a30465873983
---
M modules/geoip/manifests/data/maxmind.pp
1 file changed, 2 insertions(+), 1 deletion(-)

Approvals:
  Giuseppe Lavagetto: Verified; Looks good to me, approved



diff --git a/modules/geoip/manifests/data/maxmind.pp 
b/modules/geoip/manifests/data/maxmind.pp
index d75291b..0672814 100644
--- a/modules/geoip/manifests/data/maxmind.pp
+++ b/modules/geoip/manifests/data/maxmind.pp
@@ -89,7 +89,8 @@
   }
 
   # logrotate for geoipupdate.log
-  file { '/etc/logrotate.d/geoipupdate':
+  logrotate::conf { 'geoipupdate':
+ensure => present,
 content => template('geoip/geoipupdate.logrotate.erb'),
 require => Cron['geoipupdate'],
   }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I49fa5f02899ba066dcfbb106a492a30465873983
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Volans 
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] Avoid calculating md5 when not caching references - change (mediawiki...Cite)

2016-02-17 Thread Cenarium (Code Review)
Cenarium has uploaded a new change for review.

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

Change subject: Avoid calculating md5 when not caching references
..

Avoid calculating md5 when not caching references

In the old caching system for references, the cache key needs the md5 of
the references, but it shouldn't be calculated when one is not using
this caching system.

Change-Id: I83c17d1df5c5e620ea21d1bf955b86ce94bc119a
---
M Cite_body.php
1 file changed, 7 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Cite 
refs/changes/70/271470/1

diff --git a/Cite_body.php b/Cite_body.php
index c150821..e62cdfa 100644
--- a/Cite_body.php
+++ b/Cite_body.php
@@ -729,15 +729,17 @@
// We add new lines between the pieces to avoid a confused tidy 
(bug 13073).
$parserInput = $prefix . "\n" . $content . "\n" . $suffix;
 
-   // Let's try to cache it.
-   global $wgMemc;
-   $cacheKey = wfMemcKey( 'citeref', md5( $parserInput ), 
$this->mParser->Title()->getArticleID() );
-
wfProfileOut( __METHOD__ . '-entries' );
 
-   global $wgCiteCacheReferences;
+   // Let's try to cache it.
+   global $wgCiteCacheReferences, $wgMemc;
$data = false;
if ( $wgCiteCacheReferences ) {
+   $cacheKey = wfMemcKey(
+   'citeref',
+   md5( $parserInput ),
+   $this->mParser->Title()->getArticleID()
+   );
wfProfileIn( __METHOD__ . '-cache-get' );
$data = $wgMemc->get( $cacheKey );
wfProfileOut( __METHOD__ . '-cache-get' );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I83c17d1df5c5e620ea21d1bf955b86ce94bc119a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Cite
Gerrit-Branch: master
Gerrit-Owner: Cenarium 

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


[MediaWiki-commits] [Gerrit] NumberInputWidget: Apex: Round the correct corners in the di... - change (oojs/ui)

2016-02-17 Thread Prtksxna (Code Review)
Prtksxna has uploaded a new change for review.

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

Change subject: NumberInputWidget: Apex: Round the correct corners in the 
disabled state
..

NumberInputWidget: Apex: Round the correct corners in the disabled state

Also add the disabled state to the demo page.

Bug: T102126
Change-Id: I7ffd19fbedf80bc108015d491f25cd4aadef78dc
---
M demos/pages/widgets.js
M src/themes/apex/widgets.less
2 files changed, 9 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/ui refs/changes/69/271469/1

diff --git a/demos/pages/widgets.js b/demos/pages/widgets.js
index 48a8d37..c9fed54 100644
--- a/demos/pages/widgets.js
+++ b/demos/pages/widgets.js
@@ -727,6 +727,13 @@
}
),
new OO.ui.FieldLayout(
+   new OO.ui.NumberInputWidget( { 
disabled: true } ),
+   {
+   label: 'NumberInputWidget 
(disabled)',
+   align: 'top'
+   }
+   ),
+   new OO.ui.FieldLayout(
new OO.ui.NumberInputWidget( { min: 1, 
max: 5, isInteger: true } ),
{
label: 'NumberInputWidget (1–5, 
ints only)',
diff --git a/src/themes/apex/widgets.less b/src/themes/apex/widgets.less
index 6281c91..cd23beb 100644
--- a/src/themes/apex/widgets.less
+++ b/src/themes/apex/widgets.less
@@ -981,13 +981,13 @@
width: 2.25em;
}
 
-   &-minusButton.oo-ui-buttonElement-framed.oo-ui-widget-enabled > 
.oo-ui-buttonElement-button {
+   &-minusButton.oo-ui-buttonElement-framed > .oo-ui-buttonElement-button {
border-top-right-radius: 0;
border-bottom-right-radius: 0;
border-right-width: 0;
}
 
-   &-plusButton.oo-ui-buttonElement-framed.oo-ui-widget-enabled > 
.oo-ui-buttonElement-button {
+   &-plusButton.oo-ui-buttonElement-framed > .oo-ui-buttonElement-button {
border-top-left-radius: 0;
border-bottom-left-radius: 0;
border-left-width: 0;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7ffd19fbedf80bc108015d491f25cd4aadef78dc
Gerrit-PatchSet: 1
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Prtksxna 

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


[MediaWiki-commits] [Gerrit] Gadgets tab on Special: Preferences badly formatted - change (mediawiki/core)

2016-02-17 Thread Haritha28 (Code Review)
Haritha28 has uploaded a new change for review.

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

Change subject: Gadgets tab on Special: Preferences badly formatted
..

Gadgets tab on Special: Preferences badly formatted

The section headers are changed from  to 
and the "label = " is removed.

Bug: T46231
Change-Id: Ica05064ba2f4a43c15898b4111099d73cf5fe4ea
---
M includes/htmlform/HTMLMultiSelectField.php
M tests/phpunit/includes/api/ApiOptionsTest.php
2 files changed, 1 insertion(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/68/271468/1

diff --git a/includes/htmlform/HTMLMultiSelectField.php 
b/includes/htmlform/HTMLMultiSelectField.php
index 251bb05..04dbc56 100644
--- a/includes/htmlform/HTMLMultiSelectField.php
+++ b/includes/htmlform/HTMLMultiSelectField.php
@@ -41,7 +41,7 @@
 
foreach ( $options as $label => $info ) {
if ( is_array( $info ) ) {
-   $html .= Html::rawElement( 'h1', [], $label ) . 
"\n";
+   $html .= Html::rawElement( 'h2', [], $label ) . 
"\n";
$html .= $this->formatOptions( $info, $value );
} else {
$thisAttribs = [
diff --git a/tests/phpunit/includes/api/ApiOptionsTest.php 
b/tests/phpunit/includes/api/ApiOptionsTest.php
index 0a577c1..3bb1b0d 100644
--- a/tests/phpunit/includes/api/ApiOptionsTest.php
+++ b/tests/phpunit/includes/api/ApiOptionsTest.php
@@ -66,7 +66,6 @@
$preferences[$k] = [
'type' => 'text',
'section' => 'test',
-   'label' => '',
];
}
 

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

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

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


[MediaWiki-commits] [Gerrit] Improve handling of cite warnings - change (mediawiki...Cite)

2016-02-17 Thread Cenarium (Code Review)
Cenarium has uploaded a new change for review.

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

Change subject: Improve handling of cite warnings
..

Improve handling of cite warnings

This improves handling of cite warnings by creating a function
specifically for them instead of using the error function with an
optional downgrade.

Change-Id: I872d79335c8dd2bd19bbe254c28b0d9025d256be
---
M Cite_body.php
1 file changed, 44 insertions(+), 17 deletions(-)


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

diff --git a/Cite_body.php b/Cite_body.php
index c150821..f508038 100644
--- a/Cite_body.php
+++ b/Cite_body.php
@@ -849,7 +849,11 @@
 */
function referenceText( $key, $text ) {
if ( !isset( $text ) || $text === '' ) {
-   return $this->error( 'cite_error_references_no_text', 
$key, 'noparse' );
+   if ( 
!$this->mParser->getOptions()->getIsSectionPreview() ) {
+   return $this->error( 
'cite_error_references_no_text', $key, 'noparse' );
+   } else {
+   return $this->warning( 
'cite_warning_sectionpreview_no_text', $key, 'noparse' );
+   }
}
return '' . rtrim( $text, "\n" ) . 
"\n";
}
@@ -1256,16 +1260,6 @@
 * @return string XHTML or wikitext ready for output
 */
function error( $key, $param = null, $parse = 'parse' ) {
-   $decreaseToWarning = false;
-   if (
-   $this->mParser->getOptions()->getIsSectionPreview() &&
-   $key === 'cite_error_references_no_text'
-   ) {
-   // ref may be defined somewhere else on the page so use 
distinct message
-   // and be less intrusive than in a real error
-   $key = 'cite_warning_sectionpreview_no_text';
-   $decreaseToWarning = true;
-   }
# We rely on the fact that PHP is okay with passing unused argu-
# ments to functions.  If $1 is not used in the message, 
wfMessage will
# just ignore the extra parameter.
@@ -1273,20 +1267,53 @@
# use the user language and split the parser cache.
$lang = $this->mParser->getOptions()->getUserLangObj();
$msg = wfMessage(
-   $decreaseToWarning ? 'cite_warning' : 'cite_error',
+   'cite_error',
wfMessage( $key, $param )->inLanguage( $lang )->plain()
)
->inLanguage( $lang )
->plain();
 
-   if ( $decreaseToWarning ) {
-   $ret = '' . 
$msg . '';
-   } else {
-   $this->mParser->addTrackingCategory( 
'cite-tracking-category-cite-error' );
+   $this->mParser->addTrackingCategory( 
'cite-tracking-category-cite-error' );
 
-   $ret = '' . 
$msg . '';
+   $ret = '' . $msg . 
'';
+
+   if ( $parse === 'parse' ) {
+   $ret = $this->mParser->recursiveTagParse( $ret );
}
 
+   return $ret;
+   }
+
+   /**
+* Return a warning message based on a warning ID
+*
+* @param string $key   Message name for the warning
+* @param string $param Parameter to pass to the message
+* @param string $parse Whether to parse the message ('parse') or not 
('noparse')
+* @param bool $parentheses Whether to put the warning in parentheses
+* @return string XHTML or wikitext ready for output
+*/
+   function warning( $key, $param = null, $parse = 'parse', $parentheses = 
false ) {
+   # We rely on the fact that PHP is okay with passing unused argu-
+   # ments to functions.  If $1 is not used in the message, 
wfMessage will
+   # just ignore the extra parameter.
+   # For ease of debugging and because errors are rare, we
+   # use the user language and split the parser cache.
+   $lang = $this->mParser->getOptions()->getUserLangObj();
+   $msg = wfMessage(
+   'cite_warning',
+   wfMessage( $key, $param )->inLanguage( $lang )->plain()
+   )
+   ->inLanguage( $lang )
+   ->plain();
+
+   if ( $parentheses ) {
+   $msg = wfMessage( 'parentheses', $msg )->inLanguage( 
$lang )->plain();
+   }
+
+   $ret = '' . $msg . '';
+
if ( $parse === 'parse' ) {
$ret = $this->mParser->recursiveTagParse( $ret );
}

-- 
To view, visit 

[MediaWiki-commits] [Gerrit] Use span with css instead of strong for cite errors - change (mediawiki...Cite)

2016-02-17 Thread Cenarium (Code Review)
Cenarium has uploaded a new change for review.

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

Change subject: Use span with css instead of strong for cite errors
..

Use span with css instead of strong for cite errors

Change-Id: I9b8954b56646ca9c4632788824346e6116de3146
---
M Cite_body.php
M citeParserTests.txt
M modules/ext.cite.styles.css
3 files changed, 34 insertions(+), 29 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Cite 
refs/changes/66/271466/1

diff --git a/Cite_body.php b/Cite_body.php
index c150821..089a3e6 100644
--- a/Cite_body.php
+++ b/Cite_body.php
@@ -1284,7 +1284,7 @@
} else {
$this->mParser->addTrackingCategory( 
'cite-tracking-category-cite-error' );
 
-   $ret = '' . 
$msg . '';
+   $ret = '' . $msg 
. '';
}
 
if ( $parse === 'parse' ) {
diff --git a/citeParserTests.txt b/citeParserTests.txt
index 0073ede..9a4e62b 100644
--- a/citeParserTests.txt
+++ b/citeParserTests.txt
@@ -210,7 +210,7 @@
 [1]
 
 
-↑ 1.0 1.1 0 
Cite error: Invalid 
ref tag; name "blank" defined multiple times with 
different content
+↑ 1.0 1.1 0 
Cite error: Invalid 
ref tag; name "blank" defined multiple times with 
different content
 
 
 
@@ -229,7 +229,7 @@
 [1]
 
 
-↑ 1.0 1.1 1 
Cite error: Invalid 
ref tag; name "blank" defined multiple times with 
different content
+↑ 1.0 1.1 1 
Cite error: Invalid 
ref tag; name "blank" defined multiple times with 
different content
 
 
 
@@ -276,23 +276,23 @@
 
 
 !! result
-Cite error: Invalid 
ref tag;
-name cannot be a simple integer. Use a descriptive title
+Cite error: Invalid 
ref tag;
+name cannot be a simple integer. Use a descriptive title
 [1]
-Cite error: The opening 
ref tag is malformed or has a bad name
+Cite error: The opening 
ref tag is malformed or has a bad name
 [2]
 [3]
-Cite error: Invalid 
references tag;
+Cite error: Invalid 
references tag;
 parameter "group" is allowed only.
-Use references /, or references group="..." 
/
+Use references /, or references group="..." 
/
 
 
 ↑ Also zero, but 
differently! (Normal ref)
 
-↑ Cite error: Invalid ref tag;
-no text was provided for refs named bar
-↑ Cite error: Invalid ref tag;
-no text was provided for refs named 
blankwithnoreference
+↑ Cite error: Invalid ref tag;
+no text was provided for refs named bar
+↑ Cite error: Invalid ref tag;
+no text was provided for refs named 
blankwithnoreference
 
 
 !! end
@@ -399,12 +399,12 @@
 [2 
1]
 
 
-↑ Cite error: Invalid ref tag;
-no text was provided for refs named foo
+↑ Cite error: Invalid ref tag;
+no text was provided for refs named foo
 
-Cite error: 
ref tag with name "unused" defined in 
references is not used in prior text.
-Cite error: ref 
tag in references has conflicting group attribute 
"1".
-Cite error: ref 
tag defined in references has no name attribute.
+Cite error: ref 
tag with name "unused" defined in references is not used 
in prior text.
+Cite error: ref tag 
in references has conflicting group attribute 
"1".
+Cite error: ref tag 
defined in references has no name attribute.
 
 !! end
 
@@ -473,8 +473,8 @@
 !! input
 Bla.
 !! result
-Bla.Cite error: Invalid 
ref tag;
-refs with no name must have content
+Bla.Cite error: Invalid 
ref tag;
+refs with no name must have content
 
 !! end
 
@@ -483,8 +483,8 @@
 !! input
 Bla.
 !! result
-Bla.Cite error: Invalid 
ref tag;
-refs with no name must have content
+Bla.Cite error: Invalid 
ref tag;
+refs with no name must have content
 
 !! end
 
@@ -494,8 +494,8 @@
 Bla.
 !! result
 Bla.[1]
-↑ Cite error: Invalid ref tag;
-no text was provided for refs named void
+↑ Cite error: Invalid ref tag;
+no text was provided for refs named void
 
 
 !! end
@@ -527,8 +527,8 @@
 Page one.This ref is invalid.
 
 !! result
-Page one.Cite error: Invalid 
ref tag;
-invalid names, e.g. too many
+Page one.Cite error: Invalid 
ref tag;
+invalid names, e.g. too many
 
 !! end
 
@@ -543,7 +543,7 @@
 [1]
 
 
-↑ 1.0 1.1 abc 
Cite error: Invalid 
ref tag; name "a" defined multiple times with different 
content
+↑ 1.0 1.1 abc 
Cite error: Invalid 
ref tag; name "a" defined multiple times with different 
content
 
 
 
@@ -561,7 +561,7 @@
 [1]
 
 
-↑ abc Cite error: Invalid ref 
tag; name "a" defined multiple times with different content
+↑ abc Cite error: Invalid ref 
tag; name "a" defined multiple times with different content
 
 
 
@@ -578,7 +578,7 @@
 [1]
 
 
-↑ abc Cite error: Invalid ref 
tag; name "a" defined multiple times with different content
+↑ abc Cite error: Invalid ref 
tag; name "a" defined multiple times with different content
 
 
 
@@ -596,7 +596,7 @@
 [1]
 
 
-↑ abc Cite error: Invalid ref 
tag; name "a" defined multiple times with different content
+↑ abc Cite error: Invalid ref 
tag; name "a" defined multiple times with different content
 
 
 
diff --git a/modules/ext.cite.styles.css 

[MediaWiki-commits] [Gerrit] Move the labs pdns db server into hiera. - change (operations/puppet)

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

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

Change subject: Move the labs pdns db server into hiera.
..

Move the labs pdns db server into hiera.

Previously labtest was hitting the production pdns db,
which isn't going to work at all.

Change-Id: If2c1bbe28b422db7359931b464925bc10167cd1a
---
M hieradata/codfw/labtest.yaml
M hieradata/eqiad.yaml
M modules/role/manifests/labs/dns.pp
3 files changed, 3 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/65/271465/1

diff --git a/hieradata/codfw/labtest.yaml b/hieradata/codfw/labtest.yaml
index 0dda8a2..5f86b5f 100644
--- a/hieradata/codfw/labtest.yaml
+++ b/hieradata/codfw/labtest.yaml
@@ -28,6 +28,7 @@
 labs_ldap_dns_host_secondary:  
"labtestservices2001.wikimedia.org"
 
 labs_dns_host:  "labtest-ns0.wikimedia.org"
+labs_dns_db_server: 'labtestcontrol2001.wikimedia.org'
 labs_recursor:  "labtest-recursor0.wikimedia.org"
 
 ldap_labs_hostname: labtestservices2001.wikimedia.org
diff --git a/hieradata/eqiad.yaml b/hieradata/eqiad.yaml
index 95e998c..48d62b7 100644
--- a/hieradata/eqiad.yaml
+++ b/hieradata/eqiad.yaml
@@ -92,6 +92,7 @@
 
 # These are the up-and-coming, better dns servers:
 labs_dns_host:  "labs-ns2.wikimedia.org"
+labs_dns_db_server: 'm5-master.eqiad.wmnet'
 labs_recursor:  "labs-recursor1.wikimedia.org"
 
 novaconfig:
diff --git a/modules/role/manifests/labs/dns.pp 
b/modules/role/manifests/labs/dns.pp
index 8e6de8e..cee7fe0 100644
--- a/modules/role/manifests/labs/dns.pp
+++ b/modules/role/manifests/labs/dns.pp
@@ -8,7 +8,7 @@
 dns_auth_ipaddress => $::ipaddress_eth0,
 dns_auth_query_address => $::ipaddress_eth0,
 dns_auth_soa_name  => hiera('labs_dns_host'),
-pdns_db_host   => 'm5-master.eqiad.wmnet',
+pdns_db_host   => hiera('labs_dns_db_server'),
 pdns_db_password   => $passwords::pdns::db_pass,
 }
 

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

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

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


[MediaWiki-commits] [Gerrit] Update VE core submodule to master (cdfd84e) - change (mediawiki...VisualEditor)

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

Change subject: Update VE core submodule to master (cdfd84e)
..


Update VE core submodule to master (cdfd84e)

New changes:
c02ea46 Clarify documentation of directionality methods
43c9b6f Move initialisation browser support checking from downstream
c89be66 Localisation updates from https://translatewiki.net.
5fb7907 Follow-up c89be66: Fix build for added language 'nan'
fc74fab dm.ElementLinearData.compareElements: Add a few missed test cases

Local changes:
Use initialisation browser support checking from upstream

Depends-On: I27a8e7b4376647f01cee648de987dc3ca6a060d5
Change-Id: I3fc79422ee5e487cf5fae3929fe492f21cd2840a
---
M .jsduck/categories.json
M .jsduck/eg-iframe.html
M extension.json
M lib/ve
M modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.init.js
5 files changed, 18 insertions(+), 37 deletions(-)

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



diff --git a/.jsduck/categories.json b/.jsduck/categories.json
index bfe492b..925e5e1 100644
--- a/.jsduck/categories.json
+++ b/.jsduck/categories.json
@@ -68,6 +68,7 @@
"ve.init",
"ve.init.Platform",
"ve.init.Target",
+   "window.VisualEditorSupportCheck",
"ve.init.sa*"
]
},
diff --git a/.jsduck/eg-iframe.html b/.jsduck/eg-iframe.html
index 7088d16..bb5d318 100644
--- a/.jsduck/eg-iframe.html
+++ b/.jsduck/eg-iframe.html
@@ -123,6 +123,9 @@


 
+   
+   
+


 
diff --git a/extension.json b/extension.json
index ab99cf3..93ce9ad 100644
--- a/extension.json
+++ b/extension.json
@@ -246,6 +246,13 @@
"mobile"
]
},
+   "ext.visualEditor.supportCheck": {
+   "scripts": "lib/ve/src/init/ve.init.SupportCheck.js",
+   "targets": [
+   "desktop",
+   "mobile"
+   ]
+   },
"ext.visualEditor.desktopArticleTarget.init": {
"class": "VisualEditorDesktopArticleTargetInitModule",
"scripts": 
"modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.init.js",
@@ -268,6 +275,7 @@
"mediawiki.util",
"mediawiki.api.options",
"user.options",
+   "ext.visualEditor.supportCheck",
"ext.visualEditor.track"
],
"messages": [
@@ -845,7 +853,8 @@
"rangefix",
"papaparse",
"jquery.client",
-   "ext.visualEditor.base"
+   "ext.visualEditor.base",
+   "ext.visualEditor.supportCheck"
],
"messages": [
"visualeditor",
diff --git a/lib/ve b/lib/ve
index 33d090b..cdfd84e 16
--- a/lib/ve
+++ b/lib/ve
-Subproject commit 33d090bc4e15e7936c3ac31956d8f0375c50b709
+Subproject commit cdfd84ea545250dfcc28bdfec011d808cc748951
diff --git a/modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.init.js 
b/modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.init.js
index 6d2c1ef..bdd6e38 100644
--- a/modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.init.js
+++ b/modules/ve-mw/init/targets/ve.init.mw.DesktopArticleTarget.init.js
@@ -21,7 +21,7 @@
  */
 ( function () {
var conf, tabMessages, uri, pageExists, viewUri, veEditUri, isViewPage, 
isEditPage,
-   pageCanLoadVE, init, support, targetPromise, enable, 
tempdisable, autodisable,
+   pageCanLoadVE, init, targetPromise, enable, tempdisable, 
autodisable,
tabPreference, userPrefEnabled, initialWikitext, oldid, 
multipleSectionEditLinks,
active = false,
progressStep = 0,
@@ -303,36 +303,7 @@
veEditUri.extend( { oldid: oldid } );
}
 
-   support = {
-   es5: !!(
-   // It would be much easier to do a quick inline 
function that asserts "use strict"
-   // works, but since IE9 doesn't support strict mode 
(and we don't use strict mode) we
-   // have to instead list all the ES5 features we do use.
-   Array.isArray &&
-   Array.prototype.filter &&
-   

[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 0f2ef11..cebaacb - change (mediawiki/extensions)

2016-02-17 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

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

Change subject: Syncronize VisualEditor: 0f2ef11..cebaacb
..

Syncronize VisualEditor: 0f2ef11..cebaacb

Change-Id: Ib5bba722331762c749c4add7f5b8d8a101ec0e43
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)


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

diff --git a/VisualEditor b/VisualEditor
index 0f2ef11..cebaacb 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 0f2ef11ca36f0edf05a2b030221c1cf5b1afe570
+Subproject commit cebaacb5463dc4135f01b38641419edcb7a3fee4

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib5bba722331762c749c4add7f5b8d8a101ec0e43
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 0f2ef11..cebaacb - change (mediawiki/extensions)

2016-02-17 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: 0f2ef11..cebaacb
..


Syncronize VisualEditor: 0f2ef11..cebaacb

Change-Id: Ib5bba722331762c749c4add7f5b8d8a101ec0e43
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Jenkins-mwext-sync: Verified; Looks good to me, approved



diff --git a/VisualEditor b/VisualEditor
index 0f2ef11..cebaacb 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 0f2ef11ca36f0edf05a2b030221c1cf5b1afe570
+Subproject commit cebaacb5463dc4135f01b38641419edcb7a3fee4

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib5bba722331762c749c4add7f5b8d8a101ec0e43
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 
Gerrit-Reviewer: Jenkins-mwext-sync 

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


[MediaWiki-commits] [Gerrit] Include composer autoloader in default settings file - change (wikimedia...crm)

2016-02-17 Thread Cdentinger (Code Review)
Cdentinger has submitted this change and it was merged.

Change subject: Include composer autoloader in default settings file
..


Include composer autoloader in default settings file

With luck, this will be copied to settings.php during install

Change-Id: Id72b02359106f39031dcd1eb3abd221dff0cae88
---
M sites/default/default.settings.php
1 file changed, 4 insertions(+), 0 deletions(-)

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



diff --git a/sites/default/default.settings.php 
b/sites/default/default.settings.php
index 40f552e..9e2dd67 100644
--- a/sites/default/default.settings.php
+++ b/sites/default/default.settings.php
@@ -551,3 +551,7 @@
  * Remove the leading hash signs to disable.
  */
 # $conf['allow_authorize_operations'] = FALSE;
+
+# Added by WMF to load Composer dependencies
+require_once __DIR__ . '/../../vendor/autoload.php';
+

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id72b02359106f39031dcd1eb3abd221dff0cae88
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] dm.ElementLinearData.compareElements: Add a few missed test ... - change (VisualEditor/VisualEditor)

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

Change subject: dm.ElementLinearData.compareElements: Add a few missed test 
cases
..


dm.ElementLinearData.compareElements: Add a few missed test cases

Use of "(!)" to express surprise/alarm/regret at expected behaviour that
shouldn't be.

Change-Id: I40fcebc1fda2ffe7e0465e7e76b72a655de36bbb
---
M tests/dm/lineardata/ve.dm.ElementLinearData.test.js
1 file changed, 75 insertions(+), 1 deletion(-)

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



diff --git a/tests/dm/lineardata/ve.dm.ElementLinearData.test.js 
b/tests/dm/lineardata/ve.dm.ElementLinearData.test.js
index f545c08..6c0664f 100644
--- a/tests/dm/lineardata/ve.dm.ElementLinearData.test.js
+++ b/tests/dm/lineardata/ve.dm.ElementLinearData.test.js
@@ -1961,7 +1961,81 @@
}
 } );
 
-// TODO: ve.dm.ElementLinearData.static.compareElements
+QUnit.test( 'compareElements', function ( assert ) {
+   var i,
+   cases = [
+   {
+   a: '母',
+   b: '母',
+   comparison: true,
+   msg: 'Identical unannotated characters are 
identical'
+   },
+   {
+   a: '다',
+   b: '가',
+   comparison: false,
+   msg: 'Non-identical unannotated characters are 
not identical'
+   },
+   {
+   a: [ 'F', [ 0 ] ],
+   b: [ 'F', [ 0 ] ],
+   comparison: true,
+   msg: 'Identically-annotated identical 
characters are identical'
+   },
+   {
+   a: [ 'F', [ 0 ] ],
+   b: [ 'F', [ 1 ] ],
+   comparison: true,
+   msg: 'Identical characters, 
non-identically-annotated, are identical (!)'
+   },
+   {
+   a: 'F',
+   b: [ 'F', [ 0 ] ],
+   comparison: true,
+   msg: 'Identical characters, one annotated, one 
not, are identical (!)'
+   },
+   {
+   a: { type: 'heading' },
+   b: { type: 'heading' },
+   comparison: true,
+   msg: 'Identical opening elements are identical'
+   },
+   {
+   a: { type: 'heading' },
+   b: { type: '/heading' },
+   comparison: false,
+   msg: 'Matching opening and closing elements are 
not identical'
+   },
+   {
+   a: { type: 'heading', attributes: { level: 3 } 
},
+   b: { type: 'heading', attributes: { level: 3 } 
},
+   comparison: true,
+   msg: 'Identical elements with identical 
attributes are identical'
+   },
+   {
+   a: { type: 'heading', attributes: { level: 3 } 
},
+   b: { type: 'heading', attributes: { level: 2 } 
},
+   comparison: false,
+   msg: 'Identical elements with non-identical 
attributes are not identical'
+   },
+   {
+   a: { type: 'heading', attributes: { level: 3 } 
},
+   b: { type: 'heading' },
+   comparison: false,
+   msg: 'Identical elements, one without an 
attribute, are not identical'
+   }
+   ];
+
+   QUnit.expect( cases.length );
+   for ( i = 0; i < cases.length; i++ ) {
+   assert.equal(
+   ve.dm.ElementLinearData.static.compareElements( cases[ 
i ].a, cases[ i ].b ),
+   cases[ i ].comparison,
+   cases[ i ].msg
+   );
+   }
+} );
+
 // TODO: ve.dm.ElementLinearData#getAnnotationIndexesFromOffset
 // TODO: ve.dm.ElementLinearData#setAnnotationsAtOffset
 // TODO: ve.dm.ElementLinearData#getCharacterData

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I40fcebc1fda2ffe7e0465e7e76b72a655de36bbb
Gerrit-PatchSet: 4

[MediaWiki-commits] [Gerrit] Rename get_recon_file_date function - change (wikimedia...crm)

2016-02-17 Thread Cdentinger (Code Review)
Cdentinger has submitted this change and it was merged.

Change subject: Rename get_recon_file_date function
..


Rename get_recon_file_date function

Not all audit reports come every day, and we just need some key
to sort them chronologically. Rename function to reflect usage.
Also fix Astropay sort key validation regex.

Bug: T121129
Change-Id: I32c08c6ef1f6e21ac3ae74ec8cc1d5e03b44
---
M sites/all/modules/wmf_audit/BaseAuditProcessor.php
M sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php
M sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php
M sites/all/modules/wmf_audit/worldpay/WorldpayAuditProcessor.php
4 files changed, 19 insertions(+), 12 deletions(-)

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



diff --git a/sites/all/modules/wmf_audit/BaseAuditProcessor.php 
b/sites/all/modules/wmf_audit/BaseAuditProcessor.php
index 667094d..3e24d63 100644
--- a/sites/all/modules/wmf_audit/BaseAuditProcessor.php
+++ b/sites/all/modules/wmf_audit/BaseAuditProcessor.php
@@ -34,7 +34,13 @@
 
protected function get_log_line_xml_parent_nodes() {}
 
-   abstract protected function get_recon_file_date( $file );
+   /**
+* Get some identifier for a given files to let us sort all
+* recon files for this processor chronologically.
+* @param string $file name of the recon file
+* @return string key for chronological sort
+*/
+   abstract protected function get_recon_file_sort_key( $file );
 
abstract protected function regex_for_recon();
 
@@ -477,26 +483,27 @@
}
 
/**
-* Returns an array of the full paths to all valid reconciliation files
+* Returns an array of the full paths to all valid reconciliation files,
+* sorted in chronological order.
 * @return array Full paths to all recon files
 */
protected function get_all_recon_files() {
$files_directory = $this->get_recon_dir();
//foreach file in the directory, if it matches our pattern, add 
it to the array.
-   $files_by_date = array();
+   $files_by_sort_key = array();
if ( $handle = opendir( $files_directory ) ) {
while ( ( $file = readdir( $handle ) ) !== false ) {
if ( $this->get_filetype( $file ) === 'recon' ) 
{
-   $filedate = $this->get_recon_file_date( 
$file ); //which is not the same thing as the edited date... probably.
-   $files_by_date[$filedate][] = 
$files_directory . $file;
+   $sort_key = 
$this->get_recon_file_sort_key( $file ); // report date or sequence number or 
something
+   $files_by_sort_key[$sort_key][] = 
$files_directory . $file;
}
}
closedir( $handle );
-   ksort( $files_by_date );
+   ksort( $files_by_sort_key );
// now flatten it
$files = array();
-   foreach ( $files_by_date as $date => $date_files ) {
-   $files = array_merge( $files, $date_files );
+   foreach ( $files_by_sort_key as $key => $key_files ) {
+   $files = array_merge( $files, $key_files );
}
return $files;
} else {
diff --git a/sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php 
b/sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php
index 01e3aae..1a7547a 100644
--- a/sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php
+++ b/sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php
@@ -9,7 +9,7 @@
return new AuditParser();
}
 
-   protected function get_recon_file_date( $file ) {
+   protected function get_recon_file_sort_key( $file ) {
// Example:  2015-09-29-SETTLEMENT_DATA_353863080016707.csv
// For that, we'd want to return 20150929
$parts = preg_split( '/-/', $file );
diff --git a/sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php 
b/sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php
index 6a87c1f..d67b10e 100644
--- a/sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php
+++ b/sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php
@@ -9,13 +9,13 @@
return new AstroPayAudit();
}
 
-   protected function get_recon_file_date( $file ) {
+   protected function get_recon_file_sort_key( $file ) {
// Example:  wikimedia_report_2015-06-16.csv
// For that, we'd want to return 20150616
$parts = preg_split( 

[MediaWiki-commits] [Gerrit] OO.ui.debounce: If an immediate timeout is already waiting, ... - change (oojs/ui)

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

Change subject: OO.ui.debounce: If an immediate timeout is already waiting, 
don't re-set it
..


OO.ui.debounce: If an immediate timeout is already waiting, don't re-set it

OO.ui.debounce normally has to re-set the internal timeout every time
the function is called, so that the real call occurs only once at the
end, `wait` milliseconds after last debounced call.

But `wait` equal to 0 (an immediate timeout) is a special case. It
means that the real call will occur as soon as the work on current
thread finishes. Therefore, if an immediate timeout is already set,
but wasn't fired yet (indicated by `timeout` being non-null), we don't
need to do anything.

(The `immediate` parameter of the function is confusingly named and
not relevant here. It should be named `callAtStart` or something.)

Bug: T126786
Change-Id: Ia3a8fcda1bde76c9085bd8f6f5478dd43848e056
---
M src/core.js
M tests/core.test.js
2 files changed, 59 insertions(+), 2 deletions(-)

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



diff --git a/src/core.js b/src/core.js
index 5f7f61c..64649df 100644
--- a/src/core.js
+++ b/src/core.js
@@ -239,8 +239,10 @@
if ( immediate && !timeout ) {
func.apply( context, args );
}
-   clearTimeout( timeout );
-   timeout = setTimeout( later, wait );
+   if ( !timeout || wait ) {
+   clearTimeout( timeout );
+   timeout = setTimeout( later, wait );
+   }
};
 };
 
diff --git a/tests/core.test.js b/tests/core.test.js
index d914504..c26f207 100644
--- a/tests/core.test.js
+++ b/tests/core.test.js
@@ -93,3 +93,58 @@
$html.remove();
}
 } );
+
+QUnit.asyncTest( 'debounce', 4, function ( assert ) {
+   var
+   realSetTimeout = window.setTimeout,
+   ourSetTimeout = function () {
+   setTimeoutCalled++;
+   return realSetTimeout.apply( window, arguments );
+   },
+   funCalled,
+   setTimeoutCalled,
+   fun = function () {
+   funCalled++;
+   },
+   cases = [
+   function () {
+   var fun50 = OO.ui.debounce( fun, 50 );
+   funCalled = 0;
+   setTimeoutCalled = 0;
+   window.setTimeout = ourSetTimeout;
+   fun50();
+   fun50();
+   window.setTimeout = realSetTimeout;
+   setTimeout( function () {
+   assert.strictEqual( setTimeoutCalled, 
2, 'wait=50: setTimeout was called twice' );
+   assert.strictEqual( funCalled, 1, 
'wait=50: debounced function was executed once' );
+   maybeFinishTest();
+   }, 100 );
+   },
+   function () {
+   var fun0 = OO.ui.debounce( fun );
+   funCalled = 0;
+   setTimeoutCalled = 0;
+   window.setTimeout = ourSetTimeout;
+   fun0();
+   fun0();
+   window.setTimeout = realSetTimeout;
+   setTimeout( function () {
+   assert.strictEqual( setTimeoutCalled, 
1, 'wait=0: setTimeout was called once' );
+   assert.strictEqual( funCalled, 1, 
'wait=0: debounced function was executed once' );
+   maybeFinishTest();
+   }, 100 );
+   }
+   ],
+   casesDone = 0,
+   maybeFinishTest = function () {
+   if ( casesDone === 2 ) {
+   QUnit.start();
+   } else {
+   cases[ casesDone ]();
+   casesDone++;
+   }
+   };
+
+   maybeFinishTest();
+} );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia3a8fcda1bde76c9085bd8f6f5478dd43848e056
Gerrit-PatchSet: 5
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński 
Gerrit-Reviewer: Bartosz Dziewoński 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: 

[MediaWiki-commits] [Gerrit] resetUserEmail: Allow resetting email without scrambling pas... - change (mediawiki/core)

2016-02-17 Thread Mattflaschen (Code Review)
Mattflaschen has uploaded a new change for review.

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

Change subject: resetUserEmail: Allow resetting email without scrambling 
password
..

resetUserEmail: Allow resetting email without scrambling password

MediaWiki-Vagrant has a short script that could use resetUserEmail.php
with this change.

Change-Id: Ieb0da6cc358506174f1ff01116d0b286f814b2c7
---
M maintenance/resetUserEmail.php
1 file changed, 8 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/63/271463/1

diff --git a/maintenance/resetUserEmail.php b/maintenance/resetUserEmail.php
index 816e8a4..8d0873f 100644
--- a/maintenance/resetUserEmail.php
+++ b/maintenance/resetUserEmail.php
@@ -34,6 +34,9 @@
$this->addDescription( "Resets a user's email" );
$this->addArg( 'user', 'Username or user ID, if starts with #', 
true );
$this->addArg( 'email', 'Email to assign' );
+
+   $this->addOption( 'no-reset-password', 'Don\'t reset the 
user\'s password', false, false );
+
parent::__construct();
}
 
@@ -57,8 +60,11 @@
$user->setEmail( $email );
$user->setEmailAuthenticationTimestamp( wfTimestampNow() );
$user->saveSettings();
-   // Kick whomever is currently controlling the account off
-   $user->setPassword( 
PasswordFactory::generateRandomPasswordString( 128 ) );
+
+   if ( !$this->hasOption( 'no-reset-password' ) ) {
+   // Kick whomever is currently controlling the account 
off
+   $user->setPassword( 
PasswordFactory::generateRandomPasswordString( 128 ) );
+   }
}
 }
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ieb0da6cc358506174f1ff01116d0b286f814b2c7
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] [POC] ResourceLoader: Default targets to both environments - change (mediawiki/core)

2016-02-17 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review.

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

Change subject: [POC] ResourceLoader: Default targets to both environments
..

[POC] ResourceLoader: Default targets to both environments

Change-Id: I7eda4b2045f7e704fff8bed19534ddec371b7787
---
M includes/resourceloader/ResourceLoaderFileModule.php
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/62/271462/1

diff --git a/includes/resourceloader/ResourceLoaderFileModule.php 
b/includes/resourceloader/ResourceLoaderFileModule.php
index b31e8dc..556d50a 100644
--- a/includes/resourceloader/ResourceLoaderFileModule.php
+++ b/includes/resourceloader/ResourceLoaderFileModule.php
@@ -126,7 +126,7 @@
/** @var bool Whether mw.loader.state() call should be omitted */
protected $raw = false;
 
-   protected $targets = [ 'desktop' ];
+   protected $targets = [ 'desktop', 'mobile' ];
 
/**
 * @var bool Whether getStyleURLsForDebug should return raw file paths,

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

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

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


[MediaWiki-commits] [Gerrit] Forward maniphest security extension to release/2016-02-18/2 - change (operations/puppet)

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

Change subject: Forward maniphest security extension to release/2016-02-18/2
..


Forward maniphest security extension to release/2016-02-18/2

Had to remove a file that conflicted with the update.

Also have to remove the event listener config to avoid
class-not-found exceptions.

Change-Id: Ib03d555817ecc6e83b54f8f796c881c5e3f3279a
---
M manifests/role/phabricator.pp
1 file changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp
index ae4d184..db7b72d 100644
--- a/manifests/role/phabricator.pp
+++ b/manifests/role/phabricator.pp
@@ -54,7 +54,7 @@
 mysql_admin_user => $role::phabricator::config::mysql_adminuser,
 mysql_admin_pass => $role::phabricator::config::mysql_adminpass,
 sprint_tag   => 'release/2016-02-18/1',
-security_tag => $current_tag,
+security_tag => 'release/2016-02-18/2',
 libraries=> ['/srv/phab/libext/Sprint/src',
 '/srv/phab/libext/security/src'],
 extension_tag=> 'release/2016-02-18/1',
@@ -76,7 +76,7 @@
 'metamta.reply-handler-domain'  => $domain,
 'repository.default-local-path' => '/srv/phab/repos',
 'phd.taskmasters'   => 10,
-'events.listeners'  => 
['SecurityPolicyEventListener'],
+'events.listeners'  => [],
 'diffusion.allow-http-auth' => true,
 'diffusion.ssh-host'=> 'git-ssh.wikimedia.org',
 },
@@ -221,7 +221,7 @@
 git_tag   => $current_tag,
 lock_file => '/var/run/phab_repo_lock',
 sprint_tag=> 'release/2016-02-18/1',
-security_tag  => $current_tag,
+security_tag  => 'release/2016-02-18/2',
 libraries => ['/srv/phab/libext/Sprint/src',
   '/srv/phab/libext/security/src'],
 extension_tag => 'release/2016-02-18/1',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib03d555817ecc6e83b54f8f796c881c5e3f3279a
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: 20after4 
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] Forward maniphest security extension to release/2016-02-18/2 - change (operations/puppet)

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

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

Change subject: Forward maniphest security extension to release/2016-02-18/2
..

Forward maniphest security extension to release/2016-02-18/2

Had to remove a file that conflicted with the update.

Also have to remove the event listener config to avoid
class-not-found exceptions.

Change-Id: Ib03d555817ecc6e83b54f8f796c881c5e3f3279a
---
M manifests/role/phabricator.pp
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/61/271461/1

diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp
index ae4d184..db7b72d 100644
--- a/manifests/role/phabricator.pp
+++ b/manifests/role/phabricator.pp
@@ -54,7 +54,7 @@
 mysql_admin_user => $role::phabricator::config::mysql_adminuser,
 mysql_admin_pass => $role::phabricator::config::mysql_adminpass,
 sprint_tag   => 'release/2016-02-18/1',
-security_tag => $current_tag,
+security_tag => 'release/2016-02-18/2',
 libraries=> ['/srv/phab/libext/Sprint/src',
 '/srv/phab/libext/security/src'],
 extension_tag=> 'release/2016-02-18/1',
@@ -76,7 +76,7 @@
 'metamta.reply-handler-domain'  => $domain,
 'repository.default-local-path' => '/srv/phab/repos',
 'phd.taskmasters'   => 10,
-'events.listeners'  => 
['SecurityPolicyEventListener'],
+'events.listeners'  => [],
 'diffusion.allow-http-auth' => true,
 'diffusion.ssh-host'=> 'git-ssh.wikimedia.org',
 },
@@ -221,7 +221,7 @@
 git_tag   => $current_tag,
 lock_file => '/var/run/phab_repo_lock',
 sprint_tag=> 'release/2016-02-18/1',
-security_tag  => $current_tag,
+security_tag  => 'release/2016-02-18/2',
 libraries => ['/srv/phab/libext/Sprint/src',
   '/srv/phab/libext/security/src'],
 extension_tag => 'release/2016-02-18/1',

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

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

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


[MediaWiki-commits] [Gerrit] Do not unauthenticate if autocreation fails due to a race - change (mediawiki/core)

2016-02-17 Thread Code Review
Gergő Tisza has uploaded a new change for review.

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

Change subject: Do not unauthenticate if autocreation fails due to a race
..

Do not unauthenticate if autocreation fails due to a race

Bug: T70012
Change-Id: I523ee94744ac943ede78af59ab381b65ae26e672
---
M includes/session/SessionManager.php
1 file changed, 15 insertions(+), 6 deletions(-)


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

diff --git a/includes/session/SessionManager.php 
b/includes/session/SessionManager.php
index d3b7a2d..7d41ba4 100644
--- a/includes/session/SessionManager.php
+++ b/includes/session/SessionManager.php
@@ -475,12 +475,21 @@
$status = $user->addToDatabase();
if ( !$status->isOK() ) {
// @codeCoverageIgnoreStart
-   $logger->error( __METHOD__ . ': failed with 
message ' . $status->getWikiText(),
-   array(
-   'username' => $userName,
-   ) );
-   $user->setId( 0 );
-   $user->loadFromId();
+   // double-check for a race condition (T70012)
+   $id = User::idFromName( $user->getName(), 
User::READ_LATEST );
+   if ( $id ) {
+   $logger->info( __METHOD__ . ': tried to 
autocreate existing user',
+   array(
+   'username' => $userName,
+   ) );
+   } else {
+   $logger->error( __METHOD__ . ': failed 
with message ' . $status->getWikiText(),
+   array(
+   'username' => $userName,
+   ) );
+   }
+   $user->setId( $id );
+   $user->loadFromId( User::READ_LATEST );
return false;
// @codeCoverageIgnoreEnd
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I523ee94744ac943ede78af59ab381b65ae26e672
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza 

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


[MediaWiki-commits] [Gerrit] Avoid parsing HTML when creating nodes - change (mediawiki/core)

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

Change subject: Avoid parsing HTML when creating  nodes
..


Avoid parsing HTML when creating  nodes

We used to create them like $( '' ), which
actually does HTML parsing under the hood, because on IE 8 and lower
trying to change the 'type' of an  node throws an exception.
But we dropped support for IE 8 recently and no longer need to do that.

Upstream change for OOjs UI is I166f5ab0dce5ab47dc6a1f4e2e5ad012635911ed.

Find: \$\( '' \)
Replace with: $( '' ).attr( 'type', '\1' )

Change-Id: Ie86f8917e8ce100de22006516daa542ad178aab6
---
M resources/src/mediawiki.special/mediawiki.special.search.js
M resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js
M resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
M resources/src/mediawiki/api/upload.js
M tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js
5 files changed, 25 insertions(+), 25 deletions(-)

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



diff --git a/resources/src/mediawiki.special/mediawiki.special.search.js 
b/resources/src/mediawiki.special/mediawiki.special.search.js
index 730119e..ab83e1a 100644
--- a/resources/src/mediawiki.special/mediawiki.special.search.js
+++ b/resources/src/mediawiki.special/mediawiki.special.search.js
@@ -16,14 +16,14 @@
$( '' )
.text( mw.msg( 'powersearch-togglelabel' ) )
).append(
-   $( '' )
+   $( '' ).attr( 'type', 'button' )
.attr( 'id', 'mw-search-toggleall' )
.prop( 'value', mw.msg( 'powersearch-toggleall' 
) )
.click( function () {
$checkboxes.prop( 'checked', true );
} )
).append(
-   $( '' )
+   $( '' ).attr( 'type', 'button' )
.attr( 'id', 'mw-search-togglenone' )
.prop( 'value', mw.msg( 
'powersearch-togglenone' ) )
.click( function () {
diff --git a/resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js 
b/resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js
index df148c7..7f36137 100644
--- a/resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js
+++ b/resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js
@@ -358,7 +358,7 @@
if ( spec.intercalarySize ) {
$.each( spec.intercalarySize, 
reduceFunc );
}
-   $field = $( '' )
+   $field = $( '' ).attr( 'type', 
'text' )
.attr( {
tabindex: disabled ? -1 
: 0,
size: spec.size,
@@ -762,7 +762,7 @@
 * @private
 */
mw.widgets.datetime.DateTimeInputWidget.prototype.getInputElement = 
function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'hidden' );
};
 
/**
diff --git a/resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js 
b/resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
index 3e03502..cba580bb1 100644
--- a/resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
+++ b/resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
@@ -235,7 +235,7 @@
 * @protected
 */
mw.widgets.DateInputWidget.prototype.getInputElement = function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'hidden' );
};
 
/**
diff --git a/resources/src/mediawiki/api/upload.js 
b/resources/src/mediawiki/api/upload.js
index 47d80d6..437ddec 100644
--- a/resources/src/mediawiki/api/upload.js
+++ b/resources/src/mediawiki/api/upload.js
@@ -61,7 +61,7 @@
 * @return {jQuery}
 */
function getHiddenInput( name, val ) {
-   return $( '' )
+   return $( '' ).attr( 'type', 'hidden' )
.attr( 'name', name )
.val( val );
}
diff --git a/tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js 
b/tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js
index 0cb9cc8..81c116c 100644
--- a/tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js
+++ b/tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js
@@ -66,14 +66,14 @@
 
byteLimitTest( {
description: 'Plain text input',
-   $input: $( '' ),
+   $input: $( '' ).attr( 'type', 'text' ),
sample: 

[MediaWiki-commits] [Gerrit] Avoid parsing HTML when creating nodes - change (oojs/ui)

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

Change subject: Avoid parsing HTML when creating  nodes
..


Avoid parsing HTML when creating  nodes

We used to create them like $( '' ), which
actually does HTML parsing under the hood, because on IE 8 and lower
trying to change the 'type' of an  node throws an exception.
But we dropped support for IE 8 recently and no longer need to do that.

Change-Id: I166f5ab0dce5ab47dc6a1f4e2e5ad012635911ed
---
M src/widgets/CheckboxInputWidget.js
M src/widgets/DropdownInputWidget.js
M src/widgets/RadioInputWidget.js
M src/widgets/RadioSelectInputWidget.js
M src/widgets/SelectFileWidget.js
M src/widgets/TextInputWidget.js
6 files changed, 7 insertions(+), 7 deletions(-)

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



diff --git a/src/widgets/CheckboxInputWidget.js 
b/src/widgets/CheckboxInputWidget.js
index 8540c47..58e6780 100644
--- a/src/widgets/CheckboxInputWidget.js
+++ b/src/widgets/CheckboxInputWidget.js
@@ -76,7 +76,7 @@
  * @protected
  */
 OO.ui.CheckboxInputWidget.prototype.getInputElement = function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'checkbox' );
 };
 
 /**
diff --git a/src/widgets/DropdownInputWidget.js 
b/src/widgets/DropdownInputWidget.js
index 7891374..c3a5f83 100644
--- a/src/widgets/DropdownInputWidget.js
+++ b/src/widgets/DropdownInputWidget.js
@@ -71,7 +71,7 @@
if ( config.$input ) {
return config.$input.addClass( 'oo-ui-element-hidden' );
}
-   return $( '' );
+   return $( '' ).attr( 'type', 'hidden' );
 };
 
 /**
diff --git a/src/widgets/RadioInputWidget.js b/src/widgets/RadioInputWidget.js
index 485847f..65cb65c 100644
--- a/src/widgets/RadioInputWidget.js
+++ b/src/widgets/RadioInputWidget.js
@@ -76,7 +76,7 @@
  * @protected
  */
 OO.ui.RadioInputWidget.prototype.getInputElement = function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'radio' );
 };
 
 /**
diff --git a/src/widgets/RadioSelectInputWidget.js 
b/src/widgets/RadioSelectInputWidget.js
index 39c0963..ea70b26 100644
--- a/src/widgets/RadioSelectInputWidget.js
+++ b/src/widgets/RadioSelectInputWidget.js
@@ -72,7 +72,7 @@
  * @protected
  */
 OO.ui.RadioSelectInputWidget.prototype.getInputElement = function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'hidden' );
 };
 
 /**
diff --git a/src/widgets/SelectFileWidget.js b/src/widgets/SelectFileWidget.js
index 36c1d3d..7ac83b4 100644
--- a/src/widgets/SelectFileWidget.js
+++ b/src/widgets/SelectFileWidget.js
@@ -147,7 +147,7 @@
 OO.ui.SelectFileWidget.static.isSupported = function () {
var $input;
if ( OO.ui.SelectFileWidget.static.isSupportedCache === null ) {
-   $input = $( '' );
+   $input = $( '' ).attr( 'type', 'file' );
OO.ui.SelectFileWidget.static.isSupportedCache = $input[ 0 
].files !== undefined;
}
return OO.ui.SelectFileWidget.static.isSupportedCache;
@@ -316,7 +316,7 @@
return;
}
 
-   this.$input = $( '' );
+   this.$input = $( '' ).attr( 'type', 'file' );
this.$input.on( 'change', this.onFileSelectedHandler );
this.$input.on( 'click', function ( e ) {
// Prevents dropTarget to get clicked which calls
diff --git a/src/widgets/TextInputWidget.js b/src/widgets/TextInputWidget.js
index 895ffa2..f3ceaf4 100644
--- a/src/widgets/TextInputWidget.js
+++ b/src/widgets/TextInputWidget.js
@@ -472,7 +472,7 @@
 OO.ui.TextInputWidget.prototype.getInputElement = function ( config ) {
return config.multiline ?
$( '' ) :
-   $( '' );
+   $( '' ).attr( 'type', this.getSaneType( config ) );
 };
 
 /**

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I166f5ab0dce5ab47dc6a1f4e2e5ad012635911ed
Gerrit-PatchSet: 1
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński 
Gerrit-Reviewer: Bartosz Dziewoński 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: Ricordisamoa 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Avoid parsing HTML when creating nodes - change (mediawiki/core)

2016-02-17 Thread Code Review
Bartosz Dziewoński has uploaded a new change for review.

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

Change subject: Avoid parsing HTML when creating  nodes
..

Avoid parsing HTML when creating  nodes

We used to create them like $( '' ), which
actually does HTML parsing under the hood, because on IE 8 and lower
trying to change the 'type' of an  node throws an exception.
But we dropped support for IE 8 recently and no longer need to do that.

Upstream change for OOjs UI is I166f5ab0dce5ab47dc6a1f4e2e5ad012635911ed.

Find: \$\( '' \)
Replace with: $( '' ).attr( 'type', '\1' )

Change-Id: Ie86f8917e8ce100de22006516daa542ad178aab6
---
M resources/src/mediawiki.special/mediawiki.special.search.js
M resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js
M resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
M resources/src/mediawiki/api/upload.js
M tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js
5 files changed, 25 insertions(+), 25 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/59/271459/1

diff --git a/resources/src/mediawiki.special/mediawiki.special.search.js 
b/resources/src/mediawiki.special/mediawiki.special.search.js
index 730119e..ab83e1a 100644
--- a/resources/src/mediawiki.special/mediawiki.special.search.js
+++ b/resources/src/mediawiki.special/mediawiki.special.search.js
@@ -16,14 +16,14 @@
$( '' )
.text( mw.msg( 'powersearch-togglelabel' ) )
).append(
-   $( '' )
+   $( '' ).attr( 'type', 'button' )
.attr( 'id', 'mw-search-toggleall' )
.prop( 'value', mw.msg( 'powersearch-toggleall' 
) )
.click( function () {
$checkboxes.prop( 'checked', true );
} )
).append(
-   $( '' )
+   $( '' ).attr( 'type', 'button' )
.attr( 'id', 'mw-search-togglenone' )
.prop( 'value', mw.msg( 
'powersearch-togglenone' ) )
.click( function () {
diff --git a/resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js 
b/resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js
index df148c7..7f36137 100644
--- a/resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js
+++ b/resources/src/mediawiki.widgets.datetime/DateTimeInputWidget.js
@@ -358,7 +358,7 @@
if ( spec.intercalarySize ) {
$.each( spec.intercalarySize, 
reduceFunc );
}
-   $field = $( '' )
+   $field = $( '' ).attr( 'type', 
'text' )
.attr( {
tabindex: disabled ? -1 
: 0,
size: spec.size,
@@ -762,7 +762,7 @@
 * @private
 */
mw.widgets.datetime.DateTimeInputWidget.prototype.getInputElement = 
function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'hidden' );
};
 
/**
diff --git a/resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js 
b/resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
index 3e03502..cba580bb1 100644
--- a/resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
+++ b/resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
@@ -235,7 +235,7 @@
 * @protected
 */
mw.widgets.DateInputWidget.prototype.getInputElement = function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'hidden' );
};
 
/**
diff --git a/resources/src/mediawiki/api/upload.js 
b/resources/src/mediawiki/api/upload.js
index 47d80d6..437ddec 100644
--- a/resources/src/mediawiki/api/upload.js
+++ b/resources/src/mediawiki/api/upload.js
@@ -61,7 +61,7 @@
 * @return {jQuery}
 */
function getHiddenInput( name, val ) {
-   return $( '' )
+   return $( '' ).attr( 'type', 'hidden' )
.attr( 'name', name )
.val( val );
}
diff --git a/tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js 
b/tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js
index 0cb9cc8..81c116c 100644
--- a/tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js
+++ b/tests/qunit/suites/resources/jquery/jquery.byteLimit.test.js
@@ -66,14 +66,14 @@
 
byteLimitTest( {
description: 'Plain text input',
-   $input: $( '' ),
+   $input: $( '' 

[MediaWiki-commits] [Gerrit] phabricator: allow port 25 for ipv6 too - change (operations/puppet)

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

Change subject: phabricator: allow port 25 for ipv6 too
..


phabricator: allow port 25 for ipv6 too

Bug: T127053
Change-Id: I07d6929b358bd3d00b251142113368096f4653b5
---
M manifests/role/phabricator.pp
1 file changed, 6 insertions(+), 0 deletions(-)

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



diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp
index 0180bcf..ae4d184 100644
--- a/manifests/role/phabricator.pp
+++ b/manifests/role/phabricator.pp
@@ -172,6 +172,12 @@
 srange => inline_template('(<%= @mail_smarthost.map{|x| 
"@resolve(#{x})" }.join(" ") %>)'),
 }
 
+ferm::service { 'phabmain-smtp_ipv6':
+port   => '25',
+proto  => 'tcp',
+srange => inline_template('(<%= @mail_smarthost.map{|x| 
"@resolve(#{x}, )" }.join(" ") %>)'),
+}
+
 ferm::rule { 'ssh_public':
 rule => 'saddr (0.0.0.0/0 ::/0) daddr (10.64.32.186/32 
208.80.154.250/32 2620:0:861:103:10:64:32:186/128 2620:0:861:ed1a::3:16/128) 
proto tcp dport (22) ACCEPT;',
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I07d6929b358bd3d00b251142113368096f4653b5
Gerrit-PatchSet: 5
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: ArielGlenn 
Gerrit-Reviewer: 20after4 
Gerrit-Reviewer: ArielGlenn 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Filippo Giunchedi 
Gerrit-Reviewer: Muehlenhoff 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Avoid parsing HTML when creating nodes - change (oojs/ui)

2016-02-17 Thread Code Review
Bartosz Dziewoński has uploaded a new change for review.

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

Change subject: Avoid parsing HTML when creating  nodes
..

Avoid parsing HTML when creating  nodes

We used to create them like $( '' ), which
actually does HTML parsing under the hood, because on IE 8 and lower
trying to change the 'type' of an  node throws an exception.
But we dropped support for IE 8 recently and no longer need to do that.

Change-Id: I166f5ab0dce5ab47dc6a1f4e2e5ad012635911ed
---
M src/widgets/CheckboxInputWidget.js
M src/widgets/DropdownInputWidget.js
M src/widgets/RadioInputWidget.js
M src/widgets/RadioSelectInputWidget.js
M src/widgets/SelectFileWidget.js
M src/widgets/TextInputWidget.js
6 files changed, 7 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/ui refs/changes/58/271458/1

diff --git a/src/widgets/CheckboxInputWidget.js 
b/src/widgets/CheckboxInputWidget.js
index 8540c47..58e6780 100644
--- a/src/widgets/CheckboxInputWidget.js
+++ b/src/widgets/CheckboxInputWidget.js
@@ -76,7 +76,7 @@
  * @protected
  */
 OO.ui.CheckboxInputWidget.prototype.getInputElement = function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'checkbox' );
 };
 
 /**
diff --git a/src/widgets/DropdownInputWidget.js 
b/src/widgets/DropdownInputWidget.js
index 7891374..c3a5f83 100644
--- a/src/widgets/DropdownInputWidget.js
+++ b/src/widgets/DropdownInputWidget.js
@@ -71,7 +71,7 @@
if ( config.$input ) {
return config.$input.addClass( 'oo-ui-element-hidden' );
}
-   return $( '' );
+   return $( '' ).attr( 'type', 'hidden' );
 };
 
 /**
diff --git a/src/widgets/RadioInputWidget.js b/src/widgets/RadioInputWidget.js
index 485847f..65cb65c 100644
--- a/src/widgets/RadioInputWidget.js
+++ b/src/widgets/RadioInputWidget.js
@@ -76,7 +76,7 @@
  * @protected
  */
 OO.ui.RadioInputWidget.prototype.getInputElement = function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'radio' );
 };
 
 /**
diff --git a/src/widgets/RadioSelectInputWidget.js 
b/src/widgets/RadioSelectInputWidget.js
index 39c0963..ea70b26 100644
--- a/src/widgets/RadioSelectInputWidget.js
+++ b/src/widgets/RadioSelectInputWidget.js
@@ -72,7 +72,7 @@
  * @protected
  */
 OO.ui.RadioSelectInputWidget.prototype.getInputElement = function () {
-   return $( '' );
+   return $( '' ).attr( 'type', 'hidden' );
 };
 
 /**
diff --git a/src/widgets/SelectFileWidget.js b/src/widgets/SelectFileWidget.js
index 36c1d3d..7ac83b4 100644
--- a/src/widgets/SelectFileWidget.js
+++ b/src/widgets/SelectFileWidget.js
@@ -147,7 +147,7 @@
 OO.ui.SelectFileWidget.static.isSupported = function () {
var $input;
if ( OO.ui.SelectFileWidget.static.isSupportedCache === null ) {
-   $input = $( '' );
+   $input = $( '' ).attr( 'type', 'file' );
OO.ui.SelectFileWidget.static.isSupportedCache = $input[ 0 
].files !== undefined;
}
return OO.ui.SelectFileWidget.static.isSupportedCache;
@@ -316,7 +316,7 @@
return;
}
 
-   this.$input = $( '' );
+   this.$input = $( '' ).attr( 'type', 'file' );
this.$input.on( 'change', this.onFileSelectedHandler );
this.$input.on( 'click', function ( e ) {
// Prevents dropTarget to get clicked which calls
diff --git a/src/widgets/TextInputWidget.js b/src/widgets/TextInputWidget.js
index 895ffa2..f3ceaf4 100644
--- a/src/widgets/TextInputWidget.js
+++ b/src/widgets/TextInputWidget.js
@@ -472,7 +472,7 @@
 OO.ui.TextInputWidget.prototype.getInputElement = function ( config ) {
return config.multiline ?
$( '' ) :
-   $( '' );
+   $( '' ).attr( 'type', this.getSaneType( config ) );
 };
 
 /**

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I166f5ab0dce5ab47dc6a1f4e2e5ad012635911ed
Gerrit-PatchSet: 1
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński 

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


[MediaWiki-commits] [Gerrit] Fix link element - change (mediawiki...WikimediaPageViewInfo)

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

Change subject: Fix link element
..


Fix link element

Add an href attribute so that it's a proper link with the correct
cursor type.

Change-Id: I32dd9c21390c6a7fef997bef1f2724120c3f1bff
---
M resources/ext.wmpageviewinfo.js
1 file changed, 4 insertions(+), 2 deletions(-)

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



diff --git a/resources/ext.wmpageviewinfo.js b/resources/ext.wmpageviewinfo.js
index e3600f4..a901271 100644
--- a/resources/ext.wmpageviewinfo.js
+++ b/resources/ext.wmpageviewinfo.js
@@ -4,10 +4,12 @@
count = $count.text();
 
// Turn it into an  tag so it's obvious you can click on it
-   $count.html( mw.html.element( 'a', {}, count ) );
+   $count.html( mw.html.element( 'a', { href: '#' }, count ) );
 
-   $count.click( function () {
+   $count.click( function ( e ) {
var myDialog, windowManager;
+   e.preventDefault();
+
// A simple dialog window.
function MyDialog( config ) {
MyDialog.parent.call( this, config );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I32dd9c21390c6a7fef997bef1f2724120c3f1bff
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikimediaPageViewInfo
Gerrit-Branch: master
Gerrit-Owner: Wctaiwan 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Enable tests - change (wikidata...gui)

2016-02-17 Thread Smalyshev (Code Review)
Smalyshev has uploaded a new change for review.

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

Change subject: Enable tests
..

Enable tests

Change-Id: I5f61a0ce9116c64b39d2b36a57869589406853a5
---
M Gruntfile.js
1 file changed, 0 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikidata/query/gui 
refs/changes/57/271457/1

diff --git a/Gruntfile.js b/Gruntfile.js
index 7ff7179..03ec54c 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -13,7 +13,6 @@
'**/*.js',
'!vendor/**',
 '!node_modules/**',
-   '!**/*.js'
]
},
jscs: {
@@ -24,7 +23,6 @@
'*.json',
'**/*.json',
 '!node_modules/**',
-   '!vendor/**'
]
}
} );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5f61a0ce9116c64b39d2b36a57869589406853a5
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/gui
Gerrit-Branch: master
Gerrit-Owner: Smalyshev 

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


[MediaWiki-commits] [Gerrit] Update jscs configuration - change (mediawiki...Scribunto)

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

Change subject: Update jscs configuration
..


Update jscs configuration

Change-Id: I1da096b453413ae0faa06b551e35d270c78e0c41
---
M .jscsrc
M modules/ext.scribunto.edit.js
2 files changed, 2 insertions(+), 8 deletions(-)

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



diff --git a/.jscsrc b/.jscsrc
index a321544..7561d8c 100644
--- a/.jscsrc
+++ b/.jscsrc
@@ -3,7 +3,6 @@
"disallowEmptyBlocks": {
"allExcept": [ "comments" ]
},
-   "jsDoc": false,
"requireDotNotation": {
"allExcept": [ "keywords" ]
}
diff --git a/modules/ext.scribunto.edit.js b/modules/ext.scribunto.edit.js
index 0c857d8..5142927 100644
--- a/modules/ext.scribunto.edit.js
+++ b/modules/ext.scribunto.edit.js
@@ -41,6 +41,7 @@
 
/**
 * Use onkeydown because IE doesn't support onkeypress for arrow keys
+*
 * @param {jQuery.Event} e
 */
function inputKeydown( e ) {
@@ -70,9 +71,6 @@
setTimeout( recalculateInputHeight, 0 );
}
 
-   /**
-* @param {jQuery.Event} e
-*/
function inputFocus() {
if ( sessionContent === null ) {
// No previous state to clear
@@ -337,9 +335,6 @@
}
}
 
-   /**
-* @param {jQuery.Event} e
-*/
function onClearClick() {
$( '#mw-scribunto-output' ).empty();
clearNextRequest = true;
@@ -404,4 +399,4 @@
}
} );
 
-} )( jQuery, mediaWiki );
+}( jQuery, mediaWiki ) );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1da096b453413ae0faa06b551e35d270c78e0c41
Gerrit-PatchSet: 8
Gerrit-Project: mediawiki/extensions/Scribunto
Gerrit-Branch: master
Gerrit-Owner: Paladox 
Gerrit-Reviewer: Addshore 
Gerrit-Reviewer: Anomie 
Gerrit-Reviewer: Aude 
Gerrit-Reviewer: Jackmcbarn 
Gerrit-Reviewer: JanZerebecki 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Mattflaschen 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: Ricordisamoa 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] build: Bump grunt-svg2png to a newer (still personal) versio... - change (oojs/ui)

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

Change subject: build: Bump grunt-svg2png to a newer (still personal) version; 
lots faster
..


build: Bump grunt-svg2png to a newer (still personal) version; lots faster

Change-Id: I4d80115f35c0e04ce40a9139ff88b16a39deb3e5
---
M package.json
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/package.json b/package.json
index a2602a4..6c25322 100644
--- a/package.json
+++ b/package.json
@@ -46,7 +46,7 @@
 "grunt-jsonlint": "1.0.7",
 "grunt-karma": "0.12.1",
 "grunt-promise-q": "0.1.1",
-"grunt-svg2png": 
"git://github.com/jdforrester/grunt-svg2png.git#8bf55ef0c1d4814a5dede5f3f50506cd8c1e89f6",
+"grunt-svg2png": 
"git://github.com/jdforrester/grunt-svg2png.git#b7da0f41921cc7f734f5462b77299e6262d6dc03",
 "grunt-tyops": "0.1.0",
 "karma-chrome-launcher": "0.2.2",
 "karma-coverage": "0.5.3",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I4d80115f35c0e04ce40a9139ff88b16a39deb3e5
Gerrit-PatchSet: 1
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Bartosz Dziewoński 
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] Merge branch 'master' of https://gerrit.wikimedia.org/r/wiki... - change (wikimedia...crm)

2016-02-17 Thread Eileen (Code Review)
Eileen has submitted this change and it was merged.

Change subject: Merge branch 'master' of 
https://gerrit.wikimedia.org/r/wikimedia/fundraising/crm into deployment
..


Merge branch 'master' of 
https://gerrit.wikimedia.org/r/wikimedia/fundraising/crm into deployment

0db4c8f Minor data tidy up spotted during refund spot-checking.
a3696be Follow up on adding missing Refund financial trxns
fc5b8aa Allow setting read timeouts per queue
350750c Fix financial_account.account_type_code to EXP (expense) for Refund 
andn Chargeback
b2f9f86 Get more info when contribution create fails
7568c2a Fix e-Notice due to some Option Values not having the 'name' field 
filled in.

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

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




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

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

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


[MediaWiki-commits] [Gerrit] Merge branch 'master' of https://gerrit.wikimedia.org/r/wiki... - change (wikimedia...crm)

2016-02-17 Thread Eileen (Code Review)
Eileen has uploaded a new change for review.

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

Change subject: Merge branch 'master' of 
https://gerrit.wikimedia.org/r/wikimedia/fundraising/crm into deployment
..

Merge branch 'master' of 
https://gerrit.wikimedia.org/r/wikimedia/fundraising/crm into deployment

0db4c8f Minor data tidy up spotted during refund spot-checking.
a3696be Follow up on adding missing Refund financial trxns
fc5b8aa Allow setting read timeouts per queue
350750c Fix financial_account.account_type_code to EXP (expense) for Refund 
andn Chargeback
b2f9f86 Get more info when contribution create fails
7568c2a Fix e-Notice due to some Option Values not having the 'name' field 
filled in.

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


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/56/271456/1


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

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

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


[MediaWiki-commits] [Gerrit] Update VE core submodule to master (d87c384) - change (mediawiki...VisualEditor)

2016-02-17 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review.

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

Change subject: Update VE core submodule to master (d87c384)
..

Update VE core submodule to master (d87c384)

New changes:
c02ea46 Clarify documentation of directionality methods
43c9b6f Move initialisation browser support checking from downstream
c89be66 Localisation updates from https://translatewiki.net.
5fb7907 Follow-up c89be66: Fix build for added language 'nan'

Change-Id: Ib66330357932421c04c7e71b1ed052aebcd89323
---
M .jsduck/categories.json
M .jsduck/eg-iframe.html
M lib/ve
3 files changed, 4 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/VisualEditor 
refs/changes/55/271455/1

diff --git a/.jsduck/categories.json b/.jsduck/categories.json
index bfe492b..925e5e1 100644
--- a/.jsduck/categories.json
+++ b/.jsduck/categories.json
@@ -68,6 +68,7 @@
"ve.init",
"ve.init.Platform",
"ve.init.Target",
+   "window.VisualEditorSupportCheck",
"ve.init.sa*"
]
},
diff --git a/.jsduck/eg-iframe.html b/.jsduck/eg-iframe.html
index 7088d16..bb5d318 100644
--- a/.jsduck/eg-iframe.html
+++ b/.jsduck/eg-iframe.html
@@ -123,6 +123,9 @@


 
+   
+   
+


 
diff --git a/lib/ve b/lib/ve
index 33d090b..d87c384 16
--- a/lib/ve
+++ b/lib/ve
-Subproject commit 33d090bc4e15e7936c3ac31956d8f0375c50b709
+Subproject commit d87c384bb3d611d8dbdebe43a439973563e7c327

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib66330357932421c04c7e71b1ed052aebcd89323
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Jforrester 

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


[MediaWiki-commits] [Gerrit] Fix e-Notice due to some Option Values not having the 'name'... - change (wikimedia...crm)

2016-02-17 Thread Ejegg (Code Review)
Ejegg has submitted this change and it was merged.

Change subject: Fix e-Notice due to some Option Values not having the 'name' 
field filled in.
..


Fix e-Notice due to some Option Values not having the 'name' field filled in.

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

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index 2f9b093..fcf45ef 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -50,6 +50,7 @@
 wmf_civicrm_update_7110();
 wmf_civicrm_update_7120();
 wmf_civicrm_update_7170();
+wmf_civicrm_update_7180();
 }
 
 /**
@@ -1864,3 +1865,23 @@
WHERE name in ('Refund', 'Chargeback')
   ");
 }
+
+/**
+ * Fix e-Notice due to some Option Values not having the 'name' field filled 
in.
+ *
+ * This is just an e-notice visible in the jenkins log. It appears to do no 
harm
+ * other than having caused me to investigate it when checking the logs.
+ *
+ * T127029.
+ */
+function wmf_civicrm_update_7180() {
+  civicrm_initialize();
+  CRM_Core_DAO::executeQuery("
+UPDATE civicrm_option_group g
+LEFT JOIN civicrm_option_value v ON v.option_group_id = g.id
+INNER JOIN civicrm_custom_field cf ON cf.option_group_id = g.id
+SET v.name = REPLACE(v.value, ' ', '_')
+WHERE
+ v.name IS NULL
+  ");
+}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I91b20869da0236fd3aaeb7ac726c68490cc8cd32
Gerrit-PatchSet: 6
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Eileen 
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] Decode an escaped data attribute before making an API request - change (mediawiki...MobileFrontend)

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

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

Change subject: Decode an escaped data attribute before making an API request
..

Decode an escaped data attribute before making an API request

This step is especially important when the page title is
in cyrillic.

Bug: T127190
Change-Id: Ieb390e6be70b39027196f53f5b8b1661160c3cd1
---
M resources/skins.minerva.talk/init.js
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MobileFrontend 
refs/changes/54/271454/1

diff --git a/resources/skins.minerva.talk/init.js 
b/resources/skins.minerva.talk/init.js
index 5475c38..cd2a39d 100644
--- a/resources/skins.minerva.talk/init.js
+++ b/resources/skins.minerva.talk/init.js
@@ -4,7 +4,7 @@
user = M.require( 'mobile.user/user' ),
Button = M.require( 'mobile.startup/Button' ),
$talk = $( '.talk' ),
-   title = $talk.data( 'title' ) || mw.config.get( 'wgPageName' ),
+   title = decodeURIComponent( $talk.data( 'title' ) ) || 
mw.config.get( 'wgPageName' ),
page = M.getCurrentPage(),
overlayManager = M.require( 'mobile.startup/overlayManager' ),
skin = M.require( 'skins.minerva.scripts/skin' );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ieb390e6be70b39027196f53f5b8b1661160c3cd1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Bmansurov 

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


[MediaWiki-commits] [Gerrit] Move initialisation browser support checking from downstream - change (VisualEditor/VisualEditor)

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

Change subject: Move initialisation browser support checking from downstream
..


Move initialisation browser support checking from downstream

These checks were written in VisualEditor-MediaWiki but apply to all clients
and so are moved here.

Change-Id: I27a8e7b4376647f01cee648de987dc3ca6a060d5
---
M .jsduck/categories.json
M build/modules.json
M demos/ve/demo.minimal.js
M demos/ve/desktop.html
M demos/ve/mobile.html
M src/init/sa/ve.init.sa.Platform.js
M src/init/ve.init.Platform.js
A src/init/ve.init.SupportCheck.js
M tests/index.html
9 files changed, 103 insertions(+), 19 deletions(-)

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



diff --git a/.jsduck/categories.json b/.jsduck/categories.json
index 5f01180..cd1ddf9 100644
--- a/.jsduck/categories.json
+++ b/.jsduck/categories.json
@@ -25,7 +25,12 @@
"groups": [
{
"name": "General",
-   "classes": ["ve.init", "ve.init.Platform", 
"ve.init.Target"]
+   "classes": [
+   "ve.init",
+   "ve.init.Platform",
+   "ve.init.Target",
+   "window.VisualEditorSupportCheck"
+   ]
},
{
"name": "Stand-alone",
diff --git a/build/modules.json b/build/modules.json
index 181e0db..e72d77b 100644
--- a/build/modules.json
+++ b/build/modules.json
@@ -175,6 +175,11 @@
"papaparse"
]
},
+   "visualEditor.supportCheck": {
+   "scripts": [
+   "src/init/ve.init.SupportCheck.js"
+   ]
+   },
"visualEditor.base": {
"dependencies": [
"baselibs",
@@ -193,6 +198,7 @@
"src/init/ve.init.Target.js"
],
"dependencies": [
+   "visualEditor.supportCheck",
"unicodejs",
"rangefix"
]
diff --git a/demos/ve/demo.minimal.js b/demos/ve/demo.minimal.js
index 57bcd72..9ee070f 100644
--- a/demos/ve/demo.minimal.js
+++ b/demos/ve/demo.minimal.js
@@ -5,25 +5,28 @@
  */
 
 // Set up the platform and wait for i18n messages to load
-new ve.init.sa.Platform( ve.messagePaths ).initialize().done( function () {
+new ve.init.sa.Platform( ve.messagePaths ).initialize()
+   .fail( function () {
+   $( '.ve-instance' ).text( 'Sorry, this browser is not 
supported.' );
+   } )
+   .done( function () {
+   // Create the target
+   var target = new ve.init.sa.Target();
 
-   // Create the target
-   var target = new ve.init.sa.Target();
+   // Create a document model for a new surface
+   target.addSurface(
+   ve.dm.converter.getModelFromDom(
+   ve.createDocumentFromHtml( 'Hello, 
World!' ),
+   // Optional: Document language, directionality 
(ltr/rtl)
+   { lang: $.i18n().locale, dir: $( 'body' ).css( 
'direction' ) }
+   )
+   );
 
-   // Create a document model for a new surface
-   target.addSurface(
-   ve.dm.converter.getModelFromDom(
-   ve.createDocumentFromHtml( 'Hello, 
World!' ),
-   // Optional: Document language, directionality (ltr/rtl)
-   { lang: $.i18n().locale, dir: $( 'body' ).css( 
'direction' ) }
-   )
-   );
+   // Append the target to the document
+   $( '.ve-instance' ).append( target.$element );
 
-   // Append the target to the document
-   $( '.ve-instance' ).append( target.$element );
-
-   $( '.ve-demo-convert' ).on( 'click', function () {
-   // Get the current HTML from the surface and display
-   $( '.ve-demo-html' ).val( target.getSurface().getHtml() );
+   $( '.ve-demo-convert' ).on( 'click', function () {
+   // Get the current HTML from the surface and display
+   $( '.ve-demo-html' ).val( target.getSurface().getHtml() 
);
+   } );
} );
-} );
diff --git a/demos/ve/desktop.html b/demos/ve/desktop.html
index c5f9940..fdf0876 100644
--- a/demos/ve/desktop.html
+++ b/demos/ve/desktop.html
@@ -142,6 +142,9 @@


 
+   
+   
+


 
diff --git a/demos/ve/mobile.html b/demos/ve/mobile.html
index bb35c37..d8d83b8 100644
--- a/demos/ve/mobile.html
+++ 

[MediaWiki-commits] [Gerrit] lvs: remove rt_cache_rebuild_count sysctl - change (operations/puppet)

2016-02-17 Thread BBlack (Code Review)
BBlack has uploaded a new change for review.

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

Change subject: lvs: remove rt_cache_rebuild_count sysctl
..

lvs: remove rt_cache_rebuild_count sysctl

This doesn't exist in 3.6+.  We've been on jessie w/ 3.19 for a
while, and now we're on 4.4, so this is just historical cruft.

Change-Id: I9e987367309a0db6c6938319116f71c4543053bb
---
M modules/lvs/manifests/balancer.pp
1 file changed, 0 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/53/271453/1

diff --git a/modules/lvs/manifests/balancer.pp 
b/modules/lvs/manifests/balancer.pp
index 617f5fc..9f2d144 100644
--- a/modules/lvs/manifests/balancer.pp
+++ b/modules/lvs/manifests/balancer.pp
@@ -54,11 +54,6 @@
 # LVS servers sit on all subnets
 'net.ipv4.ip_forward' => 0,
 
-# Disable the route cache
-# It is prone to DDoS attacks, and was even
-# removed in >= 3.6 kernels.
-'net.ipv4.rt_cache_rebuild_count' => -1,
-
 # Defenses (see 
http://www.linuxvirtualserver.org/docs/defense.html)
 # amemthresh is available mem threshold for triggering defenses,
 # specified in pages.  Default is 1024 (4MB).

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9e987367309a0db6c6938319116f71c4543053bb
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] Vary the parser cache on $wgResponsiveImages - change (mediawiki/core)

2016-02-17 Thread Ori.livneh (Code Review)
Ori.livneh has uploaded a new change for review.

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

Change subject: Vary the parser cache on $wgResponsiveImages
..

Vary the parser cache on $wgResponsiveImages

The point of responsive images is to let the client select the right image
variants. Unfortunately, all major browsers make the mistake of only
considering one criterion -- device pixel density. Connection speed and
bandwidth costs are not considered. There is thus good reason for wanting to
suppress the srcset attribute based on what the server knows about the user:
the value of a user-set preference, for example, or the user's device or
connection profile.

For MediaWiki to be able to serve srcset in some cases and suppress it in
others, need the parser cache to vary on the value of $wgResponsiveImages.

$wgResponsiveImages was introduced in MediaWiki 1.21 (released in 2013), and it
has always been true by default. To avoid needlessly invalidating existing
parser cache values, we only update the key when $wgResponsiveImages is false.

Change-Id: Ifa29d8b430ba1198f73c792264e3c4fc90d23f97
---
M includes/parser/ParserOptions.php
1 file changed, 8 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/52/271452/1

diff --git a/includes/parser/ParserOptions.php 
b/includes/parser/ParserOptions.php
index 49c6ce9..4891e0c 100644
--- a/includes/parser/ParserOptions.php
+++ b/includes/parser/ParserOptions.php
@@ -763,7 +763,7 @@
 * @return string Page rendering hash
 */
public function optionsHash( $forOptions, $title = null ) {
-   global $wgRenderHashAppend;
+   global $wgRenderHashAppend, $wgResponsiveImages;
 
// FIXME: Once the cache key is reorganized this argument
// can be dropped. It was used when the math extension was
@@ -826,6 +826,13 @@
$confstr .= '!printable=1';
}
 
+   // Responsive images are enabled by default, so only record the 
value
+   // of $wgResponsiveImages when it is false, to avoid needlessly
+   // invalidating parser cache entries which predate Ifa29d8b4.
+   if ( $wgResponsiveImages === false ) {
+   $confstr .= '!responsiveimages=0';
+   }
+
if ( $this->mExtraKey != '' ) {
$confstr .= $this->mExtraKey;
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifa29d8b430ba1198f73c792264e3c4fc90d23f97
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Ori.livneh 

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


[MediaWiki-commits] [Gerrit] Hygiene: Remove old function rmTransclusions() - change (mediawiki...mobileapps)

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

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

Change subject: Hygiene: Remove old function rmTransclusions()
..

Hygiene: Remove old function rmTransclusions()

Was commented out anyways.
Code has been moved to https://github.com/gwicke/parsoid-dom-utils

Bug: T121881
Change-Id: I72adc418f9ad9e4532fedfb3fcc9abc3eefa41c2
---
M lib/transforms.js
1 file changed, 0 insertions(+), 40 deletions(-)


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

diff --git a/lib/transforms.js b/lib/transforms.js
index 38bd4dc..cde8d8a 100644
--- a/lib/transforms.js
+++ b/lib/transforms.js
@@ -93,41 +93,6 @@
 }
 }
 
-//** Remove transclusion data-mw provided by Parsoid. */
-/*
-function rmTransclusions(doc, names) {
-var nodes = doc.querySelectorAll('[typeof~=mw:Transclusion]');
-var dataMW;
-for (var i = 0; i < nodes.length; i++) {
-var node = nodes[i];
-dataMW = node.getAttribute('data-mw');
-if (dataMW) {
-var name;
-try {
-name = 
JSON.parse(dataMW).parts[0].template.target.wt.trim().toLowerCase();
-} catch (e) {}
-if (name && names[name]) {
-// remove siblings if the about matches
-var about = node.getAttribute('about');
-var next = node.nextSibling;
-while (next
-&& ( // Skip over inter-element whitespace
-next.nodeType === NodeType.TEXT && 
/^\w+$/.test(next.nodeValue))
-// same about
-|| next.getAttribute && next.getAttribute('about') === about) {
-if (next.nodeType !== 3) {
-node.parentNode.removeChild(next);
-}
-next = node.nextSibling;
-}
-// finally, remove the transclusion node itself
-node.parentNode.removeChild(node);
-}
-}
-}
-}
-*/
-
 function rewriteUrlAttribute(doc, selector, attribute) {
 var ps = doc.querySelectorAll(selector) || [],
 value;
@@ -189,11 +154,6 @@
 }
 
 function applyOptionalParsoidSpecificTransformations(doc) {
-// TODO: remove content produced by specific templates. Still needs work 
since it removes too much.
-//rmTransclusions(doc, {
-//reflist: true
-//});
-
 rmAttributes(doc, 'a:not([rel=nofollow])', ['rel']); // only leave rel 
attributes with value nofollow
 rmAttributes(doc, 'a', ['about', 'data-mw', 'id', 'typeof', 'title']);
 rmAttributes(doc, 'div,ol,p,ul,table', ['about', 'data-mw', 'id', 
'typeof']);

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

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

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


[MediaWiki-commits] [Gerrit] Get more info when contribution create fails - change (wikimedia...crm)

2016-02-17 Thread Ejegg (Code Review)
Ejegg has submitted this change and it was merged.

Change subject: Get more info when contribution create fails
..


Get more info when contribution create fails

I just saw this in the failmail

Error: INVALID_MESSAGE Cannot create contribution, civi error!
Source: 'DB Error: unknown error'

There is not enough info to tell what it relates to so this patch increased the 
error info

Change-Id: I93ad1ced10a397e99fb87b8a5ce93e8ad5659e07
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.module
1 file changed, 7 insertions(+), 7 deletions(-)

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.module 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.module
index 0e7ecaa..a1ad028 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.module
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.module
@@ -326,6 +326,7 @@
 'contribution_recur_id' => $msg['contribution_recur_id'],
 'check_number' => $msg['check_number'],
 'soft_credit_to' => $msg['soft_credit_to_id'],
+'debug' => TRUE,
 
 // API required fields
 'version' => '3'
@@ -406,16 +407,15 @@
 }
 
 watchdog( 'wmf_civicrm', 'Contribution array for 
civicrm_contribution_add(): ' . print_r($contribution, TRUE), NULL, 
WATCHDOG_DEBUG);
-
-$contribution_result = civicrm_api( "Contribution", "Create", 
$contribution );
-
-watchdog( 'wmf_civicrm', 'Contribution result from 
civicrm_contribution_add(): ' . print_r($contribution_result, TRUE), NULL, 
WATCHDOG_DEBUG);
-
-if ( array_key_exists( 'is_error', $contribution_result ) && 
$contribution_result['is_error'] != 0 ) {
+try {
+  $contribution_result = civicrm_api3("Contribution", "Create", 
$contribution);
+  watchdog('wmf_civicrm', 'Contribution result from 
civicrm_contribution_add(): ' . print_r($contribution_result, TRUE), NULL, 
WATCHDOG_DEBUG);
+}
+catch (CiviCRM_API3_Exception $e) {
 throw new WmfException(
 'INVALID_MESSAGE',
 'Cannot create contribution, civi error!',
-$contribution_result['error_message']
+$e->getMessage() . print_r($e->getExtraParams(), TRUE)
 );
 }
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I93ad1ced10a397e99fb87b8a5ce93e8ad5659e07
Gerrit-PatchSet: 2
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Eileen 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
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] Rename get_recon_file_date function - change (wikimedia...crm)

2016-02-17 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review.

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

Change subject: Rename get_recon_file_date function
..

Rename get_recon_file_date function

Not all audit reports come every day, and we just need some key
to sort them chronologically. Rename function to reflect usage.

Bug: T121129
Change-Id: I32c08c6ef1f6e21ac3ae74ec8cc1d5e03b44
---
M sites/all/modules/wmf_audit/BaseAuditProcessor.php
M sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php
M sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php
M sites/all/modules/wmf_audit/worldpay/WorldpayAuditProcessor.php
4 files changed, 18 insertions(+), 11 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/50/271450/1

diff --git a/sites/all/modules/wmf_audit/BaseAuditProcessor.php 
b/sites/all/modules/wmf_audit/BaseAuditProcessor.php
index 667094d..3e24d63 100644
--- a/sites/all/modules/wmf_audit/BaseAuditProcessor.php
+++ b/sites/all/modules/wmf_audit/BaseAuditProcessor.php
@@ -34,7 +34,13 @@
 
protected function get_log_line_xml_parent_nodes() {}
 
-   abstract protected function get_recon_file_date( $file );
+   /**
+* Get some identifier for a given files to let us sort all
+* recon files for this processor chronologically.
+* @param string $file name of the recon file
+* @return string key for chronological sort
+*/
+   abstract protected function get_recon_file_sort_key( $file );
 
abstract protected function regex_for_recon();
 
@@ -477,26 +483,27 @@
}
 
/**
-* Returns an array of the full paths to all valid reconciliation files
+* Returns an array of the full paths to all valid reconciliation files,
+* sorted in chronological order.
 * @return array Full paths to all recon files
 */
protected function get_all_recon_files() {
$files_directory = $this->get_recon_dir();
//foreach file in the directory, if it matches our pattern, add 
it to the array.
-   $files_by_date = array();
+   $files_by_sort_key = array();
if ( $handle = opendir( $files_directory ) ) {
while ( ( $file = readdir( $handle ) ) !== false ) {
if ( $this->get_filetype( $file ) === 'recon' ) 
{
-   $filedate = $this->get_recon_file_date( 
$file ); //which is not the same thing as the edited date... probably.
-   $files_by_date[$filedate][] = 
$files_directory . $file;
+   $sort_key = 
$this->get_recon_file_sort_key( $file ); // report date or sequence number or 
something
+   $files_by_sort_key[$sort_key][] = 
$files_directory . $file;
}
}
closedir( $handle );
-   ksort( $files_by_date );
+   ksort( $files_by_sort_key );
// now flatten it
$files = array();
-   foreach ( $files_by_date as $date => $date_files ) {
-   $files = array_merge( $files, $date_files );
+   foreach ( $files_by_sort_key as $key => $key_files ) {
+   $files = array_merge( $files, $key_files );
}
return $files;
} else {
diff --git a/sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php 
b/sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php
index 01e3aae..1a7547a 100644
--- a/sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php
+++ b/sites/all/modules/wmf_audit/amazon/AmazonAuditProcessor.php
@@ -9,7 +9,7 @@
return new AuditParser();
}
 
-   protected function get_recon_file_date( $file ) {
+   protected function get_recon_file_sort_key( $file ) {
// Example:  2015-09-29-SETTLEMENT_DATA_353863080016707.csv
// For that, we'd want to return 20150929
$parts = preg_split( '/-/', $file );
diff --git a/sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php 
b/sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php
index 6a87c1f..fc0af38 100644
--- a/sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php
+++ b/sites/all/modules/wmf_audit/astropay/AstroPayAuditProcessor.php
@@ -9,7 +9,7 @@
return new AstroPayAudit();
}
 
-   protected function get_recon_file_date( $file ) {
+   protected function get_recon_file_sort_key( $file ) {
// Example:  wikimedia_report_2015-06-16.csv
// For that, we'd want to return 20150616
$parts = preg_split( 

[MediaWiki-commits] [Gerrit] build: Bump grunt-svg2png to a newer (still personal) versio... - change (oojs/ui)

2016-02-17 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review.

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

Change subject: build: Bump grunt-svg2png to a newer (still personal) version; 
lots faster
..

build: Bump grunt-svg2png to a newer (still personal) version; lots faster

Change-Id: I4d80115f35c0e04ce40a9139ff88b16a39deb3e5
---
M package.json
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/ui refs/changes/49/271449/1

diff --git a/package.json b/package.json
index a2602a4..6c25322 100644
--- a/package.json
+++ b/package.json
@@ -46,7 +46,7 @@
 "grunt-jsonlint": "1.0.7",
 "grunt-karma": "0.12.1",
 "grunt-promise-q": "0.1.1",
-"grunt-svg2png": 
"git://github.com/jdforrester/grunt-svg2png.git#8bf55ef0c1d4814a5dede5f3f50506cd8c1e89f6",
+"grunt-svg2png": 
"git://github.com/jdforrester/grunt-svg2png.git#b7da0f41921cc7f734f5462b77299e6262d6dc03",
 "grunt-tyops": "0.1.0",
 "karma-chrome-launcher": "0.2.2",
 "karma-coverage": "0.5.3",

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4d80115f35c0e04ce40a9139ff88b16a39deb3e5
Gerrit-PatchSet: 1
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Jforrester 

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


[MediaWiki-commits] [Gerrit] Revert "Depool ulsfo" - change (operations/dns)

2016-02-17 Thread BBlack (Code Review)
BBlack has submitted this change and it was merged.

Change subject: Revert "Depool ulsfo"
..


Revert "Depool ulsfo"

This reverts commit ec388837956e1f78750e331b3f3987a51fcc31bd.

Bug: T127094
Change-Id: I43fd299ead8ce094c73be4c3c7da7065314051f9
---
M admin_state
1 file changed, 0 insertions(+), 1 deletion(-)

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



diff --git a/admin_state b/admin_state
index 17d80a2..7295eeb 100644
--- a/admin_state
+++ b/admin_state
@@ -69,4 +69,3 @@
 # geoip/text-*/ulsfo => UP # ... this overrides the line above completely
 #
 ##
-geoip/generic-map/ulsfo => DOWN

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I43fd299ead8ce094c73be4c3c7da7065314051f9
Gerrit-PatchSet: 1
Gerrit-Project: operations/dns
Gerrit-Branch: master
Gerrit-Owner: BBlack 
Gerrit-Reviewer: BBlack 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Fix link element - change (mediawiki...WikimediaPageViewInfo)

2016-02-17 Thread Wctaiwan (Code Review)
Wctaiwan has uploaded a new change for review.

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

Change subject: Fix link element
..

Fix link element

Add an href attribute so that it's a proper link with the correct
cursor type.

Change-Id: I32dd9c21390c6a7fef997bef1f2724120c3f1bff
---
M resources/ext.wmpageviewinfo.js
1 file changed, 4 insertions(+), 2 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikimediaPageViewInfo 
refs/changes/48/271448/1

diff --git a/resources/ext.wmpageviewinfo.js b/resources/ext.wmpageviewinfo.js
index e3600f4..a901271 100644
--- a/resources/ext.wmpageviewinfo.js
+++ b/resources/ext.wmpageviewinfo.js
@@ -4,10 +4,12 @@
count = $count.text();
 
// Turn it into an  tag so it's obvious you can click on it
-   $count.html( mw.html.element( 'a', {}, count ) );
+   $count.html( mw.html.element( 'a', { href: '#' }, count ) );
 
-   $count.click( function () {
+   $count.click( function ( e ) {
var myDialog, windowManager;
+   e.preventDefault();
+
// A simple dialog window.
function MyDialog( config ) {
MyDialog.parent.call( this, config );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I32dd9c21390c6a7fef997bef1f2724120c3f1bff
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikimediaPageViewInfo
Gerrit-Branch: master
Gerrit-Owner: Wctaiwan 

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


[MediaWiki-commits] [Gerrit] Switch to BasicObjectMapper for TopicListEntry - change (mediawiki...Flow)

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

Change subject: Switch to BasicObjectMapper for TopicListEntry
..


Switch to BasicObjectMapper for TopicListEntry

Before, depending on what was loaded and ordering, either a full
(with last_updated) or regular (just what's in flow_topic_list)
version of TopicListEntry would be cached by CachingObjectMapper.

That meant that moving would fail on some boards due to topic
moderation.

The default ordering is now last updated, and moves
trigger the ordering issue and force a re-render that requires
an offset to avoid moderated topics.

I looked at an alternative:

Add a separate mapper for TopicListLastUpdatedStorage (even just
any separate mapper would work, but I was going to make the updated
one uses a tri-key PK including last updated).

This was somewhat feasible, but still turned out more invasive than
seemed justified (e.g. we would have needed a separate
ObjectManager just for this reason, and then a way to get that out
of ManagerGroup, and conditionally pass it to Pager...).

I doubt there are any actual significant performance issues with this
(fromStorageRow and toStorageRow are both simple for TopicListEntry).

At some point, we could consider changing how CachingObjectMapper
works to avoid this issue in general, or revisiting whether we need
this caching layer.

Bug: T126701
Change-Id: I43872e87b0cf181e1a351bb1e258645413d07fbb
(cherry picked from commit b563a6e2bfbc89a7a6df3442e63a9adb1d1cc062)
---
M container.php
1 file changed, 3 insertions(+), 1 deletion(-)

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



diff --git a/container.php b/container.php
index ed7be41..70070ee 100644
--- a/container.php
+++ b/container.php
@@ -505,7 +505,9 @@
);
 };
 $c['storage.topic_list.mapper'] = function( $c ) {
-   return CachingObjectMapper::model(
+   // Must be BasicObjectMapper, due to variance in when
+   // we have workflow_last_update_timestamp
+   return BasicObjectMapper::model(
$c['storage.topic_list.class'],
$c['storage.topic_list.primary_key']
);

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I43872e87b0cf181e1a351bb1e258645413d07fbb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: wmf/1.27.0-wmf.13
Gerrit-Owner: Mattflaschen 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Add ady.wikipedia.org to wikipedia_family.py - change (pywikibot/core)

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

Change subject: Add ady.wikipedia.org to wikipedia_family.py
..


Add ady.wikipedia.org to wikipedia_family.py

Change-Id: I2c407a1029394b9a07e3afaf2693db910058833a
---
M pywikibot/families/wikipedia_family.py
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/pywikibot/families/wikipedia_family.py 
b/pywikibot/families/wikipedia_family.py
index 6d8eb43..576b5d6 100644
--- a/pywikibot/families/wikipedia_family.py
+++ b/pywikibot/families/wikipedia_family.py
@@ -78,7 +78,7 @@
 'srn', 'ki', 'ab', 'ltg', 'zu', 'lg', 'om', 'rmy', 'chy', 'cu',
 'tw', 'tn', 'chr', 'rn', 'bi', 'pih', 'xh', 'tum', 'got', 'sm',
 'ss', 'pnt', 'ch', 'bm', 'iu', 'ee', 'st', 'ts', 'ks', 'fj', 'ak',
-'sg', 'ik', 've', 'ff', 'ny', 'ti', 'dz', 'cr',
+'sg', 'ik', 've', 'ff', 'ny', 'ti', 'dz', 'cr', 'ady'
 ]
 
 # Sites we want to edit but not count as real languages

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2c407a1029394b9a07e3afaf2693db910058833a
Gerrit-PatchSet: 2
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Ladsgroup 
Gerrit-Reviewer: John Vandenberg 
Gerrit-Reviewer: Ladsgroup 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Get more info when contribution create fails - change (wikimedia...crm)

2016-02-17 Thread Eileen (Code Review)
Eileen has uploaded a new change for review.

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

Change subject: Get more info when contribution create fails
..

Get more info when contribution create fails

I just saw this in the failmail

Error: INVALID_MESSAGE Cannot create contribution, civi error!
Source: 'DB Error: unknown error'

There is not enough info to tell what it relates to so this patch increased the 
error info

Change-Id: I93ad1ced10a397e99fb87b8a5ce93e8ad5659e07
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.module
1 file changed, 7 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/47/271447/1

diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.module 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.module
index 0e7ecaa..f1cb21b 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.module
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.module
@@ -326,6 +326,7 @@
 'contribution_recur_id' => $msg['contribution_recur_id'],
 'check_number' => $msg['check_number'],
 'soft_credit_to' => $msg['soft_credit_to_id'],
+'debug' => TRUE,
 
 // API required fields
 'version' => '3'
@@ -406,16 +407,15 @@
 }
 
 watchdog( 'wmf_civicrm', 'Contribution array for 
civicrm_contribution_add(): ' . print_r($contribution, TRUE), NULL, 
WATCHDOG_DEBUG);
-
-$contribution_result = civicrm_api( "Contribution", "Create", 
$contribution );
-
-watchdog( 'wmf_civicrm', 'Contribution result from 
civicrm_contribution_add(): ' . print_r($contribution_result, TRUE), NULL, 
WATCHDOG_DEBUG);
-
-if ( array_key_exists( 'is_error', $contribution_result ) && 
$contribution_result['is_error'] != 0 ) {
+try {
+  $contribution_result = civicrm_api3("Contribution", "Create", 
$contribution);
+  watchdog('wmf_civicrm', 'Contribution result from 
civicrm_contribution_add(): ' . print_r($contribution_result, TRUE), NULL, 
WATCHDOG_DEBUG);
+}
+catch (CiviCRM_API3_Exception $e) {
 throw new WmfException(
 'INVALID_MESSAGE',
 'Cannot create contribution, civi error!',
-$contribution_result['error_message']
+$e->getMessage() . print_r($e->getExtraParams(), TRUE),
 );
 }
 

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

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

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


[MediaWiki-commits] [Gerrit] Revert "Depool ulsfo" - change (operations/dns)

2016-02-17 Thread BBlack (Code Review)
BBlack has uploaded a new change for review.

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

Change subject: Revert "Depool ulsfo"
..

Revert "Depool ulsfo"

This reverts commit ec388837956e1f78750e331b3f3987a51fcc31bd.

Bug: T127094
Change-Id: I43fd299ead8ce094c73be4c3c7da7065314051f9
---
M admin_state
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/dns 
refs/changes/46/271446/1

diff --git a/admin_state b/admin_state
index 17d80a2..7295eeb 100644
--- a/admin_state
+++ b/admin_state
@@ -69,4 +69,3 @@
 # geoip/text-*/ulsfo => UP # ... this overrides the line above completely
 #
 ##
-geoip/generic-map/ulsfo => DOWN

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

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

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


[MediaWiki-commits] [Gerrit] Update restbase to 9dae0c9 - change (mediawiki...deploy)

2016-02-17 Thread Ppchelko (Code Review)
Ppchelko has submitted this change and it was merged.

Change subject: Update restbase to 9dae0c9
..


Update restbase to 9dae0c9

List of changes:
0651f82 Use new config format to make modules export valid swagger spec
3b2ceb5 v0.11.0 and updated HyperSwitch dependency
xxx Update node module dependencies

Change-Id: Ic5a64841db2dc19e5b2d0a6be1b3ce7396149717
---
M node_modules/content-type/package.json
M node_modules/hyperswitch/.npmignore
M node_modules/hyperswitch/lib/router.js
M node_modules/hyperswitch/node_modules/ajv/dist/ajv.bundle.js
M node_modules/hyperswitch/node_modules/ajv/dist/ajv.min.js
M node_modules/hyperswitch/node_modules/ajv/dist/ajv.min.js.map
M node_modules/hyperswitch/node_modules/ajv/lib/compile/resolve.js
M node_modules/hyperswitch/node_modules/ajv/lib/dot/custom.def
M node_modules/hyperswitch/node_modules/ajv/lib/dot/definitions.def
M node_modules/hyperswitch/node_modules/ajv/lib/dot/ref.jst
M node_modules/hyperswitch/node_modules/ajv/lib/dotjs/ref.js
M node_modules/hyperswitch/node_modules/ajv/lib/dotjs/validate.js
M node_modules/hyperswitch/node_modules/ajv/package.json
M node_modules/hyperswitch/node_modules/json-stable-stringify/package.json
M node_modules/hyperswitch/node_modules/swagger-ui/package.json
M node_modules/hyperswitch/package.json
A node_modules/hyperswitch/test/router/api_module_1.yaml
A node_modules/hyperswitch/test/router/api_module_2.yaml
M node_modules/hyperswitch/test/router/buildTree.js
A node_modules/hyperswitch/test/router/module_with_resources.js
M node_modules/hyperswitch/test/router/multi_domain_spec.yaml
A node_modules/hyperswitch/test/router/node_modules/sample_module.js
A node_modules/hyperswitch/test/router/options_testing_module.js
A node_modules/hyperswitch/test/router/root_api_spec.yaml
M node_modules/hyperswitch/test/router/secure_subspec.yaml
M node_modules/hyperswitch/test/streaming/test_config.yaml
M node_modules/json-stable-stringify/package.json
M 
node_modules/restbase-mod-table-cassandra/node_modules/json-stable-stringify/package.json
M 
node_modules/restbase-mod-table-cassandra/node_modules/restbase-mod-table-spec/node_modules/routeswitch/node_modules/async/package.json
D node_modules/service-runner/node_modules/hot-shots/CHANGES.md~
M restbase
31 files changed, 575 insertions(+), 299 deletions(-)

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




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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic5a64841db2dc19e5b2d0a6be1b3ce7396149717
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/restbase/deploy
Gerrit-Branch: master
Gerrit-Owner: Mobrovac 
Gerrit-Reviewer: Ppchelko 

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


[MediaWiki-commits] [Gerrit] Update restbase to 9dae0c9 - change (mediawiki...deploy)

2016-02-17 Thread Mobrovac (Code Review)
Mobrovac has uploaded a new change for review.

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

Change subject: Update restbase to 9dae0c9
..

Update restbase to 9dae0c9

List of changes:
0651f82 Use new config format to make modules export valid swagger spec
3b2ceb5 v0.11.0 and updated HyperSwitch dependency
xxx Update node module dependencies

Change-Id: Ic5a64841db2dc19e5b2d0a6be1b3ce7396149717
---
M node_modules/content-type/package.json
M node_modules/hyperswitch/.npmignore
M node_modules/hyperswitch/lib/router.js
M node_modules/hyperswitch/node_modules/ajv/dist/ajv.bundle.js
M node_modules/hyperswitch/node_modules/ajv/dist/ajv.min.js
M node_modules/hyperswitch/node_modules/ajv/dist/ajv.min.js.map
M node_modules/hyperswitch/node_modules/ajv/lib/compile/resolve.js
M node_modules/hyperswitch/node_modules/ajv/lib/dot/custom.def
M node_modules/hyperswitch/node_modules/ajv/lib/dot/definitions.def
M node_modules/hyperswitch/node_modules/ajv/lib/dot/ref.jst
M node_modules/hyperswitch/node_modules/ajv/lib/dotjs/ref.js
M node_modules/hyperswitch/node_modules/ajv/lib/dotjs/validate.js
M node_modules/hyperswitch/node_modules/ajv/package.json
M node_modules/hyperswitch/node_modules/json-stable-stringify/package.json
M node_modules/hyperswitch/node_modules/swagger-ui/package.json
M node_modules/hyperswitch/package.json
A node_modules/hyperswitch/test/router/api_module_1.yaml
A node_modules/hyperswitch/test/router/api_module_2.yaml
M node_modules/hyperswitch/test/router/buildTree.js
A node_modules/hyperswitch/test/router/module_with_resources.js
M node_modules/hyperswitch/test/router/multi_domain_spec.yaml
A node_modules/hyperswitch/test/router/node_modules/sample_module.js
A node_modules/hyperswitch/test/router/options_testing_module.js
A node_modules/hyperswitch/test/router/root_api_spec.yaml
M node_modules/hyperswitch/test/router/secure_subspec.yaml
M node_modules/hyperswitch/test/streaming/test_config.yaml
M node_modules/json-stable-stringify/package.json
M 
node_modules/restbase-mod-table-cassandra/node_modules/json-stable-stringify/package.json
M 
node_modules/restbase-mod-table-cassandra/node_modules/restbase-mod-table-spec/node_modules/routeswitch/node_modules/async/package.json
D node_modules/service-runner/node_modules/hot-shots/CHANGES.md~
M restbase
31 files changed, 575 insertions(+), 299 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/restbase/deploy 
refs/changes/45/271445/1


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic5a64841db2dc19e5b2d0a6be1b3ce7396149717
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/restbase/deploy
Gerrit-Branch: master
Gerrit-Owner: Mobrovac 

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


[MediaWiki-commits] [Gerrit] Changed linking of articles to Linker::link in ChangeList - change (mediawiki/core)

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

Change subject: Changed linking of articles to Linker::link in ChangeList
..


Changed linking of articles to Linker::link in ChangeList

When non-existent categories appear in the changelist
they wont get marked reddue to the use of
Linker::linkKnown.

Bug: T126854
Change-Id: I3dc9746c0fe55e81ffd2df1c04ade6950efcc020
---
M includes/changes/ChangesList.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/includes/changes/ChangesList.php b/includes/changes/ChangesList.php
index 2599cf2..485d523 100644
--- a/includes/changes/ChangesList.php
+++ b/includes/changes/ChangesList.php
@@ -387,7 +387,7 @@
$params = [ 'redirect' => 'no' ];
}
 
-   $articlelink = Linker::linkKnown(
+   $articlelink = Linker::link(
$rc->getTitle(),
null,
[ 'class' => 'mw-changeslist-title' ],

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3dc9746c0fe55e81ffd2df1c04ade6950efcc020
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: WMDE-Fisch 
Gerrit-Reviewer: Addshore 
Gerrit-Reviewer: Jakob 
Gerrit-Reviewer: Tobias Gritschacher 
Gerrit-Reviewer: WMDE-leszek 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Labs: Enable the structured language overlay and increase th... - change (operations/mediawiki-config)

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

Change subject: Labs: Enable the structured language overlay and increase the 
instrumentation rate
..


Labs: Enable the structured language overlay and increase the instrumentation 
rate

In stable 90% of users will see the simpler language overlay, the remaining
10% will see the structured language overlay. In beta 100% of users will see
the structured language overlay.
Increase the stable channel instrumentation rate by a factor of 10.

Change-Id: Id07dbfb923d3145ab35167f7ce153b12aa535e6e
Dependency: If82c5c53b68e881c9d6cad66e48a4af93a54c25d
Bug: T123980
---
M wmf-config/InitialiseSettings-labs.php
1 file changed, 18 insertions(+), 0 deletions(-)

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



diff --git a/wmf-config/InitialiseSettings-labs.php 
b/wmf-config/InitialiseSettings-labs.php
index 307f2bf..ed5ce0a 100644
--- a/wmf-config/InitialiseSettings-labs.php
+++ b/wmf-config/InitialiseSettings-labs.php
@@ -300,6 +300,24 @@
'default' => true,
'enwiki' => false,
),
+   'wgMFExperiments' => array(
+   'default' => array(
+   'languageOverlay' => array(
+   'enabled' => true,
+   'buckets' => array(
+   'control' => 0.9,  // simpler 
overlay
+   'A' => 0.1  // structured 
overlay
+   ),
+   ),
+   'languageOverlayBeta' => array(
+   'enabled' => true,
+   'buckets' => array(
+   'control' => 0,  // simpler 
overlay
+   'A' => 1  // structured overlay
+   ),
+   ),
+   ),
+   ),
'wgMFSchemaMobileWebLanguageSwitcherSampleRate' => array(
'default' => array(
'beta' => 1,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id07dbfb923d3145ab35167f7ce153b12aa535e6e
Gerrit-PatchSet: 2
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Bmansurov 
Gerrit-Reviewer: Catrope 
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] Add ady.wikipedia.org to family members - change (pywikibot/core)

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

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

Change subject: Add ady.wikipedia.org to family members
..

Add ady.wikipedia.org to family members

Change-Id: I2c407a1029394b9a07e3afaf2693db910058833a
---
M pywikibot/families/wikipedia_family.py
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/44/271444/1

diff --git a/pywikibot/families/wikipedia_family.py 
b/pywikibot/families/wikipedia_family.py
index 6d8eb43..576b5d6 100644
--- a/pywikibot/families/wikipedia_family.py
+++ b/pywikibot/families/wikipedia_family.py
@@ -78,7 +78,7 @@
 'srn', 'ki', 'ab', 'ltg', 'zu', 'lg', 'om', 'rmy', 'chy', 'cu',
 'tw', 'tn', 'chr', 'rn', 'bi', 'pih', 'xh', 'tum', 'got', 'sm',
 'ss', 'pnt', 'ch', 'bm', 'iu', 'ee', 'st', 'ts', 'ks', 'fj', 'ak',
-'sg', 'ik', 've', 'ff', 'ny', 'ti', 'dz', 'cr',
+'sg', 'ik', 've', 'ff', 'ny', 'ti', 'dz', 'cr', 'ady'
 ]
 
 # Sites we want to edit but not count as real languages

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2c407a1029394b9a07e3afaf2693db910058833a
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
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] Install the scap package from deb instead of trebuchet - change (operations/puppet)

2016-02-17 Thread Rush (Code Review)
Rush has submitted this change and it was merged.

Change subject: Install the scap package from deb instead of trebuchet
..


Install the scap package from deb instead of trebuchet

This was previously reverted (Iaa518889fa2c8b3d81db9e466cb63d0fcbc30cc4)

Now it's been tested on deployment-tin and it needs to get re-re-verted

This switches scap to use the apt provider and fixes paths to point to
`/usr/bin/$binary` instead of `/srv/deployment/scap/scap/bin/$binary`

Bug: T114363
Change-Id: I7dd552056c6ad58164e44b77e0c20e15daac2a0b
---
M modules/mediawiki/manifests/scap.pp
M modules/mediawiki/templates/mediawiki.sh.erb
M modules/restbase/manifests/deploy.pp
M modules/scap/files/l10nupdate-1
M modules/scap/manifests/init.pp
M modules/scap/manifests/l10nupdate.pp
M modules/scap/templates/mw-deployment-vars.erb
7 files changed, 7 insertions(+), 20 deletions(-)

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



diff --git a/modules/mediawiki/manifests/scap.pp 
b/modules/mediawiki/manifests/scap.pp
index 6a61609..8702c0d 100644
--- a/modules/mediawiki/manifests/scap.pp
+++ b/modules/mediawiki/manifests/scap.pp
@@ -12,7 +12,7 @@
 
 $mediawiki_deployment_dir = '/srv/mediawiki'
 $mediawiki_staging_dir= '/srv/mediawiki-staging'
-$scap_bin_dir = '/srv/deployment/scap/scap/bin'
+$scap_bin_dir = '/usr/bin'
 $mediawiki_web_user   = $::mediawiki::users::web
 
 # /srv/mediawiki is the root path of the MediaWiki deployment tree.
diff --git a/modules/mediawiki/templates/mediawiki.sh.erb 
b/modules/mediawiki/templates/mediawiki.sh.erb
index 0aa6eac..1b16432 100644
--- a/modules/mediawiki/templates/mediawiki.sh.erb
+++ b/modules/mediawiki/templates/mediawiki.sh.erb
@@ -9,6 +9,7 @@
 # into scap.
 
 if groups | grep -Pqw '(wikidev|l10nupdate)'; then
-  PATH="${PATH}:/srv/deployment/scap/scap/bin"
+  # scap is now in /usr/bin thanks to debian package 'scap'
+  # PATH="${PATH}:/srv/deployment/scap/scap/bin"
   umask 0002
 fi
diff --git a/modules/restbase/manifests/deploy.pp 
b/modules/restbase/manifests/deploy.pp
index f5d7d89..45cd3f3 100644
--- a/modules/restbase/manifests/deploy.pp
+++ b/modules/restbase/manifests/deploy.pp
@@ -29,14 +29,6 @@
 source => $public_key_file,
 }
 
-# Using trebuchet provider while scap service deployment is under
-# development—chicken and egg things
-#
-# This should be removed once scap3 is in a final state
-package { 'scap/scap':
-provider => 'trebuchet',
-}
-
 # Rather than futz with adding new functionality to allow a deployment
 # user set per repository in trebuchet, I'm running an exec here
 $dir = '/srv/deployment/restbase/deploy'
diff --git a/modules/scap/files/l10nupdate-1 b/modules/scap/files/l10nupdate-1
index 52e48b5..7b0f6c8 100755
--- a/modules/scap/files/l10nupdate-1
+++ b/modules/scap/files/l10nupdate-1
@@ -7,7 +7,7 @@
 . /etc/profile.d/mediawiki.sh
 
 BINDIR=/usr/local/bin
-SCAPDIR=/srv/deployment/scap/scap/bin
+SCAPDIR=/usr/bin
 # The configuration in CommonSettings.php should match GITDIR and GITREPOS
 GITDIR=/var/lib/l10nupdate/mediawiki
 GITURL=https://gerrit.wikimedia.org/r/p/mediawiki
diff --git a/modules/scap/manifests/init.pp b/modules/scap/manifests/init.pp
index 3a01956..07ebe45 100644
--- a/modules/scap/manifests/init.pp
+++ b/modules/scap/manifests/init.pp
@@ -3,14 +3,9 @@
 # Common role for scap masters and targets
 
 class scap {
-# Using trebuchet provider while scap service deployment is under
-# development -- chicken and egg things
-#
-# This should be removed once scap3 is in a final state (i.e. packaged
-# or deployed via another method)
+
 package { 'scap':
-ensure   => latest,
-provider => 'trebuchet',
+ensure   => '3.0.1-1',
 }
 
 file { '/etc/scap.cfg':
diff --git a/modules/scap/manifests/l10nupdate.pp 
b/modules/scap/manifests/l10nupdate.pp
index 3d4ca08..91abdbf 100644
--- a/modules/scap/manifests/l10nupdate.pp
+++ b/modules/scap/manifests/l10nupdate.pp
@@ -64,7 +64,7 @@
 # This command is equivalent to a restricted sync-dir call that
 # only syncs l10n cache files followed by a scap-rebuild-cdbs
 # call.
-'ALL = (mwdeploy) NOPASSWD: 
/srv/deployment/scap/scap/bin/sync-l10n',
+'ALL = (mwdeploy) NOPASSWD: /usr/bin/sync-l10n',
 # Allow l10nupdate user to run anything as the unprivledged web
 # user. Needed for mwscript actions and related operations.
 "ALL = (${::mediawiki::users::web}) NOPASSWD: ALL",
diff --git a/modules/scap/templates/mw-deployment-vars.erb 
b/modules/scap/templates/mw-deployment-vars.erb
index b0c9230..abd8da3 100644
--- a/modules/scap/templates/mw-deployment-vars.erb
+++ b/modules/scap/templates/mw-deployment-vars.erb
@@ 

[MediaWiki-commits] [Gerrit] Enable the structured language overlay and increase the inst... - change (operations/mediawiki-config)

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

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

Change subject: Enable the structured language overlay and increase the 
instrumentation rate
..

Enable the structured language overlay and increase the instrumentation rate

In stable 90% of users will see the simpler language overlay, the remaining
10% will see the structured language overlay. In beta 100% of users will see
the structured language overlay.
Increase the stable channel instrumentation rate by a factor of 10.

Change-Id: Id07dbfb923d3145ab35167f7ce153b12aa535e6e
Dependency: If82c5c53b68e881c9d6cad66e48a4af93a54c25d
Bug: T123980
---
M wmf-config/InitialiseSettings-labs.php
1 file changed, 18 insertions(+), 0 deletions(-)


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

diff --git a/wmf-config/InitialiseSettings-labs.php 
b/wmf-config/InitialiseSettings-labs.php
index 307f2bf..ed5ce0a 100644
--- a/wmf-config/InitialiseSettings-labs.php
+++ b/wmf-config/InitialiseSettings-labs.php
@@ -300,6 +300,24 @@
'default' => true,
'enwiki' => false,
),
+   'wgMFExperiments' => array(
+   'default' => array(
+   'languageOverlay' => array(
+   'enabled' => true,
+   'buckets' => array(
+   'control' => 0.9,  // simpler 
overlay
+   'A' => 0.1  // structured 
overlay
+   ),
+   ),
+   'languageOverlayBeta' => array(
+   'enabled' => true,
+   'buckets' => array(
+   'control' => 0,  // simpler 
overlay
+   'A' => 1  // structured overlay
+   ),
+   ),
+   ),
+   ),
'wgMFSchemaMobileWebLanguageSwitcherSampleRate' => array(
'default' => array(
'beta' => 1,

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

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

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


[MediaWiki-commits] [Gerrit] Install the scap package from deb instead of trebuchet - change (operations/puppet)

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

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

Change subject: Install the scap package from deb instead of trebuchet
..

Install the scap package from deb instead of trebuchet

This was previously reverted (Iaa518889fa2c8b3d81db9e466cb63d0fcbc30cc4)

Now it's been tested on deployment-tin and it needs to get re-re-verted

This switches scap to use the apt provider and fixes paths to point to
`/usr/bin/$binary` instead of `/srv/deployment/scap/scap/bin/$binary`

Bug: T114363
Change-Id: I7dd552056c6ad58164e44b77e0c20e15daac2a0b
---
M modules/mediawiki/manifests/scap.pp
M modules/mediawiki/templates/mediawiki.sh.erb
M modules/restbase/manifests/deploy.pp
M modules/scap/files/l10nupdate-1
M modules/scap/manifests/init.pp
M modules/scap/manifests/l10nupdate.pp
M modules/scap/templates/mw-deployment-vars.erb
7 files changed, 7 insertions(+), 20 deletions(-)


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

diff --git a/modules/mediawiki/manifests/scap.pp 
b/modules/mediawiki/manifests/scap.pp
index 6a61609..8702c0d 100644
--- a/modules/mediawiki/manifests/scap.pp
+++ b/modules/mediawiki/manifests/scap.pp
@@ -12,7 +12,7 @@
 
 $mediawiki_deployment_dir = '/srv/mediawiki'
 $mediawiki_staging_dir= '/srv/mediawiki-staging'
-$scap_bin_dir = '/srv/deployment/scap/scap/bin'
+$scap_bin_dir = '/usr/bin'
 $mediawiki_web_user   = $::mediawiki::users::web
 
 # /srv/mediawiki is the root path of the MediaWiki deployment tree.
diff --git a/modules/mediawiki/templates/mediawiki.sh.erb 
b/modules/mediawiki/templates/mediawiki.sh.erb
index 0aa6eac..1b16432 100644
--- a/modules/mediawiki/templates/mediawiki.sh.erb
+++ b/modules/mediawiki/templates/mediawiki.sh.erb
@@ -9,6 +9,7 @@
 # into scap.
 
 if groups | grep -Pqw '(wikidev|l10nupdate)'; then
-  PATH="${PATH}:/srv/deployment/scap/scap/bin"
+  # scap is now in /usr/bin thanks to debian package 'scap'
+  # PATH="${PATH}:/srv/deployment/scap/scap/bin"
   umask 0002
 fi
diff --git a/modules/restbase/manifests/deploy.pp 
b/modules/restbase/manifests/deploy.pp
index f5d7d89..45cd3f3 100644
--- a/modules/restbase/manifests/deploy.pp
+++ b/modules/restbase/manifests/deploy.pp
@@ -29,14 +29,6 @@
 source => $public_key_file,
 }
 
-# Using trebuchet provider while scap service deployment is under
-# development—chicken and egg things
-#
-# This should be removed once scap3 is in a final state
-package { 'scap/scap':
-provider => 'trebuchet',
-}
-
 # Rather than futz with adding new functionality to allow a deployment
 # user set per repository in trebuchet, I'm running an exec here
 $dir = '/srv/deployment/restbase/deploy'
diff --git a/modules/scap/files/l10nupdate-1 b/modules/scap/files/l10nupdate-1
index 52e48b5..7b0f6c8 100755
--- a/modules/scap/files/l10nupdate-1
+++ b/modules/scap/files/l10nupdate-1
@@ -7,7 +7,7 @@
 . /etc/profile.d/mediawiki.sh
 
 BINDIR=/usr/local/bin
-SCAPDIR=/srv/deployment/scap/scap/bin
+SCAPDIR=/usr/bin
 # The configuration in CommonSettings.php should match GITDIR and GITREPOS
 GITDIR=/var/lib/l10nupdate/mediawiki
 GITURL=https://gerrit.wikimedia.org/r/p/mediawiki
diff --git a/modules/scap/manifests/init.pp b/modules/scap/manifests/init.pp
index 3a01956..07ebe45 100644
--- a/modules/scap/manifests/init.pp
+++ b/modules/scap/manifests/init.pp
@@ -3,14 +3,9 @@
 # Common role for scap masters and targets
 
 class scap {
-# Using trebuchet provider while scap service deployment is under
-# development -- chicken and egg things
-#
-# This should be removed once scap3 is in a final state (i.e. packaged
-# or deployed via another method)
+
 package { 'scap':
-ensure   => latest,
-provider => 'trebuchet',
+ensure   => '3.0.1-1',
 }
 
 file { '/etc/scap.cfg':
diff --git a/modules/scap/manifests/l10nupdate.pp 
b/modules/scap/manifests/l10nupdate.pp
index 3d4ca08..91abdbf 100644
--- a/modules/scap/manifests/l10nupdate.pp
+++ b/modules/scap/manifests/l10nupdate.pp
@@ -64,7 +64,7 @@
 # This command is equivalent to a restricted sync-dir call that
 # only syncs l10n cache files followed by a scap-rebuild-cdbs
 # call.
-'ALL = (mwdeploy) NOPASSWD: 
/srv/deployment/scap/scap/bin/sync-l10n',
+'ALL = (mwdeploy) NOPASSWD: /usr/bin/sync-l10n',
 # Allow l10nupdate user to run anything as the unprivledged web
 # user. Needed for mwscript actions and related operations.
 "ALL = (${::mediawiki::users::web}) NOPASSWD: ALL",
diff --git a/modules/scap/templates/mw-deployment-vars.erb 
b/modules/scap/templates/mw-deployment-vars.erb
index b0c9230..abd8da3 100644
--- a/modules/scap/templates/mw-deployment-vars.erb
+++ b/modules/scap/templates/mw-deployment-vars.erb
@@ -1,5 +1,4 

[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: dabeb42..0f2ef11 - change (mediawiki/extensions)

2016-02-17 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

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

Change subject: Syncronize VisualEditor: dabeb42..0f2ef11
..

Syncronize VisualEditor: dabeb42..0f2ef11

Change-Id: I8a0c57508bbaedf9b9ab0cd8eb773138a5417b7b
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/40/271440/1

diff --git a/VisualEditor b/VisualEditor
index dabeb42..0f2ef11 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit dabeb4218d1af9608097c6cf002f4da0799b255c
+Subproject commit 0f2ef11ca36f0edf05a2b030221c1cf5b1afe570

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8a0c57508bbaedf9b9ab0cd8eb773138a5417b7b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 

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


[MediaWiki-commits] [Gerrit] make scap::target use the scap3 package provider - change (operations/puppet)

2016-02-17 Thread Rush (Code Review)
Rush has submitted this change and it was merged.

Change subject: make scap::target use the scap3 package provider
..


make scap::target use the scap3 package provider

This also updates eventbus to pass manage_user=>false
Refs T113072

Bug: T127215

Change-Id: I223a9fff2d48a3372ca14e56ae94087a6530f9ee
---
M modules/role/manifests/eventbus/eventbus.pp
M modules/scap/manifests/target.pp
2 files changed, 38 insertions(+), 55 deletions(-)

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



diff --git a/modules/role/manifests/eventbus/eventbus.pp 
b/modules/role/manifests/eventbus/eventbus.pp
index 9f2fe93..e7146c2 100644
--- a/modules/role/manifests/eventbus/eventbus.pp
+++ b/modules/role/manifests/eventbus/eventbus.pp
@@ -22,6 +22,7 @@
 public_key_source => 
"puppet:///modules/eventlogging/deployment/eventlogging_rsa.pub.${::realm}",
 deploy_path   => $eventlogging_path,
 service_name  => 'eventlogging-service-eventbus',
+manage_user   => false,
 }
 
 file { '/etc/eventbus':
diff --git a/modules/scap/manifests/target.pp b/modules/scap/manifests/target.pp
index 477e77a..5f1b696 100644
--- a/modules/scap/manifests/target.pp
+++ b/modules/scap/manifests/target.pp
@@ -3,12 +3,7 @@
 # Sets up a scap3 target for a deployment repository.
 # This will include ths scap package and ferm fules,
 # ensure that the $deploy_user has proper sudo rules
-# and public key installed, and that the $deploy_path
-# is set up with proper permissions.
-#
-# NOTE: This define will not manage $deploy_user for you.  You must
-# ensure that this is done somewhere else in puppet first, e.g.
-#   user { 'my_deploy_user': ... }
+# and public key installed.
 #
 # == Params
 # [*deploy_user*]
@@ -22,9 +17,13 @@
 #   service name that should be allowed to be restarted via sudo by
 #   deploy_user.  Default: undef.
 #
-# [*deploy_path*]
-#   Path at which scap3 will deploy.
-#   Default: /srv/deployment/$title
+# [*package_name*]
+#   the name of the scap3 deployment package Default: $title
+#
+# [*manage_user*]
+#   Specify whether to create a User resource for the $deploy_user.
+#   This should be set to false if you have defined the user elsewhere.
+#   Default: true
 #
 # Usage:
 #
@@ -36,25 +35,48 @@
 #   scap::target { 'eventlogging/eventlogging':
 #   deploy_user => 'eventlogging',
 #   public_key_source => 
"puppet:///modules/eventlogging/deployment/eventlogging_rsa.pub.${::realm}",
-#   deploy_path => '/srv/i/am/special/eventlogging/eventlogging'
 #   }
 #
 define scap::target(
 $deploy_user,
 $public_key_source,
 $service_name = undef,
-$deploy_path = "/srv/deployment/${title}",
+$package_name = $title,
+$manage_user = true,
 ) {
-User[$deploy_user] -> Scap::Target[$title]
-
 # Include scap3 package and ssh ferm rules.
 include scap
 include scap::ferm
 
+if $manage_user {
+user { $deploy_user:
+ensure => present,
+shell  => '/bin/bash',
+home   => '/var/lib/scap',
+system => true,
+managehome => true,
+}
+} else {
+User[$deploy_user] -> Scap::Target[$title]
+}
+
+package { $package_name:
+install_options => [{ owner => $deploy_user}],
+provider => 'scap3',
+require  => [Package['scap'], User[$deploy_user]],
+}
+
+if !defined(Ssh::Userkey[$deploy_user]) {
+ssh::userkey { $deploy_user:
+source => $public_key_source,
+}
+}
+
 # Allow deploy user user to sudo -u $user, and to sudo /usr/sbin/service
 # if $service_name is defined.
-# sudo -u $user is currently needed by scap3.  TODO: Remove this
-# when it is no longer needed.
+#
+# NOTE: sudo -u $user is currently needed by scap3.
+# TODO: Remove this when it is no longer needed.
 $privileges = $service_name ? {
 undef   => [
 "ALL=(${deploy_user}) NOPASSWD: ALL",
@@ -71,44 +93,4 @@
 }
 }
 
-if !defined(Ssh::Userkey[$deploy_user]) {
-ssh::userkey { $deploy_user:
-source => $public_key_source,
-}
-}
-
-# $parent_dir needs to be writable by deploy user in order
-# for scap to be able to create the -cache directories it needs.
-# This in case you are deploying a repository with
-# a '/' in the name, e.g. eventlogging/eventlogging.  This makes
-# sure that /srv/deployment/eventlogging is writable by
-# scap.
-#
-# TODO: if scap3 -cache directory location becomes configurable,
-# change this.
-# (dirname() stdlib puppet function not available???)
-#
-# NOTE:  We have to manage the parent directory this way,
-# instead of the scap3 -cache directory directly, to account
-# for the case where a scap3 git_repo is somethign like
-# repo/repo/deploy.  We don't know how 

[MediaWiki-commits] [Gerrit] Adds browser breakdown - change (wikimedia...prince)

2016-02-17 Thread Bearloga (Code Review)
Bearloga has uploaded a new change for review.

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

Change subject: Adds browser breakdown
..

Adds browser breakdown

- Lets users see share % of each browser over time
- Includes filtering for easier selection
- Includes a variety of sorting options

Bug: T124827
Change-Id: Id905906a04e00c4c78b190e44ec30c1dc87687f4
---
M functions.R
M server.R
A tab_documentation/browsers.md
M ui.R
4 files changed, 123 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/discovery/prince 
refs/changes/41/271441/1

diff --git a/functions.R b/functions.R
index af5932d..f7d3ac5 100644
--- a/functions.R
+++ b/functions.R
@@ -29,3 +29,32 @@
 by = "date"],
formula = date ~ country, fun.aggregate = 
sum)
 }
+
+# Fits an exponential model to the data and returns the rate of growth (or 
decay!)
+get_exp_rate <- function(dates, y) {
+  time_frame <- range(dates)
+  days <- as.character(seq(time_frame[1], time_frame[2], "day"))
+  if (length(days) < 3) {
+return(as.double(NA))
+  } else {
+x <- as.numeric(as.character(factor(as.character(dates), days, 
1:length(days
+return(tryCatch({
+  fit <- nls(y ~ exp(a + b * x), start = list(a = 0, b = 0))
+  round(as.double(fit$m$getPars()['b']), 4)
+}, error = function(e) {}, finally = as.double(NA)))
+  }
+  # plot(x, y, type = "l")
+  # lines(x, predict(fit, list(x = x)), lty = "dashed", col = "blue")
+}
+
+read_useragents <- function(){
+  data <- as.data.table(polloi::read_dataset(path = 
"portal/user_agent_data.tsv"))
+  data$browser <- paste(data$browser, data$version)
+  data$version <- NULL
+  data <- data[order(data$date, data$browser),,]
+  ua_data <<- data
+  browser_rates <<- data[, list(rate = get_exp_rate(date, percent),
+last = tail(percent, 1),
+times = length(percent)),
+   by = "browser"]
+}
diff --git a/server.R b/server.R
index b03e03f..7f081b3 100644
--- a/server.R
+++ b/server.R
@@ -52,4 +52,49 @@
   dyAxis("x", axisLabelFormatter = polloi::custom_axis_formatter, 
axisLabelWidth = 70) %>%
   dyLegend(labelsDiv = "country_breakdown_legend", show = "always", width 
= 400)
   })
+  
+  output$browser_selector_container <- renderUI({
+browsers <- switch(input$browser_order,
+   "alphabet" = {
+ sort(browser_rates$browser)
+   },
+   "growth" = {
+ browser_rates$browser[order(browser_rates$rate, 
decreasing = TRUE)]
+   },
+   "decay" = {
+ browser_rates$browser[order(browser_rates$rate, 
decreasing = FALSE)]
+   },
+   "last" = {
+ browser_rates$browser[order(browser_rates$last, 
decreasing = TRUE)]
+   },
+   "times" = {
+ browser_rates$browser[order(browser_rates$times, 
decreasing = TRUE)]
+   })
+if (input$browser_filter != "") {
+  if (grepl(",\\s?", input$browser_filter, fixed = FALSE)) {
+browser_filter <- gsub(", ", ",", input$browser_filter, fixed = TRUE)
+browser_filter <- strsplit(browser_filter, ",")[[1]]
+browsers <- browsers[browsers %in% unlist(lapply(browser_filter, 
function(browser) {
+  browsers[grepl(browser, browsers, ignore.case = TRUE)]
+}))]
+  } else {
+browsers <- browsers[grepl(input$browser_filter, browsers, ignore.case 
= TRUE)]
+  }
+}
+if (!is.null(input$browser_selector)) {
+  selected <- input$browser_selector
+} else {
+  selected <- browsers[1]
+}
+return(selectInput("browser_selector", "Browser", selected = selected, 
choices = browsers,
+   multiple = TRUE, selectize = FALSE, size = 15))
+  })
+  
+  output$browser_breakdown_dygraph <- renderDygraph({
+ua_data[ua_data$browser %in% input$browser_selector, , ] %>%
+  reshape2::dcast(date ~ browser, fun.aggregate = sum) %>%
+  polloi::make_dygraph(xlab = "Date", ylab = "Share (%)", title = "Browser 
breakdown of portal visitors") %>%
+  dyCSS(css = "www/inverse.css") %>%
+  dyLegend(labelsDiv = "browser_breakdown_legend", show = "always", width 
= 400)
+  })
 })
diff --git a/tab_documentation/browsers.md b/tab_documentation/browsers.md
new file mode 100644
index 000..14aa0a9
--- /dev/null
+++ b/tab_documentation/browsers.md
@@ -0,0 +1,26 @@
+What users use to view the Wikipedia portal
+===
+
+This measures which Internet browsers portal users use from each day, 
displaying the proportion of traffic accounted for by the browser. For any 
given day, we only record browsers with at least 0.5% share of 

[MediaWiki-commits] [Gerrit] build: Update mediawiki-codesniffer to 0.6.0, add "composer ... - change (mediawiki...VisualEditor)

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

Change subject: build: Update mediawiki-codesniffer to 0.6.0, add "composer fix"
..


build: Update mediawiki-codesniffer to 0.6.0, add "composer fix"

Change-Id: Ic96081539c2ae98b5b239b59ca9b0362b337e522
---
M ApiVisualEditor.php
M ApiVisualEditorEdit.php
M VisualEditor.hooks.php
M VisualEditor.php
M VisualEditorDataModule.php
M VisualEditorDesktopArticleTargetInitModule.php
M autodisablePref.php
M composer.json
8 files changed, 187 insertions(+), 186 deletions(-)

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



diff --git a/ApiVisualEditor.php b/ApiVisualEditor.php
index 7952106..5f8371d 100644
--- a/ApiVisualEditor.php
+++ b/ApiVisualEditor.php
@@ -11,9 +11,9 @@
 class ApiVisualEditor extends ApiBase {
// These are safe even if VE is not enabled on the page.
// This is intended for other VE interfaces, such as Flow's.
-   protected static $SAFE_ACTIONS = array(
+   protected static $SAFE_ACTIONS = [
'parsefragment',
-   );
+   ];
 
/**
 * @var Config
@@ -28,7 +28,7 @@
public function __construct( ApiMain $main, $name, Config $config ) {
parent::__construct( $main, $name );
$this->veConfig = $config;
-   $this->serviceClient = new VirtualRESTServiceClient( new 
MultiHttpClient( array() ) );
+   $this->serviceClient = new VirtualRESTServiceClient( new 
MultiHttpClient( [] ) );
$this->serviceClient->mount( '/restbase/', 
$this->getVRSObject() );
}
 
@@ -44,7 +44,7 @@
 */
private function getVRSObject() {
// the params array to create the service object with
-   $params = array();
+   $params = [];
// the VRS class to use, defaults to Parsoid
$class = 'ParsoidVirtualRESTService';
$config = $this->veConfig;
@@ -61,7 +61,7 @@
$params['restbaseCompat'] = true;
} else {
// no global modules defined, fall back to old defaults
-   $params = array(
+   $params = [
'URL' => $config->get( 'VisualEditorParsoidURL' 
),
'prefix' => $config->get( 
'VisualEditorParsoidPrefix' ),
'domain' => $config->get( 
'VisualEditorParsoidDomain' ),
@@ -69,7 +69,7 @@
'HTTPProxy' => $config->get( 
'VisualEditorParsoidHTTPProxy' ),
'forwardCookies' => $config->get( 
'VisualEditorParsoidForwardCookies' ),
'restbaseCompat' => true
-   );
+   ];
}
// merge the global and service-specific params
if ( isset( $vrs['global'] ) ) {
@@ -85,11 +85,11 @@
return new $class( $params );
}
 
-   private function requestRestbase( $method, $path, $params, $reqheaders 
= array() ) {
-   $request = array(
+   private function requestRestbase( $method, $path, $params, $reqheaders 
= [] ) {
+   $request = [
'method' => $method,
'url' => '/restbase/local/v1/' . $path
-   );
+   ];
if ( $method === 'GET' ) {
$request['query'] = $params;
} else {
@@ -121,7 +121,7 @@
global $wgMemc;
 
// Convert the VE HTML to wikitext
-   $text = $this->postHTML( $title, $html, array( 'oldid' => 
$oldid ), $etag );
+   $text = $this->postHTML( $title, $html, [ 'oldid' => $oldid ], 
$etag );
if ( $text === false ) {
return false;
}
@@ -161,11 +161,11 @@
return $this->requestRestbase(
'POST',
$path,
-   array(
+   [
'html' => $html,
'scrub_wikitext' => 1,
-   ),
-   array( 'If-Match' => $etag )
+   ],
+   [ 'If-Match' => $etag ]
);
}
 
@@ -183,20 +183,20 @@
return $this->requestRestbase(
'POST',
'transform/wikitext/to/html/' . urlencode( 
$title->getPrefixedDBkey() ),
-   array(
+   [
'wikitext' => $wikitext,
'body_only' => 1,
-   )
+   ]
);
}
 

[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: dabeb42..0f2ef11 - change (mediawiki/extensions)

2016-02-17 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: dabeb42..0f2ef11
..


Syncronize VisualEditor: dabeb42..0f2ef11

Change-Id: I8a0c57508bbaedf9b9ab0cd8eb773138a5417b7b
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Jenkins-mwext-sync: Verified; Looks good to me, approved



diff --git a/VisualEditor b/VisualEditor
index dabeb42..0f2ef11 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit dabeb4218d1af9608097c6cf002f4da0799b255c
+Subproject commit 0f2ef11ca36f0edf05a2b030221c1cf5b1afe570

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8a0c57508bbaedf9b9ab0cd8eb773138a5417b7b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 
Gerrit-Reviewer: Jenkins-mwext-sync 

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


[MediaWiki-commits] [Gerrit] Remove superflous `background-size` property & make use of m... - change (mediawiki/core)

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

Change subject: Remove superflous `background-size` property & make use of 
mixing
..


Remove superflous `background-size` property & make use of mixing

Removing superflous `background-size` property, which is overwritten
few lines below and make use of correspondent mixin in `:checked`
state.

Change-Id: I4f24c84c2f93bd85f495ff74ae21fbc210c18f57
---
M resources/src/mediawiki.ui/components/checkbox.less
M resources/src/mediawiki.ui/components/radio.less
2 files changed, 4 insertions(+), 6 deletions(-)

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



diff --git a/resources/src/mediawiki.ui/components/checkbox.less 
b/resources/src/mediawiki.ui/components/checkbox.less
index d44e5d7..b0fbf51 100644
--- a/resources/src/mediawiki.ui/components/checkbox.less
+++ b/resources/src/mediawiki.ui/components/checkbox.less
@@ -75,8 +75,7 @@
background-position: center center;
background-origin: border-box;
background-repeat: no-repeat;
-   .background-size( @checkboxSize - 0.2em, @checkboxSize 
- 0.2em );
-   background-size: 0 0;
+   .background-size( 0, 0 );
.box-sizing( border-box );
position: absolute;
// align the checkbox to middle of the text
@@ -93,7 +92,7 @@
 
// when the input is checked, style the label pseudo before 
element that followed as a checked checkbox
&:checked + label::before {
-   background-size: 100% 100%;
+   .background-size( 100%, 100% );
}
 
&:active + label::before {
diff --git a/resources/src/mediawiki.ui/components/radio.less 
b/resources/src/mediawiki.ui/components/radio.less
index 448390a..53c22b44 100644
--- a/resources/src/mediawiki.ui/components/radio.less
+++ b/resources/src/mediawiki.ui/components/radio.less
@@ -67,8 +67,7 @@
background-origin: border-box;
background-position: center center;
background-repeat: no-repeat;
-   .background-size( @radioSize, @radioSize );
-   background-size: 0 0;
+   .background-size( 0, 0 );
.box-sizing( border-box );
position: absolute;
left: 0;
@@ -81,7 +80,7 @@
 
// when the input is checked, style the label pseudo before 
element that followed as a checked radio
&:checked + label::before {
-   background-size: 100% 100%;
+   .background-size( 100%, 100% );
}
 
&:active + label::before {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I4f24c84c2f93bd85f495ff74ae21fbc210c18f57
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: VolkerE 
Gerrit-Reviewer: Edokter 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Jack Phoenix 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Umherirrender 
Gerrit-Reviewer: VolkerE 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] update phabricator to release/2016-02-18/1 - change (operations/puppet)

2016-02-17 Thread Rush (Code Review)
Rush has submitted this change and it was merged.

Change subject: update phabricator to release/2016-02-18/1
..


update phabricator to release/2016-02-18/1

Bug: T120013
Change-Id: Id61aff3802401cbfe4773818572060c4d4ab052d
---
M manifests/role/phabricator.pp
1 file changed, 6 insertions(+), 6 deletions(-)

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



diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp
index f693df3..0180bcf 100644
--- a/manifests/role/phabricator.pp
+++ b/manifests/role/phabricator.pp
@@ -40,7 +40,7 @@
 
 # this site's misc-lb caching proxies hostnames
 $cache_misc_nodes = hiera('cache::misc::nodes', [])
-$current_tag = 'release/2016-02-04/1'
+$current_tag = 'release/2016-02-18/1'
 $domain = 'phabricator.wikimedia.org'
 $altdom = 'phab.wmfusercontent.org'
 $mysql_host = 'm3-master.eqiad.wmnet'
@@ -53,11 +53,11 @@
 lock_file=> '/var/run/phab_repo_lock',
 mysql_admin_user => $role::phabricator::config::mysql_adminuser,
 mysql_admin_pass => $role::phabricator::config::mysql_adminpass,
-sprint_tag   => 'release/2016-02-04/1',
+sprint_tag   => 'release/2016-02-18/1',
 security_tag => $current_tag,
 libraries=> ['/srv/phab/libext/Sprint/src',
 '/srv/phab/libext/security/src'],
-extension_tag=> 'release/2016-02-04/1',
+extension_tag=> 'release/2016-02-18/1',
 extensions   => [ 'MediaWikiUserpageCustomField.php',
   'LDAPUserpageCustomField.php',
   'PhabricatorMediaWikiAuthProvider.php',
@@ -210,15 +210,15 @@
 
 # pass not sensitive but has to match phab and db
 $mysqlpass = 'labspass'
-$current_tag = 'release/2016-02-04/1'
+$current_tag = 'release/2016-02-18/1'
 class { '::phabricator':
 git_tag   => $current_tag,
 lock_file => '/var/run/phab_repo_lock',
-sprint_tag=> 'release/2016-02-04/1',
+sprint_tag=> 'release/2016-02-18/1',
 security_tag  => $current_tag,
 libraries => ['/srv/phab/libext/Sprint/src',
   '/srv/phab/libext/security/src'],
-extension_tag => 'release/2016-02-04/1',
+extension_tag => 'release/2016-02-18/1',
 extensions=> [ 'MediaWikiUserpageCustomField.php',
   'LDAPUserpageCustomField.php',
   'PhabricatorMediaWikiAuthProvider.php',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id61aff3802401cbfe4773818572060c4d4ab052d
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: 20after4 
Gerrit-Reviewer: Rush 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Add id field to watchlist db table - change (mediawiki/core)

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

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

Change subject: Add id field to watchlist db table
..

Add id field to watchlist db table

Bug: T125990
Change-Id: I3ce3a736d51bc06fe40fd773f079e694039b4f3e
---
M includes/installer/MssqlUpdater.php
M includes/installer/MysqlUpdater.php
M includes/installer/OracleUpdater.php
M includes/installer/PostgresUpdater.php
M includes/installer/SqliteUpdater.php
A maintenance/archives/patch-watchlist-wl_id.sql
A maintenance/mssql/archives/patch-watchlist-wl_id.sql
M maintenance/mssql/tables.sql
A maintenance/oracle/archives/patch-watchlist-wl_id.sql
M maintenance/oracle/tables.sql
M maintenance/postgres/tables.sql
A maintenance/sqlite/archives/patch-watchlist-wl_id.sql
M maintenance/tables.sql
13 files changed, 52 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/35/271435/2

diff --git a/includes/installer/MssqlUpdater.php 
b/includes/installer/MssqlUpdater.php
index b3675f8..bdaf4c8 100644
--- a/includes/installer/MssqlUpdater.php
+++ b/includes/installer/MssqlUpdater.php
@@ -68,6 +68,7 @@
// 1.27
[ 'dropTable', 'msg_resource_links' ],
[ 'dropTable', 'msg_resource' ],
+   [ 'addField', 'watchlist', 'wl_id', 
'patch-watchlist-wl_id.sql' ],
];
}
 
diff --git a/includes/installer/MysqlUpdater.php 
b/includes/installer/MysqlUpdater.php
index 57eaffe..b09f3a6 100644
--- a/includes/installer/MysqlUpdater.php
+++ b/includes/installer/MysqlUpdater.php
@@ -279,6 +279,7 @@
[ 'dropTable', 'msg_resource_links' ],
[ 'dropTable', 'msg_resource' ],
[ 'addTable', 'bot_passwords', 
'patch-bot_passwords.sql' ],
+   [ 'addField', 'watchlist', 'wl_id', 
'patch-watchlist-wl_id.sql' ],
];
}
 
diff --git a/includes/installer/OracleUpdater.php 
b/includes/installer/OracleUpdater.php
index 02e59f5..334256b 100644
--- a/includes/installer/OracleUpdater.php
+++ b/includes/installer/OracleUpdater.php
@@ -111,6 +111,7 @@
// 1.27
[ 'dropTable', 'msg_resource_links' ],
[ 'dropTable', 'msg_resource' ],
+   [ 'addField', 'watchlist', 'wl_id', 
'patch-watchlist-wl_id.sql' ],
 
// KEEP THIS AT THE BOTTOM!!
[ 'doRebuildDuplicateFunction' ],
diff --git a/includes/installer/PostgresUpdater.php 
b/includes/installer/PostgresUpdater.php
index 038c953..a3b50ac 100644
--- a/includes/installer/PostgresUpdater.php
+++ b/includes/installer/PostgresUpdater.php
@@ -67,6 +67,7 @@
[ 'addSequence', 'filearchive', 'fa_id', 
'filearchive_fa_id_seq' ],
[ 'addSequence', 'archive', false, 'archive_ar_id_seq' 
],
[ 'addSequence', 'externallinks', false, 
'externallinks_el_id_seq' ],
+   [ 'addSequence', 'watchlist', false, 
'watchlist_wl_id_seq' ],
 
# new tables
[ 'addTable', 'category', 'patch-category.sql' ],
@@ -428,6 +429,10 @@
// 1.27
[ 'dropTable', 'msg_resource_links' ],
[ 'dropTable', 'msg_resource' ],
+   [
+   'addPgField', 'watchlist', 'wl_id',
+   "INTEGER NOT NULL PRIMARY KEY DEFAULT 
nextval('watchlist_wl_id_seq')"
+   ],
];
}
 
diff --git a/includes/installer/SqliteUpdater.php 
b/includes/installer/SqliteUpdater.php
index 7db4f1a..99ab4e5 100644
--- a/includes/installer/SqliteUpdater.php
+++ b/includes/installer/SqliteUpdater.php
@@ -148,6 +148,7 @@
[ 'dropTable', 'msg_resource_links' ],
[ 'dropTable', 'msg_resource' ],
[ 'addTable', 'bot_passwords', 
'patch-bot_passwords.sql' ],
+   [ 'addField', 'watchlist', 'wl_id', 
'patch-watchlist-wl_id.sql' ],
];
}
 
diff --git a/maintenance/archives/patch-watchlist-wl_id.sql 
b/maintenance/archives/patch-watchlist-wl_id.sql
new file mode 100644
index 000..59fc1c8
--- /dev/null
+++ b/maintenance/archives/patch-watchlist-wl_id.sql
@@ -0,0 +1,5 @@
+-- Primary key in watchlist
+
+ALTER TABLE /*$wgDBprefix*/watchlist
+  ADD wl_id int NOT NULL auto_increment,
+  ADD PRIMARY KEY wl_id (wl_id);
diff --git a/maintenance/mssql/archives/patch-watchlist-wl_id.sql 
b/maintenance/mssql/archives/patch-watchlist-wl_id.sql
new file mode 100644
index 000..b71f817
--- /dev/null
+++ b/maintenance/mssql/archives/patch-watchlist-wl_id.sql
@@ -0,0 +1,2 @@
+ALTER TABLE /*_*/watchlist ADD wl_id INT IDENTITY;
+ALTER 

[MediaWiki-commits] [Gerrit] update phabricator to release/2016-02-18/1 - change (operations/puppet)

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

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

Change subject: update phabricator to release/2016-02-18/1
..

update phabricator to release/2016-02-18/1

Bug: T120013
Change-Id: Id61aff3802401cbfe4773818572060c4d4ab052d
---
M manifests/role/phabricator.pp
1 file changed, 6 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/39/271439/1

diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp
index f693df3..0180bcf 100644
--- a/manifests/role/phabricator.pp
+++ b/manifests/role/phabricator.pp
@@ -40,7 +40,7 @@
 
 # this site's misc-lb caching proxies hostnames
 $cache_misc_nodes = hiera('cache::misc::nodes', [])
-$current_tag = 'release/2016-02-04/1'
+$current_tag = 'release/2016-02-18/1'
 $domain = 'phabricator.wikimedia.org'
 $altdom = 'phab.wmfusercontent.org'
 $mysql_host = 'm3-master.eqiad.wmnet'
@@ -53,11 +53,11 @@
 lock_file=> '/var/run/phab_repo_lock',
 mysql_admin_user => $role::phabricator::config::mysql_adminuser,
 mysql_admin_pass => $role::phabricator::config::mysql_adminpass,
-sprint_tag   => 'release/2016-02-04/1',
+sprint_tag   => 'release/2016-02-18/1',
 security_tag => $current_tag,
 libraries=> ['/srv/phab/libext/Sprint/src',
 '/srv/phab/libext/security/src'],
-extension_tag=> 'release/2016-02-04/1',
+extension_tag=> 'release/2016-02-18/1',
 extensions   => [ 'MediaWikiUserpageCustomField.php',
   'LDAPUserpageCustomField.php',
   'PhabricatorMediaWikiAuthProvider.php',
@@ -210,15 +210,15 @@
 
 # pass not sensitive but has to match phab and db
 $mysqlpass = 'labspass'
-$current_tag = 'release/2016-02-04/1'
+$current_tag = 'release/2016-02-18/1'
 class { '::phabricator':
 git_tag   => $current_tag,
 lock_file => '/var/run/phab_repo_lock',
-sprint_tag=> 'release/2016-02-04/1',
+sprint_tag=> 'release/2016-02-18/1',
 security_tag  => $current_tag,
 libraries => ['/srv/phab/libext/Sprint/src',
   '/srv/phab/libext/security/src'],
-extension_tag => 'release/2016-02-04/1',
+extension_tag => 'release/2016-02-18/1',
 extensions=> [ 'MediaWikiUserpageCustomField.php',
   'LDAPUserpageCustomField.php',
   'PhabricatorMediaWikiAuthProvider.php',

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

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

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


[MediaWiki-commits] [Gerrit] API: Clarify cutimecond behaviour in docs/errors - change (mediawiki...CheckUser)

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

Change subject: API: Clarify cutimecond behaviour in docs/errors
..


API: Clarify cutimecond behaviour in docs/errors

Bug: T94745
Change-Id: I897ad988de8cc2111f28c5619d26ab8d83283943
---
M api/ApiQueryCheckUser.php
M i18n/en.json
M i18n/qqq.json
3 files changed, 4 insertions(+), 4 deletions(-)

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



diff --git a/api/ApiQueryCheckUser.php b/api/ApiQueryCheckUser.php
index 8d08a40..89fa4b8 100644
--- a/api/ApiQueryCheckUser.php
+++ b/api/ApiQueryCheckUser.php
@@ -29,7 +29,7 @@
$reason = $this->msg( 'checkuser-reason-api', $reason 
)->inContentLanguage()->text();
$timeCutoff = strtotime( $timecond ); // absolute time
if ( !$timeCutoff ) {
-   $this->dieUsage( 'You need use correct time limit (like 
"2 weeks")', 'invalidtime' );
+   $this->dieUsage( 'You need use correct time limit (like 
"-2 weeks" or "2 weeks ago")', 'invalidtime' );
}
 
$this->addTables( 'cu_changes' );
@@ -270,7 +270,7 @@
'target'   => "Username or IP-address/range to perform 
check",
'reason'   => 'Reason to check',
'limit'=> 'Limit of rows',
-   'timecond' => 'Time limit of user data (like "2 
weeks")',
+   'timecond' => 'Time limit of user data (like "-2 weeks" 
or "2 weeks ago")',
'xff'  => 'Use xff data instead of IP',
);
}
diff --git a/i18n/en.json b/i18n/en.json
index 80b6f98..435f7c6 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -89,7 +89,7 @@
"apihelp-query+checkuser-param-target": "Username, IP address, or CIDR 
range to check.",
"apihelp-query+checkuser-param-reason": "Reason to check.",
"apihelp-query+checkuser-param-limit": "Limit of rows.",
-   "apihelp-query+checkuser-param-timecond": "Time limit of user data 
(like \"2 weeks\").",
+   "apihelp-query+checkuser-param-timecond": "Time limit of user data 
(like \"-2 weeks\" or \"2 weeks ago\").",
"apihelp-query+checkuser-param-xff": "Use XFF data instead of IP 
address.",
"apihelp-query+checkuser-example-1": "Check IP addresses for 
[[User:Example]]",
"apihelp-query+checkuser-example-2": "Check edits from 192.0.2.0/24",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 7618add..8df6e82 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -108,7 +108,7 @@
"apihelp-query+checkuser-param-target": 
"{{doc-apihelp-param|query+checkuser|target}}",
"apihelp-query+checkuser-param-reason": 
"{{doc-apihelp-param|query+checkuser|reason}}",
"apihelp-query+checkuser-param-limit": 
"{{doc-apihelp-param|query+checkuser|limit}}",
-   "apihelp-query+checkuser-param-timecond": "Do not translate \"2 
weeks\". It must be in [http://www.php.net/strtotime original 
format].\n\n{{doc-apihelp-param|query+checkuser|timecond}}",
+   "apihelp-query+checkuser-param-timecond": "Do not translate \"-2 
weeks\" or \"2 weeks ago\". It must be in [http://www.php.net/strtotime 
original format].\n\n{{doc-apihelp-param|query+checkuser|timecond}}",
"apihelp-query+checkuser-param-xff": 
"{{doc-apihelp-param|query+checkuser|xff}}",
"apihelp-query+checkuser-example-1": 
"{{doc-apihelp-example|query+checkuser}}",
"apihelp-query+checkuser-example-2": 
"{{doc-apihelp-example|query+checkuser}}",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I897ad988de8cc2111f28c5619d26ab8d83283943
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/CheckUser
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: Glaisher 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Log in via the API instead of logging in via the web site - change (mediawiki...Gather)

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

Change subject: Log in via the API instead of logging in via the web site
..


Log in via the API instead of logging in via the web site

Bug: T127042
Change-Id: I68d6bed5ae28307fb2a2fa7a84413f90cf525a9e
---
M tests/browser/features/step_definitions/common_steps.rb
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/tests/browser/features/step_definitions/common_steps.rb 
b/tests/browser/features/step_definitions/common_steps.rb
index b0768d1..434 100644
--- a/tests/browser/features/step_definitions/common_steps.rb
+++ b/tests/browser/features/step_definitions/common_steps.rb
@@ -17,7 +17,7 @@
 
 Given(/^I am logged into the mobile website$/) do
   step 'I am using the mobile site'
-  visit(LoginPage).login_with(user, password, false)
+  log_in
   expect(on(ArticlePage).is_authenticated_element.when_present(20)).to exist
 end
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I68d6bed5ae28307fb2a2fa7a84413f90cf525a9e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Gather
Gerrit-Branch: master
Gerrit-Owner: Zfilipin 
Gerrit-Reviewer: Dduvall 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Zfilipin 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Logging in via LoginPage#login_with is a security risk - change (mediawiki...ZeroPortal)

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

Change subject: Logging in via LoginPage#login_with is a security risk
..


Logging in via LoginPage#login_with is a security risk

Log in via the API instead.

Bug: T127042
Change-Id: Ifa07019efa40511bfe3e138cbab0f17757fd30cd
---
M tests/browser/features/step_definitions/common_steps.rb
D tests/browser/features/support/pages/login_page.rb
2 files changed, 1 insertion(+), 18 deletions(-)

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



diff --git a/tests/browser/features/step_definitions/common_steps.rb 
b/tests/browser/features/step_definitions/common_steps.rb
index 9694777..4c5aacd 100644
--- a/tests/browser/features/step_definitions/common_steps.rb
+++ b/tests/browser/features/step_definitions/common_steps.rb
@@ -1,7 +1,7 @@
 # Utility step definitions for common use across features
 
 Given /^I am logged in as an? (.*?)$/ do |userType|
-  as_user(userType) { visit(LoginPage).login_with(user, password) }
+  as_user(userType) { log_in }
 end
 
 # Check for link visibility within a section
diff --git a/tests/browser/features/support/pages/login_page.rb 
b/tests/browser/features/support/pages/login_page.rb
deleted file mode 100644
index d859d04..000
--- a/tests/browser/features/support/pages/login_page.rb
+++ /dev/null
@@ -1,17 +0,0 @@
-class LoginPage
-  include PageObject
-
-  page_url "Special:UserLogin"
-
-  button(:login, id: "wpLoginAttempt")
-  text_field(:username, name: "wpName")
-  text_field(:password, name: "wpPassword")
-  div(:login_error, class: "errorbox")
-
-  def login_with(username, password)
-self.username_element.when_present.clear
-self.username = username
-self.password = password
-login
-  end
-end

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ifa07019efa40511bfe3e138cbab0f17757fd30cd
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ZeroPortal
Gerrit-Branch: master
Gerrit-Owner: Zfilipin 
Gerrit-Reviewer: Dduvall 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Zfilipin 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Delay ZeroBanner die requirement after setup - change (mediawiki...ZeroPortal)

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

Change subject: Delay ZeroBanner die requirement after setup
..


Delay ZeroBanner die requirement after setup

ZeroPortal depends on ZeroBanner which might be included AFTER the
ZeroPortal entry point (ex: loading them from disk in order of
directories creation).

Move the die() to $wgExtensionFunctions

Bug: T88015
Change-Id: I00ec4fa41d8b6894efe69818f175f8955ab3eeb9
---
M ZeroPortal.php
1 file changed, 10 insertions(+), 6 deletions(-)

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



diff --git a/ZeroPortal.php b/ZeroPortal.php
index 9ee5a82..2f13175 100644
--- a/ZeroPortal.php
+++ b/ZeroPortal.php
@@ -1,6 +1,8 @@
 https://gerrit.wikimedia.org/r/188115
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I00ec4fa41d8b6894efe69818f175f8955ab3eeb9
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/ZeroPortal
Gerrit-Branch: master
Gerrit-Owner: Hashar 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: TheDJ 
Gerrit-Reviewer: Yurik 
Gerrit-Reviewer: Zfilipin 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] build: Upgrade mediawiki-codesniffer to 0.6.0 - change (mediawiki...WikimediaPageViewInfo)

2016-02-17 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review.

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

Change subject: build: Upgrade mediawiki-codesniffer to 0.6.0
..

build: Upgrade mediawiki-codesniffer to 0.6.0

Change-Id: I046c70a684dbfe65a09c7d3447c0f1be8f7a1330
---
M composer.json
M includes/PageViewInfo.hooks.php
2 files changed, 8 insertions(+), 8 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikimediaPageViewInfo 
refs/changes/38/271438/1

diff --git a/composer.json b/composer.json
index 79e739e..2ed82c8 100644
--- a/composer.json
+++ b/composer.json
@@ -1,13 +1,13 @@
 {
"require-dev": {
"jakub-onderka/php-parallel-lint": "0.9.2",
-   "mediawiki/mediawiki-codesniffer": "0.5.1"
+   "mediawiki/mediawiki-codesniffer": "0.6.0"
},
"scripts": {
"test": [
"parallel-lint . --exclude vendor",
"phpcs -p -s"
],
-   "fix": "phpcbf -p"
+   "fix": "phpcbf"
}
 }
diff --git a/includes/PageViewInfo.hooks.php b/includes/PageViewInfo.hooks.php
index 6c8d9d3..82b53b1 100644
--- a/includes/PageViewInfo.hooks.php
+++ b/includes/PageViewInfo.hooks.php
@@ -24,10 +24,10 @@
$count += $item['views'];
}
$formatted = $ctx->getLanguage()->formatNum( $count );
-   $pageInfo['header-basic'][] = array(
+   $pageInfo['header-basic'][] = [
$ctx->msg( 'wmpvi-month-count' ),
-   Html::element( 'div', array( 'class' => 
'mw-wmpvi-month' ), $formatted )
-   );
+   Html::element( 'div', [ 'class' => 'mw-wmpvi-month' ], 
$formatted )
+   ];
 
$info = FormatJson::decode(
file_get_contents( __DIR__ . '/../graphs/month.json' ),
@@ -36,9 +36,9 @@
$info['data'][0]['values'] = $views['items'];
 
$ctx->getOutput()->addModules( 'ext.wmpageviewinfo' );
-   $ctx->getOutput()->addJsConfigVars( array(
+   $ctx->getOutput()->addJsConfigVars( [
'wgWMPageViewInfo' => $info,
-   ) );
+   ] );
}
 
/**
@@ -70,7 +70,7 @@
 
$req = Http::get(
$url,
-   array( 'timeout' => 10 ),
+   [ 'timeout' => 10 ],
__METHOD__
);
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I046c70a684dbfe65a09c7d3447c0f1be8f7a1330
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikimediaPageViewInfo
Gerrit-Branch: master
Gerrit-Owner: Legoktm 

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


[MediaWiki-commits] [Gerrit] WIP: tag split - change (mediawiki...Kartographer)

2016-02-17 Thread MaxSem (Code Review)
MaxSem has uploaded a new change for review.

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

Change subject: WIP: tag split
..

WIP: tag split

Change-Id: I68614aa620fbbf166c00977f98f720387b9047de
---
M includes/Hooks.php
A includes/Tag/MapData.php
A includes/Tag/MapFrame.php
A includes/Tag/MapLink.php
R includes/Tag/TagHandler.php
5 files changed, 127 insertions(+), 55 deletions(-)


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

diff --git a/includes/Hooks.php b/includes/Hooks.php
index 0815d8f..4dd9ff7 100644
--- a/includes/Hooks.php
+++ b/includes/Hooks.php
@@ -20,7 +20,7 @@
 * @return bool
 */
public static function onParserFirstCallInit( Parser $parser ) {
-   $parser->setHook( 'maps', 
'Kartographer\TagHandler::handleMapsTag' );
+   $parser->setHook( 'mapframe', 
'Kartographer\TagHandler::handleMapsTag' );
return true;
}
 
diff --git a/includes/Tag/MapData.php b/includes/Tag/MapData.php
new file mode 100644
index 000..469352b
--- /dev/null
+++ b/includes/Tag/MapData.php
@@ -0,0 +1,8 @@
+parseMapArgs();
+   // @todo: should these have defaults?
+   $this->width = $this->getInt( 'width' );
+   $this->height = $this->getInt( 'height' );
+   }
+}
diff --git a/includes/Tag/MapLink.php b/includes/Tag/MapLink.php
new file mode 100644
index 000..97fba78
--- /dev/null
+++ b/includes/Tag/MapLink.php
@@ -0,0 +1,8 @@
+getOutput();
$output->addModuleStyles( 'ext.kartographer' );
 
-   if ( $input !== '' && $input !== null ) {
-   $status = FormatJson::parse( $input, 
FormatJson::TRY_FIXING | FormatJson::STRIP_COMMENTS );
-   $value = false;
-   if ( $status->isOK() ) {
-   $value = self::validateContent( $status );
-   if ( $value && !is_array( $value ) ) {
-   $value = array( $value );
-   }
-   $sanitizer = new SimpleStyleSanitizer( $parser, 
$frame );
-   $sanitizer->sanitize( $value );
-   }
-   } else {
-   $status = Status::newGood();
-   $value = array();
-   }
+   $this->status = Status::newGood();
+   $this->args = $args;
 
-   $mode = self::validateEnum( $status, $args, 'mode', false, 
'static' );
-   if ( !in_array( $mode, array( 'interactive', 'static', 'data', 
'link' ) ) ) {
-   $status->fatal( 'kartographer-error-bad_attr', 'mode' );
-   return self::reportError( $output, $status );
-   }
+   $this->parseGeometries( $input, $parser, $frame );
+   $this->parseArgs();
+
+
 
$width = $height = $groups = $liveId = null;
$group = isset( $args['group'] ) ? $args['group'] : '*';
@@ -195,6 +191,74 @@
return $html;
}
 
+   protected function parseGeometries( $input, Parser $parser, PPFrame 
$frame ) {
+   if ( $input !== '' && $input !== null ) {
+   $status = FormatJson::parse( $input, 
FormatJson::TRY_FIXING | FormatJson::STRIP_COMMENTS );
+   if ( $status->isOK() ) {
+   $json = $status->getValue();
+   if ( $json && !is_array( $json ) ) {
+   $json = array( $json );
+   }
+   $status = $this->validateContent( $json );
+   $sanitizer = new SimpleStyleSanitizer( $parser, 
$frame );
+   $sanitizer->sanitize( $json );
+   $this->geometries = $json;
+   }
+   } else {
+   $status = Status::newGood();
+   }
+   $this->status->merge( $status );
+
+   return $status->isOK();
+   }
+
+   protected abstract function parseArgs();
+
+   protected function parseMapArgs() {
+   global $wgKartographerStyles, $wgKartographerDfltStyle;
+
+   $this->lat = $this->getFloat( 'latitude' );
+   $this->lon = $this->getFloat( 'longitude' );
+   $this->zoom = $this->getInt( 'zoom' );
+   $regexp = '/^(' . implode( '|', $wgKartographerStyles ) . ')$/';
+   $this->style = $this->getAndValidate( 'style', 
$wgKartographerDfltStyle, $regexp );
+   }
+
+   protected function getInt( $name, $default = false ) {
+   $value = $this->getAndValidate( $name, $default, '/^-?[0-9]+$/' 
);
+   if ( $value 

[MediaWiki-commits] [Gerrit] RESTBase: Enable purging and minor config style changes - change (operations/puppet)

2016-02-17 Thread Mobrovac (Code Review)
Mobrovac has uploaded a new change for review.

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

Change subject: RESTBase: Enable purging and minor config style changes
..

RESTBase: Enable purging and minor config style changes

We have a purging module which allows us to send HTCP purge requests to
the vhtcpd daemon sitting on the Varnish text machine. This change
enables purging content (currently only for MobileApps) whenever there's
a new render of the same content stored in RESTBase's storage.

This patch also slightly changes the config file style of RESTBase to be
fully Swagger-compliant.

Change-Id: Ia50d2a293a98265a4e560f558339d0553d6bd203
---
M hieradata/labs/deployment-prep/common.yaml
M modules/restbase/manifests/init.pp
M modules/restbase/templates/config.labs.yaml.erb
M modules/restbase/templates/config.yaml.erb
4 files changed, 104 insertions(+), 92 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/36/271436/1

diff --git a/hieradata/labs/deployment-prep/common.yaml 
b/hieradata/labs/deployment-prep/common.yaml
index f6d9a0f..e6ef15b 100644
--- a/hieradata/labs/deployment-prep/common.yaml
+++ b/hieradata/labs/deployment-prep/common.yaml
@@ -114,6 +114,7 @@
 restbase::mobileapps_uri: http://appservice.wmflabs.org
 restbase::mathoid_uri: http://mathoid-tester.wmflabs.org
 restbase::aqs_uri: https://wikimedia.org/api/rest_v1/metrics
+restbase::purge_host: deployment-cache-text04.deployment-prep.eqiad.wmflabs
 "mediawiki::log_aggregator": deployment-fluorine.eqiad.wmflabs:8420
 "mediawiki::forward_syslog": 
deployment-logstash2.deployment-prep.eqiad.wmflabs:10514
 mediawiki_memcached_servers:
diff --git a/modules/restbase/manifests/init.pp 
b/modules/restbase/manifests/init.pp
index ddf8693..bf7fb7a 100644
--- a/modules/restbase/manifests/init.pp
+++ b/modules/restbase/manifests/init.pp
@@ -63,6 +63,12 @@
 #   Analytics Query Service URI. Default:
 #   http://aqs.svc.eqiad.wmnet:7232/analytics.wikimedia.org/v1
 #
+# [*purge_host*]
+#   The vhtcpd daemon host to send purge requests to. Default: 239.128.0.112
+#
+# [*purge_port*]
+#   The port the vhtcp daemon listens to. Default: 4827
+#
 # [*monitor_domain*]
 #   The domain to monitor during the service's operation.
 #   Default: en.wikipedia.org
@@ -89,6 +95,8 @@
 $mathoid_uri= 'http://mathoid.svc.eqiad.wmnet:10042',
 $aqs_uri=
 'http://aqs.svc.eqiad.wmnet:7232/analytics.wikimedia.org/v1',
+$purge_host = '239.128.0.112',
+$purge_port = 4827,
 $monitor_domain = 'en.wikipedia.org',
 ) {
 
diff --git a/modules/restbase/templates/config.labs.yaml.erb 
b/modules/restbase/templates/config.labs.yaml.erb
index ed01f91..66c247a 100644
--- a/modules/restbase/templates/config.labs.yaml.erb
+++ b/modules/restbase/templates/config.labs.yaml.erb
@@ -4,44 +4,46 @@
 # between domains in the root_spec further down.
 default_project: _project
   x-modules:
-/:
-  - path: projects/wmf_default.yaml
-options: _options
-  table:
-hosts: [<%= Array(@seeds).join(',') %>]
-keyspace: system
-localDc: <%= @cassandra_localDc %>
-datacenters: [<%= Array(@cassandra_datacenters).join(',') %>]
-username: <%= @cassandra_user %>
-password: <%= @cassandra_password %>
-defaultConsistency: <%= @cassandra_defaultConsistency %>
-storage_groups:
-  # Catch-all group
-  - name: default.group.local
-domains: /./
+- path: projects/wmf_default.yaml
+  options: _options
+table:
+  hosts: [<%= Array(@seeds).join(',') %>]
+  keyspace: system
+  localDc: <%= @cassandra_localDc %>
+  datacenters: [<%= Array(@cassandra_datacenters).join(',') %>]
+  username: <%= @cassandra_user %>
+  password: <%= @cassandra_password %>
+  defaultConsistency: <%= @cassandra_defaultConsistency %>
+  storage_groups:
+# Catch-all group
+- name: default.group.local
+  domains: /./
 
-  parsoid:
-host: <%= @parsoid_uri %>
-  action:
-apiUriTemplate: "{{'http://{domain}/w/api.php'}}"
-  graphoid:
-host: <%= @graphoid_uri %>
-  mathoid:
-host: <%= @mathoid_uri %>
-# 10 days Varnish caching, one day client-side
-cache-control: s-maxage=864000, max-age=86400
-  mobileapps:
-host: <%= @mobileapps_uri %>
+parsoid:
+  host: <%= @parsoid_uri %>
+action:
+  apiUriTemplate: "{{'http://{domain}/w/api.php'}}"
+graphoid:
+  host: <%= @graphoid_uri %>
+mathoid:
+  host: <%= @mathoid_uri %>
+  # 10 days Varnish caching, one day client-side
+  cache-control: s-maxage=864000, max-age=86400
+mobileapps:
+  

[MediaWiki-commits] [Gerrit] Revert "Add extension descripion message" - change (mediawiki...WikimediaPageViewInfo)

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

Change subject: Revert "Add extension descripion message"
..


Revert "Add extension descripion message"

Ouch... I was blind. Sorry...

This reverts commit 4c0fff5e86fae73790ae92fad6e4c1b2ccbe5755.

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

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



diff --git a/i18n/en.json b/i18n/en.json
index 7ecad0b..9f38894 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -4,7 +4,6 @@
"Legoktm"
]
},
-   "wmpvi-desc": "Provides graphs of page view data",
-   "wmpvi-month-count": "Page views in the past 30 days",
-   "wmpvi-desc": "Adds page view information to the info action"
+   "wmpvi-desc": "Adds page view information to the info action",
+   "wmpvi-month-count": "Page views in the past 30 days"
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I9e1703d110632479fae995378ad85398732b936c
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/WikimediaPageViewInfo
Gerrit-Branch: master
Gerrit-Owner: Raimond Spekking 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Apply the nomobile class - change (mediawiki...FlaggedRevs)

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

Change subject: Apply the nomobile class
..


Apply the nomobile class

The ext.flaggedRevs.basic is not currently targeted at mobile and looking
at it, there is no need for it to be.

Unfortunately this means the banner in FlaggablePageview is visible in mobile
browsers taking up real estate.

This generic solution allows the hiding of this banner at mobile resolutions

Bug: T119344
Change-Id: I8c718394f870812ec946dffb2b89474757c64b08
---
M frontend/FlaggablePageView.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/frontend/FlaggablePageView.php b/frontend/FlaggablePageView.php
index 5eb51a5..6746776 100755
--- a/frontend/FlaggablePageView.php
+++ b/frontend/FlaggablePageView.php
@@ -380,7 +380,7 @@
}
# Wrap tag contents in a div
if ( $tag != '' ) {
-   $css = "{$tagClass} plainlinks noprint";
+   $css = "{$tagClass} plainlinks noprint nomobile";
$notice = "{$tag}\n";
$this->reviewNotice .= $notice;
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8c718394f870812ec946dffb2b89474757c64b08
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/FlaggedRevs
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 
Gerrit-Reviewer: Aaron Schulz 
Gerrit-Reviewer: Jackmcbarn 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Add viewResponseTime metric (split by platform) - change (mediawiki...WikimediaEvents)

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

Change subject: Add viewResponseTime metric (split by platform)
..


Add viewResponseTime metric (split by platform)

This only measures server time, unlike time-to-first-byte.

Change-Id: Ife7603752134482dd622b4d935fa42c478a18952
---
M WikimediaEventsHooks.php
M extension.json
2 files changed, 23 insertions(+), 0 deletions(-)

Approvals:
  Krinkle: Looks good to me, but someone else must approve
  Ori.livneh: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/WikimediaEventsHooks.php b/WikimediaEventsHooks.php
index 3578808..7d062db 100644
--- a/WikimediaEventsHooks.php
+++ b/WikimediaEventsHooks.php
@@ -486,4 +486,24 @@
 
return true;
}
+
+   public static function onArticleViewHeader() {
+   DeferredUpdates::addCallableUpdate( function () {
+   $context = RequestContext::getMain();
+   $timing = $context->getTiming();
+   if ( class_exists( 'MobileContext' )
+   && 
MobileContext::singleton()->shouldDisplayMobileView()
+   ) {
+   $platform = 'mobile';
+   } else {
+   $platform = 'desktop';
+   }
+
+   $measure = $timing->measure( 'viewResponseTime', 
'requestStart', 'requestShutdown' );
+   if ( $measure !== false ) {
+   $context->getStats()->timing(
+   "timing.viewResponseTime.{$platform}", 
$measure['duration'] * 1000 );
+   }
+   } );
+   }
 }
diff --git a/extension.json b/extension.json
index 4841f5c..c700d30 100644
--- a/extension.json
+++ b/extension.json
@@ -28,6 +28,9 @@
"ArticleUndelete": [
"WikimediaEventsHooks::onArticleUndelete"
],
+   "ArticleViewHeader": [
+   "WikimediaEventsHooks::onArticleViewHeader"
+   ],
"TitleMoveComplete": [
"WikimediaEventsHooks::onTitleMoveComplete"
],

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ife7603752134482dd622b4d935fa42c478a18952
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/WikimediaEvents
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Test summary endpoint against a lesser edited page - change (mediawiki...mobileapps)

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

Change subject: Test summary endpoint against a lesser edited page
..


Test summary endpoint against a lesser edited page

The opening text of 'Cat' is frequently changed (often frivolously) which
breaks our summary endpoint test with a false negative.

For a little more stability, instead let's test against the article Ann
Arbor Charter Township, Michigan (last edited July 5, 2015).

I've also removed the infobox output tests since the summary endpoint
in production doesn't include infoboxes.

Change-Id: Ib37b6e71f914a810518266dc32eea94985406b5a
---
M test/features/mobile-summary/pagecontent.js
1 file changed, 5 insertions(+), 8 deletions(-)

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



diff --git a/test/features/mobile-summary/pagecontent.js 
b/test/features/mobile-summary/pagecontent.js
index 9d62d8a..b5ac8cc 100644
--- a/test/features/mobile-summary/pagecontent.js
+++ b/test/features/mobile-summary/pagecontent.js
@@ -17,19 +17,16 @@
 return headers.checkHeaders(server.config.uri + 
'en.wikipedia.org/v1/page/mobile-summary/Foobar',
 'application/json');
 });
-it('en Cat page should have expected properties', function() {
-return preq.get({ uri: server.config.uri + 
'en.wikipedia.org/v1/page/mobile-summary/Cat' })
+it('Page should have expected properties', function() {
+return preq.get({ uri: server.config.uri + 
'en.wikipedia.org/v1/page/mobile-summary/Ann_Arbor_Charter_Township,_Michigan' 
})
 .then(function(res) {
 var body = res.body;
 assert.deepEqual(res.status, 200);
-assert.deepEqual(body.title, 'Cat');
-assert.ok(body.extract.indexOf('The domestic cat is a') === 0, 
'Expected different start of extract');
+assert.deepEqual(body.title, 'Ann Arbor Charter Township, 
Michigan');
+assert.ok(body.extract.indexOf('Ann Arbor Charter Township is 
a charter township') === 0, 'Expected different start of extract');
 assert.deepEqual(body.thumbnail, {
-"source": 
"https://upload.wikimedia.org/wikipedia/commons/thumb/0/0b/Cat_poster_1.jpg/320px-Cat_poster_1.jpg;
+"source": 
"https://upload.wikimedia.org/wikipedia/commons/thumb/9/9c/Ann_Arbor_Township_hall_and_fire_station.JPG/320px-Ann_Arbor_Township_hall_and_fire_station.JPG;
 });
-assert.ok(body.infobox.length > 0, 'Expected at least one 
infobox row');
-assert.ok(body.infobox[0].length > 0, 'Expected at least one 
infobox column');
-assert.ok(body.infobox[0][0].indexOf('Domestic cat
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Fjalapeno 
Gerrit-Reviewer: GWicke 
Gerrit-Reviewer: Mhurd 
Gerrit-Reviewer: Mobrovac 
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] WIP: Allow lazy loading of references - change (mediawiki...MobileFrontend)

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

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

Change subject: WIP: Allow lazy loading of references
..

WIP: Allow lazy loading of references

TODO:
* Introduce a ReferencesGateway for accessing the references via
the API
* Translate the references "view list" substitute
* Wire up references drawer with API query result

Change-Id: I287608a8fdfa61fe2d9270ab7df4da9bca3aef4c
Depends-On: I81a965bcb47d17df18f1e415e3c25f88f6b48ffc
Bug: T125896
---
M extension.json
M includes/MobileFormatter.php
M resources/skins.minerva.content.styles/text.less
3 files changed, 50 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MobileFrontend 
refs/changes/34/271434/1

diff --git a/extension.json b/extension.json
index d048513..dd04832 100644
--- a/extension.json
+++ b/extension.json
@@ -2031,6 +2031,10 @@
"base": false,
"beta": false
},
+   "MFLazyLoadReferences": {
+   "base": false,
+   "beta": false
+   },
"MFNoMobileCategory": false,
"MFNoMobilePages": [],
"MFNearbyRange": 1,
diff --git a/includes/MobileFormatter.php b/includes/MobileFormatter.php
index 714f47f..cf4b7e8 100644
--- a/includes/MobileFormatter.php
+++ b/includes/MobileFormatter.php
@@ -106,8 +106,9 @@
 */
public function filterContent( $removeDefaults = true ) {
$ctx = MobileContext::singleton();
-   $mfRemovableClasses = $ctx->getMFConfig()
-   ->get( 'MFRemovableClasses' );
+   $config = $ctx->getMFConfig();
+   $isBeta = $ctx->isBetaGroupMember();
+   $mfRemovableClasses = $config->get( 'MFRemovableClasses' );
 
if ( $removeDefaults ) {
$this->remove( $mfRemovableClasses['base'] );
@@ -116,15 +117,24 @@
}
}
 
+   $mfReferences = $config->get( 'MFLazyLoadReferences' );
+   if ( $mfReferences ) {
+   if (
+   $mfReferences['base'] ||
+   ( $isBeta && $mfReferences['beta'] )
+   ) {
+   $this->doRewriteReferencesForLazyLoading();
+   }
+   }
+
if ( $this->removeMedia ) {
$this->doRemoveImages();
} else {
-   $mfLazyLoadImages = $ctx->getMFConfig()
-   ->get( 'MFLazyLoadImages' );
+   $mfLazyLoadImages = $config->get( 'MFLazyLoadImages' );
 
if (
$mfLazyLoadImages['base'] ||
-   ( $ctx->isBetaGroupMember() && 
$mfLazyLoadImages['beta'] )
+   ( $isBeta && $mfLazyLoadImages['beta'] )
) {
$this->doRewriteImagesForLazyLoading();
}
@@ -134,6 +144,28 @@
}
 
/**
+* Replaces any references list with a link to Special:References
+*/
+   private function doRewriteReferencesForLazyLoading() {
+   $doc = $this->getDoc();
+   $listId = 0;
+   // Accessing by tag is cheaper than class
+   foreach ( $doc->getElementsByTagName( 'ol' ) as $list ) {
+   // Use class to decide it is a list of references
+   if ( strpos( $list->getAttribute( 'class' ), 
'references' ) !== false ) {
+   // TODO: i18n
+   $placeholder = $doc->createElement( 'a', 'View 
list' );
+   $placeholder->setAttribute( 'class', 
'lazy-references-placeholder' );
+   // Currently a broken link
+   $placeholder->setAttribute( 'href',
+   SpecialPage::getTitleFor( 'Cite', 
"$listId/" . $this->title->getPrefixedText() )->getLocalUrl() );
+   $list->parentNode->replaceChild( $placeholder, 
$list );
+   $listId += 1;
+   }
+   }
+   }
+
+   /**
 * Enables images to be loaded asynchronously
 */
private function doRewriteImagesForLazyLoading() {
diff --git a/resources/skins.minerva.content.styles/text.less 
b/resources/skins.minerva.content.styles/text.less
index 44299a0..a4e852f 100644
--- a/resources/skins.minerva.content.styles/text.less
+++ b/resources/skins.minerva.content.styles/text.less
@@ -71,4 +71,12 @@
font-size: 0.75em;
// Avoid line-height 

[MediaWiki-commits] [Gerrit] Test summary endpoint against a lesser edited page - change (mediawiki...mobileapps)

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

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

Change subject: Test summary endpoint against a lesser edited page
..

Test summary endpoint against a lesser edited page

The opening text of 'Cat' is frequently changed (often frivolously) which
breaks our summary endpoint test with a false negative.

For a little more stability, instead let's test against the article Ann
Arbor Charter Township, Michigan (last edited July 5, 2015).

I've also removed the infobox output tests since the summary endpoint
in production doesn't include infoboxes.

Change-Id: Ib37b6e71f914a810518266dc32eea94985406b5a
---
M test/features/mobile-summary/pagecontent.js
1 file changed, 5 insertions(+), 8 deletions(-)


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

diff --git a/test/features/mobile-summary/pagecontent.js 
b/test/features/mobile-summary/pagecontent.js
index 9d62d8a..b5ac8cc 100644
--- a/test/features/mobile-summary/pagecontent.js
+++ b/test/features/mobile-summary/pagecontent.js
@@ -17,19 +17,16 @@
 return headers.checkHeaders(server.config.uri + 
'en.wikipedia.org/v1/page/mobile-summary/Foobar',
 'application/json');
 });
-it('en Cat page should have expected properties', function() {
-return preq.get({ uri: server.config.uri + 
'en.wikipedia.org/v1/page/mobile-summary/Cat' })
+it('Page should have expected properties', function() {
+return preq.get({ uri: server.config.uri + 
'en.wikipedia.org/v1/page/mobile-summary/Ann_Arbor_Charter_Township,_Michigan' 
})
 .then(function(res) {
 var body = res.body;
 assert.deepEqual(res.status, 200);
-assert.deepEqual(body.title, 'Cat');
-assert.ok(body.extract.indexOf('The domestic cat is a') === 0, 
'Expected different start of extract');
+assert.deepEqual(body.title, 'Ann Arbor Charter Township, 
Michigan');
+assert.ok(body.extract.indexOf('Ann Arbor Charter Township is 
a charter township') === 0, 'Expected different start of extract');
 assert.deepEqual(body.thumbnail, {
-"source": 
"https://upload.wikimedia.org/wikipedia/commons/thumb/0/0b/Cat_poster_1.jpg/320px-Cat_poster_1.jpg;
+"source": 
"https://upload.wikimedia.org/wikipedia/commons/thumb/9/9c/Ann_Arbor_Township_hall_and_fire_station.JPG/320px-Ann_Arbor_Township_hall_and_fire_station.JPG;
 });
-assert.ok(body.infobox.length > 0, 'Expected at least one 
infobox row');
-assert.ok(body.infobox[0].length > 0, 'Expected at least one 
infobox column');
-assert.ok(body.infobox[0][0].indexOf('Domestic cat

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


[MediaWiki-commits] [Gerrit] nginx keepalives: enable for upload - change (operations/puppet)

2016-02-17 Thread BBlack (Code Review)
BBlack has submitted this change and it was merged.

Change subject: nginx keepalives: enable for upload
..


nginx keepalives: enable for upload

Bug: T107749
Change-Id: I86f7ea691a78c16eadcbb42b2cf38a7caac48ce0
---
M hieradata/role/common/cache/upload.yaml
1 file changed, 1 insertion(+), 0 deletions(-)

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



diff --git a/hieradata/role/common/cache/upload.yaml 
b/hieradata/role/common/cache/upload.yaml
index 9400c3f..7ca1605 100644
--- a/hieradata/role/common/cache/upload.yaml
+++ b/hieradata/role/common/cache/upload.yaml
@@ -1,3 +1,4 @@
 cluster: cache_upload
 admin::groups:
   - perf-roots
+tlsproxy::localssl::keepalives_per_worker: 1

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

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

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


[MediaWiki-commits] [Gerrit] Add maintenance script for generating a list of human-readab... - change (mediawiki...WikimediaMaintenance)

2016-02-17 Thread Mattflaschen (Code Review)
Mattflaschen has uploaded a new change for review.

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

Change subject: Add maintenance script for generating a list of human-readable 
names for projects.
..

Add maintenance script for generating a list of human-readable
names for projects.

It generates both en.json and and qqq.json files to a specified
directory.  This is intended to feed into WikimediaMessages.

See If07983030e18141d2047da2de02b5b3a5f7057a5

Change-Id: I0baa4916d2fabf19242b68ebce487f50a24041f6
Co-Author: Moriel Schottlender 
Co-Author: Matthew Flaschen 
---
A createHumanReadableProjectNameFiles.php
1 file changed, 221 insertions(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikimediaMaintenance 
refs/changes/31/271431/1

diff --git a/createHumanReadableProjectNameFiles.php 
b/createHumanReadableProjectNameFiles.php
new file mode 100644
index 000..721d326
--- /dev/null
+++ b/createHumanReadableProjectNameFiles.php
@@ -0,0 +1,221 @@
+mDescription = 'Builds i18n files for translating names 
of Wikimedia projects';
+
+   $this->addOption( 'directory', 'Output directory where files 
should be created', true, true );
+   }
+
+   /**
+* Gets actual language code (not necessarily the same as subdomain, 
even if there is
+* a language subdomain)
+*
+* @param string $projURL URL of root of domain (e.g. 
https://en.wikipedia.org)
+* @return Language code, or null on failure
+*/
+   private function getLanguageCode( $projURL ) {
+   $url = 
"$projURL/w/api.php?action=query=siteinfo=json";
+   $responseText = Http::get( $url );
+   $response = FormatJson::decode( $responseText, true );
+   if ( isset( $response['query']['general']['lang'] ) ) {
+   return $response['query']['general']['lang'];
+   } else {
+   return null;
+   }
+   }
+
+   private function createQQQ( $projName, $projURL ) {
+   $languageCode = $this->getLanguageCode( $projURL );
+
+   return 
"{{ProjectNameDocumentation|url=$projURL|name=$projName|language=$languageCode}}";
+   }
+
+   public function execute() {
+   $outEn = array();
+   $outQqq = array();
+   $counter = 0;
+   $info = $this->getSitematrixFromAPI();
+   $languages = LanguageNames::getNames( 'en' );
+
+   // Wikis that have messages in WikimediaMessages
+   $messageMatrix = array(
+   // code => project name
+   "wiki" => wfMessage( "wikibase-otherprojects-wikipedia" 
)->text(),
+   "wiktionary" => "Wiktionary", // No message for this!?
+   "wikibooks" => wfMessage( 
"wikibase-otherprojects-wikibooks" )->text(),
+   "wikiquote" => wfMessage( 
"wikibase-otherprojects-wikiquote" )->text(),
+   "wikinews" => wfMessage( 
"wikibase-otherprojects-wikinews" )->text(),
+   "wikisource" => wfMessage( 
"wikibase-sitelinks-wikisource" )->text(),
+   "wikiversity" => "Wikiversity", // No message for this, 
either!
+   "wikivoyage" => wfMessage( 
"wikibase-otherprojects-wikivoyage" )->text(),
+   );
+
+   $failedLangWikis = array(
+   "azbwiki" => "South Azerbaijani Wikipedia",
+   "be_x_oldwiki" => "Belarusian (Taraškievica) Wikipedia",
+   "bhwiki" => "Bihari Wikipedia",
+   "bhwiktionary" => "Bihari Wiktionary",
+   "bxrwiki" => "Buryat Wikipedia",
+   "lbewiki" => "Laki Wikipedia",
+   "mowiki" => "Moldovan Wikipedia",
+   "mowiktionary" => "Moldovan Wiktionary",
+   "roa_tarawiki" => "Tarandíne Wikipedia",
+   "zh_min_nanwiki" => "Min Nan Wikipedia",
+   "zh_min_nanwiktionary" => "Min Nan Wiktionary",
+   "zh_min_nanwikibooks" => "Min Nan Wikibooks",
+   "zh_min_nanwikiquote" => "Min Nan Wikiquote",
+   "zh_min_nanwikisource" => "Min Nan Wikisource",
+   );
+
+
+   // SPECIAL WIKIS
+   $exceptions = array(
+   // code => full message
+   "arbcom-de" => "German Wikipedia Arbitration Committee",
+   "arbcom-en" => "English Wikipedia Arbitration 
Committee",
+   "arbcom-fi" => "Finnish Wikipedia Arbitration 
Committee",
+   "arbcom-nl" => "Dutch Wikipedia Arbitration Committee",
+   

[MediaWiki-commits] [Gerrit] Fix text extract test - change (mediawiki...mobileapps)

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

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

Change subject: Fix text extract test
..

Fix text extract test

The text extract value has changed. Trying to make it more stable by
not requiring the start of the extract to be exact.

Note: there is another test failure currently, but that one requires more than 
five minutes.
So I filed ticket T127243 for that other issue.

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


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

diff --git a/test/features/mobile-summary/pagecontent.js 
b/test/features/mobile-summary/pagecontent.js
index 9d62d8a..9238fab 100644
--- a/test/features/mobile-summary/pagecontent.js
+++ b/test/features/mobile-summary/pagecontent.js
@@ -23,7 +23,8 @@
 var body = res.body;
 assert.deepEqual(res.status, 200);
 assert.deepEqual(body.title, 'Cat');
-assert.ok(body.extract.indexOf('The domestic cat is a') === 0, 
'Expected different start of extract');
+assert.ok(body.extract.indexOf('cat') >= 0, 'Expected "cat" in 
extract');
+assert.ok(body.extract.indexOf('domestic') >= 0, 'Expected 
"domestic" in extract');
 assert.deepEqual(body.thumbnail, {
 "source": 
"https://upload.wikimedia.org/wikipedia/commons/thumb/0/0b/Cat_poster_1.jpg/320px-Cat_poster_1.jpg;
 });

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

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

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


[MediaWiki-commits] [Gerrit] PHP: Take advantage of PHP 5.5 understanding ( new Foo )->foo - change (oojs/ui)

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

Change subject: PHP: Take advantage of PHP 5.5 understanding ( new Foo )->foo
..


PHP: Take advantage of PHP 5.5 understanding ( new Foo )->foo

Change-Id: I5cdc15cb7a6419e69ab57beda3084242eb99b698
---
M demos/widgets.php
M php/widgets/ButtonInputWidget.php
M php/widgets/CheckboxInputWidget.php
M php/widgets/ComboBoxInputWidget.php
M php/widgets/DropdownInputWidget.php
M php/widgets/RadioInputWidget.php
M php/widgets/TextInputWidget.php
M tests/phpunit/TagTest.php
8 files changed, 17 insertions(+), 39 deletions(-)

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



diff --git a/demos/widgets.php b/demos/widgets.php
index f5e1348..697df2a 100644
--- a/demos/widgets.php
+++ b/demos/widgets.php
@@ -434,15 +434,15 @@
# (recursively) made infusable.  We protect the 
FieldLayout
# by wrapping it with a new  Tag, so that 
it won't get
# rebuilt during infusion.
-   $wrappedFieldLayout = new OOUI\Tag( 'div' );
-   $wrappedFieldLayout->appendContent(
+   $wrappedFieldLayout = ( new OOUI\Tag( 'div' ) )
+   ->appendContent(
new OOUI\FieldLayout(

$buttonStyleShowcaseWidget,
[
'align' => 'top'
]
)
-   );
+   );
$demoContainer->appendContent( new 
OOUI\FieldsetLayout( [
'infusable' => true,
'label' => 'Button style showcase',
diff --git a/php/widgets/ButtonInputWidget.php 
b/php/widgets/ButtonInputWidget.php
index 583ac53..f9276df 100644
--- a/php/widgets/ButtonInputWidget.php
+++ b/php/widgets/ButtonInputWidget.php
@@ -72,9 +72,8 @@
$type = in_array( $config['type'], [ 'button', 'submit', 
'reset' ] ) ?
$config['type'] :
'button';
-   $input = new Tag( $config['useInputTag'] ? 'input' : 'button' );
-   $input->setAttributes( [ 'type' => $type ] );
-   return $input;
+   $tag = $config['useInputTag'] ? 'input' : 'button';
+   return ( new Tag( $tag ) )->setAttributes( [ 'type' => $type ] 
);
}
 
/**
diff --git a/php/widgets/CheckboxInputWidget.php 
b/php/widgets/CheckboxInputWidget.php
index ef097dd..44167fd 100644
--- a/php/widgets/CheckboxInputWidget.php
+++ b/php/widgets/CheckboxInputWidget.php
@@ -33,9 +33,7 @@
}
 
protected function getInputElement( $config ) {
-   $input = new Tag( 'input' );
-   $input->setAttributes( [ 'type' => 'checkbox' ] );
-   return $input;
+   return ( new Tag( 'input' ) )->setAttributes( [ 'type' => 
'checkbox' ] );
}
 
/**
diff --git a/php/widgets/ComboBoxInputWidget.php 
b/php/widgets/ComboBoxInputWidget.php
index 0d8d3d2..1d84e0d 100644
--- a/php/widgets/ComboBoxInputWidget.php
+++ b/php/widgets/ComboBoxInputWidget.php
@@ -55,9 +55,9 @@
 
$this->datalist->clearContent();
foreach ( $options as $opt ) {
-   $option = new Tag( 'option' );
-   $option->setAttributes( [ 'value' => $opt['data'] ] );
-   $option->appendContent( isset( $opt['label'] ) ? 
$opt['label'] : $opt['data'] );
+   $option = ( new Tag( 'option' ) )
+   ->setAttributes( [ 'value' => $opt['data'] ] )
+   ->appendContent( isset( $opt['label'] ) ? 
$opt['label'] : $opt['data'] );
 
$this->options[] = $option;
$this->datalist->appendContent( $option );
diff --git a/php/widgets/DropdownInputWidget.php 
b/php/widgets/DropdownInputWidget.php
index c534ce4..0c43fa8 100644
--- a/php/widgets/DropdownInputWidget.php
+++ b/php/widgets/DropdownInputWidget.php
@@ -64,9 +64,9 @@
$this->input->clearContent();
foreach ( $options as $opt ) {
$optValue = $this->cleanUpValue( $opt['data'] );
-   $option = new Tag( 'option' );
-   $option->setAttributes( [ 'value' => $optValue ] );
-   $option->appendContent( isset( $opt['label'] ) ? 
$opt['label'] : $optValue );
+   $option = ( new Tag( 'option' ) )
+  

[MediaWiki-commits] [Gerrit] fix typo in FQDN of es2015 - change (operations/dns)

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

Change subject: fix typo in FQDN of es2015
..


fix typo in FQDN of es2015

Change-Id: I6cb1ece1f23801257061f8311927a4044643661a
---
M templates/10.in-addr.arpa
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa
index 828f994..2ecdf10 100644
--- a/templates/10.in-addr.arpa
+++ b/templates/10.in-addr.arpa
@@ -3069,7 +3069,7 @@
 127 1H IN PTR   ms-be2021.codfw.wmnet.
 128 1H IN PTR   pc2005.codfw.wmnet.
 129 1H IN PTR   es2012.codfw.wmnet.
-130 1H IN PTR   es2015.codfw.wmnt.
+130 1H IN PTR   es2015.codfw.wmnet.
 
 $ORIGIN 33.192.{{ zonename }}.
 1   1H IN PTR   vl2019-eth2.lvs2001.codfw.wmnet.

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6cb1ece1f23801257061f8311927a4044643661a
Gerrit-PatchSet: 1
Gerrit-Project: operations/dns
Gerrit-Branch: master
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] fix typo in FQDN of es2015 - change (operations/dns)

2016-02-17 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review.

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

Change subject: fix typo in FQDN of es2015
..

fix typo in FQDN of es2015

Change-Id: I6cb1ece1f23801257061f8311927a4044643661a
---
M templates/10.in-addr.arpa
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/dns 
refs/changes/30/271430/1

diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa
index 828f994..2ecdf10 100644
--- a/templates/10.in-addr.arpa
+++ b/templates/10.in-addr.arpa
@@ -3069,7 +3069,7 @@
 127 1H IN PTR   ms-be2021.codfw.wmnet.
 128 1H IN PTR   pc2005.codfw.wmnet.
 129 1H IN PTR   es2012.codfw.wmnet.
-130 1H IN PTR   es2015.codfw.wmnt.
+130 1H IN PTR   es2015.codfw.wmnet.
 
 $ORIGIN 33.192.{{ zonename }}.
 1   1H IN PTR   vl2019-eth2.lvs2001.codfw.wmnet.

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

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

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


[MediaWiki-commits] [Gerrit] nginx keepalives: enable for upload - change (operations/puppet)

2016-02-17 Thread BBlack (Code Review)
BBlack has uploaded a new change for review.

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

Change subject: nginx keepalives: enable for upload
..

nginx keepalives: enable for upload

Bug: T107749
Change-Id: I86f7ea691a78c16eadcbb42b2cf38a7caac48ce0
---
M hieradata/role/common/cache/upload.yaml
1 file changed, 1 insertion(+), 0 deletions(-)


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

diff --git a/hieradata/role/common/cache/upload.yaml 
b/hieradata/role/common/cache/upload.yaml
index 9400c3f..7ca1605 100644
--- a/hieradata/role/common/cache/upload.yaml
+++ b/hieradata/role/common/cache/upload.yaml
@@ -1,3 +1,4 @@
 cluster: cache_upload
 admin::groups:
   - perf-roots
+tlsproxy::localssl::keepalives_per_worker: 1

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I86f7ea691a78c16eadcbb42b2cf38a7caac48ce0
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] Fix financial_account.account_type_code to EXP (expense) for... - change (wikimedia...crm)

2016-02-17 Thread Ejegg (Code Review)
Ejegg has submitted this change and it was merged.

Change subject: Fix financial_account.account_type_code to EXP (expense) for 
Refund andn Chargeback
..


Fix financial_account.account_type_code to EXP (expense) for Refund andn 
Chargeback

Bug: T122946
Change-Id: Iff8d107593a9fc0a31f9641d6992a39e7db287d6
---
M sites/all/modules/wmf_civicrm/wmf_civicrm.install
1 file changed, 24 insertions(+), 0 deletions(-)

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



diff --git a/sites/all/modules/wmf_civicrm/wmf_civicrm.install 
b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
index c3b7719..2f9b093 100644
--- a/sites/all/modules/wmf_civicrm/wmf_civicrm.install
+++ b/sites/all/modules/wmf_civicrm/wmf_civicrm.install
@@ -49,6 +49,7 @@
 wmf_civicrm_update_7100();
 wmf_civicrm_update_7110();
 wmf_civicrm_update_7120();
+wmf_civicrm_update_7170();
 }
 
 /**
@@ -1840,3 +1841,26 @@
 WHERE ft.id IS NULL AND fi.created_date > '2016-02-01'
   ");
 }
+
+/**
+ * Further refund financial data fix.
+ *
+ * This is a change Elliott made on live to reflect these accounts as Expenses 
not Income.
+ *
+ * Added here to ensure dev sites have the same info.
+ */
+function wmf_civicrm_update_7170() {
+  civicrm_initialize();
+  CRM_Core_DAO::executeQuery("
+   UPDATE civicrm_financial_account
+   SET account_type_code = 'EXP',
+   financial_account_type_id = (
+ SELECT v.value
+ FROM civicrm_option_value v
+ INNER JOIN civicrm_option_group g
+   ON g.id = v.option_group_id AND g.name = 'financial_account_type'
+   AND v.name = 'Expenses'
+   )
+   WHERE name in ('Refund', 'Chargeback')
+  ");
+}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iff8d107593a9fc0a31f9641d6992a39e7db287d6
Gerrit-PatchSet: 3
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Eileen 
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] Move novaadmin authority from 'testlabs' to 'admin' - change (operations/puppet)

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

Change subject: Move novaadmin authority from 'testlabs' to 'admin'
..


Move novaadmin authority from 'testlabs' to 'admin'

Having the 'testlabs' project contain the admin role
for administrative tasks is a weird historical leftover.  We
now have an 'admin' project which can serve this purpose
and be less confusing to future users.

Change-Id: I3b6a1ebbef463296c7407a3fac388fc78e4635f0
---
M hieradata/eqiad.yaml
M modules/openstack/files/kilo/virtscripts/cold-migrate
M modules/openstack/files/kilo/virtscripts/cold-nova-migrate
M modules/openstack/files/kilo/virtscripts/live-migrate
4 files changed, 5 insertions(+), 5 deletions(-)

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



diff --git a/hieradata/eqiad.yaml b/hieradata/eqiad.yaml
index d6d5f18..95e998c 100644
--- a/hieradata/eqiad.yaml
+++ b/hieradata/eqiad.yaml
@@ -123,8 +123,8 @@
   auth_port: '35357'
   auth_protocol: 'http'
   auth_host: 208.80.154.92
-  admin_project_id: 'testlabs'
-  admin_project_name: 'testlabs'
+  admin_project_id: 'admin'
+  admin_project_name: 'admin'
 
 designateconfig:
   db_host:  'm5-master.eqiad.wmnet'
diff --git a/modules/openstack/files/kilo/virtscripts/cold-migrate 
b/modules/openstack/files/kilo/virtscripts/cold-migrate
index 0c4652c..63be3c7 100755
--- a/modules/openstack/files/kilo/virtscripts/cold-migrate
+++ b/modules/openstack/files/kilo/virtscripts/cold-migrate
@@ -134,7 +134,7 @@
 argparser.add_argument(
 '--nova-project',
 help='project for nova auth',
-default='testlabs'
+default='admin'
 )
 argparser.add_argument(
 '--mysql-password',
diff --git a/modules/openstack/files/kilo/virtscripts/cold-nova-migrate 
b/modules/openstack/files/kilo/virtscripts/cold-nova-migrate
index 64eb0e8..c039346 100755
--- a/modules/openstack/files/kilo/virtscripts/cold-nova-migrate
+++ b/modules/openstack/files/kilo/virtscripts/cold-nova-migrate
@@ -107,7 +107,7 @@
 argparser.add_argument(
 '--nova-project',
 help='project for nova auth',
-default='testlabs'
+default='admin'
 )
 argparser.add_argument(
 '--no-restart',
diff --git a/modules/openstack/files/kilo/virtscripts/live-migrate 
b/modules/openstack/files/kilo/virtscripts/live-migrate
index 512acda..a1fab3d 100755
--- a/modules/openstack/files/kilo/virtscripts/live-migrate
+++ b/modules/openstack/files/kilo/virtscripts/live-migrate
@@ -131,7 +131,7 @@
 argparser.add_argument(
 '--nova-project',
 help='project for nova auth',
-default='testlabs'
+default='admin'
 )
 argparser.add_argument(
 'instanceid',

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

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

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


[MediaWiki-commits] [Gerrit] T127218: Update sitematrix for ady - change (mediawiki...parsoid)

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

Change subject: T127218: Update sitematrix for ady
..


T127218: Update sitematrix for ady

Change-Id: I920c9d27b6713dd25c59e3eb66fc842ba2f8371b
---
M lib/config/sitematrix.json
1 file changed, 305 insertions(+), 292 deletions(-)

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



diff --git a/lib/config/sitematrix.json b/lib/config/sitematrix.json
index d75f3a0..0f29898 100644
--- a/lib/config/sitematrix.json
+++ b/lib/config/sitematrix.json
@@ -62,6 +62,19 @@
"localname": "Achinese"
},
"3": {
+   "code": "ady",
+   "name": "адыгабзэ",
+   "site": [
+   {
+   "url": "https://ady.wikipedia.org;,
+   "dbname": "adywiki",
+   "code": "wiki",
+   "sitename": "Википедие"
+   }
+   ],
+   "localname": "Adyghe"
+   },
+   "4": {
"code": "af",
"name": "Afrikaans",
"site": [
@@ -92,7 +105,7 @@
],
"localname": "Afrikaans"
},
-   "4": {
+   "5": {
"code": "ak",
"name": "Akan",
"site": [
@@ -119,7 +132,7 @@
],
"localname": "Akan"
},
-   "5": {
+   "6": {
"code": "als",
"name": "Alemannisch",
"site": [
@@ -153,7 +166,7 @@
],
"localname": "Alemannisch"
},
-   "6": {
+   "7": {
"code": "am",
"name": "አማርኛ",
"site": [
@@ -179,7 +192,7 @@
],
"localname": "Amharic"
},
-   "7": {
+   "8": {
"code": "an",
"name": "aragonés",
"site": [
@@ -198,7 +211,7 @@
],
"localname": "Aragonese"
},
-   "8": {
+   "9": {
"code": "ang",
"name": "Ænglisc",
"site": [
@@ -238,7 +251,7 @@
],
"localname": "Old English"
},
-   "9": {
+   "10": {
"code": "ar",
"name": "العربية",
"site": [
@@ -287,7 +300,7 @@
],
"localname": "Arabic"
},
-   "10": {
+   "11": {
"code": "arc",
"name": "ܐܪܡܝܐ",
"site": [
@@ -300,7 +313,7 @@
],
"localname": "Aramaic"
},
-   "11": {
+   "12": {
"code": "arz",
"name": "مصرى",
"site": [
@@ -313,7 +326,7 @@
],
"localname": "Egyptian Arabic"
},
-   "12": {
+   "13": {
"code": "as",
"name": "অসমীয়া",
"site": [
@@ -346,7 +359,7 @@
],
"localname": "Assamese"
},
-   "13": {
+   "14": {
"code": "ast",
"name": "asturianu",
"site": [
@@ -379,7 +392,7 @@
],
"localname": "Asturian"
},
-   "14": {
+   "15": {
"code": "av",
"name": "авар",
"site": [
@@ -399,7 +412,7 @@
],
"localname": "Avaric"
},
-   "15": {
+   "16": {
"code": "ay",
"name": "Aymar aru",
"site": [
@@ -425,7 +438,7 @@
],
"localname": "Aymara"
},
-   "16": {
+   "17": {
"code": "az",
"name": "azərbaycanca",
"site": [
@@ -462,7 

[MediaWiki-commits] [Gerrit] Fix strpos(): Empty needle - change (mediawiki/core)

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

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

Change subject: Fix strpos(): Empty needle
..

Fix strpos(): Empty needle

I keep getting
[17-Feb-2016 22:18:11 Europe/London] PHP Warning:
strpos(): Empty needle in
/home/pal2015/public_html/includes/OutputPage.php on line 3873

In my error log. This has happend since mediawiki 1.27 since that is when
the function was introduced.

Following how it was fixed in
http://stackoverflow.com/questions/26325407/warning-strpos-empty-needle-in-wordpress-plugin

Change-Id: I06b56316e0aeb0d18f3c242a38efb952f05489ed
---
M includes/OutputPage.php
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/28/271428/1

diff --git a/includes/OutputPage.php b/includes/OutputPage.php
index 2570cfb..6c9cf05 100644
--- a/includes/OutputPage.php
+++ b/includes/OutputPage.php
@@ -3871,7 +3871,7 @@
public static function transformResourcePath( Config $config, $path ) {
global $IP;
$remotePath = $config->get( 'ResourceBasePath' );
-   if ( strpos( $path, $remotePath ) !== 0 ) {
+   if ( !empty( $remotePath ) && strpos( $path, $remotePath ) !== 
0 ) {
// Path is outside wgResourceBasePath, ignore.
return $path;
}

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

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

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


[MediaWiki-commits] [Gerrit] Fixes to masterPosWait() - change (mediawiki/core)

2016-02-17 Thread Aaron Schulz (Code Review)
Aaron Schulz has uploaded a new change for review.

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

Change subject: Fixes to masterPosWait()
..

Fixes to masterPosWait()

* Clean up return value types and docs.
* Handle master switch-over better w.r.t the job queue due
  to binlog name changes (the host portion). Previously the method
  would fail and trigger read-only mode when waiting on former
  master positions. Assume the the switch-over was done properly
  and thus return immediately.
* Only cache lastKnownSlavePos if the return value was >= 0.
  Previously it would be wrongly set even for timeouts (-1).

Bug: T126436
Change-Id: Ib8c05a5c72d03a5c98e41b23c5653fc194b6d130
---
M includes/db/DatabaseMysqlBase.php
M includes/db/DatabaseUtility.php
M includes/db/IDatabase.php
M tests/phpunit/includes/db/DatabaseMysqlBaseTest.php
4 files changed, 114 insertions(+), 34 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/27/271427/1

diff --git a/includes/db/DatabaseMysqlBase.php 
b/includes/db/DatabaseMysqlBase.php
index 7058061..964dcdd 100644
--- a/includes/db/DatabaseMysqlBase.php
+++ b/includes/db/DatabaseMysqlBase.php
@@ -757,19 +757,13 @@
return $approxLag;
}
 
-   /**
-* Wait for the slave to catch up to a given master position.
-* @todo Return values for this and base class are rubbish
-*
-* @param DBMasterPos|MySQLMasterPos $pos
-* @param int $timeout The maximum number of seconds to wait for 
synchronisation
-* @return int Zero if the slave was past that position already,
-*   greater than zero if we waited for some period of time, less than
-*   zero if we timed out.
-*/
function masterPosWait( DBMasterPos $pos, $timeout ) {
+   if ( !( $pos instanceof MySQLMasterPos ) ) {
+   throw new InvalidArgumentException( "Position not an 
instance of MySQLMasterPos" );
+   }
+
if ( $this->lastKnownSlavePos && 
$this->lastKnownSlavePos->hasReached( $pos ) ) {
-   return '0'; // 
http://dev.mysql.com/doc/refman/5.0/en/miscellaneous-functions.html
+   return 0;
}
 
# Commit any open transactions
@@ -778,18 +772,28 @@
# Call doQuery() directly, to avoid opening a transaction if 
DBO_TRX is set
$encFile = $this->addQuotes( $pos->file );
$encPos = intval( $pos->pos );
-   $sql = "SELECT MASTER_POS_WAIT($encFile, $encPos, $timeout)";
-   $res = $this->doQuery( $sql );
+   $res = $this->doQuery( "SELECT MASTER_POS_WAIT($encFile, 
$encPos, $timeout)" );
 
-   $status = false;
-   if ( $res ) {
-   $row = $this->fetchRow( $res );
-   if ( $row ) {
-   $status = $row[0]; // can be NULL, -1, or 0+ 
per the MySQL manual
-   if ( ctype_digit( $status ) ) { // success
-   $this->lastKnownSlavePos = $pos;
-   }
+   $row = $res ? $this->fetchRow( $res ) : false;
+   if ( !$row ) {
+   return null; // this shouldn't happen
+   }
+
+   // Result can be NULL (error), -1 (timeout), or 0+ per the 
MySQL manual
+   $status = ctype_digit( $row[0] ) ? intval( $row[0] ) : null;
+   if ( $status === null ) {
+   // T126436: jobs programmed to wait on master positions 
might be referencing binlogs
+   // with an old master hostname. Such calls make 
MASTER_POS_WAIT() return null. Try
+   // to detect this and treat the slave as having reached 
the position; a proper master
+   // switchover already requires that the new master be 
caught up before the switch.
+   $slavePos = $this->getSlavePos();
+   if ( $slavePos && !$slavePos->channelsMatch( $pos ) ) {
+   $this->lastKnownSlavePos = $slavePos;
+   $status = 0;
}
+   } elseif ( $status >= 0 ) {
+   // Remember that this position was reached to save 
queries next time
+   $this->lastKnownSlavePos = $pos;
}
 
return $status;
@@ -1446,12 +1450,32 @@
return ( $thisPos && $thatPos && $thisPos >= $thatPos );
}
 
+   function channelsMatch( DBMasterPos $pos ) {
+   if ( !( $pos instanceof self ) ) {
+   throw new InvalidArgumentException( "Position not an 
instance of " . __CLASS__ );
+   }
+
+   return ( $this->getBinlogName() === 

[MediaWiki-commits] [Gerrit] Allow setting read timeouts per queue - change (wikimedia...crm)

2016-02-17 Thread Ejegg (Code Review)
Ejegg has submitted this change and it was merged.

Change subject: Allow setting read timeouts per queue
..


Allow setting read timeouts per queue

Change-Id: Iad41bfc9ebc02cba8485fe5f9aa9f4261dbd2d5f
---
M sites/all/modules/wmf_common/Queue.php
1 file changed, 2 insertions(+), 0 deletions(-)

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



diff --git a/sites/all/modules/wmf_common/Queue.php 
b/sites/all/modules/wmf_common/Queue.php
index babc2cc..c9702c5 100644
--- a/sites/all/modules/wmf_common/Queue.php
+++ b/sites/all/modules/wmf_common/Queue.php
@@ -193,6 +193,8 @@
 'ack' => 'client',
 'selector' => "JMSCorrelationID='{$correlationId}'",
 );
+   $timeout = variable_get( "queue_timeout_$queue", 5 );
+   $con->setReadTimeout( $timeout );
 $con->subscribe( $this->normalizeQueueName( $queue ), $properties );
 
 return $con->readFrame();

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iad41bfc9ebc02cba8485fe5f9aa9f4261dbd2d5f
Gerrit-PatchSet: 4
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
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] Use flake8-docstrings>=0.2.5 - change (pywikibot/core)

2016-02-17 Thread John Vandenberg (Code Review)
John Vandenberg has uploaded a new change for review.

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

Change subject: Use flake8-docstrings>=0.2.5
..

Use flake8-docstrings>=0.2.5

(Fails at the moment)

Bug: T119790
Change-Id: I8d42e5e710f544e365063047e8e17e4d56a8b7a7
---
M tox.ini
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/25/271425/1

diff --git a/tox.ini b/tox.ini
index 5437e66..fb6cc07 100644
--- a/tox.ini
+++ b/tox.ini
@@ -30,7 +30,7 @@
 deps = flake8
git+https://github.com/pyflakes/pyflakes.git
hacking
-   flake8-docstrings<0.2.2
+   flake8-docstrings>=0.2.5
flake8-putty>=0.2.0
flake8-coding
flake8-future-import
@@ -45,7 +45,7 @@
 basepython = python3
 deps = flake8
git+https://github.com/pyflakes/pyflakes.git
-   flake8-docstrings<0.2.2
+   flake8-docstrings>=0.2.5
flake8-putty>=0.2.0
 
 [testenv:nose]

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8d42e5e710f544e365063047e8e17e4d56a8b7a7
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: John Vandenberg 

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


[MediaWiki-commits] [Gerrit] RESTBase: Update config to new style - change (mediawiki/vagrant)

2016-02-17 Thread Mobrovac (Code Review)
Mobrovac has submitted this change and it was merged.

Change subject: RESTBase: Update config to new style
..


RESTBase: Update config to new style

There was a backwards-incompatible change in config style
for RESTBase where modules definitions are an array, not an
object any more. Updating vagrant to use new config style.

Change-Id: Iddb4278df1cd3a847f12ce444acc66d65e2dd667
---
M puppet/modules/restbase/templates/config.yaml.erb
1 file changed, 30 insertions(+), 32 deletions(-)

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



diff --git a/puppet/modules/restbase/templates/config.yaml.erb 
b/puppet/modules/restbase/templates/config.yaml.erb
index a8b0924..f38415a 100644
--- a/puppet/modules/restbase/templates/config.yaml.erb
+++ b/puppet/modules/restbase/templates/config.yaml.erb
@@ -4,41 +4,39 @@
 # in the root_spec further down.
 default_project: _project
   x-modules:
-/:
-  - path: projects/wmf_sqlite.yaml
-options: _options
-  table:
-hosts: [localhost]
-keyspace: system
-username: cassandra
-password: cassandra
-defaultConsistency: one # or 'localQuorum' for production
-storage_groups:
-  - name: group.local
-domains: /./
-dbname: <%= @dbdir %>/mw-vagrant.sqlite3
-version: 1
-  parsoid:
-host: http://localhost:<%= scope['::mediawiki::parsoid::port'] %>
-  action:
-apiUriTemplate: "{{'http://localhost<%= scope['::port_fragment'] 
%>/w/api.php'}}"
-  graphoid:
-host: http://localhost:<%= @graphoid_port %>
-  mathoid:
-host: http://localhost:<%= @mathoid_port %>
-# 10 days Varnish caching, one day client-side
-cache-control: s-maxage=864000, max-age=86400
-  mobileapps:
-host: http://appservice.wmflabs.org
+- path: projects/wmf_sqlite.yaml
+  options: _options
+table:
+  hosts: [localhost]
+  keyspace: system
+  username: cassandra
+  password: cassandra
+  defaultConsistency: one # or 'localQuorum' for production
+  storage_groups:
+- name: group.local
+  domains: /./
+  dbname: <%= @dbdir %>/mw-vagrant.sqlite3
+  version: 1
+parsoid:
+  host: http://localhost:<%= scope['::mediawiki::parsoid::port'] %>
+action:
+  apiUriTemplate: "{{'http://localhost<%= scope['::port_fragment'] 
%>/w/api.php'}}"
+graphoid:
+  host: http://localhost:<%= @graphoid_port %>
+mathoid:
+  host: http://localhost:<%= @mathoid_port %>
+  # 10 days Varnish caching, one day client-side
+  cache-control: s-maxage=864000, max-age=86400
+mobileapps:
+  host: http://appservice.wmflabs.org
 
 wikimedia.org: 
   x-modules:
-/:
-  - path: projects/wikimedia.org_sqlite.yaml
-options:
-  <<: *default_options
-  pageviews:
-host: https://wikimedia.org/api/rest_v1/metrics
+- path: projects/wikimedia.org_sqlite.yaml
+  options:
+<<: *default_options
+pageviews:
+  host: https://wikimedia.org/api/rest_v1/metrics
 
 
 # The root of the spec tree. Domains tend to share specs by referencing them

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iddb4278df1cd3a847f12ce444acc66d65e2dd667
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/vagrant
Gerrit-Branch: master
Gerrit-Owner: Ppchelko 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: Dduvall 
Gerrit-Reviewer: GWicke 
Gerrit-Reviewer: Mobrovac 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] tlsproxy: set files ulimit at 2x conns - change (operations/puppet)

2016-02-17 Thread BBlack (Code Review)
BBlack has submitted this change and it was merged.

Change subject: tlsproxy: set files ulimit at 2x conns
..


tlsproxy: set files ulimit at 2x conns

Change-Id: I9f09a7f807a90eaba74349dcf5e928a0524bfda1
---
M modules/tlsproxy/templates/nginx.conf.erb
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/modules/tlsproxy/templates/nginx.conf.erb 
b/modules/tlsproxy/templates/nginx.conf.erb
index 6daf258..4db5ea5 100644
--- a/modules/tlsproxy/templates/nginx.conf.erb
+++ b/modules/tlsproxy/templates/nginx.conf.erb
@@ -32,14 +32,14 @@
 end
 -%>
 worker_cpu_affinity <%= affinity_mask.join(" ") %>;
-worker_rlimit_nofile 3;
+worker_rlimit_nofile <%= @nginx_worker_connections.to_i * 2 %>;
 
 
 error_log  /var/log/nginx/error.log;
 pid/run/nginx.pid;
 
 events {
-worker_connections  <%= @nginx_worker_connections %>;
+worker_connections <%= @nginx_worker_connections %>;
 multi_accept off; # accept 1 conn per epoll hit, basically
 accept_mutex off; # better latencies at high connection rates
 }

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

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

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


[MediaWiki-commits] [Gerrit] Apply the nomobile class - change (mediawiki...FlaggedRevs)

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

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

Change subject: Apply the nomobile class
..

Apply the nomobile class

The ext.flaggedRevs.basic is not currently targeted at mobile and looking
at it, there is no need for it to be.

Unfortunately this means the banner in FlaggablePageview is visible in mobile
browsers taking up real estate.

This generic solution allows the hiding of this banner at mobile resolutions

Change-Id: I8c718394f870812ec946dffb2b89474757c64b08
---
M frontend/FlaggablePageView.php
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/frontend/FlaggablePageView.php b/frontend/FlaggablePageView.php
index 5eb51a5..6746776 100755
--- a/frontend/FlaggablePageView.php
+++ b/frontend/FlaggablePageView.php
@@ -380,7 +380,7 @@
}
# Wrap tag contents in a div
if ( $tag != '' ) {
-   $css = "{$tagClass} plainlinks noprint";
+   $css = "{$tagClass} plainlinks noprint nomobile";
$notice = "{$tag}\n";
$this->reviewNotice .= $notice;
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8c718394f870812ec946dffb2b89474757c64b08
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/FlaggedRevs
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 

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


[MediaWiki-commits] [Gerrit] tlsproxy: set files ulimit at 2x conns - change (operations/puppet)

2016-02-17 Thread BBlack (Code Review)
BBlack has uploaded a new change for review.

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

Change subject: tlsproxy: set files ulimit at 2x conns
..

tlsproxy: set files ulimit at 2x conns

Change-Id: I9f09a7f807a90eaba74349dcf5e928a0524bfda1
---
M modules/tlsproxy/templates/nginx.conf.erb
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/23/271423/1

diff --git a/modules/tlsproxy/templates/nginx.conf.erb 
b/modules/tlsproxy/templates/nginx.conf.erb
index 6daf258..f5f7baf 100644
--- a/modules/tlsproxy/templates/nginx.conf.erb
+++ b/modules/tlsproxy/templates/nginx.conf.erb
@@ -32,14 +32,14 @@
 end
 -%>
 worker_cpu_affinity <%= affinity_mask.join(" ") %>;
-worker_rlimit_nofile 3;
+worker_rlimit_nofile <%= @nginx_worker_connections * 2 %>;
 
 
 error_log  /var/log/nginx/error.log;
 pid/run/nginx.pid;
 
 events {
-worker_connections  <%= @nginx_worker_connections %>;
+worker_connections <%= @nginx_worker_connections %>;
 multi_accept off; # accept 1 conn per epoll hit, basically
 accept_mutex off; # better latencies at high connection rates
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9f09a7f807a90eaba74349dcf5e928a0524bfda1
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] Surface references via api query property - change (mediawiki...Cite)

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

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

Change subject: Surface references via api query property
..

Surface references via api query property

* The query request prop=references will return a JSON blob of all
references in the page (the idea of groups is ignored here as this makes
assumptions on presentation)
* When references storage is disabled the API request will trigger an
error.

Bug: T123290
Change-Id: I81a965bcb47d17df18f1e415e3c25f88f6b48ffc
---
A ApiQueryReferences.php
M extension.json
M i18n/en.json
M i18n/qqq.json
4 files changed, 70 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Cite 
refs/changes/22/271422/1

diff --git a/ApiQueryReferences.php b/ApiQueryReferences.php
new file mode 100644
index 000..2c3c273
--- /dev/null
+++ b/ApiQueryReferences.php
@@ -0,0 +1,57 @@
+https://www.mediawiki.org/wiki/Extension:Cite#API
+ *
+ * @license WTFPL 2.0
+ */
+class ApiQueryReferences extends ApiQueryBase {
+
+   public function __construct( $query, $moduleName ) {
+   parent::__construct( $query, $moduleName, 'rf' );
+   }
+
+   public function execute() {
+   $config = ConfigFactory::getDefaultInstance()->makeConfig( 
'cite' );
+   if ( !$config->get( 'CiteStoreReferencesData' ) ) {
+   $this->dieUsage( 'This feature needs to enabled by a 
site admin', 'citestoragedisabled' );
+   }
+   $params = $this->extractRequestParams();
+   $titles = $this->getPageSet()->getGoodTitles();
+   if ( count( $titles ) === 0 ) {
+   return;
+   } else {
+   $result = $this->getResult();
+   foreach ( $titles as $id => $title ) {
+   $storedRefs = Cite::getStoredReferences( $title 
);
+   $allReferences = array();
+   // some pages may not have references stored
+   if ( isset( $storedRefs['refs'] ) ) {
+   // a page can have multiple 
 tags but they all have unique keys
+   foreach( $storedRefs['refs'] as $group 
) {
+   $allReferences = array_merge( 
$allReferences, $group[""] );
+   }
+   }
+   // Ship a data representation of the combined 
references.
+   $result->addValue( array( 'query', 'pages', $id 
), 'references', $allReferences );
+   }
+   }
+   }
+
+   public function getCacheMode( $params ) {
+   return 'public';
+   }
+
+   /**
+* @see ApiBase::getExamplesMessages()
+*/
+   protected function getExamplesMessages() {
+   return array(
+   'action=query=references=Albert%20Einstein' 
=>
+   'apihelp-query+references-example-1',
+   );
+   }
+
+}
diff --git a/extension.json b/extension.json
index 24e3fe3..e428ede 100644
--- a/extension.json
+++ b/extension.json
@@ -18,6 +18,11 @@
"cite": "i18n",
"ve-cite": "modules/ve-cite/i18n"
},
+   "APIPropModules": {
+   "references": {
+   "class": "ApiQueryReferences"
+   }
+   },
"Hooks": {
"ParserFirstCallInit": [
"Cite::setHooks"
@@ -167,6 +172,9 @@
"VisualEditorPluginModules": [
"ext.cite.visualEditor"
],
+   "ConfigRegistry": {
+   "cite": "GlobalVarConfig::newInstance"
+   },
"config": {
"AllowCiteGroups": true,
"CiteCacheReferences": false,
@@ -174,6 +182,7 @@
"CiteCacheReferencesDataOnParse": false
},
"AutoloadClasses": {
+   "ApiQueryReferences": "ApiQueryReferences.php",
"Cite": "Cite_body.php",
"CiteHooks": "CiteHooks.php",
"CiteDataModule": "CiteDataModule.php",
diff --git a/i18n/en.json b/i18n/en.json
index bf39a3f..13ca495 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -15,6 +15,8 @@
"Ævar Arnfjörð Bjarmason"
]
},
+   "apihelp-query+references-description": "Return a data representation 
of references associated with the given pages.",
+   "apihelp-query+references-example-1": "References associated with 
Albert Einstein.",
"cite-desc": "Adds  and 
 tags, for citations",
"cite_error": "Cite error: $1",
"cite_error_ref_numeric_key": "Invalid ref 
tag;\nname cannot be a simple integer. Use a 

[MediaWiki-commits] [Gerrit] Simplify statementview and add invariant checks - change (mediawiki...Wikibase)

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

Change subject: Simplify statementview and add invariant checks
..


Simplify statementview and add invariant checks

Change-Id: I3f6b76c3bcb24ce2efe64c4e02ef82aca5c1407e
---
M view/resources/jquery/wikibase/jquery.wikibase.statementview.js
1 file changed, 52 insertions(+), 84 deletions(-)

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



diff --git a/view/resources/jquery/wikibase/jquery.wikibase.statementview.js 
b/view/resources/jquery/wikibase/jquery.wikibase.statementview.js
index 4d24286..bea6ea1 100644
--- a/view/resources/jquery/wikibase/jquery.wikibase.statementview.js
+++ b/view/resources/jquery/wikibase/jquery.wikibase.statementview.js
@@ -481,36 +481,22 @@
 * @return {boolean}
 */
isInitialValue: function() {
-   var i;
+   if ( !this.isInEditMode() ) {
+   mw.log.warn( 'statementview::isInitialValue should only 
be called in edit mode' );
+   return true;
+   }
 
if ( this.options.value ) {
-   if ( this._rankSelector && 
!this._rankSelector.isInitialValue() ) {
+   if ( !this._rankSelector.isInitialValue() ) {
return false;
}
 
-   var snaklistviews = this._qualifiers ? 
this._qualifiers.value() : [],
-   qualifiers = new wb.datamodel.SnakList();
-
-   // Generate a SnakList object featuring all current 
qualifier snaks to be able to
-   // compare it to the SnakList object the claimview has 
been initialized with:
-   for ( i = 0; i < snaklistviews.length; i++ ) {
-   qualifiers.merge( snaklistviews[i].value() );
-   }
-
+   var qualifiers = this._getQualifiers();
if ( !qualifiers.equals( 
this.options.value.getClaim().getQualifiers() ) ) {
return false;
}
 
-   var referenceviews = this._referencesListview ? 
this._referencesListview.value() : [],
-   references = new wb.datamodel.ReferenceList();
-
-   for ( i = 0; i < referenceviews.length; i++ ) {
-   var reference = referenceviews[i].value();
-   if ( reference ) {
-   references.addItem( reference );
-   }
-   }
-
+   var references = this._getReferences();
if ( !references.equals( 
this.options.value.getReferences() ) ) {
return false;
}
@@ -528,26 +514,23 @@
 * @return {wikibase.datamodel.Statement|null}
 */
_instantiateStatement: function( guid ) {
+   if ( !this.isInEditMode() ) {
+   mw.log.warn( 'statementview::_instantiateStatement 
should only be called in edit mode' );
+   return null;
+   }
+
var mainSnak = this._mainSnakSnakView.snak();
 
if ( !mainSnak ) {
return null;
}
 
-   var qualifiers = new wb.datamodel.SnakList(),
-   snaklistviews = this._qualifiers ? 
this._qualifiers.value() : [];
-
-   // Combine qualifiers grouped by property to a single SnakList:
-   for ( var i = 0; i < snaklistviews.length; i++ ) {
-   qualifiers.merge( snaklistviews[i].value() );
-   }
+   var qualifiers = this._getQualifiers();
 
return new wb.datamodel.Statement(
new wb.datamodel.Claim( mainSnak, qualifiers, guid ),
-   new wb.datamodel.ReferenceList( this._getReferences() ),
-   this._rankSelector ? this._rankSelector.value() : ( 
this.options.value
-   ? this.options.value.getRank()
-   : wb.datamodel.Statement.RANK.NORMAL )
+   this._getReferences(),
+   this._rankSelector.value()
);
},
 
@@ -563,32 +546,35 @@
},
 
/**
+* @private
+*
+* @return {wikibase.datamodel.SnakList}
+*/
+   _getQualifiers: function() {
+   var qualifiers = new wb.datamodel.SnakList(),
+   snaklistviews = this._qualifiers.value();
+
+   // Combine qualifiers grouped by property to 

[MediaWiki-commits] [Gerrit] Move novaadmin authority from 'testlabs' to 'admin' - change (operations/puppet)

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

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

Change subject: Move novaadmin authority from 'testlabs' to 'admin'
..

Move novaadmin authority from 'testlabs' to 'admin'

Having the 'testlabs' project contain the admin role
for administrative tasks is a weird historical leftover.  We
now have an 'admin' project which can serve this purpose
and be less confusing to future users.

Change-Id: I3b6a1ebbef463296c7407a3fac388fc78e4635f0
---
M hieradata/eqiad.yaml
M modules/openstack/files/kilo/virtscripts/cold-migrate
M modules/openstack/files/kilo/virtscripts/cold-nova-migrate
M modules/openstack/files/kilo/virtscripts/live-migrate
M modules/openstack/templates/novaenv.sh.erb
5 files changed, 6 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/20/271420/1

diff --git a/hieradata/eqiad.yaml b/hieradata/eqiad.yaml
index d6d5f18..95e998c 100644
--- a/hieradata/eqiad.yaml
+++ b/hieradata/eqiad.yaml
@@ -123,8 +123,8 @@
   auth_port: '35357'
   auth_protocol: 'http'
   auth_host: 208.80.154.92
-  admin_project_id: 'testlabs'
-  admin_project_name: 'testlabs'
+  admin_project_id: 'admin'
+  admin_project_name: 'admin'
 
 designateconfig:
   db_host:  'm5-master.eqiad.wmnet'
diff --git a/modules/openstack/files/kilo/virtscripts/cold-migrate 
b/modules/openstack/files/kilo/virtscripts/cold-migrate
index 0c4652c..63be3c7 100755
--- a/modules/openstack/files/kilo/virtscripts/cold-migrate
+++ b/modules/openstack/files/kilo/virtscripts/cold-migrate
@@ -134,7 +134,7 @@
 argparser.add_argument(
 '--nova-project',
 help='project for nova auth',
-default='testlabs'
+default='admin'
 )
 argparser.add_argument(
 '--mysql-password',
diff --git a/modules/openstack/files/kilo/virtscripts/cold-nova-migrate 
b/modules/openstack/files/kilo/virtscripts/cold-nova-migrate
index 64eb0e8..c039346 100755
--- a/modules/openstack/files/kilo/virtscripts/cold-nova-migrate
+++ b/modules/openstack/files/kilo/virtscripts/cold-nova-migrate
@@ -107,7 +107,7 @@
 argparser.add_argument(
 '--nova-project',
 help='project for nova auth',
-default='testlabs'
+default='admin'
 )
 argparser.add_argument(
 '--no-restart',
diff --git a/modules/openstack/files/kilo/virtscripts/live-migrate 
b/modules/openstack/files/kilo/virtscripts/live-migrate
index 512acda..a1fab3d 100755
--- a/modules/openstack/files/kilo/virtscripts/live-migrate
+++ b/modules/openstack/files/kilo/virtscripts/live-migrate
@@ -131,7 +131,7 @@
 argparser.add_argument(
 '--nova-project',
 help='project for nova auth',
-default='testlabs'
+default='admin'
 )
 argparser.add_argument(
 'instanceid',
diff --git a/modules/openstack/templates/novaenv.sh.erb 
b/modules/openstack/templates/novaenv.sh.erb
index d63f13b..c01787b 100644
--- a/modules/openstack/templates/novaenv.sh.erb
+++ b/modules/openstack/templates/novaenv.sh.erb
@@ -4,6 +4,6 @@
 export OS_PASSWORD="<%= @wikitech_nova_ldap_user_pass %>"
 export OS_AUTH_URL="http://<%= @nova_controller_hostname %>:35357/v3"
 export OS_REGION_NAME="<%= @nova_region %>"
-export OS_TENANT_NAME="testlabs"
+export OS_TENANT_NAME=<%= @wikitech_nova_admin_project_name %>
 export OS_NO_CACHE=1
 export OS_IDENTITY_API_VERSION=3

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

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

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 83d8a7d..dabeb42 - change (mediawiki/extensions)

2016-02-17 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

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

Change subject: Syncronize VisualEditor: 83d8a7d..dabeb42
..

Syncronize VisualEditor: 83d8a7d..dabeb42

Change-Id: Ifb1d87186e8f1564b7fc5c97a2cabb03d3f90b35
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/21/271421/1

diff --git a/VisualEditor b/VisualEditor
index 83d8a7d..dabeb42 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 83d8a7d9bb7867dc21f1a2390e2d0ecb6a2b6b75
+Subproject commit dabeb4218d1af9608097c6cf002f4da0799b255c

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifb1d87186e8f1564b7fc5c97a2cabb03d3f90b35
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 

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


  1   2   3   4   >