[MediaWiki-commits] [Gerrit] pywikibot/core[master]: [bugfix] Remove overlap warning

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

Change subject: [bugfix] Remove overlap warning
..


[bugfix] Remove overlap warning

The overlap warning was introduced with T92626 but is still unclear what to
do with it. The naming conflict seems already solved.

See also:
https://gerrit.wikimedia.org/r/#/c/196642/5/pywikibot/data/api.py@269

Bug: T92626
Bug: T171068
Bug: T178794
Change-Id: Ib81558295da67145f5b76d4100b60484f9fa2281
---
M pywikibot/data/api.py
1 file changed, 0 insertions(+), 9 deletions(-)

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



diff --git a/pywikibot/data/api.py b/pywikibot/data/api.py
index f2c06dd..540648d 100644
--- a/pywikibot/data/api.py
+++ b/pywikibot/data/api.py
@@ -299,15 +299,6 @@
 self._fetch(set(['query']))
 assert 'query' in self._modules
 
-_reused_module_names = self._action_modules & self._modules['query']
-
-# The only name clash in core between actions and query submodules is
-# action=tokens and actions=query=tokens, and this will warn if
-# any new ones appear.
-if _reused_module_names > set(['tokens']):
-warn('Unexpected overlap between action and query submodules: %s'
- % (_reused_module_names - set(['tokens'])), UserWarning)
-
 def _emulate_pageset(self):
 """Emulate the pageset module, which existed in MW 1.15-1.24."""
 # pageset isnt a module in the new system, so it is emulated, with

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib81558295da67145f5b76d4100b60484f9fa2281
Gerrit-PatchSet: 2
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Xqt 
Gerrit-Reviewer: Dalba 
Gerrit-Reviewer: John Vandenberg 
Gerrit-Reviewer: Magul 
Gerrit-Reviewer: MarcoAurelio 
Gerrit-Reviewer: Zoranzoki21 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] wikidata...gui[master]: Improve code samples for several languages

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

Change subject: Improve code samples for several languages
..


Improve code samples for several languages

Use heredocs/nowdocs for PHP and Ruby, triple-quoted strings for Python,
and concatenate multiple string literals for Java and JavaScript.

Change-Id: I60c12c835836241b13070d82b356ec0f80289838
---
M wikibase/queryService/api/CodeSamples.js
1 file changed, 58 insertions(+), 13 deletions(-)

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



diff --git a/wikibase/queryService/api/CodeSamples.js 
b/wikibase/queryService/api/CodeSamples.js
index 1267afe..7aa92a6 100644
--- a/wikibase/queryService/api/CodeSamples.js
+++ b/wikibase/queryService/api/CodeSamples.js
@@ -40,6 +40,18 @@
},
PHP: {
escape: function( query ) {
+   // try nowdoc first
+   var identifiers = [ 'SPARQL', 'QUERY', 
'EOF' ];
+   for ( var index in identifiers ) {
+   var identifier = identifiers[ 
index ];
+   if ( !( new RegExp( '^' + 
identifier + '$', 'm' ).test( query ) ) ) {
+   return '<<< \'' + 
identifier + '\'\n'
+   + query + '\n'
+   + identifier;
+   }
+   }
+
+   // fall back to double quoted
var escapedQuery = query
.replace( /\\/g, '' )
.replace( /"/g, '\\"' )
@@ -50,11 +62,22 @@
},
'JavaScript (jQuery)': {
escape: function( query ) {
-   var escapedQuery = query
-   .replace( /\\/g, '' )
-   .replace( /"/g, '\\"' )
-   .replace( /\n/g, '\\n' );
-   return '"' + escapedQuery + '"';
+   var code = '';
+   var lines = query.split( '\n' );
+   for ( var index in lines ) {
+   var line = lines[ index ];
+   var escapedLine = line
+   .replace( /\\/g, '' 
)
+   .replace( /"/g, '\\"' );
+   if ( index > 0 ) {
+   code += '\\n" +\n   
 ';
+   }
+   code += '"' + escapedLine;
+   }
+   if ( index > 0 ) {
+   code += '"';
+   }
+   return code;
},
mimetype: 'application/javascript'
},
@@ -70,24 +93,46 @@
},
Java: {
escape: function( query ) {
-   var escapedQuery = query
-   .replace( /\\/g, '' )
-   .replace( /"/g, '\\"' )
-   .replace( /\n/g, '\\n' );
-   return '"' + escapedQuery + '"';
+   var code = '';
+   var lines = query.split( '\n' );
+   for ( var index in lines ) {
+   var line = lines[ index ];
+   var escapedLine = line
+   .replace( /\\/g, '' 
)
+   .replace( /"/g, '\\"' );
+   if ( index > 0 ) {
+   code += '\\n" +\n   
 ';
+   }
+ 

[MediaWiki-commits] [Gerrit] wikidata...gui[master]: Fix documentation of CodeSamples.getExamples()

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

Change subject: Fix documentation of CodeSamples.getExamples()
..


Fix documentation of CodeSamples.getExamples()

Change-Id: Ide58b0d7ae9219be1ef1f97367e12f9ea0958c7a
---
M wikibase/queryService/api/CodeSamples.js
1 file changed, 2 insertions(+), 1 deletion(-)

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



diff --git a/wikibase/queryService/api/CodeSamples.js 
b/wikibase/queryService/api/CodeSamples.js
index 7aa92a6..2227820 100644
--- a/wikibase/queryService/api/CodeSamples.js
+++ b/wikibase/queryService/api/CodeSamples.js
@@ -179,7 +179,8 @@
SELF.prototype._endpoint = null;
 
/**
-* @return {jQuery.Promise} Object taking list of example queries { 
title:, query: }
+* @return {jQuery.Promise} yields a list of code examples for the 
current query
+* ({ code: string, mimetype: string })
 */
SELF.prototype.getExamples = function ( currentQuery ) {
var self = this,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ide58b0d7ae9219be1ef1f97367e12f9ea0958c7a
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/gui
Gerrit-Branch: master
Gerrit-Owner: Lucas Werkmeister (WMDE) 
Gerrit-Reviewer: Jonas Kress (WMDE) 
Gerrit-Reviewer: Smalyshev 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] pywikibot/core[master]: dev-requirements.txt: Use httpbin<0.6.0 on Windows

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

Change subject: dev-requirements.txt: Use httpbin<0.6.0 on Windows
..


dev-requirements.txt: Use httpbin<0.6.0 on Windows

Bug: T174886
Change-Id: I48660ffb5446382526c958f953c0379a0ed723e7
---
M dev-requirements.txt
1 file changed, 1 insertion(+), 2 deletions(-)

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



diff --git a/dev-requirements.txt b/dev-requirements.txt
index 8bfa279..0e5b501 100644
--- a/dev-requirements.txt
+++ b/dev-requirements.txt
@@ -8,8 +8,7 @@
 pytest-cov
 pytest-attrib
 pytest-httpbin
-httpbin<0.6.0 ; python_version < '2.7'
-httpbin!=0.6.0,!=0.6.1 ; os_name != 'posix' and python_version >= '2.7'
+httpbin<0.6.0 ; os_name != 'posix' or python_version < '2.7'
 
 six
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I48660ffb5446382526c958f953c0379a0ed723e7
Gerrit-PatchSet: 3
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Dalba 
Gerrit-Reviewer: John Vandenberg 
Gerrit-Reviewer: Xqt 
Gerrit-Reviewer: Zoranzoki21 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...ContentTranslation[master]: Use convertNumber for numbers

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

Change subject: Use convertNumber for numbers
..


Use convertNumber for numbers

Change-Id: I9544647c7b41f7c9f237dd508297017395ced4ac
---
M extension.json
M modules/widgets/translator/ext.cx.translator.js
2 files changed, 6 insertions(+), 3 deletions(-)

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



diff --git a/extension.json b/extension.json
index eb70bbf..f09e565 100644
--- a/extension.json
+++ b/extension.json
@@ -1174,7 +1174,8 @@
],
"dependencies": [
"ext.cx.model",
-   "mediawiki.api"
+   "mediawiki.api",
+   "mediawiki.language"
]
},
"mw.cx.dm": {
diff --git a/modules/widgets/translator/ext.cx.translator.js 
b/modules/widgets/translator/ext.cx.translator.js
index 67902a6..74ee041 100644
--- a/modules/widgets/translator/ext.cx.translator.js
+++ b/modules/widgets/translator/ext.cx.translator.js
@@ -81,8 +81,10 @@
}
 
$header.text( mw.msg( 'cx-translator-header' ) );
-   $total.find( '.cx-translator__total-translations-count' 
).text( total );
-   $monthStats.find( '.cx-translator__month-stats-count' 
).text( thisMonthStats );
+   $total.find( '.cx-translator__total-translations-count' 
)
+   .text( mw.language.convertNumber( total ) );
+   $monthStats.find( '.cx-translator__month-stats-count' )
+   .text( mw.language.convertNumber( 
thisMonthStats ) );
 
$.each( monthKeys, function ( i, month ) {
self.max = Math.max( self.max, publishTrend[ 
month ].delta );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I9544647c7b41f7c9f237dd508297017395ced4ac
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Nikerabbit 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: Petar.petkovic 
Gerrit-Reviewer: Santhosh 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] pywikibot/core[master]: dev-requirements.txt: Use httpbin<0.6.0 on Windows

2017-10-23 Thread Dalba (Code Review)
Dalba has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386126 )

Change subject: dev-requirements.txt: Use httpbin<0.6.0 on Windows
..

dev-requirements.txt: Use httpbin<0.6.0 on Windows

Bug: T174886
Change-Id: I48660ffb5446382526c958f953c0379a0ed723e7
---
M dev-requirements.txt
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/26/386126/1

diff --git a/dev-requirements.txt b/dev-requirements.txt
index 8bfa279..a275393 100644
--- a/dev-requirements.txt
+++ b/dev-requirements.txt
@@ -8,8 +8,8 @@
 pytest-cov
 pytest-attrib
 pytest-httpbin
-httpbin<0.6.0 ; python_version < '2.7'
-httpbin!=0.6.0,!=0.6.1 ; os_name != 'posix' and python_version >= '2.7'
+httpbin<0.6.0 ; os_name != 'posix' or python_version < '2.7'
+httpbin ; os_name == 'posix' and python_version >= '2.7'
 
 six
 

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...Wikidata[wmf/1.31.0-wmf.5]: New deployment branch - wmf/1.31.0-wmf.5

2017-10-23 Thread Aude (Code Review)
Aude has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386125 )

Change subject: New deployment branch - wmf/1.31.0-wmf.5
..

New deployment branch - wmf/1.31.0-wmf.5

Change-Id: I14c65d7dcd1077e71e38d41e5522729e6036f0a0
---
M WikibaseClient.settings.php
M WikibaseRepo.settings.php
M composer.json
M composer.lock
M extensions/ArticlePlaceholder/includes/ItemNotabilityFilter.php
M extensions/Constraints/README.md
M extensions/Constraints/WikibaseQualityConstraintsHooks.php
M extensions/Constraints/api/CheckConstraints.php
M extensions/Constraints/extension.json
M extensions/Constraints/i18n/cs.json
M extensions/Constraints/i18n/uk.json
M extensions/Constraints/includes/Constraint.php
M extensions/Constraints/includes/ConstraintCheck/Checker/CommonsLinkChecker.php
M 
extensions/Constraints/includes/ConstraintCheck/Checker/ConflictsWithChecker.php
M 
extensions/Constraints/includes/ConstraintCheck/Checker/DiffWithinRangeChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/FormatChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/InverseChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/ItemChecker.php
M 
extensions/Constraints/includes/ConstraintCheck/Checker/MandatoryQualifiersChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/MultiValueChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/OneOfChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/QualifierChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/QualifiersChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/RangeChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/ReferenceChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/SingleValueChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/SymmetricChecker.php
M 
extensions/Constraints/includes/ConstraintCheck/Checker/TargetRequiredClaimChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/TypeChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/UniqueValueChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/ValueOnlyChecker.php
M extensions/Constraints/includes/ConstraintCheck/Checker/ValueTypeChecker.php
M extensions/Constraints/includes/ConstraintCheck/ConstraintChecker.php
M extensions/Constraints/includes/ConstraintCheck/Context/AbstractContext.php
M extensions/Constraints/includes/ConstraintCheck/Context/ApiV2Context.php
M extensions/Constraints/includes/ConstraintCheck/Context/Context.php
M extensions/Constraints/includes/ConstraintCheck/Context/MainSnakContext.php
M extensions/Constraints/includes/ConstraintCheck/Context/QualifierContext.php
M extensions/Constraints/includes/ConstraintCheck/Context/ReferenceContext.php
D extensions/Constraints/includes/ConstraintCheck/Context/StatementContext.php
M 
extensions/Constraints/includes/ConstraintCheck/DelegatingConstraintChecker.php
M 
extensions/Constraints/includes/ConstraintCheck/Helper/ConnectionCheckerHelper.php
M 
extensions/Constraints/includes/ConstraintCheck/Helper/ConstraintParameterException.php
M 
extensions/Constraints/includes/ConstraintCheck/Helper/ConstraintParameterParser.php
M extensions/Constraints/includes/ConstraintCheck/Helper/LoggingHelper.php
M extensions/Constraints/includes/ConstraintCheck/Helper/RangeCheckerHelper.php
M extensions/Constraints/includes/ConstraintCheck/Helper/SparqlHelper.php
M extensions/Constraints/includes/ConstraintCheck/Helper/TypeCheckerHelper.php
M 
extensions/Constraints/includes/ConstraintCheck/Helper/ValueCountCheckerHelper.php
M extensions/Constraints/includes/ConstraintCheck/Result/CheckResult.php
A extensions/Constraints/includes/ConstraintCheck/Result/NullResult.php
M extensions/Constraints/includes/ConstraintParameterRenderer.php
M extensions/Constraints/includes/ConstraintReportFactory.php
M extensions/Constraints/includes/ConstraintRepository.php
M extensions/Constraints/includes/Role.php
M extensions/Constraints/includes/UpdateConstraintsTableJob.php
M extensions/Constraints/maintenance/ImportConstraintStatements.php
M extensions/Constraints/specials/SpecialConstraintReport.php
M extensions/Constraints/tests/phpunit/Api/CheckConstraintsTest.php
M 
extensions/Constraints/tests/phpunit/Checker/CommonsLinkChecker/CommonsLinkCheckerTest.php
M 
extensions/Constraints/tests/phpunit/Checker/ConnectionChecker/ConflictsWithCheckerTest.php
M 
extensions/Constraints/tests/phpunit/Checker/ConnectionChecker/InverseCheckerTest.php
M 
extensions/Constraints/tests/phpunit/Checker/ConnectionChecker/ItemCheckerTest.php
M 
extensions/Constraints/tests/phpunit/Checker/ConnectionChecker/SymmetricCheckerTest.php
M 
extensions/Constraints/tests/phpunit/Checker/ConnectionChecker/TargetRequiredClaimCheckerTest.php
M 

[MediaWiki-commits] [Gerrit] labs/libraryupgrader[master]: Don't use subprocess.run(), it's Python 3.5+

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

Change subject: Don't use subprocess.run(), it's Python 3.5+
..


Don't use subprocess.run(), it's Python 3.5+

And jessie has 3.4.

Change-Id: I3c38c3e63a6fe2ddf0930b75a19f4c74b6232cc2
---
M docker.py
1 file changed, 2 insertions(+), 3 deletions(-)

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



diff --git a/docker.py b/docker.py
index 5c2166a..4abef7e 100644
--- a/docker.py
+++ b/docker.py
@@ -51,12 +51,11 @@
 
 
 def logs(name: str) -> str:
-out = subprocess.run(
+out = subprocess.check_output(
 ['docker', 'logs', name],
-stdout=subprocess.PIPE,
 stderr=subprocess.STDOUT
 )
-return out.stdout.decode()
+return out.decode()
 
 
 def remove_container(name: str):

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3c38c3e63a6fe2ddf0930b75a19f4c74b6232cc2
Gerrit-PatchSet: 2
Gerrit-Project: labs/libraryupgrader
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
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] labs/libraryupgrader[master]: Fix E722: do not use bare except

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

Change subject: Fix E722: do not use bare except
..


Fix E722: do not use bare except

Change-Id: I61e6b72a6a43898f5fc72667596c283fe20573f9
---
M mw.py
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/mw.py b/mw.py
index cfa716c..2e777fc 100644
--- a/mw.py
+++ b/mw.py
@@ -60,5 +60,5 @@
 r = s.get(url)
 try:
 return r.json()
-except:
+except ValueError:
 return None

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I61e6b72a6a43898f5fc72667596c283fe20573f9
Gerrit-PatchSet: 1
Gerrit-Project: labs/libraryupgrader
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
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] labs/libraryupgrader[master]: Fix E722: do not use bare except

2017-10-23 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386124 )

Change subject: Fix E722: do not use bare except
..

Fix E722: do not use bare except

Change-Id: I61e6b72a6a43898f5fc72667596c283fe20573f9
---
M mw.py
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/libraryupgrader 
refs/changes/24/386124/1

diff --git a/mw.py b/mw.py
index cfa716c..2e777fc 100644
--- a/mw.py
+++ b/mw.py
@@ -60,5 +60,5 @@
 r = s.get(url)
 try:
 return r.json()
-except:
+except ValueError:
 return None

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I61e6b72a6a43898f5fc72667596c283fe20573f9
Gerrit-PatchSet: 1
Gerrit-Project: labs/libraryupgrader
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] labs/libraryupgrader[master]: Don't use subprocess.run(), it's Python 3.5+

2017-10-23 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386123 )

Change subject: Don't use subprocess.run(), it's Python 3.5+
..

Don't use subprocess.run(), it's Python 3.5+

And jessie has 3.4.

Change-Id: I3c38c3e63a6fe2ddf0930b75a19f4c74b6232cc2
---
M docker.py
1 file changed, 2 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/libraryupgrader 
refs/changes/23/386123/1

diff --git a/docker.py b/docker.py
index 5c2166a..4abef7e 100644
--- a/docker.py
+++ b/docker.py
@@ -51,12 +51,11 @@
 
 
 def logs(name: str) -> str:
-out = subprocess.run(
+out = subprocess.check_output(
 ['docker', 'logs', name],
-stdout=subprocess.PIPE,
 stderr=subprocess.STDOUT
 )
-return out.stdout.decode()
+return out.decode()
 
 
 def remove_container(name: str):

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3c38c3e63a6fe2ddf0930b75a19f4c74b6232cc2
Gerrit-PatchSet: 1
Gerrit-Project: labs/libraryupgrader
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] analytics...WDCM[master]: fix Overview Dashboard

2017-10-23 Thread GoranSMilovanovic (Code Review)
GoranSMilovanovic has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/386122 )

Change subject: fix Overview Dashboard
..


fix Overview Dashboard

Change-Id: Ia64b3c4548b02c8366adacdddea922aea003dc10
---
M WDCM_OverviewDashboard/server.R
1 file changed, 0 insertions(+), 4 deletions(-)

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



diff --git a/WDCM_OverviewDashboard/server.R b/WDCM_OverviewDashboard/server.R
index 7e05dc3..86149ee 100644
--- a/WDCM_OverviewDashboard/server.R
+++ b/WDCM_OverviewDashboard/server.R
@@ -40,10 +40,6 @@
 header = T,
 drop = 1)
 
-currentStats <- fread("currentStats.csv",
-  header = T,
-  drop = 1)
-
 ### -- Connect
 con <- dbConnect(MySQL(), 
  host = "tools.labsdb", 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia64b3c4548b02c8366adacdddea922aea003dc10
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wmde/WDCM
Gerrit-Branch: master
Gerrit-Owner: GoranSMilovanovic 
Gerrit-Reviewer: GoranSMilovanovic 

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


[MediaWiki-commits] [Gerrit] analytics...WDCM[master]: fix Overview Dashboard

2017-10-23 Thread GoranSMilovanovic (Code Review)
GoranSMilovanovic has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386122 )

Change subject: fix Overview Dashboard
..

fix Overview Dashboard

Change-Id: Ia64b3c4548b02c8366adacdddea922aea003dc10
---
M WDCM_OverviewDashboard/server.R
1 file changed, 0 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wmde/WDCM 
refs/changes/22/386122/1

diff --git a/WDCM_OverviewDashboard/server.R b/WDCM_OverviewDashboard/server.R
index 7e05dc3..86149ee 100644
--- a/WDCM_OverviewDashboard/server.R
+++ b/WDCM_OverviewDashboard/server.R
@@ -40,10 +40,6 @@
 header = T,
 drop = 1)
 
-currentStats <- fread("currentStats.csv",
-  header = T,
-  drop = 1)
-
 ### -- Connect
 con <- dbConnect(MySQL(), 
  host = "tools.labsdb", 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia64b3c4548b02c8366adacdddea922aea003dc10
Gerrit-PatchSet: 1
Gerrit-Project: analytics/wmde/WDCM
Gerrit-Branch: master
Gerrit-Owner: GoranSMilovanovic 

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


[MediaWiki-commits] [Gerrit] analytics...WDCM[master]: Semantics Dashboard

2017-10-23 Thread GoranSMilovanovic (Code Review)
GoranSMilovanovic has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/386121 )

Change subject: Semantics Dashboard
..


Semantics Dashboard

Change-Id: I53b8d162a3e729f388992efdb3d5358ab6646565
---
M WDCM_SemanticsDashboard/server.R
M WDCM_SemanticsDashboard/ui.R
A WDCM_ShinyServerFrontPage/SemanticsDashboard.png
M WDCM_ShinyServerFrontPage/wdcm_ShinyFront.html
4 files changed, 398 insertions(+), 20 deletions(-)

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



diff --git a/WDCM_SemanticsDashboard/server.R b/WDCM_SemanticsDashboard/server.R
index 1ebb4a8..f07ae5b 100644
--- a/WDCM_SemanticsDashboard/server.R
+++ b/WDCM_SemanticsDashboard/server.R
@@ -57,6 +57,9 @@
 res <- dbSendQuery(con, q)
 dbClearResult(res)
 
+### --- itemTopicTables
+itemTopicTables <- st$tables[which(grepl("wdcm2_itemtopic_", st$tables, fixed 
= T))]
+
 ### --- fetch wdcm2_project
 q <- "SELECT * FROM wdcm2_project;"
 res <- dbSendQuery(con, q)
@@ -96,7 +99,7 @@
 lF <- lF[grepl("wdcm2_projecttopic_", lF, fixed = T)]
 projectTopic <- vector(mode = "list", length = length(lF))
 for (i in 1:length(lF)) {
-  projectTopic[[i]] <- fread(lF[i])
+  projectTopic[[i]] <- fread(lF[i], data.table = F)
 }
 names(projectTopic) <- sapply(lF, function(x) {
   strsplit(strsplit(x, split = ".", fixed = T)[[1]][1],
@@ -157,6 +160,294 @@
 ### --- shinyServer
 shinyServer(function(input, output, session) {
   
+  ### --
+  ### --- TAB: tabPanel Semantic Models
+  ### --
+  
+  ### --- SELECT: update select 'selectCategory'
+  updateSelectizeInput(session,
+   'selectCategory',
+   "Select Semantic Category:",
+   choices = categories,
+   selected = categories[round(runif(1, 1, 
length(categories)))],
+   server = TRUE)
+  
+  ### --- REACTIVE: category specific wdcm_itemtopic data.frame
+  itemTopicsNum <- reactive({
+sC <- gsub(" ", "", input$selectCategory, fixed = T)
+sTable <- itemTopicTables[which(grepl(sC, itemTopicTables, fixed = T))]
+### -- Connect
+con <- dbConnect(MySQL(), 
+ host = "tools.labsdb", 
+ defult.file = 
"/home/goransm/mySQL_Credentials/replica.my.cnf",
+ dbname = "u16664__wdcm_p",
+ user = mySQLCreds$user,
+ password = mySQLCreds$password)
+### --- check the particular table
+q <- paste("DESCRIBE ", sTable, ";", sep = "")
+res <- dbSendQuery(con, q)
+sIT <- fetch(res, -1)
+dbClearResult(res)
+### --- Disconnect
+dbDisconnect(con)
+sum(grepl("topic", sIT$Field))
+  })
+  
+  ### --- SELECT: updateSelectizeInput 'selectCatTopic'
+  output$selectCatTopic <-
+renderUI({
+  if ((is.null(input$selectCategory)) | (length(input$selectCategory) == 
0)) {
+selectInput(inputId = "selectCategoryTopic",
+label = "Select Semantic Topic:",
+choices = NULL,
+selected = NULL)
+  } else {
+cH <- paste("Topic", 1:itemTopicsNum(), sep = " ")
+selectInput(inputId = "selectCategoryTopic",
+label = "Select Semantic Topic:",
+choices = cH,
+selected = cH[1])
+  }
+})
+  
+  ### --- REACTIVE current itemTopic table:
+  itemTopic <- reactive({
+  sC <- gsub(" ", "", input$selectCategory, fixed = T)
+  sTable <- itemTopicTables[which(grepl(sC, itemTopicTables, fixed = T))]
+  cTopic <- tolower(gsub(" ", "", input$selectCategoryTopic))
+  if (!length(cTopic) == 0) {
+### -- Connect
+con <- dbConnect(MySQL(),
+ host = "tools.labsdb",
+ defult.file = 
"/home/goransm/mySQL_Credentials/replica.my.cnf",
+ dbname = "u16664__wdcm_p",
+ user = mySQLCreds$user,
+ password = mySQLCreds$password)
+### --- check the particular table
+q <- 'SET CHARACTER SET utf8;'
+res <- dbSendQuery(con, q)
+q <- paste("SELECT * FROM ", sTable, " ORDER BY ", cTopic, " DESC 
LIMIT 50;", sep = "")
+res <- dbSendQuery(con, q)
+iT <- fetch(res, -1)
+dbClearResult(res)
+### --- Disconnect
+dbDisconnect(con)
+### --- Output:
+return(iT) 
+  } else {return(NULL)}
+  })
+  
+  ### --- OUTPUT output$topItemsTopic
+  output$topItemsTopic <- renderPlot({
+if (!is.null(itemTopic())) {
+  cTopic <- tolower(gsub(" ", "", input$selectCategoryTopic))
+  plotFrame <- itemTopic()
+  plotFrame <- select(plotFrame, 
+  eu_label, eu_entity_id, cTopic)
+  colnames(plotFrame) <- c('Label', 'Id', 'Probability')
+  

[MediaWiki-commits] [Gerrit] analytics...WDCM[master]: Semantics Dashboard

2017-10-23 Thread GoranSMilovanovic (Code Review)
GoranSMilovanovic has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386121 )

Change subject: Semantics Dashboard
..

Semantics Dashboard

Change-Id: I53b8d162a3e729f388992efdb3d5358ab6646565
---
M WDCM_SemanticsDashboard/server.R
M WDCM_SemanticsDashboard/ui.R
A WDCM_ShinyServerFrontPage/SemanticsDashboard.png
M WDCM_ShinyServerFrontPage/wdcm_ShinyFront.html
4 files changed, 398 insertions(+), 20 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/wmde/WDCM 
refs/changes/21/386121/1

diff --git a/WDCM_SemanticsDashboard/server.R b/WDCM_SemanticsDashboard/server.R
index 1ebb4a8..f07ae5b 100644
--- a/WDCM_SemanticsDashboard/server.R
+++ b/WDCM_SemanticsDashboard/server.R
@@ -57,6 +57,9 @@
 res <- dbSendQuery(con, q)
 dbClearResult(res)
 
+### --- itemTopicTables
+itemTopicTables <- st$tables[which(grepl("wdcm2_itemtopic_", st$tables, fixed 
= T))]
+
 ### --- fetch wdcm2_project
 q <- "SELECT * FROM wdcm2_project;"
 res <- dbSendQuery(con, q)
@@ -96,7 +99,7 @@
 lF <- lF[grepl("wdcm2_projecttopic_", lF, fixed = T)]
 projectTopic <- vector(mode = "list", length = length(lF))
 for (i in 1:length(lF)) {
-  projectTopic[[i]] <- fread(lF[i])
+  projectTopic[[i]] <- fread(lF[i], data.table = F)
 }
 names(projectTopic) <- sapply(lF, function(x) {
   strsplit(strsplit(x, split = ".", fixed = T)[[1]][1],
@@ -157,6 +160,294 @@
 ### --- shinyServer
 shinyServer(function(input, output, session) {
   
+  ### --
+  ### --- TAB: tabPanel Semantic Models
+  ### --
+  
+  ### --- SELECT: update select 'selectCategory'
+  updateSelectizeInput(session,
+   'selectCategory',
+   "Select Semantic Category:",
+   choices = categories,
+   selected = categories[round(runif(1, 1, 
length(categories)))],
+   server = TRUE)
+  
+  ### --- REACTIVE: category specific wdcm_itemtopic data.frame
+  itemTopicsNum <- reactive({
+sC <- gsub(" ", "", input$selectCategory, fixed = T)
+sTable <- itemTopicTables[which(grepl(sC, itemTopicTables, fixed = T))]
+### -- Connect
+con <- dbConnect(MySQL(), 
+ host = "tools.labsdb", 
+ defult.file = 
"/home/goransm/mySQL_Credentials/replica.my.cnf",
+ dbname = "u16664__wdcm_p",
+ user = mySQLCreds$user,
+ password = mySQLCreds$password)
+### --- check the particular table
+q <- paste("DESCRIBE ", sTable, ";", sep = "")
+res <- dbSendQuery(con, q)
+sIT <- fetch(res, -1)
+dbClearResult(res)
+### --- Disconnect
+dbDisconnect(con)
+sum(grepl("topic", sIT$Field))
+  })
+  
+  ### --- SELECT: updateSelectizeInput 'selectCatTopic'
+  output$selectCatTopic <-
+renderUI({
+  if ((is.null(input$selectCategory)) | (length(input$selectCategory) == 
0)) {
+selectInput(inputId = "selectCategoryTopic",
+label = "Select Semantic Topic:",
+choices = NULL,
+selected = NULL)
+  } else {
+cH <- paste("Topic", 1:itemTopicsNum(), sep = " ")
+selectInput(inputId = "selectCategoryTopic",
+label = "Select Semantic Topic:",
+choices = cH,
+selected = cH[1])
+  }
+})
+  
+  ### --- REACTIVE current itemTopic table:
+  itemTopic <- reactive({
+  sC <- gsub(" ", "", input$selectCategory, fixed = T)
+  sTable <- itemTopicTables[which(grepl(sC, itemTopicTables, fixed = T))]
+  cTopic <- tolower(gsub(" ", "", input$selectCategoryTopic))
+  if (!length(cTopic) == 0) {
+### -- Connect
+con <- dbConnect(MySQL(),
+ host = "tools.labsdb",
+ defult.file = 
"/home/goransm/mySQL_Credentials/replica.my.cnf",
+ dbname = "u16664__wdcm_p",
+ user = mySQLCreds$user,
+ password = mySQLCreds$password)
+### --- check the particular table
+q <- 'SET CHARACTER SET utf8;'
+res <- dbSendQuery(con, q)
+q <- paste("SELECT * FROM ", sTable, " ORDER BY ", cTopic, " DESC 
LIMIT 50;", sep = "")
+res <- dbSendQuery(con, q)
+iT <- fetch(res, -1)
+dbClearResult(res)
+### --- Disconnect
+dbDisconnect(con)
+### --- Output:
+return(iT) 
+  } else {return(NULL)}
+  })
+  
+  ### --- OUTPUT output$topItemsTopic
+  output$topItemsTopic <- renderPlot({
+if (!is.null(itemTopic())) {
+  cTopic <- tolower(gsub(" ", "", input$selectCategoryTopic))
+  plotFrame <- itemTopic()
+  plotFrame <- select(plotFrame, 
+  eu_label, eu_entity_id, cTopic)
+  colnames(plotFrame) <- c('Label', 'Id', 'Probability')
+  

[MediaWiki-commits] [Gerrit] operations/puppet[production]: toolforge: Update shinken checks

2017-10-23 Thread Madhuvishy (Code Review)
Madhuvishy has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/386112 )

Change subject: toolforge: Update shinken checks
..


toolforge: Update shinken checks

* Rebrand from ToolLabs to Toolforge
* Use https for main page check

Change-Id: Ib98b9b741a57598f7165dcbd50ec432c2dc73886
---
M modules/toollabs/files/shinken.cfg
1 file changed, 5 insertions(+), 5 deletions(-)

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



diff --git a/modules/toollabs/files/shinken.cfg 
b/modules/toollabs/files/shinken.cfg
index b700160..67e0a83 100644
--- a/modules/toollabs/files/shinken.cfg
+++ b/modules/toollabs/files/shinken.cfg
@@ -1,15 +1,15 @@
 define host{
-host_name   toollabs
-alias   ToolLabs
+host_name   toolforge
+alias   Toolforge
 address tools.wmflabs.org
 contact_groups  tools
 use generic-host
 }
 
 define service {
-service_description ToolLabs Home Page
-host_name   toollabs
-check_command   
check_http_url_at_address_for_string!tools.wmflabs.org!/!Magnus
+service_description Toolforge Home Page
+host_name   toolforge
+check_command   
check_https_url_at_address_for_string!tools.wmflabs.org!/!Magnus
 use generic-service
 }
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib98b9b741a57598f7165dcbd50ec432c2dc73886
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: BryanDavis 
Gerrit-Reviewer: Andrew Bogott 
Gerrit-Reviewer: Coren 
Gerrit-Reviewer: Madhuvishy 
Gerrit-Reviewer: Merlijn van Deen 
Gerrit-Reviewer: Rush 
Gerrit-Reviewer: Yuvipanda 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...mobileapps[master]: Remove unnecessary API call in unit test

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

Change subject: Remove unnecessary API call in unit test
..


Remove unnecessary API call in unit test

We do not need to hit the API in this test. It's unnecessary and makes
the test harder to comprehend.

Instead of testing this way, simulate a promise that resolves without
pages.

(npm run test:unit should work without an internet connection)

Change-Id: Iee834114890a64c96ccf255601503a25efd884bc
---
M test/lib/api-util/api-util-test.js
1 file changed, 3 insertions(+), 19 deletions(-)

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



diff --git a/test/lib/api-util/api-util-test.js 
b/test/lib/api-util/api-util-test.js
index 33ef32b..4080c58 100644
--- a/test/lib/api-util/api-util-test.js
+++ b/test/lib/api-util/api-util-test.js
@@ -1,6 +1,5 @@
 'use strict';
 
-const preq   = require('preq');
 const assert = require('../../utils/assert');
 const mwapi = require('../../../lib/mwapi');
 
@@ -11,26 +10,11 @@
 
 logger.log = function(a, b) {};
 
-describe('lib:apiUtil', function() {
-
-this.timeout(2); // eslint-disable-line no-invalid-this
+describe('lib:apiUtil', () => {
 
 it('checkForQueryPagesInResponse should return 504 when query.pages are 
absent', () => {
-return preq.post({
-uri: 'https://commons.wikimedia.org/w/api.php',
-body: {
-action: 'query',
-format: 'json',
-formatversion: 2,
-generator: 'images',
-prop: 'imageinfo|revisions',
-iiextmetadatafilter: 'ImageDescription',
-iiextmetadatamultilang: true,
-iiprop: 'url|extmetadata|dimensions',
-iiurlwidth: 1024,
-rawcontinue: '',
-titles: `Template:Potd/1980-07-06`
-}
+return new Promise((resolve) => {
+return resolve({});
 }).then((response) => {
 assert.throws(() => {
 mwapi.checkForQueryPagesInResponse({ logger }, response);

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...cookiecutter-library[master]: Add CODE_OF_CONDUCT.md

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

Change subject: Add CODE_OF_CONDUCT.md
..


Add CODE_OF_CONDUCT.md

To both this repository and the bootstrap package.

Change-Id: I7b3cfbd9672b3f6d940e7480da53126604902df4
---
A CODE_OF_CONDUCT.md
A {{ cookiecutter.library_name }}/CODE_OF_CONDUCT.md
2 files changed, 4 insertions(+), 0 deletions(-)

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



diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md
new file mode 100644
index 000..7815dda
--- /dev/null
+++ b/CODE_OF_CONDUCT.md
@@ -0,0 +1,2 @@
+The development of this software is covered by a [Code of 
Conduct](https://www.mediawiki.org/wiki/Code_of_Conduct).
+
diff --git "a/\173\173 cookiecutter.library_name \175\175/CODE_OF_CONDUCT.md" 
"b/\173\173 cookiecutter.library_name \175\175/CODE_OF_CONDUCT.md"
new file mode 100644
index 000..7815dda
--- /dev/null
+++ "b/\173\173 cookiecutter.library_name \175\175/CODE_OF_CONDUCT.md"
@@ -0,0 +1,2 @@
+The development of this software is covered by a [Code of 
Conduct](https://www.mediawiki.org/wiki/Code_of_Conduct).
+

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7b3cfbd9672b3f6d940e7480da53126604902df4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/tools/cookiecutter-library
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
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] mediawiki...cookiecutter-library[master]: Add CODE_OF_CONDUCT.md

2017-10-23 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386120 )

Change subject: Add CODE_OF_CONDUCT.md
..

Add CODE_OF_CONDUCT.md

To both this repository and the bootstrap package.

Change-Id: I7b3cfbd9672b3f6d940e7480da53126604902df4
---
A CODE_OF_CONDUCT.md
A {{ cookiecutter.library_name }}/CODE_OF_CONDUCT.md
2 files changed, 4 insertions(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/tools/cookiecutter-library 
refs/changes/20/386120/1

diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md
new file mode 100644
index 000..7815dda
--- /dev/null
+++ b/CODE_OF_CONDUCT.md
@@ -0,0 +1,2 @@
+The development of this software is covered by a [Code of 
Conduct](https://www.mediawiki.org/wiki/Code_of_Conduct).
+
diff --git "a/\173\173 cookiecutter.library_name \175\175/CODE_OF_CONDUCT.md" 
"b/\173\173 cookiecutter.library_name \175\175/CODE_OF_CONDUCT.md"
new file mode 100644
index 000..7815dda
--- /dev/null
+++ "b/\173\173 cookiecutter.library_name \175\175/CODE_OF_CONDUCT.md"
@@ -0,0 +1,2 @@
+The development of this software is covered by a [Code of 
Conduct](https://www.mediawiki.org/wiki/Code_of_Conduct).
+

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7b3cfbd9672b3f6d940e7480da53126604902df4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/tools/cookiecutter-library
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] mediawiki/extensions[master]: Rm numorous extensions

2017-10-23 Thread Chad (Code Review)
Chad has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/386054 )

Change subject: Rm numorous extensions
..


Rm numorous extensions

Bug:T178754
Bug:T178756
Bug:T178758
Bug:T178759
Bug:T178760
Bug:T178761
Bug:T178762
Bug:T178763
Bug:T178764
Bug:T178765
Bug:T178766
Bug:T178767
Bug:T178768
Bug:T178769
Bug:T178770
Bug:T178771
Change-Id: I143d20654916aa112519e634387f9afc85458528
---
M .gitmodules
D CommentPages
D FeedsFromPrivateWikis
D Foxway
D FundraisingChart
D FundraisingEmailUnsubscribe
D ImageLink
D Moodle
D PostEdit
D ReaderFeedback
D RevealEmail
D SecurePasswords
D SharedCssJs
D SimpleAntiSpam
D ThemeDesigner
D TwoFactorAuthentication
D WikiShare
17 files changed, 0 insertions(+), 80 deletions(-)

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



diff --git a/.gitmodules b/.gitmodules
index 8e0399f..41678bf 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -414,10 +414,6 @@
path = Collection
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Collection
branch = .
-[submodule "CommentPages"]
-   path = CommentPages
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/CommentPages
-   branch = .
 [submodule "CommentStreams"]
path = CommentStreams
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/CommentStreams
@@ -806,10 +802,6 @@
path = FeaturedFeeds
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/FeaturedFeeds
branch = .
-[submodule "FeedsFromPrivateWikis"]
-   path = FeedsFromPrivateWikis
-   url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FeedsFromPrivateWikis
-   branch = .
 [submodule "FileAnnotations"]
path = FileAnnotations
url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FileAnnotations
@@ -866,21 +858,9 @@
path = FormelApplet
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/FormelApplet
branch = .
-[submodule "Foxway"]
-   path = Foxway
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Foxway
-   branch = .
 [submodule "FundraiserLandingPage"]
path = FundraiserLandingPage
url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FundraiserLandingPage
-   branch = .
-[submodule "FundraisingChart"]
-   path = FundraisingChart
-   url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FundraisingChart
-   branch = .
-[submodule "FundraisingEmailUnsubscribe"]
-   path = FundraisingEmailUnsubscribe
-   url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FundraisingEmailUnsubscribe
branch = .
 [submodule "FundraisingTranslateWorkflow"]
path = FundraisingTranslateWorkflow
@@ -1121,10 +1101,6 @@
 [submodule "IframePage"]
path = IframePage
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/IframePage
-   branch = .
-[submodule "ImageLink"]
-   path = ImageLink
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/ImageLink
branch = .
 [submodule "ImageMap"]
path = ImageMap
@@ -1477,10 +1453,6 @@
 [submodule "MolHandler"]
path = MolHandler
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/MolHandler
-   branch = .
-[submodule "Moodle"]
-   path = Moodle
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Moodle
branch = .
 [submodule "Mpdf"]
path = Mpdf
@@ -1942,10 +1914,6 @@
path = Popups
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Popups
branch = .
-[submodule "PostEdit"]
-   path = PostEdit
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/PostEdit
-   branch = .
 [submodule "Premoderation"]
path = Premoderation
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Premoderation
@@ -2062,10 +2030,6 @@
path = RandomUsersWithAvatars
url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/RandomUsersWithAvatars
branch = .
-[submodule "ReaderFeedback"]
-   path = ReaderFeedback
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/ReaderFeedback
-   branch = .
 [submodule "ReadingLists"]
path = ReadingLists
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/ReadingLists
@@ -2125,10 +2089,6 @@
 [submodule "RestBaseUpdateJobs"]
path = RestBaseUpdateJobs
url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/RestBaseUpdateJobs
-   branch = .
-[submodule "RevealEmail"]
-   path = RevealEmail
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/RevealEmail
branch = .
 [submodule "RevisionCommentSupplement"]
path = RevisionCommentSupplement
@@ -2197,10 +2157,6 @@
 [submodule "SecureHTML"]
path = SecureHTML
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/SecureHTML
-   branch = .

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: objectcache: Always use interim values on WAN cache tombstones

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

Change subject: objectcache: Always use interim values on WAN cache tombstones
..


objectcache: Always use interim values on WAN cache tombstones

This stores values for very short times while the main
value is a tombstone in case of particularly high traffic.

Also make mutex keys expire immediately on unlock.

Change-Id: I4ec5cf7f8b49239fdd2518e5d955534877a0f7ee
---
M includes/libs/objectcache/WANObjectCache.php
M tests/phpunit/includes/libs/objectcache/WANObjectCacheTest.php
2 files changed, 10 insertions(+), 4 deletions(-)

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



diff --git a/includes/libs/objectcache/WANObjectCache.php 
b/includes/libs/objectcache/WANObjectCache.php
index 15e5759..120ae45 100644
--- a/includes/libs/objectcache/WANObjectCache.php
+++ b/includes/libs/objectcache/WANObjectCache.php
@@ -964,6 +964,10 @@
 
// A deleted key with a negative TTL left must be tombstoned
$isTombstone = ( $curTTL !== null && $value === false );
+   if ( $isTombstone && $lockTSE <= 0 ) {
+   // Use the INTERIM value for tombstoned keys to reduce 
regeneration load
+   $lockTSE = 1;
+   }
// Assume a key is hot if requested soon after invalidation
$isHot = ( $curTTL !== null && $curTTL <= 0 && abs( $curTTL ) 
<= $lockTSE );
// Use the mutex if there is no value and a busy fallback is 
given
@@ -1032,7 +1036,7 @@
 
if ( $lockAcquired ) {
// Avoid using delete() to avoid pointless mcrouter 
broadcasting
-   $this->cache->changeTTL( self::MUTEX_KEY_PREFIX . $key, 
1 );
+   $this->cache->changeTTL( self::MUTEX_KEY_PREFIX . $key, 
(int)$preCallbackTime - 60 );
}
 
return $value;
@@ -1751,7 +1755,7 @@
return array_diff( $keys, $keysFound );
}
 
-   /**
+   /**
 * @param array $keys
 * @param array $checkKeys
 * @return array Map of (cache key => mixed)
diff --git a/tests/phpunit/includes/libs/objectcache/WANObjectCacheTest.php 
b/tests/phpunit/includes/libs/objectcache/WANObjectCacheTest.php
index c5a1759..e23f318 100644
--- a/tests/phpunit/includes/libs/objectcache/WANObjectCacheTest.php
+++ b/tests/phpunit/includes/libs/objectcache/WANObjectCacheTest.php
@@ -159,8 +159,9 @@
$this->assertEquals( 9, $hit, "Values evicted" );
 
$key = reset( $keys );
-   // Get into cache
+   // Get into cache (default process cache group)
$this->cache->getWithSetCallback( $key, 100, $callback, [ 
'pcTTL' => 5 ] );
+   $this->assertEquals( 10, $hit, "Value calculated" );
$this->cache->getWithSetCallback( $key, 100, $callback, [ 
'pcTTL' => 5 ] );
$this->assertEquals( 10, $hit, "Value cached" );
$outerCallback = function () use ( &$callback, $key ) {
@@ -168,7 +169,8 @@
 
return 43 + $v;
};
-   $this->cache->getWithSetCallback( $key, 100, $outerCallback );
+   // Outer key misses and refuses inner key process cache value
+   $this->cache->getWithSetCallback( "$key-miss-outer", 100, 
$outerCallback );
$this->assertEquals( 11, $hit, "Nested callback value process 
cache skipped" );
}
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I4ec5cf7f8b49239fdd2518e5d955534877a0f7ee
Gerrit-PatchSet: 8
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...WikibaseQualityConstraints[master]: Lower hotTTR in matchesRegularExpression() to raise hit rate

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

Change subject: Lower hotTTR in matchesRegularExpression() to raise hit rate
..


Lower hotTTR in matchesRegularExpression() to raise hit rate

Bug: T173696
Change-Id: I844cce846943eee9dbab04cfa5478b357b63779e
---
M includes/ConstraintCheck/Helper/SparqlHelper.php
1 file changed, 2 insertions(+), 3 deletions(-)

Approvals:
  Aaron Schulz: Looks good to me, but someone else must approve
  Krinkle: Looks good to me, approved
  Lucas Werkmeister (WMDE): Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/includes/ConstraintCheck/Helper/SparqlHelper.php 
b/includes/ConstraintCheck/Helper/SparqlHelper.php
index 294a37e..4adbd16 100644
--- a/includes/ConstraintCheck/Helper/SparqlHelper.php
+++ b/includes/ConstraintCheck/Helper/SparqlHelper.php
@@ -373,9 +373,8 @@
[
// Once map is > 1 sec old, consider refreshing
'ageNew' => 1,
-   // Increase likelihood of refresh to certainty 
once 1 minute old;
-   // the most common keys are more likely to 
trigger this
-   'hotTTR' => 60,
+   // Update 5 seconds after "ageNew" given a 1 
query/sec cache check rate
+   'hotTTR' => 5,
// avoid querying cache servers multiple times 
in a request
// (e. g. when checking format of a reference 
URL used multiple times on an entity)
'pcTTL' => WANObjectCache::TTL_PROC_LONG,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I844cce846943eee9dbab04cfa5478b357b63779e
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/WikibaseQualityConstraints
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 
Gerrit-Reviewer: Aaron Schulz 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: Lucas Werkmeister (WMDE) 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] operations/dns[master]: Assigning v4/v6 IPs for eqiad/esams tunnel

2017-10-23 Thread Ayounsi (Code Review)
Ayounsi has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386119 )

Change subject: Assigning v4/v6 IPs for eqiad/esams tunnel
..

Assigning v4/v6 IPs for eqiad/esams tunnel

Change-Id: I31ec9d41493d7f5e63037dfa6803b26084cc5d7e
---
M templates/1.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa
M templates/154.80.208.in-addr.arpa
2 files changed, 10 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/dns 
refs/changes/19/386119/1

diff --git a/templates/1.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa 
b/templates/1.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa
index 079c7bc..2b6f9f1 100644
--- a/templates/1.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa
+++ b/templates/1.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa
@@ -298,6 +298,12 @@
 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 1H IN PTR   xe-4-2-0.cr2-eqiad.wikimedia.org.
 2.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 1H IN PTR   xe-1-1-0.cr1-eqord.wikimedia.org.
 
+; cr2-eqiad:gr-5/2/0.1 <--> cr2-esams:gr-0/0/0.1 (2620:0:861:fe03::/64)
+
+$ORIGIN 3.0.e.f.{{ zonename }}.
+1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 1H IN PTR   gr-5-2-0-1.cr2-eqiad.wikimedia.org.
+2.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0 1H IN PTR   gr-0-0-0-1.cr2-esams.wikimedia.org.
+
 ; cr1-eqiad <--> mr1-eqiad (2620:0:861:fe04::/64)
 
 $ORIGIN 4.0.e.f.{{ zonename }}.
diff --git a/templates/154.80.208.in-addr.arpa 
b/templates/154.80.208.in-addr.arpa
index 9bef1b9..616a629 100644
--- a/templates/154.80.208.in-addr.arpa
+++ b/templates/154.80.208.in-addr.arpa
@@ -156,7 +156,10 @@
 
 219 1H  IN PTR  pfw3-eqiad.wikimedia.org.
 
-; 208.80.154.220/31 unused
+; 208.80.154.220/31 (cr2-eqiad:gr-5/2/0.1 <--> cr2-esams:gr-0/0/0.1)
+
+220 1H IN PTR   gr-5-2-0-1.cr2-eqiad.wikimedia.org.
+221 1H IN PTR   gr-0-0-0-1.cr2-esams.wikimedia.org.
 
 ; 208.80.154.222/31 unused
 

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: objectcache: Add more hotTTR comments to WANObjectCache

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

Change subject: objectcache: Add more hotTTR comments to WANObjectCache
..


objectcache: Add more hotTTR comments to WANObjectCache

Change-Id: I123e5231206350ee51098fcb6528da126d1a86ce
---
M includes/libs/objectcache/WANObjectCache.php
1 file changed, 13 insertions(+), 8 deletions(-)

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



diff --git a/includes/libs/objectcache/WANObjectCache.php 
b/includes/libs/objectcache/WANObjectCache.php
index 15e5759..bacea7b 100644
--- a/includes/libs/objectcache/WANObjectCache.php
+++ b/includes/libs/objectcache/WANObjectCache.php
@@ -686,8 +686,11 @@
 * having to inspect a "current time left" variable (e.g. $curTTL, 
$curTTLs), a cache
 * regeneration will automatically be triggered using the callback.
 *
-* The simplest way to avoid stampedes for hot keys is to use
-* the 'lockTSE' option in $opts. If cache purges are needed, also:
+* The $ttl argument and "hotTTR" option (in $opts) use time-dependant 
randomization
+* to avoid stampedes. Keys that are slow to regenerate and either 
heavily used
+* or subject to explicit (unpredictable) purges, may need additional 
mechanisms.
+* The simplest way to avoid stampedes for such keys is to use 
'lockTSE' (in $opts).
+* If explicit purges are needed, also:
 *   - a) Pass $key into $checkKeys
 *   - b) Use touchCheckKey( $key ) instead of delete( $key )
 *
@@ -839,11 +842,13 @@
 *  This is useful if the source of a key is suspected of having 
possibly changed
 *  recently, and the caller wants any such changes to be reflected.
 *  Default: WANObjectCache::MIN_TIMESTAMP_NONE.
-*   - hotTTR: Expected time-till-refresh for keys that average ~1 
hit/second.
-*  This should be greater than "ageNew". Keys with higher hit 
rates will regenerate
-*  more often. This is useful when a popular key is changed but 
the cache purge was
-*  delayed or lost. Seldom used keys are rarely affected by this 
setting, unless an
-*  extremely low "hotTTR" value is passed in.
+*   - hotTTR: Expected time-till-refresh (TTR) for keys that average 
~1 hit/second (1 Hz).
+*  Keys with a hit rate higher than 1Hz will refresh sooner than 
this TTR and vise versa.
+*  Such refreshes won't happen until keys are "ageNew" seconds 
old. The TTR is useful at
+*  reducing the impact of missed cache purges, since the effect of 
a heavily referenced
+*  key being stale is worse than that of a rarely referenced key. 
Unlike simply lowering
+*  $ttl, seldomly used keys are largely unaffected by this option, 
which makes it possible
+*  to have a high hit rate for the "long-tail" of less-used keys.
 *  Default: WANObjectCache::HOT_TTR.
 *   - lowTTL: Consider pre-emptive updates when the current TTL 
(seconds) of the key is less
 *  than this. It becomes more likely over time, becoming certain 
once the key is expired.
@@ -1534,7 +1539,7 @@
}
 
/**
-* Check if a key should be regenerated (using random probability)
+* Check if a key is nearing expiration and thus due for randomized 
regeneration
 *
 * This returns false if $curTTL >= $lowTTL. Otherwise, the chance
 * of returning true increases steadily from 0% to 100% as the $curTTL

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I123e5231206350ee51098fcb6528da126d1a86ce
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...WikiLove[master]: Simplify by using api.parse from module 'mediawiki.api.parse'

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

Change subject: Simplify by using api.parse from module 'mediawiki.api.parse'
..


Simplify by using api.parse from module 'mediawiki.api.parse'

Change-Id: I000c7e85e13de30d9203bae86b13696dc4153315
---
M extension.json
M resources/ext.wikiLove.core.js
2 files changed, 7 insertions(+), 9 deletions(-)

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



diff --git a/extension.json b/extension.json
index 9a4ba0e..274fe4c 100644
--- a/extension.json
+++ b/extension.json
@@ -216,6 +216,7 @@
],
"dependencies": [
"mediawiki.api",
+   "mediawiki.api.parse",
"ext.wikiLove.defaultOptions",
"jquery.ui.dialog",
"mediawiki.ui.button",
diff --git a/resources/ext.wikiLove.core.js b/resources/ext.wikiLove.core.js
index 338fa9a..645db1a 100644
--- a/resources/ext.wikiLove.core.js
+++ b/resources/ext.wikiLove.core.js
@@ -560,16 +560,13 @@
 */
doPreview: function ( wikitext ) {
$( '#mw-wikilove-preview-spinner' ).fadeIn( 200 );
-   api.post( {
-   'action': 'parse',
-   'contentmodel': 'wikitext',
-   'text': wikitext,
-   'prop': 'text',
-   'disableeditsection': true,
-   'pst': true
+   api.parse( wikitext, {
+   prop: 'text',
+   disableeditsection: true,
+   pst: true
} )
-   .done( function ( data ) {
-   $.wikiLove.showPreview( data.parse.text['*'] );
+   .done( function ( html ) {
+   $.wikiLove.showPreview( html );
$( '#mw-wikilove-preview-spinner' ).fadeOut( 
200 );
} )
.fail( function () {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I000c7e85e13de30d9203bae86b13696dc4153315
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: master
Gerrit-Owner: Fomafix 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: Thiemo Mättig (WMDE) 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Update phpunit requirement

2017-10-23 Thread MarkAHershberger (Code Review)
MarkAHershberger has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386118 )

Change subject: Update phpunit requirement
..

Update phpunit requirement

Bug: T178859
Change-Id: I9cae424026fc3ae6f0b9d43ed5c8c22f9dd16f30
---
M composer.json
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/composer.json b/composer.json
index a0fe9a2..a24da69 100644
--- a/composer.json
+++ b/composer.json
@@ -58,7 +58,7 @@
"monolog/monolog": "~1.22.1",
"nikic/php-parser": "2.1.0",
"nmred/kafka-php": "0.1.5",
-   "phpunit/phpunit": "4.8.35",
+   "phpunit/phpunit": "5.7.23",
"psy/psysh": "0.8.11",
"wikimedia/avro": "1.7.7",
"wikimedia/testing-access-wrapper": "~1.0",

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

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

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


[MediaWiki-commits] [Gerrit] integration/config[master]: Rm numerous extensions

2017-10-23 Thread MacFan4000 (Code Review)
MacFan4000 has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386070 )

Change subject: Rm numerous extensions
..

Rm numerous extensions

Bug:T178762
Bug:T178765
Bug:T178768
Bug:T178769
Bug:T178770
Bug:T178758
Bug:T178756
Bug:T178771
Change-Id: I5be23dc636f17b1e72e468f6001179ddf7d79628
---
M zuul/layout.yaml
1 file changed, 8 insertions(+), 14 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/70/386070/3

diff --git a/zuul/layout.yaml b/zuul/layout.yaml
index 7a1fbc5..a044747 100644
--- a/zuul/layout.yaml
+++ b/zuul/layout.yaml
@@ -3008,8 +3008,7 @@
 
   - name: mediawiki/extensions/FundraisingChart
 template:
-  - name: extension-unittests-generic
-  - name: mwgate-npm
+  - name: archived
 
   - name: mediawiki/extensions/ContributionReporting
 template:
@@ -4852,8 +4851,7 @@
 
   - name: mediawiki/extensions/Moodle
 template:
-  - name: extension-unittests-generic
-  - name: mwgate-npm
+  - name: archived
 
   - name: mediawiki/extensions/Mpdf
 template:
@@ -5383,8 +5381,7 @@
 
   - name: mediawiki/extensions/SecurePasswords
 template:
-  - name: extension-unittests-generic
-  - name: mwgate-npm
+  - name: archived
 
   - name: mediawiki/extensions/SecureSessions
 template:
@@ -5432,8 +5429,7 @@
 
   - name: mediawiki/extensions/SharedCssJs
 template:
-  - name: extension-unittests-generic
-  - name: mwgate-npm
+  - name: archived
 
   - name: mediawiki/extensions/SharedHelpPages
 template:
@@ -5744,8 +5740,7 @@
 
   - name: mediawiki/extensions/TwoFactorAuthentication
 template:
-  - name: extension-unittests-generic
-  - name: mwgate-npm
+  - name: archived
 
   - name: mediawiki/extensions/UIFeedback
 template:
@@ -6002,8 +5997,7 @@
 
   - name: mediawiki/extensions/WikiShare
 template:
-  - name: extension-unittests-generic
-  - name: mwgate-npm
+  - name: archived
 
   - name: mediawiki/extensions/Wikisource
 template:
@@ -6540,7 +6534,7 @@
 
   - name: mediawiki/extensions/PostEdit
 template:
-  - name: extension-unittests-generic
+  - name: archived
 
   - name: mediawiki/extensions/ProofreadPage
 template:
@@ -6696,7 +6690,7 @@
 
   - name: mediawiki/extensions/SimpleAntiSpam
 template:
-  - name: extension-unittests-generic
+  - name: archived
 
   - name: mediawiki/extensions/SimpleFarm
 template:

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5be23dc636f17b1e72e468f6001179ddf7d79628
Gerrit-PatchSet: 3
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: MacFan4000 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] oojs/ui[master]: WikimediaUI theme: Visually treat MenuSectionOptionWidget si...

2017-10-23 Thread VolkerE (Code Review)
VolkerE has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386117 )

Change subject: WikimediaUI theme: Visually treat MenuSectionOptionWidget 
sibling menu items better
..

WikimediaUI theme: Visually treat MenuSectionOptionWidget sibling menu items 
better

Improve MenuSectionOptionWidget and its sectioned MenuOptionWidgets
visual treatment by identing them.

Bug: T92452
Change-Id: I7558b0eaaefcea36cbb85ce3626e6fa27e8d73b8
---
M demos/pages/widgets.js
M src/themes/wikimediaui/widgets.less
2 files changed, 15 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/ui refs/changes/17/386117/1

diff --git a/demos/pages/widgets.js b/demos/pages/widgets.js
index 31678e3..713f536 100644
--- a/demos/pages/widgets.js
+++ b/demos/pages/widgets.js
@@ -1259,7 +1259,8 @@
} ),
new 
OO.ui.MenuOptionWidget( {
data: 
'poodle',
-   label: 
'Standard Poodle'
+   label: 
'Standard Poodle',
+   icon: 
'star'
} ),
new 
OO.ui.MenuSectionOptionWidget( {
label: 
'Cats'
@@ -1928,7 +1929,7 @@
}
} ),
{
-   label: 
'CapsuleMultiselectWidget (with sections)',
+   label: 
'CapsuleMultiselectWidget (sectioned by MenuSectionOptionWidget)',
align: 'top'
}
),
diff --git a/src/themes/wikimediaui/widgets.less 
b/src/themes/wikimediaui/widgets.less
index 5023370..d4e3785 100644
--- a/src/themes/wikimediaui/widgets.less
+++ b/src/themes/wikimediaui/widgets.less
@@ -784,6 +784,18 @@
color: @color-base--subtle;
padding: @padding-top-menu @padding-horizontal-base 
@padding-vertical-label;
font-weight: bold;
+
+   & ~ .oo-ui-menuOptionWidget {
+   padding-left: 2 * @padding-horizontal-base;
+
+   &.oo-ui-iconElement {
+   padding-left: @padding-start-menu-icon-label + 
@padding-horizontal-base;
+
+   .oo-ui-iconElement-icon {
+   left: 2 * @padding-horizontal-base;
+   }
+   }
+   }
 }
 
 .theme-oo-ui-menuSelectWidget () {

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...WikiLove[master]: Replace deprecated jQuery.isArray by Array.isArray

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

Change subject: Replace deprecated jQuery.isArray by Array.isArray
..


Replace deprecated jQuery.isArray by Array.isArray

jQuery.isArray is deprecated since jQuery 3.2.0. [1]
Array.isArray is part of ES5 and is supported since the following
browser versions: [2]
* Chrome 5
* Firefox (Gecko) 4.0 (2.0)
* Internet Explorer 9
* Opera 10.5
* Safari 5

This change requires MediaWiki 1.29+ which ensures that JavaScript is
only used when the browser supports ES5.

[1] https://blog.jquery.com/2017/03/16/jquery-3-2-0-is-out/ [2]
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/isArray#Browser_compatibility

Change-Id: I275c470a06109727e4a76b13f0426e5c0b4d8e6f
---
M resources/ext.wikiLove.core.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/resources/ext.wikiLove.core.js b/resources/ext.wikiLove.core.js
index c791a83..338fa9a 100644
--- a/resources/ext.wikiLove.core.js
+++ b/resources/ext.wikiLove.core.js
@@ -387,7 +387,7 @@
$( '#mw-wikilove-image' ).val( currentRememberData.image || 
currentTypeOrSubtype.image || '' );
 
if( typeof currentTypeOrSubtype.gallery === 'object' &&
-   $.isArray( currentTypeOrSubtype.gallery.imageList )
+   Array.isArray( currentTypeOrSubtype.gallery.imageList )
) {
$( '#mw-wikilove-gallery, #mw-wikilove-gallery-label' 
).show();
$.wikiLove.showGallery(); // build gallery from array 
of images

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I275c470a06109727e4a76b13f0426e5c0b4d8e6f
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: master
Gerrit-Owner: Fomafix 
Gerrit-Reviewer: Fomafix 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Hygiene: Update test script comments

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

Change subject: Hygiene: Update test script comments
..


Hygiene: Update test script comments

Change-Id: I9cc9bc44b4a6a041975c5724b2599c9cdbfb47fd
---
M scripts/apps-android-wikipedia-publish
M scripts/apps-android-wikipedia-test
2 files changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/scripts/apps-android-wikipedia-publish 
b/scripts/apps-android-wikipedia-publish
index d364a34..721a72b 100755
--- a/scripts/apps-android-wikipedia-publish
+++ b/scripts/apps-android-wikipedia-publish
@@ -1,7 +1,7 @@
 #!/usr/bin/env bash
 set -euo pipefail
 
-# For use with Jenkins CI, pass the Android SDK location as an argument:
+# Optionally pass an Android SDK location as an argument:
 # $ apps-android-wikipedia-publish /srv/jenkins-workspace/tools/android-sdk
 if [ ! $# -eq 0 ]; then
   echo "org.gradle.jvmargs=-Xmx1536M" >> gradle.properties
diff --git a/scripts/apps-android-wikipedia-test 
b/scripts/apps-android-wikipedia-test
index 4aca812..0feba95 100755
--- a/scripts/apps-android-wikipedia-test
+++ b/scripts/apps-android-wikipedia-test
@@ -1,7 +1,7 @@
 #!/usr/bin/env bash
 set -euo pipefail
 
-# For use with Jenkins CI, pass the Android SDK location as an argument:
+# Optionally pass an Android SDK location as an argument:
 # $ apps-android-wikipedia-test /srv/jenkins-workspace/tools/android-sdk
 if [ ! $# -eq 0 ]; then
   echo "org.gradle.jvmargs=-Xmx1536M" >> gradle.properties

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...WikibaseQualityConstraints[master]: Split some long lines in SparqlHelper

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

Change subject: Split some long lines in SparqlHelper
..


Split some long lines in SparqlHelper

They could also be shortened by extracting the common prefix into a
variable, but then it would no longer be possible to search for the full
key in the code.

Change-Id: I1c1982cdbe83b90fd2b14cf95048f473a0c98dc2
---
M includes/ConstraintCheck/Helper/SparqlHelper.php
1 file changed, 12 insertions(+), 6 deletions(-)

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



diff --git a/includes/ConstraintCheck/Helper/SparqlHelper.php 
b/includes/ConstraintCheck/Helper/SparqlHelper.php
index cd1be46..89680c8 100644
--- a/includes/ConstraintCheck/Helper/SparqlHelper.php
+++ b/includes/ConstraintCheck/Helper/SparqlHelper.php
@@ -349,17 +349,21 @@
function( $cacheMapArray ) use ( $text, $regex, 
$textHash, $cacheMapSize ) {
// Initialize the cache map if not set
if ( $cacheMapArray === false ) {
-   $this->dataFactory->increment( 
'wikibase.quality.constraints.regex.cache.refresh.init' );
+   $key = 
'wikibase.quality.constraints.regex.cache.refresh.init';
+   $this->dataFactory->increment( $key );
return [];
}
 
-   $this->dataFactory->increment( 
'wikibase.quality.constraints.regex.cache.refresh' );
+   $key = 
'wikibase.quality.constraints.regex.cache.refresh';
+   $this->dataFactory->increment( $key );
$cacheMap = MapCacheLRU::newFromArray( 
$cacheMapArray, $cacheMapSize );
if ( $cacheMap->has( $textHash ) ) {
-   $this->dataFactory->increment( 
'wikibase.quality.constraints.regex.cache.refresh.hit' );
+   $key = 
'wikibase.quality.constraints.regex.cache.refresh.hit';
+   $this->dataFactory->increment( $key );
$cacheMap->get( $textHash ); // ping 
cache
} else {
-   $this->dataFactory->increment( 
'wikibase.quality.constraints.regex.cache.refresh.miss' );
+   $key = 
'wikibase.quality.constraints.regex.cache.refresh.miss';
+   $this->dataFactory->increment( $key );
$cacheMap->set(
$textHash,

$this->matchesRegularExpressionWithSparql( $text, $regex ),
@@ -382,10 +386,12 @@
);
 
if ( isset( $cacheMapArray[$textHash] ) ) {
-   $this->dataFactory->increment( 
'wikibase.quality.constraints.regex.cache.hit' );
+   $key = 'wikibase.quality.constraints.regex.cache.hit';
+   $this->dataFactory->increment( $key );
return $cacheMapArray[$textHash];
} else {
-   $this->dataFactory->increment( 
'wikibase.quality.constraints.regex.cache.miss' );
+   $key = 'wikibase.quality.constraints.regex.cache.miss';
+   $this->dataFactory->increment( $key );
return $this->matchesRegularExpressionWithSparql( 
$text, $regex );
}
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1c1982cdbe83b90fd2b14cf95048f473a0c98dc2
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikibaseQualityConstraints
Gerrit-Branch: master
Gerrit-Owner: Lucas Werkmeister (WMDE) 
Gerrit-Reviewer: Aaron Schulz 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Working Class Movement Library (Salford) throttle rule

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

Change subject: Working Class Movement Library (Salford) throttle rule
..


Working Class Movement Library (Salford) throttle rule

This patch adds an exemption to the account creation throttle
for use at a Wikipedia edit-a-thon to be organised on 2017-11-19
at the Working Class Movement Library in Salford, Manchester.

Bug: T178689
Change-Id: I7b9cfca46f77930b8a281469ef46692234e8d307
---
M wmf-config/throttle.php
1 file changed, 6 insertions(+), 9 deletions(-)

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



diff --git a/wmf-config/throttle.php b/wmf-config/throttle.php
index feb58e9..5315b4c 100644
--- a/wmf-config/throttle.php
+++ b/wmf-config/throttle.php
@@ -28,15 +28,12 @@
 # ];
 ## Add throttling definitions below.
 
-$wmgThrottlingExceptions[] = [ // T177835 - XLDB Clermont-Ferrand
-   'from'   => '2017-10-12T00:00+02:00', // Central
-   'to' => '2017-10-12T23:59+02:00',
-   'IP'  => [
-   '217.128.125.42',
-   '82.127.41.166',
-   ],
-   'dbname' => [ 'wikidatawiki', 'frwiki', 'enwiki', 'commonswiki' ],
-   'value'  => 60, // 45 expected participants
+$wmgThrottlingExceptions[] = [ // T178689 - Working Class Movement Library 
(Salford)
+   'from' => '2017-11-19T09:00 -0:00',
+   'to' => '2017-11-19T17:00 -0:00',
+   'IP' => '212.121.214.227',
+   'dbname' => [ 'enwiki', 'commonswiki' ],
+   'value' => 50,
 ];
 
 ## Add throttling definitions above.

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7b9cfca46f77930b8a281469ef46692234e8d307
Gerrit-PatchSet: 4
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Odder 
Gerrit-Reviewer: Chad 
Gerrit-Reviewer: Urbanecm 
Gerrit-Reviewer: Zoranzoki21 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] operations...service-checker[master]: [WIP] Improve the checking procedure and emit better messages

2017-10-23 Thread Mobrovac (Code Review)
Mobrovac has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386116 )

Change subject: [WIP] Improve the checking procedure and emit better messages
..

[WIP] Improve the checking procedure and emit better messages

Bug: T150560
Change-Id: Ide292c7ae8ced694e97fd7cde84ab65c28a69185
---
M servicechecker/swagger.py
1 file changed, 62 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/software/service-checker 
refs/changes/16/386116/1

diff --git a/servicechecker/swagger.py b/servicechecker/swagger.py
index ab7137f..27bcbb1 100755
--- a/servicechecker/swagger.py
+++ b/servicechecker/swagger.py
@@ -116,7 +116,8 @@
 if key == 'get':
 default_example = [{
 'request': {},
-'response': self.default_response
+'response': self.default_response,
+'title': 'Untitled test'
 }]
 else:
 # Only GETs have default examples
@@ -124,6 +125,9 @@
 examples = d.get('x-amples', default_example)
 for x in examples:
 x['http_method'] = key
+### TODO finish this
+#if not 'request' in x or not 'response' in x:
+###
 # Merge query parameters with defaults
 # In Py 3.5 we could do {**default_query, **query}
 query = default_query.copy()
@@ -349,6 +353,29 @@
 elif t == 're':
 return lambda x: re.search(arg, x)
 
+def _set_warning(prefix, data):
+"""
+Sets self.status and self.msg to WARNING with
+an appropriate message, based on the args. If
+the status is set to something other than OK or
+WARNING, it does not update the state, so as
+not to potentially overwrite a CRITICAL message.
+
+Args:
+prefix (str): the body path being chcked
+
+data (mixed): the data to use in the message
+"""
+if not self.status in ['OK', 'WARNING']:
+return False
+if self.status == 'OK':
+self.msg = ''
+self.status = "WARNING"
+self.msg += ("Test {} responds with "
+"unexpected value at path {} => {}\n".format(
+self.title, prefix, data))
+return True
+
 def _check_json_chunk(self, data, model, prefix=''):
 """
 Recursively check a json chunk of the response.
@@ -360,23 +387,52 @@
 
 prefix (str): the depth we're checking at
 """
+if model is None:
+# if the model happens to be None, there is nothing
+# we can say about the validity of the received value
+return True
+elif data is None:
+# assume that means 'empty'
+if type(model).__name__ in ['dict', 'list', 'int', 'float']:
+data = type(model)()
+else:
+data = ''
 if isinstance(model, dict):
+if not isinstance(data, dict):
+self._set_warning(prefix, "Expected dict, "
+  "gotten a {}".format(type(data).__name__))
+return True
+missing_keys = []
 for k, v in model.items():
+if not k in d:
+missing_keys.append(k)
+continue
 p = prefix + '/' + k
 d = data.get(k, None)
 self._check_json_chunk(d, v, prefix=p)
+if len(missing_keys) > 0:
+self._set_warning(prefix,
+  "Missing keys: {}".format(missing_keys))
 elif isinstance(model, list):
+if not isinstance(data, list):
+self._set_warning(prefix, "Expected list, "
+  "gotten a {}".format(type(data).__name__))
+return True
+if len(model) == 0:
+return True
+if len(model) == 1 and len(data) > 1:
+model *= len(data)
+elif len(data) != len(model):
+self._set_warning(prefix, "Expected {} array elements, "
+  "gotten {}".format(len(model), len(data))
+return True
 for i in range(len(model)):
 p = prefix + '[%d]' % i
 self._check_json_chunk(data[i], model[i], prefix=p)
 else:
 check = self._verify(model)
 if not check(str(data)):
-self.status = "WARNING"
-self.msg = ("Test {} responds with "
-"unexpected body: {} => {}".format(
-   

[MediaWiki-commits] [Gerrit] operations...wikistats[master]: Fix checking for private wiki's in import_miraheze.php

2017-10-23 Thread Paladox (Code Review)
Paladox has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386115 )

Change subject: Fix checking for private wiki's in import_miraheze.php
..

Fix checking for private wiki's in import_miraheze.php

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


  git pull ssh://gerrit.wikimedia.org:29418/operations/debs/wikistats 
refs/changes/15/386115/1


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia9cbe0201bd927c8264879a2a86ee50af5b64ff9
Gerrit-PatchSet: 1
Gerrit-Project: operations/debs/wikistats
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] mediawiki...parsoid[master]: Add new categories to tools/compare.linter.results.js

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

Change subject: Add new categories to tools/compare.linter.results.js
..


Add new categories to tools/compare.linter.results.js

Change-Id: I5240d4c603a85dcc6f847712743988b6f3a7acc3
---
M tools/compare.linter.results.js
1 file changed, 2 insertions(+), 0 deletions(-)

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



diff --git a/tools/compare.linter.results.js b/tools/compare.linter.results.js
index 2a93e8a..5b7dfb9 100755
--- a/tools/compare.linter.results.js
+++ b/tools/compare.linter.results.js
@@ -80,6 +80,8 @@
"pwrap-bug-workaround",
"self-closed-tag",
"tidy-whitespace-bug",
+   "html5-misnesting",
+   "tidy-font-bug",
 ];
 
 var argv = opts.argv;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I5240d4c603a85dcc6f847712743988b6f3a7acc3
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/services/parsoid
Gerrit-Branch: master
Gerrit-Owner: Subramanya Sastry 
Gerrit-Reviewer: Arlolra 
Gerrit-Reviewer: C. Scott Ananian 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki/core[REL1_27]: Password reset link is shown when no reset options are avail...

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

Change subject: Password reset link is shown when no reset options are available
..


Password reset link is shown when no reset options are available

This is just to retrospectively apply 313853 to the 1_27 branch

Bug: T144705
Bug: T148662
Change-Id: I7d6b563e32039e7313121de9629f02ad4f02d351
(cherry picked from commit 183f0bd5e382ae67707a4829c482649e1fa83bf9)
---
M includes/specialpage/LoginSignupSpecialPage.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/includes/specialpage/LoginSignupSpecialPage.php 
b/includes/specialpage/LoginSignupSpecialPage.php
index 1e6bdc7..76e1748 100644
--- a/includes/specialpage/LoginSignupSpecialPage.php
+++ b/includes/specialpage/LoginSignupSpecialPage.php
@@ -704,7 +704,7 @@
 
if ( !$this->isSignup() && $this->showExtraInformation() ) {
$passwordReset = new PasswordReset( $this->getConfig(), 
AuthManager::singleton() );
-   if ( $passwordReset->isAllowed( $this->getUser() ) ) {
+   if ( $passwordReset->isAllowed( $this->getUser() 
)->isGood() ) {
$form->addFooterText( Html::rawElement(
'div',
[ 'class' => 'mw-ui-vform-field 
mw-form-related-link-container' ],

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7d6b563e32039e7313121de9629f02ad4f02d351
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/core
Gerrit-Branch: REL1_27
Gerrit-Owner: Florianschmidtwelzow 
Gerrit-Reviewer: Aaron Schulz 
Gerrit-Reviewer: Huji 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Zoranzoki21 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...parsoid[master]: Linter: Add tidy-font-bug category

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

Change subject: Linter: Add tidy-font-bug category
..


Linter: Add tidy-font-bug category

* This identifies breakage identified in T25467.
  Clearly, Tidy does some strange things sometimes.

* Added a bunch of mocha tests to verify this
  expectation.

Bug: T25467
Bug: T176568

Change-Id: I7510ad39172b4025a79bc6f3f26eb265587c8d8c
---
M lib/wt2html/pp/handlers/linter.js
M tests/mocha/linter.js
2 files changed, 114 insertions(+), 1 deletion(-)

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



diff --git a/lib/wt2html/pp/handlers/linter.js 
b/lib/wt2html/pp/handlers/linter.js
index 87d1ba0..22712e7 100644
--- a/lib/wt2html/pp/handlers/linter.js
+++ b/lib/wt2html/pp/handlers/linter.js
@@ -443,8 +443,9 @@
obsoleteTagsRE = new RegExp('^(' + elts.join('|') + ')$');
}
 
+   var templateInfo;
if (!(dp.autoInsertedStart && dp.autoInsertedEnd) && 
obsoleteTagsRE.test(c.nodeName)) {
-   var templateInfo = findEnclosingTemplateName(env, tplInfo);
+   templateInfo = findEnclosingTemplateName(env, tplInfo);
var lintObj = {
dsr: findLintDSR(templateInfo, tplInfo, dp.dsr),
templateInfo: templateInfo,
@@ -452,6 +453,66 @@
};
env.log('lint/obsolete-tag', lintObj);
}
+
+   if (c.nodeName === 'FONT' && c.getAttribute('color')) {
+   /* --
+* Tidy migrates  into the link in these cases
+* [[Foo]]
+* [[Foo]]l (link-trail)
+* [[Foo]]
+* __NOTOC__[[Foo]]
+* [[Category:Foo]][[Foo]]
+* {{1x|[[Foo]]}}
+*
+* Tidy does not migrate  into the link in these cases
+*  [[Foo]]
+* [[Foo]] 
+* [[Foo]]L (not a link-trail)
+* [[Foo]][[Bar]]
+* [[Foo]][[Bar]]
+*
+*  is special.
+* This behavior is not seen with other formatting tags.
+*
+* Remex/parsoid won't do any of this.
+* This difference in behavior only matters when the font tag
+* specifies a link colour because the link no longer renders
+* as blue/red but in the font-specified colour.
+* -- */
+   var tidyFontBug = true;
+   var haveLink = false;
+   for (var n = c.firstChild; n; n = n.nextSibling) {
+   if (!DU.isComment(n) &&
+   n.nodeName !== 'A' &&
+   n.nodeName !== 'FIGURE' &&
+   !(n.nodeName === 'SPAN' && 
/\bmw:Image\b/.test(n.getAttribute('typeof'))) &&
+   !DU.isBehaviorSwitch(env, n) &&
+   !DU.isSolTransparentLink(n) &&
+   !(n.nodeName === 'META' && 
Util.TPL_META_TYPE_REGEXP.test(n.getAttribute('typeof')))
+   ) {
+   tidyFontBug = false;
+   break;
+   }
+
+   if (n.nodeName === 'A' || n.nodeName === 'FIGURE') {
+   if (!haveLink) {
+   haveLink = true;
+   } else {
+   tidyFontBug = false;
+   break;
+   }
+   }
+   }
+
+   if (tidyFontBug) {
+   templateInfo = findEnclosingTemplateName(env, tplInfo);
+   env.log('lint/tidy-font-bug', {
+   dsr: findLintDSR(templateInfo, tplInfo, dp.dsr),
+   templateInfo: templateInfo,
+   params: { name: 'font' },
+   });
+   }
+   }
 }
 
 /*
diff --git a/tests/mocha/linter.js b/tests/mocha/linter.js
index 33d68df..d710ede 100644
--- a/tests/mocha/linter.js
+++ b/tests/mocha/linter.js
@@ -745,4 +745,56 @@
});
});
});
+   describe('TIDY FONT BUG', function() {
+   var wtLines = [
+   "[[Foo]]",
+   "[[Category:Boo]][[Foo]]",
+   "__NOTOC__[[Foo]]",
+   "[[Foo]]",
+   "[[Foo|bar]]",
+   "[[Foo|''bar'']]",
+   "[[Foo|''bar'' 

[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Add attributes parameter to ShowSearchHitTitle

2017-10-23 Thread Smalyshev (Code Review)
Smalyshev has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386114 )

Change subject: Add attributes parameter to ShowSearchHitTitle
..

Add attributes parameter to ShowSearchHitTitle

This would allow extensions to define custom attributes on title link,
such as put information in "title", change attributes depending on
specific search hit, etc.

Now Wikidata does the same by overriding LinkBegin, but this applies
to all links, not specifically to search result link.

Since ShowSearchHitTitle is always used with the link, I think it makes
sense to enable this specific customization.

Change-Id: I19f64e0909d92e32ddf6271f74c014e8b65d5014
---
M docs/hooks.txt
M includes/widget/search/FullSearchResultWidget.php
2 files changed, 4 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/14/386114/1

diff --git a/docs/hooks.txt b/docs/hooks.txt
index b7fe8c1..5740040 100644
--- a/docs/hooks.txt
+++ b/docs/hooks.txt
@@ -2947,6 +2947,7 @@
 $terms: String of the search terms entered
 $specialSearch: The SpecialSearch object
 &$query: Array of query string parameters for the link representing the search 
result.
+&$attributes: Array of title link attributes, can be modified by extension.
 
 'SidebarBeforeOutput': Allows to edit sidebar just before it is output by 
skins.
 Warning: This hook is run on each display. You should consider to use
diff --git a/includes/widget/search/FullSearchResultWidget.php 
b/includes/widget/search/FullSearchResultWidget.php
index 0d0fa12..4c98399 100644
--- a/includes/widget/search/FullSearchResultWidget.php
+++ b/includes/widget/search/FullSearchResultWidget.php
@@ -133,13 +133,14 @@
$title = clone $result->getTitle();
$query = [];
 
+   $attributes = [ 'data-serp-pos' => $position ];
Hooks::run( 'ShowSearchHitTitle',
-   [ &$title, &$snippet, $result, $terms, 
$this->specialPage, &$query ] );
+   [ &$title, &$snippet, $result, $terms, 
$this->specialPage, &$query, &$attributes ] );
 
$link = $this->linkRenderer->makeLink(
$title,
$snippet,
-   [ 'data-serp-pos' => $position ],
+   $attributes,
$query
);
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I19f64e0909d92e32ddf6271f74c014e8b65d5014
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
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] mediawiki...Wikibase[master]: Properly react on unknown languages in LanguageDirectionalit...

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

Change subject: Properly react on unknown languages in 
LanguageDirectionalityLookup
..


Properly react on unknown languages in LanguageDirectionalityLookup

Instead of throwing a MWException (which is not documented anywhere, not
even in Language::factory), return null. This is fine for all callers.
No caller would do anything with an exception, other than turning it
into null anyway.

Bug: T138724
Change-Id: Ia96cdc61947f18409e334b4fa2c1b8589a52a142
---
M repo/includes/MediaWikiLanguageDirectionalityLookup.php
A repo/tests/phpunit/includes/MediaWikiLanguageDirectionalityLookupTest.php
2 files changed, 43 insertions(+), 1 deletion(-)

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



diff --git a/repo/includes/MediaWikiLanguageDirectionalityLookup.php 
b/repo/includes/MediaWikiLanguageDirectionalityLookup.php
index d682f1c..1b402cb 100644
--- a/repo/includes/MediaWikiLanguageDirectionalityLookup.php
+++ b/repo/includes/MediaWikiLanguageDirectionalityLookup.php
@@ -3,6 +3,7 @@
 namespace Wikibase\Repo;
 
 use Language;
+use MWException;
 use Wikibase\View\LanguageDirectionalityLookup;
 
 /**
@@ -22,7 +23,13 @@
 * @return string|null 'ltr', 'rtl' or null if unknown
 */
public function getDirectionality( $languageCode ) {
-   return Language::factory( $languageCode )->getDir();
+   try {
+   $lang = Language::factory( $languageCode );
+   } catch ( MWException $ex ) {
+   return null;
+   }
+
+   return $lang->getDir();
}
 
 }
diff --git 
a/repo/tests/phpunit/includes/MediaWikiLanguageDirectionalityLookupTest.php 
b/repo/tests/phpunit/includes/MediaWikiLanguageDirectionalityLookupTest.php
new file mode 100644
index 000..021303a
--- /dev/null
+++ b/repo/tests/phpunit/includes/MediaWikiLanguageDirectionalityLookupTest.php
@@ -0,0 +1,35 @@
+ [ 'en', 'ltr' ],
+   'Known RTL language' => [ 'fa', 'rtl' ],
+   'Unknown code' => [ 'unknown', 'ltr' ],
+   'Invalid code' => [ '', null ],
+   ];
+   }
+
+   /**
+* @dataProvider provideLanguageCodes
+*/
+   public function testGetDirectionality( $languageCode, $expected ) {
+   $lookup = new MediaWikiLanguageDirectionalityLookup();
+   $this->assertSame( $expected, $lookup->getDirectionality( 
$languageCode ) );
+   }
+
+}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia96cdc61947f18409e334b4fa2c1b8589a52a142
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Thiemo Mättig (WMDE) 
Gerrit-Reviewer: Addshore 
Gerrit-Reviewer: Aude 
Gerrit-Reviewer: Hoo man 
Gerrit-Reviewer: Ladsgroup 
Gerrit-Reviewer: Thiemo Mättig (WMDE) 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki/core[master]: Add more hotTTR comments to WANObjectCache

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

Change subject: Add more hotTTR comments to WANObjectCache
..

Add more hotTTR comments to WANObjectCache

Change-Id: I123e5231206350ee51098fcb6528da126d1a86ce
---
M includes/libs/objectcache/WANObjectCache.php
1 file changed, 13 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/13/386113/1

diff --git a/includes/libs/objectcache/WANObjectCache.php 
b/includes/libs/objectcache/WANObjectCache.php
index 15e5759..6c198f2 100644
--- a/includes/libs/objectcache/WANObjectCache.php
+++ b/includes/libs/objectcache/WANObjectCache.php
@@ -686,8 +686,11 @@
 * having to inspect a "current time left" variable (e.g. $curTTL, 
$curTTLs), a cache
 * regeneration will automatically be triggered using the callback.
 *
-* The simplest way to avoid stampedes for hot keys is to use
-* the 'lockTSE' option in $opts. If cache purges are needed, also:
+* The $ttl argument and "hotTTR" option (in $opts) use time-dependant 
randomization
+* to avoid stampedes. Keys that are slow to regenerate and either 
heavily used
+* or subject to explicit (unpredictable) purges, may need additional 
mechanisms.
+* The simplest way to avoid stampedes for such keys is to use 
'lockTSE' (in $opts).
+* If explicit purges are needed, also:
 *   - a) Pass $key into $checkKeys
 *   - b) Use touchCheckKey( $key ) instead of delete( $key )
 *
@@ -839,11 +842,13 @@
 *  This is useful if the source of a key is suspected of having 
possibly changed
 *  recently, and the caller wants any such changes to be reflected.
 *  Default: WANObjectCache::MIN_TIMESTAMP_NONE.
-*   - hotTTR: Expected time-till-refresh for keys that average ~1 
hit/second.
-*  This should be greater than "ageNew". Keys with higher hit 
rates will regenerate
-*  more often. This is useful when a popular key is changed but 
the cache purge was
-*  delayed or lost. Seldom used keys are rarely affected by this 
setting, unless an
-*  extremely low "hotTTR" value is passed in.
+*   - hotTTR: Expected time-till-refresh (TTR) for keys that average 
~1 hit/second (1 Hz).
+*  Keys with a hit rate higher than 1Hz will refresh sooner than 
this TTR and vise versa.
+*  Such refreshses won't happen until keys are "ageNew" seconds 
old. The TTR is useful at
+*  reducing the impact of missed cache purges, since the effect of 
a heavily referenced
+*  key being stale is worse than that of a rarely referenced key. 
Unlike simply lowering
+*  $ttl, seldomly used keys are largely unaffected by this option, 
which makes it possible
+*  to have a high hit rate for the "long-tail" of less-used keys.
 *  Default: WANObjectCache::HOT_TTR.
 *   - lowTTL: Consider pre-emptive updates when the current TTL 
(seconds) of the key is less
 *  than this. It becomes more likely over time, becoming certain 
once the key is expired.
@@ -1534,7 +1539,7 @@
}
 
/**
-* Check if a key should be regenerated (using random probability)
+* Check if a key is nearing expiration and thus due for randomized 
regeneration
 *
 * This returns false if $curTTL >= $lowTTL. Otherwise, the chance
 * of returning true increases steadily from 0% to 100% as the $curTTL

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

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

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: toolforge: Update shinken checks

2017-10-23 Thread BryanDavis (Code Review)
BryanDavis has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386112 )

Change subject: toolforge: Update shinken checks
..

toolforge: Update shinken checks

* Rebrand from ToolLabs to Toolforge
* Use https for main page check

Change-Id: Ib98b9b741a57598f7165dcbd50ec432c2dc73886
---
M modules/toollabs/files/shinken.cfg
1 file changed, 5 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/12/386112/1

diff --git a/modules/toollabs/files/shinken.cfg 
b/modules/toollabs/files/shinken.cfg
index b700160..67e0a83 100644
--- a/modules/toollabs/files/shinken.cfg
+++ b/modules/toollabs/files/shinken.cfg
@@ -1,15 +1,15 @@
 define host{
-host_name   toollabs
-alias   ToolLabs
+host_name   toolforge
+alias   Toolforge
 address tools.wmflabs.org
 contact_groups  tools
 use generic-host
 }
 
 define service {
-service_description ToolLabs Home Page
-host_name   toollabs
-check_command   
check_http_url_at_address_for_string!tools.wmflabs.org!/!Magnus
+service_description Toolforge Home Page
+host_name   toolforge
+check_command   
check_https_url_at_address_for_string!tools.wmflabs.org!/!Magnus
 use generic-service
 }
 

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...Wikibase[master]: Minor clean up for Lua tests

2017-10-23 Thread Hoo man (Code Review)
Hoo man has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386111 )

Change subject: Minor clean up for Lua tests
..

Minor clean up for Lua tests

Also add a new test case I used when looking after T173194#3702372
(which wasn't needed… but it shouldn't harm).

Change-Id: I742f40ae892563debe7cd2ccbb0ccda55789274c
---
M client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua
1 file changed, 7 insertions(+), 3 deletions(-)


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

diff --git 
a/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua
 
b/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua
index 73de15f..1fbbe3a 100644
--- 
a/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua
+++ 
b/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua
@@ -118,7 +118,7 @@
  args = { 0, 'P12' },
  expect = "bad argument #1 to 'getBestStatements' (string expected, 
got number)"
},
-   { name = 'mw.wikibase.getBestStatements (entityId must be string)', 
func = mw.wikibase.getBestStatements, type='ToString',
+   { name = 'mw.wikibase.getBestStatements (propertyId must be string)', 
func = mw.wikibase.getBestStatements, type='ToString',
  args = { 'Q2', 12 },
  expect = "bad argument #2 to 'getBestStatements' (string expected, 
got number)"
},
@@ -132,7 +132,7 @@
  args = { 0, 'P12' },
  expect = "bad argument #1 to 'getAllStatements' (string expected, got 
number)"
},
-   { name = 'mw.wikibase.getAllStatements (entityId must be string)', func 
= mw.wikibase.getAllStatements, type='ToString',
+   { name = 'mw.wikibase.getAllStatements (propertyId must be string)', 
func = mw.wikibase.getAllStatements, type='ToString',
  args = { 'Q2', 12 },
  expect = "bad argument #2 to 'getAllStatements' (string expected, got 
number)"
},
@@ -263,10 +263,14 @@
  args = { 'Q32488' },
  expect = { nil }
},
-   { name = 'mw.wikibase.sitelink (with global site id)', func = 
mw.wikibase.sitelink, type='ToString',
+   { name = 'mw.wikibase.sitelink (with global site id 1)', func = 
mw.wikibase.sitelink, type='ToString',
  args = { 'Q32487', 'fooSiteId' },
  expect = { 'FooBarFoo' }
},
+   { name = 'mw.wikibase.sitelink (with global site id 2)', func = 
mw.wikibase.sitelink, type='ToString',
+ args = { 'Q32487', 'dewiki' },
+ expect = { 'WikibaseClientDataAccessTest' }
+   },
{ name = 'mw.wikibase.sitelink (with global site id not found)', func = 
mw.wikibase.sitelink, type='ToString',
  args = { 'Q32487', 'does-not-exist' },
  expect = { nil }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I742f40ae892563debe7cd2ccbb0ccda55789274c
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Hoo man 

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


[MediaWiki-commits] [Gerrit] operations...wmf_styleguide-check[master]: Use the hiera() value in the message

2017-10-23 Thread Volans (Code Review)
Volans has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386110 )

Change subject: Use the hiera() value in the message
..

Use the hiera() value in the message

* When reporting invalid hiera calls, add the value of the hiera call to
  the message to make messages unique, so that they can be easily
  distinguished when comparing previous and current linter violations.

Change-Id: Ia59fe90a11ed55576d7564a9c6a9dd417a7e1372
---
M lib/puppet-lint/plugins/check_wmf_styleguide.rb
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/operations/puppet-lint/wmf_styleguide-check 
refs/changes/10/386110/1

diff --git a/lib/puppet-lint/plugins/check_wmf_styleguide.rb 
b/lib/puppet-lint/plugins/check_wmf_styleguide.rb
index 1bd9e58..d28cbfa 100644
--- a/lib/puppet-lint/plugins/check_wmf_styleguide.rb
+++ b/lib/puppet-lint/plugins/check_wmf_styleguide.rb
@@ -218,7 +218,7 @@
 def hiera_errors(tokens, klass)
   tokens.each do |token|
 msg = {
-  message: "wmf-style: Found hiera call in #{klass.type} '#{klass.name}'",
+  message: "wmf-style: Found hiera call in #{klass.type} '#{klass.name}' 
for '#{token.next_token.next_token.value}'",
   line: token.line,
   column: token.column
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia59fe90a11ed55576d7564a9c6a9dd417a7e1372
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet-lint/wmf_styleguide-check
Gerrit-Branch: master
Gerrit-Owner: Volans 

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


[MediaWiki-commits] [Gerrit] mediawiki...deploy[master]: Updates for deb v0.8.0 pkg release

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

Change subject: Updates for deb v0.8.0 pkg release
..


Updates for deb v0.8.0 pkg release

- Updated src to 86fa7220
- Updated maintainer info
- Updated deb changelog

Change-Id: I08a5e5975b6d8dc6afdd6442d05cc164f0d950c6
---
M debian/changelog
M debian/control
M src
3 files changed, 14 insertions(+), 2 deletions(-)

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



diff --git a/debian/changelog b/debian/changelog
index 9dc648c..b688232 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,15 @@
+parsoid (0.8.0all) jessie-mediawiki; urgency=medium
+
+  * Updated bundled parsoid to git commit 6fd67276
+  * See src/HISTORY.md for details of what changed in Parsoid
+  * Notable changes:
+- audio/video support
+- red links and disambiguation links marked up
+- support for improved TemplateData format specifier which lets
+  templates control formatting of transclusions after VE edits
+
+ -- Subramanya Sastry   Mon, 23 Oct 2017 14:50:36 -0500
+
 parsoid (0.7.1all) jessie-mediawiki; urgency=medium
 
   * No code / functionality changes since 0.7.1
diff --git a/debian/control b/debian/control
index 39b604b..2fe8e2d 100644
--- a/debian/control
+++ b/debian/control
@@ -1,7 +1,7 @@
 Source: parsoid
 Section: web
 Priority: optional
-Maintainer: Gabriel Wicke 
+Maintainer: Parsing Team, Wikimedia Foundation 
 Build-Depends: debhelper (>= 8.0.0)
 Standards-Version: 3.9.4
 Homepage: http://www.mediawiki.org/wiki/Parsoid
diff --git a/src b/src
index 1cefef1..86fa722 16
--- a/src
+++ b/src
@@ -1 +1 @@
-Subproject commit 1cefef127c51854952f8035ec4b17238a1eda96e
+Subproject commit 86fa722032ec3c9f17a516b9b452bc790389360a

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I08a5e5975b6d8dc6afdd6442d05cc164f0d950c6
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/services/parsoid/deploy
Gerrit-Branch: master
Gerrit-Owner: Subramanya Sastry 
Gerrit-Reviewer: Arlolra 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...Linter[master]: Add tidy-font-bug linter high-priority category

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

Change subject: Add tidy-font-bug linter high-priority category
..


Add tidy-font-bug linter high-priority category

*  tags with color attribute that wrap links and images
  will have different behavior and hence rendering compared to Tidy.

Change-Id: I7a551ef9b7e8f57d7a43c823832f0e3add6b1367
---
M extension.json
M i18n/en.json
M i18n/qqq.json
M includes/CategoryManager.php
M includes/LintErrorsPager.php
5 files changed, 13 insertions(+), 0 deletions(-)

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



diff --git a/extension.json b/extension.json
index 6ce3aa3..566ef08 100644
--- a/extension.json
+++ b/extension.json
@@ -116,6 +116,11 @@
"enabled": true,
"priority": "high",
"parser-migration": true
+   },
+   "tidy-font-bug": {
+   "enabled": true,
+   "priority": "high",
+   "parser-migration": true
}
},
"LinterSubmitterWhitelist": {
diff --git a/i18n/en.json b/i18n/en.json
index 11b097c..a02e36b 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -21,6 +21,7 @@
"linter-pager-pwrap-bug-workaround-details": "Paragraph wrapping bug 
workaround",
"linter-pager-tidy-whitespace-bug-details": "Tidy whitespace bug",
"linter-pager-html5-misnesting-details": "Misnesting in HTML5 (but not 
in Tidy)",
+   "linter-pager-tidy-font-bug-details": "Font tag changes link color in 
Tidy but won't in HTML5",
"linter-category-fostered": "Fostered content",
"linter-category-fostered-desc": "These pages have fostered content.",
"linter-category-obsolete-tag": "Obsolete HTML tags",
@@ -45,6 +46,8 @@
"linter-category-tidy-whitespace-bug-desc": "These pages trigger a tidy 
whitespace bug that should be worked around.",
"linter-category-html5-misnesting": "Misnested tag with different 
rendering in HTML5 and HTML4",
"linter-category-html5-misnesting-desc": "These misnested tags will 
behave differently in HTML5 compared to HTML4.",
+   "linter-category-tidy-font-bug": "Tidy bug affecting font tags wrapping 
links",
+   "linter-category-tidy-font-bug-desc": "Tidy moves these font tags 
inside links to change link colour",
"linter-numerrors": "($1 {{PLURAL:$1|error|errors}})",
"linker-page-title-edit": "$1 ($2)",
"linker-page-edit": "edit",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 7d9f15c..aac9405 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -25,6 +25,7 @@
"linter-pager-pwrap-bug-workaround-details": "Table column heading",
"linter-pager-tidy-whitespace-bug-details": "Table column heading. 
\"Tidy\" is a name of a software package that transforms HTML files, so it 
doesn't have to be translated. For information about the bug, see the commit 
message https://gerrit.wikimedia.org/r/#/c/371068 .",
"linter-pager-html5-misnesting-details": "Table column heading.",
+   "linter-pager-tidy-font-bug-details": "Table column heading.",
"linter-category-fostered": "Name of lint error category. See 
[[:mw:Help:Extension:Linter/fostered]]",
"linter-category-fostered-desc": "Description of category.",
"linter-category-obsolete-tag": "Name of lint error category. See 
[[:mw:Help:Extension:Linter/obsolete-tag]]",
@@ -49,6 +50,8 @@
"linter-category-tidy-whitespace-bug-desc": "Description of category.",
"linter-category-html5-misnesting": "Name of lint error category. See 
[[:mw:Help:Extension:Linter/html5-misnesting]]",
"linter-category-html5-misnesting-desc": "Description of category",
+   "linter-category-tidy-font-bug": "Name of lint error category. See 
[[:mw:Help:Extension:Linter/tidy-font-bug]]",
+   "linter-category-tidy-font-bug-desc": "Description of category",
"linter-numerrors": "Shown after a category link to indicate how many 
errors are in that category. $1 is the number of errors, and can be used for 
PLURAL.\n{{Identical|Error}}",
"linker-page-title-edit": "Used in a table cell. $1 is a link to the 
page, $2 is pipe separated links to the edit and history pages, the link text 
is {{msg-mw|linker-page-edit}} and {{msg-mw|linker-page-history}}",
"linker-page-edit": "Link text for edit link in 
{{msg-mw|linker-page-title-edit}}\n{{Identical|Edit}}",
diff --git a/includes/CategoryManager.php b/includes/CategoryManager.php
index 614bf17..3e57251 100644
--- a/includes/CategoryManager.php
+++ b/includes/CategoryManager.php
@@ -48,6 +48,7 @@
'tidy-whitespace-bug' => 10,
'multi-colon-escape' => 11,

[MediaWiki-commits] [Gerrit] mediawiki...parsoid[master]: Bump version after release

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

Change subject: Bump version after release
..


Bump version after release

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

Approvals:
  Subramanya Sastry: Looks good to me, approved
  C. Scott Ananian: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/package.json b/package.json
index 6c1ddbc..f405822 100644
--- a/package.json
+++ b/package.json
@@ -1,7 +1,7 @@
 {
   "name": "parsoid",
   "description": "Mediawiki parser for the VisualEditor.",
-  "version": "0.8.0",
+  "version": "0.8.0+git",
   "license": "GPL-2.0+",
   "dependencies": {
 "async": "^0.9.2",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I126679b695346cb79fd53237b504bca7e68a1fac
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/services/parsoid
Gerrit-Branch: master
Gerrit-Owner: Arlolra 
Gerrit-Reviewer: Arlolra 
Gerrit-Reviewer: C. Scott Ananian 
Gerrit-Reviewer: Sbailey 
Gerrit-Reviewer: Subramanya Sastry 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: contint: profile, role, and packages for R language

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

Change subject: contint: profile, role, and packages for R language
..


contint: profile, role, and packages for R language

Bug: T153856
Change-Id: I72825701f624b495376cd9967dfff53b91632b97
---
A modules/profile/manifests/rlang/dev.pp
A modules/role/manifests/ci/slave/rlang.pp
2 files changed, 40 insertions(+), 0 deletions(-)

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



diff --git a/modules/profile/manifests/rlang/dev.pp 
b/modules/profile/manifests/rlang/dev.pp
new file mode 100644
index 000..0f1b4e0
--- /dev/null
+++ b/modules/profile/manifests/rlang/dev.pp
@@ -0,0 +1,22 @@
+# == Class profile::rlang::dev
+#
+# A profile that configures the environment for installing R packages from
+# sources like Git/GitHub and enables checking package sources with unit tests
+# and lint checking.
+#
+class profile::rlang::dev {
+
+# `include ::r_lang` would not install devtools, which would mean that we
+# could not install R packages from Git/GitHub
+class { 'r_lang':
+devtools => true,
+}
+
+# For unit testing and lint checking:
+$test_packages = [
+'testthat',
+'lintr',
+]
+r_lang::cran { $test_packages: }
+
+}
diff --git a/modules/role/manifests/ci/slave/rlang.pp 
b/modules/role/manifests/ci/slave/rlang.pp
new file mode 100644
index 000..52d6c58
--- /dev/null
+++ b/modules/role/manifests/ci/slave/rlang.pp
@@ -0,0 +1,18 @@
+# == Class role::ci::slave::rlang
+#
+# A continuous integration slave that runs R language based tests.
+#
+# filtertags: labs-project-integration
+class role::ci::slave::rlang {
+
+requires_realm('labs')
+requires_os('debian >= jessie')
+
+system::role { 'ci::slave::rlang':
+description => 'CI Jenkins slave for R language testing',
+}
+
+include role::ci::slave::labs::common
+include profile::rlang::dev
+
+}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I72825701f624b495376cd9967dfff53b91632b97
Gerrit-PatchSet: 10
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Hashar 
Gerrit-Reviewer: Addshore 
Gerrit-Reviewer: Bearloga 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Elukey 
Gerrit-Reviewer: Gehel 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Ottomata 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] unicodejs[master]: build: Bump devDependencies to latest and make pass

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386109 )

Change subject: build: Bump devDependencies to latest and make pass
..

build: Bump devDependencies to latest and make pass

 eslint-config-wikimedia   0.3.0  →   0.5.0
 grunt-contrib-clean   1.0.0  →   1.1.0
 grunt-eslint 19.0.0  →  20.1.0
 grunt-karma   1.0.0  →   2.0.0
 karma 1.1.0  →   1.7.1
 karma-chrome-launcher 1.0.1  →   2.2.0
 karma-coverage1.0.0  →   1.1.1
 karma-firefox-launcher1.0.0  →   1.0.1
 karma-qunit   1.1.0  →   1.2.1
 qunitjs  1.23.0  →   2.4.1

Change-Id: I5ce9c93e0241326a3bbb378c79dc32bfdc7da371
---
M package.json
M tests/unicodejs.characterclass.test.js
M tests/unicodejs.graphemebreak.test.js
M tests/unicodejs.test.js
M tests/unicodejs.wordbreak.test.js
5 files changed, 30 insertions(+), 21 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/unicodejs refs/changes/09/386109/1

diff --git a/package.json b/package.json
index 1777041..5cdbdbe 100644
--- a/package.json
+++ b/package.json
@@ -18,17 +18,17 @@
   },
   "dependencies": {},
   "devDependencies": {
-"eslint-config-wikimedia" : "0.3.0",
+"eslint-config-wikimedia": "0.5.0",
 "grunt": "1.0.1",
-"grunt-contrib-clean": "1.0.0",
+"grunt-contrib-clean": "1.1.0",
 "grunt-contrib-concat": "1.0.1",
-"grunt-eslint": "19.0.0",
-"grunt-karma": "1.0.0",
-"karma": "1.1.0",
-"karma-chrome-launcher": "1.0.1",
-"karma-coverage": "1.0.0",
-"karma-firefox-launcher": "1.0.0",
-"karma-qunit": "1.1.0",
-"qunitjs": "1.23.0"
+"grunt-eslint": "20.1.0",
+"grunt-karma": "2.0.0",
+"karma": "1.7.1",
+"karma-chrome-launcher": "2.2.0",
+"karma-coverage": "1.1.1",
+"karma-firefox-launcher": "1.0.1",
+"karma-qunit": "1.2.1",
+"qunitjs": "2.4.1"
   }
 }
diff --git a/tests/unicodejs.characterclass.test.js 
b/tests/unicodejs.characterclass.test.js
index 476977f..6e3739a 100644
--- a/tests/unicodejs.characterclass.test.js
+++ b/tests/unicodejs.characterclass.test.js
@@ -49,7 +49,7 @@
'', 'ퟠ'
];
 
-   QUnit.expect( 2 );
+   assert.expect( 2 );
assert.deepEqual( wordChars.join( '' ).match( wordGlobalRegex ), 
wordChars );
assert.strictEqual( nonWordChars.join( '' ).match( wordGlobalRegex ), 
null );
 } );
diff --git a/tests/unicodejs.graphemebreak.test.js 
b/tests/unicodejs.graphemebreak.test.js
index 0b65b6c..a51d3bb 100644
--- a/tests/unicodejs.graphemebreak.test.js
+++ b/tests/unicodejs.graphemebreak.test.js
@@ -7,7 +7,7 @@
 
 QUnit.module( 'unicodeJS.graphemebreak' );
 
-QUnit.test( 'splitClusters', 1, function ( assert ) {
+QUnit.test( 'splitClusters', function ( assert ) {
var expected = [
'a',
' ',
diff --git a/tests/unicodejs.test.js b/tests/unicodejs.test.js
index 33032b4..20e3494 100644
--- a/tests/unicodejs.test.js
+++ b/tests/unicodejs.test.js
@@ -14,8 +14,14 @@
[ [ 0x0040 ], '\\u0040', 'single BMP character' ],
[ [ 0x ], '\\u', 'highest BMP character' ],
[
-   [ 0x005F, [ 0x203F, 0x2040 ], 0x2054, [ 0xFE33, 0xFE34 
],
-   [ 0xFE4D, 0xFE4F ], 0xFF3F ],
+   [
+   0x005F,
+   [ 0x203F, 0x2040 ],
+   0x2054,
+   [ 0xFE33, 0xFE34 ],
+   [ 0xFE4D, 0xFE4F ],
+   0xFF3F
+   ],

'[\\u005f\\u203f-\\u2040\\u2054\\ufe33-\\ufe34\\ufe4d-\\ufe4f\\uff3f]',
'multiple BMP ranges (= ExtendNumLet from wordbreak 
rules)'
],
@@ -105,7 +111,7 @@
[ [ [ 0x, 0x ] ], 'surrogate overlap 4' ]
];
 
-   QUnit.expect( equalityTests.length + throwTests.length );
+   assert.expect( equalityTests.length + throwTests.length );
for ( i = 0; i < equalityTests.length; i++ ) {
test = equalityTests[ i ];
assert.equal(
diff --git a/tests/unicodejs.wordbreak.test.js 
b/tests/unicodejs.wordbreak.test.js
index 6d5d0d8..e54e09d 100644
--- a/tests/unicodejs.wordbreak.test.js
+++ b/tests/unicodejs.wordbreak.test.js
@@ -26,7 +26,7 @@
}
};
 
-   QUnit.expect( length + 1 );
+   assert.expect( length + 1 );
 
for ( i = 0; i <= length; i++ ) {
result = ( breakOffsets.indexOf( i ) !== -1 );
@@ -60,9 +60,12 @@
// U+10308 OLD ITALIC LETTER THE \ud800\udf08
// U+1030A OLD ITALIC LETTER KA \ud800\udf0a
// U+0302 COMBINING CIRCUMFLEX \u0302
-   '\ud800\udf08' + '\ud800\udf08\u0302' + 

[MediaWiki-commits] [Gerrit] mediawiki...CirrusSearch[master]: Support variants in prefixSearch

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

Change subject: Support variants in prefixSearch
..


Support variants in prefixSearch

Change-Id: Ife0b519ef3a758924851e2351d8cfa5ef872ed5d
---
M includes/CirrusSearch.php
M includes/Searcher.php
2 files changed, 63 insertions(+), 39 deletions(-)

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



diff --git a/includes/CirrusSearch.php b/includes/CirrusSearch.php
index 930e82a..57d16fa 100644
--- a/includes/CirrusSearch.php
+++ b/includes/CirrusSearch.php
@@ -561,34 +561,34 @@
return parent::completionSearchBackend( $search );
}
 
-   if ( !$this->completionSuggesterEnabled( $this->config ) ) {
-   // Completion suggester is not enabled, fallback to
-   // default implementation
-   return $this->prefixSearch( $search );
-   }
-
-   if ( count( $this->namespaces ) != 1 ||
-   reset( $this->namespaces ) != NS_MAIN
-   ) {
-   // for now, suggester only works for main namespace
-   return $this->prefixSearch( $search );
-   }
-
-   if ( isset( 
$this->features[SearchEngine::COMPLETION_PROFILE_TYPE] ) ) {
-   // Fallback to prefixsearch if the classic profile was 
selected.
-   if ( 
$this->features[SearchEngine::COMPLETION_PROFILE_TYPE] == 
self::COMPLETION_PREFIX_FALLBACK_PROFILE ) {
-   return $this->prefixSearch( $search );
-   }
-   }
-
// Not really useful, mostly for testing purpose
-   $variants = $this->request->getArray( 
'cirrusCompletionSuggesterVariant' );
+   $variants = $this->request->getArray( 'cirrusCompletionVariant' 
);
if ( empty( $variants ) ) {
global $wgContLang;
$variants = $wgContLang->autoConvertToAllVariants( 
$search );
} elseif ( count( $variants ) > 3 ) {
// We should not allow too many variants
$variants = array_slice( $variants, 0, 3 );
+   }
+
+   if ( !$this->completionSuggesterEnabled( $this->config ) ) {
+   // Completion suggester is not enabled, fallback to
+   // default implementation
+   return $this->prefixSearch( $search, $variants );
+   }
+
+   if ( count( $this->namespaces ) != 1 ||
+   reset( $this->namespaces ) != NS_MAIN
+   ) {
+   // for now, suggester only works for main namespace
+   return $this->prefixSearch( $search, $variants );
+   }
+
+   if ( isset( 
$this->features[SearchEngine::COMPLETION_PROFILE_TYPE] ) ) {
+   // Fallback to prefixsearch if the classic profile was 
selected.
+   if ( 
$this->features[SearchEngine::COMPLETION_PROFILE_TYPE] == 
self::COMPLETION_PREFIX_FALLBACK_PROFILE ) {
+   return $this->prefixSearch( $search, $variants 
);
+   }
}
 
return $this->getSuggestions( $search, $variants, $this->config 
);
@@ -608,9 +608,10 @@
/**
 * Older prefix search.
 * @param string $search search text
+* @param string[] $variants
 * @return SearchSuggestionSet
 */
-   protected function prefixSearch( $search ) {
+   protected function prefixSearch( $search, $variants ) {
$searcher = new Searcher( $this->connection, $this->offset, 
$this->limit, $this->config, $this->namespaces );
 
if ( $search ) {
@@ -621,7 +622,7 @@
}
 
try {
-   $status = $searcher->prefixSearch( $search );
+   $status = $searcher->prefixSearch( $search, $variants );
} catch ( ApiUsageException $e ) {
if ( defined( 'MW_API' ) ) {
throw $e;
diff --git a/includes/Searcher.php b/includes/Searcher.php
index 7c44a63..a6d883f 100644
--- a/includes/Searcher.php
+++ b/includes/Searcher.php
@@ -251,9 +251,10 @@
/**
 * Perform a prefix search.
 * @param string $term text by which to search
+* $param string[] $variants variants to search for
 * @return Status status containing results defined by resultsType on 
success
 */
-   public function prefixSearch( $term ) {
+   

[MediaWiki-commits] [Gerrit] mediawiki...parsoid[master]: Bump version to 0.8.0 for release

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

Change subject: Bump version to 0.8.0 for release
..


Bump version to 0.8.0 for release

Change-Id: I2279cbd8d56d3cd097a086b4f52741234a014346
---
M HISTORY.md
M lib/ext/Cite/index.js
M lib/ext/Gallery/index.js
M lib/ext/Gallery/modes.js
M lib/ext/JSON/index.js
M lib/ext/LST/index.js
M lib/ext/Nowiki/index.js
M lib/ext/Pre/index.js
M lib/ext/Translate/index.js
M npm-shrinkwrap.json
M package.json
M tests/parserTestsParserHook.js
12 files changed, 14 insertions(+), 12 deletions(-)

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



diff --git a/HISTORY.md b/HISTORY.md
index 941120a..bc36d13 100644
--- a/HISTORY.md
+++ b/HISTORY.md
@@ -1,4 +1,4 @@
-0.8.0 / 2017-10-13
+0.8.0 / 2017-10-24
 ==
   Notable wt -> html changes:
   * T43716: Parse and serialize language converter markup
@@ -20,6 +20,7 @@
 to control formatting of transclusions after VE edits
   * T153107: Fix unhandled detection of modified link content
   * T136653: Handle interwiki shortcuts
+  * T177784: Update reverse interwiki map to prefer language prefixes over 
others
   * Cleanup in separator handling in the wikitext serializer
   * Several bug fixes
 
@@ -37,6 +38,7 @@
   * Upgrade service-runner, mediawiki-title
   * Use uuid instead of node-uuid
   * Upgrade several dependencies to deal with security advisories
+  * Limit core-js shimming to what we need
 
   Infrastructure:
   * Migrate from jshint to eslint
diff --git a/lib/ext/Cite/index.js b/lib/ext/Cite/index.js
index bf704b2..658a243 100644
--- a/lib/ext/Cite/index.js
+++ b/lib/ext/Cite/index.js
@@ -7,7 +7,7 @@
 
 var domino = require('domino');
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 var Util = ParsoidExtApi.Util;
 var DU = ParsoidExtApi.DOMUtils;
 var Promise = ParsoidExtApi.Promise;
diff --git a/lib/ext/Gallery/index.js b/lib/ext/Gallery/index.js
index 63ac4be..6cdef35 100644
--- a/lib/ext/Gallery/index.js
+++ b/lib/ext/Gallery/index.js
@@ -9,7 +9,7 @@
 
 'use strict';
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 var Promise = ParsoidExtApi.Promise;
 var Util = ParsoidExtApi.Util;
 var DU = ParsoidExtApi.DOMUtils;
diff --git a/lib/ext/Gallery/modes.js b/lib/ext/Gallery/modes.js
index 230983d..14eea71 100644
--- a/lib/ext/Gallery/modes.js
+++ b/lib/ext/Gallery/modes.js
@@ -3,7 +3,7 @@
 var coreutil = require('util');
 var domino = require('domino');
 
-var ParsoidExtApi = 
module.parent.parent.require('./extapi.js').versionCheck('^0.7.0');
+var ParsoidExtApi = 
module.parent.parent.require('./extapi.js').versionCheck('^0.8.0');
 var DU = ParsoidExtApi.DOMUtils;
 var JSUtils = ParsoidExtApi.JSUtils;
 
diff --git a/lib/ext/JSON/index.js b/lib/ext/JSON/index.js
index 01e94f2..e07be0b 100644
--- a/lib/ext/JSON/index.js
+++ b/lib/ext/JSON/index.js
@@ -7,7 +7,7 @@
 
 'use strict';
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 var DU = ParsoidExtApi.DOMUtils;
 var Promise = ParsoidExtApi.Promise;
 var addMetaData = ParsoidExtApi.addMetaData;
diff --git a/lib/ext/LST/index.js b/lib/ext/LST/index.js
index 41e550e..394d4f7 100644
--- a/lib/ext/LST/index.js
+++ b/lib/ext/LST/index.js
@@ -1,6 +1,6 @@
 'use strict';
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 
 var DU = ParsoidExtApi.DOMUtils;
 var Promise = ParsoidExtApi.Promise;
diff --git a/lib/ext/Nowiki/index.js b/lib/ext/Nowiki/index.js
index 3af8836..1219853 100644
--- a/lib/ext/Nowiki/index.js
+++ b/lib/ext/Nowiki/index.js
@@ -9,7 +9,7 @@
 // functionality.  See T156099
 var PegTokenizer = require('../../wt2html/tokenizer.js').PegTokenizer;
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 var Promise = ParsoidExtApi.Promise;
 var Util = ParsoidExtApi.Util;
 var DU = ParsoidExtApi.DOMUtils;
diff --git a/lib/ext/Pre/index.js b/lib/ext/Pre/index.js
index 25ad27a..1e34ad8 100644
--- a/lib/ext/Pre/index.js
+++ b/lib/ext/Pre/index.js
@@ -5,7 +5,7 @@
 
 'use strict';
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 
 var Util = ParsoidExtApi.Util;
 var defines = ParsoidExtApi.defines;
diff --git a/lib/ext/Translate/index.js b/lib/ext/Translate/index.js
index e57f38e..48984fd 100644
--- 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: beta: migrate autoupdater to a profile

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

Change subject: beta: migrate autoupdater to a profile
..


beta: migrate autoupdater to a profile

2 resolved violations:

modules/beta/manifests/autoupdater.pp
'beta::autoupdater' includes scap::scripts from another module

modules/role/manifests/beta/deploymentserver.pp
role 'role::beta::deploymentserver' includes beta::autoupdater which is
neither a role nor a profile

Change-Id: Ie798dc5cf8fe872a0b08a92bb9a790d9c0331b45
---
M modules/beta/manifests/autoupdater.pp
A modules/profile/manifests/beta/autoupdater.pp
M modules/role/manifests/beta/deploymentserver.pp
3 files changed, 7 insertions(+), 3 deletions(-)

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



diff --git a/modules/beta/manifests/autoupdater.pp 
b/modules/beta/manifests/autoupdater.pp
index e39c42b..ad3af6b 100644
--- a/modules/beta/manifests/autoupdater.pp
+++ b/modules/beta/manifests/autoupdater.pp
@@ -4,8 +4,6 @@
 # cluster. This is the lame way to automatically pull any code merged in master
 # branches.
 class beta::autoupdater {
-require ::scap::scripts
-
 $stage_dir = '/srv/mediawiki-staging'
 
 # Parsoid JavaScript dependencies are updated on beta via npm
diff --git a/modules/profile/manifests/beta/autoupdater.pp 
b/modules/profile/manifests/beta/autoupdater.pp
new file mode 100644
index 000..0e337fd
--- /dev/null
+++ b/modules/profile/manifests/beta/autoupdater.pp
@@ -0,0 +1,6 @@
+class profile::beta::autoupdater {
+class { '::scap::scripts': }
+class { '::beta::autoupdater':
+require =>  Class['::scap::scripts']
+}
+}
diff --git a/modules/role/manifests/beta/deploymentserver.pp 
b/modules/role/manifests/beta/deploymentserver.pp
index 4cfebdd..1f18040 100644
--- a/modules/role/manifests/beta/deploymentserver.pp
+++ b/modules/role/manifests/beta/deploymentserver.pp
@@ -2,6 +2,6 @@
 #
 # filtertags: labs-project-deployment-prep
 class role::beta::deploymentserver {
-include beta::autoupdater
+include profile::beta::autoupdater
 include role::beta::mediawiki
 }

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

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

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


[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Hygiene: Update test script comments

2017-10-23 Thread Mholloway (Code Review)
Mholloway has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386099 )

Change subject: Hygiene: Update test script comments
..

Hygiene: Update test script comments

Change-Id: I9cc9bc44b4a6a041975c5724b2599c9cdbfb47fd
---
M scripts/apps-android-wikipedia-publish
M scripts/apps-android-wikipedia-test
2 files changed, 2 insertions(+), 2 deletions(-)


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

diff --git a/scripts/apps-android-wikipedia-publish 
b/scripts/apps-android-wikipedia-publish
index d364a34..721a72b 100755
--- a/scripts/apps-android-wikipedia-publish
+++ b/scripts/apps-android-wikipedia-publish
@@ -1,7 +1,7 @@
 #!/usr/bin/env bash
 set -euo pipefail
 
-# For use with Jenkins CI, pass the Android SDK location as an argument:
+# Optionally pass an Android SDK location as an argument:
 # $ apps-android-wikipedia-publish /srv/jenkins-workspace/tools/android-sdk
 if [ ! $# -eq 0 ]; then
   echo "org.gradle.jvmargs=-Xmx1536M" >> gradle.properties
diff --git a/scripts/apps-android-wikipedia-test 
b/scripts/apps-android-wikipedia-test
index 4aca812..0feba95 100755
--- a/scripts/apps-android-wikipedia-test
+++ b/scripts/apps-android-wikipedia-test
@@ -1,7 +1,7 @@
 #!/usr/bin/env bash
 set -euo pipefail
 
-# For use with Jenkins CI, pass the Android SDK location as an argument:
+# Optionally pass an Android SDK location as an argument:
 # $ apps-android-wikipedia-test /srv/jenkins-workspace/tools/android-sdk
 if [ ! $# -eq 0 ]; then
   echo "org.gradle.jvmargs=-Xmx1536M" >> gradle.properties

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

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

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


[MediaWiki-commits] [Gerrit] operations/puppet[production]: webperf: Remove zeroes for non existing navtiming values

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

Change subject: webperf: Remove zeroes for non existing navtiming values
..


webperf: Remove zeroes for non existing navtiming values

This will be done in the frontend instead. The problem right now is
that it adds 0 to metrics that don't exists (browsers not supporting
the navigation timing API).

Bug: T178479
Change-Id: I6621cbe8ad140216e638e40236417d697111539b
---
M modules/webperf/files/navtiming.py
M modules/webperf/files/navtiming_expected.txt
2 files changed, 0 insertions(+), 435 deletions(-)

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



diff --git a/modules/webperf/files/navtiming.py 
b/modules/webperf/files/navtiming.py
index 512b194..099bcac 100755
--- a/modules/webperf/files/navtiming.py
+++ b/modules/webperf/files/navtiming.py
@@ -446,16 +446,10 @@
 # We miss out appCache since we don't have domainLookupStart
 if 'dnsLookup' in event:
 metrics_nav2['dns'] = event['dnsLookup']
-else:
-metrics_nav2['dns'] = 0
 if 'unload' in event:
 metrics_nav2['unload'] = event['unload']
-else:
-metrics_nav2['unload'] = 0
 if 'redirecting' in event:
 metrics_nav2['redirect'] = event['redirecting']
-else:
-metrics_nav2['redirect'] = 0
 
 # If one of the metrics are wrong, don't send them at all
 for metric, value in metrics_nav2.items():
diff --git a/modules/webperf/files/navtiming_expected.txt 
b/modules/webperf/files/navtiming_expected.txt
index d240ce5..f8e9c0d 100644
--- a/modules/webperf/files/navtiming_expected.txt
+++ b/modules/webperf/files/navtiming_expected.txt
@@ -2769,7 +2769,6 @@
 frontend.navtiming2.dns.by_browser.Chrome.45:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.49:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.50:0|ms
-frontend.navtiming2.dns.by_browser.Chrome.59:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
@@ -2791,7 +2790,6 @@
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:3|ms
-frontend.navtiming2.dns.by_browser.Chrome.all:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.all:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.all:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.all:0|ms
@@ -2903,7 +2901,6 @@
 frontend.navtiming2.dns.by_continent.Europe:0|ms
 frontend.navtiming2.dns.by_continent.Europe:0|ms
 frontend.navtiming2.dns.by_continent.Europe:0|ms
-frontend.navtiming2.dns.by_continent.Europe:0|ms
 frontend.navtiming2.dns.by_continent.North_America:0|ms
 frontend.navtiming2.dns.by_continent.North_America:0|ms
 frontend.navtiming2.dns.by_continent.North_America:0|ms
@@ -2971,9 +2968,7 @@
 frontend.navtiming2.dns.desktop.authenticated:0|ms
 frontend.navtiming2.dns.desktop.authenticated:0|ms
 frontend.navtiming2.dns.desktop.authenticated:0|ms
-frontend.navtiming2.dns.desktop.authenticated:0|ms
 frontend.navtiming2.dns.desktop.authenticated:3|ms
-frontend.navtiming2.dns.desktop.overall:0|ms
 frontend.navtiming2.dns.desktop.overall:0|ms
 frontend.navtiming2.dns.desktop.overall:0|ms
 frontend.navtiming2.dns.desktop.overall:0|ms
@@ -3033,7 +3028,6 @@
 frontend.navtiming2.dns.mobile.overall:0|ms
 frontend.navtiming2.dns.mobile.overall:0|ms
 frontend.navtiming2.dns.mobile.overall:0|ms
-frontend.navtiming2.dns.overall:0|ms
 frontend.navtiming2.dns.overall:0|ms
 frontend.navtiming2.dns.overall:0|ms
 frontend.navtiming2.dns.overall:0|ms
@@ -5150,325 +5144,6 @@
 frontend.navtiming2.processing.overall:884|ms
 frontend.navtiming2.processing.overall:962|ms
 frontend.navtiming2.processing.overall:991|ms
-frontend.navtiming2.redirect.by_browser.Chrome.15:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.15:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.45:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.49:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.50:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.59:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms

[MediaWiki-commits] [Gerrit] mediawiki...Linter[master]: Add tidy-font-bug linter high-priority category

2017-10-23 Thread Subramanya Sastry (Code Review)
Subramanya Sastry has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386098 )

Change subject: Add tidy-font-bug linter high-priority category
..

Add tidy-font-bug linter high-priority category

*  tags with color attribute that wrap links and images
  will have different behavior and hence rendering compared to Tidy.

Change-Id: I7a551ef9b7e8f57d7a43c823832f0e3add6b1367
---
M extension.json
M i18n/en.json
M i18n/qqq.json
M includes/CategoryManager.php
M includes/LintErrorsPager.php
5 files changed, 12 insertions(+), 0 deletions(-)


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

diff --git a/extension.json b/extension.json
index 6ce3aa3..566ef08 100644
--- a/extension.json
+++ b/extension.json
@@ -116,6 +116,11 @@
"enabled": true,
"priority": "high",
"parser-migration": true
+   },
+   "tidy-font-bug": {
+   "enabled": true,
+   "priority": "high",
+   "parser-migration": true
}
},
"LinterSubmitterWhitelist": {
diff --git a/i18n/en.json b/i18n/en.json
index 11b097c..451893c 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -45,6 +45,8 @@
"linter-category-tidy-whitespace-bug-desc": "These pages trigger a tidy 
whitespace bug that should be worked around.",
"linter-category-html5-misnesting": "Misnested tag with different 
rendering in HTML5 and HTML4",
"linter-category-html5-misnesting-desc": "These misnested tags will 
behave differently in HTML5 compared to HTML4.",
+   "linter-category-tidy-font-bug": "Tidy bug affecting font tags wrapping 
links",
+   "linter-category-tidy-font-bug-desc": "Tidy moves these font tags 
inside links to change link colour",
"linter-numerrors": "($1 {{PLURAL:$1|error|errors}})",
"linker-page-title-edit": "$1 ($2)",
"linker-page-edit": "edit",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 7d9f15c..aac9405 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -25,6 +25,7 @@
"linter-pager-pwrap-bug-workaround-details": "Table column heading",
"linter-pager-tidy-whitespace-bug-details": "Table column heading. 
\"Tidy\" is a name of a software package that transforms HTML files, so it 
doesn't have to be translated. For information about the bug, see the commit 
message https://gerrit.wikimedia.org/r/#/c/371068 .",
"linter-pager-html5-misnesting-details": "Table column heading.",
+   "linter-pager-tidy-font-bug-details": "Table column heading.",
"linter-category-fostered": "Name of lint error category. See 
[[:mw:Help:Extension:Linter/fostered]]",
"linter-category-fostered-desc": "Description of category.",
"linter-category-obsolete-tag": "Name of lint error category. See 
[[:mw:Help:Extension:Linter/obsolete-tag]]",
@@ -49,6 +50,8 @@
"linter-category-tidy-whitespace-bug-desc": "Description of category.",
"linter-category-html5-misnesting": "Name of lint error category. See 
[[:mw:Help:Extension:Linter/html5-misnesting]]",
"linter-category-html5-misnesting-desc": "Description of category",
+   "linter-category-tidy-font-bug": "Name of lint error category. See 
[[:mw:Help:Extension:Linter/tidy-font-bug]]",
+   "linter-category-tidy-font-bug-desc": "Description of category",
"linter-numerrors": "Shown after a category link to indicate how many 
errors are in that category. $1 is the number of errors, and can be used for 
PLURAL.\n{{Identical|Error}}",
"linker-page-title-edit": "Used in a table cell. $1 is a link to the 
page, $2 is pipe separated links to the edit and history pages, the link text 
is {{msg-mw|linker-page-edit}} and {{msg-mw|linker-page-history}}",
"linker-page-edit": "Link text for edit link in 
{{msg-mw|linker-page-title-edit}}\n{{Identical|Edit}}",
diff --git a/includes/CategoryManager.php b/includes/CategoryManager.php
index 614bf17..3e57251 100644
--- a/includes/CategoryManager.php
+++ b/includes/CategoryManager.php
@@ -48,6 +48,7 @@
'tidy-whitespace-bug' => 10,
'multi-colon-escape' => 11,
'html5-misnesting' => 12,
+   'tidy-font-bug' => 13,
];
 
/**
diff --git a/includes/LintErrorsPager.php b/includes/LintErrorsPager.php
index 43b6473..f7ee521 100644
--- a/includes/LintErrorsPager.php
+++ b/includes/LintErrorsPager.php
@@ -143,6 +143,7 @@
'misnested-tag',
'stripped-tag',
'html5-misnesting',
+   'tidy-font-bug',
];
  

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Prevent accumulation of screenshots in the host's /tmp direc...

2017-10-23 Thread Mholloway (Code Review)
Mholloway has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386097 )

Change subject: Prevent accumulation of screenshots in the host's /tmp directory
..

Prevent accumulation of screenshots in the host's /tmp directory

Recently, for the second time in three months, the Android periodic
test server ran out of disk space due to an accumulation of old
screenshots in the /tmp directory.

This assigns TMPDIR a folder in the project directory so that it will be
cleared on each run.

Change-Id: Ic4b8a63934d8b79e45f1605b2f0881f7d7089f59
---
M scripts/apps-android-wikipedia-periodic-test
1 file changed, 2 insertions(+), 0 deletions(-)


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

diff --git a/scripts/apps-android-wikipedia-periodic-test 
b/scripts/apps-android-wikipedia-periodic-test
index 56aa758..657a3a6 100755
--- a/scripts/apps-android-wikipedia-periodic-test
+++ b/scripts/apps-android-wikipedia-periodic-test
@@ -1,6 +1,8 @@
 #!/usr/bin/env bash
 set -euo pipefail
 
+mkdir tmp && export TMPDIR="$PWD/tmp"
+
 ./gradlew clean checkstyle lintAlphaRelease testAllAlphaRelease
 
 scripts/diff-screenshots
\ No newline at end of file

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...Flow[master]: tests: Replace QUnit.expect with assert.expect

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

Change subject: tests: Replace QUnit.expect with assert.expect
..


tests: Replace QUnit.expect with assert.expect

Change-Id: Iade0f4eee42fb1a7dd806701aa78066466e80f0f
---
M tests/qunit/flow/dm/test_mw.flow.dm.Board.js
M tests/qunit/flow/dm/test_mw.flow.dm.Content.js
M tests/qunit/flow/dm/test_mw.flow.dm.Post.js
M tests/qunit/flow/dm/test_mw.flow.dm.System.js
M tests/qunit/flow/dm/test_mw.flow.dm.Topic.js
5 files changed, 6 insertions(+), 6 deletions(-)

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



diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.Board.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.Board.js
index cb1aa61..8993d39 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.Board.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.Board.js
@@ -173,5 +173,5 @@
}
}
 
-   QUnit.expect( expectCount );
+   assert.expect( expectCount );
 } );
diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.Content.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.Content.js
index 9c0bf34..5fa36b1 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.Content.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.Content.js
@@ -16,7 +16,7 @@
assert.equal( content.get(), 'content in default format (wikitext, for 
instance)' );
assert.equal( content.get( 'unknown format' ), null );
 
-   QUnit.expect( 4 );
+   assert.expect( 4 );
 } );
 
 QUnit.test( 'Behaves when empty', function ( assert ) {
@@ -25,5 +25,5 @@
assert.equal( content.get(), null );
assert.equal( content.get( 'whatever format' ), null );
 
-   QUnit.expect( 2 );
+   assert.expect( 2 );
 } );
diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.Post.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.Post.js
index e46f911..723a80b 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.Post.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.Post.js
@@ -508,5 +508,5 @@
assert.equal( replies[ 0 ].getWorkflowId(), topic.getId(), 'Replies: 
WorkflowId is topic Id' );
assert.equal( subreplies[ 0 ].getWorkflowId(), topic.getId(), 'Sub 
replies: WorkflowId is topic Id' );
 
-   QUnit.expect( 12 );
+   assert.expect( 12 );
 } );
diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.System.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.System.js
index 7387871..85e13c0 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.System.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.System.js
@@ -344,5 +344,5 @@
expectCounter++;
}
 
-   QUnit.expect( expectCounter );
+   assert.expect( expectCounter );
 } );
diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.Topic.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.Topic.js
index 6066a3b..95acc64 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.Topic.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.Topic.js
@@ -252,5 +252,5 @@
}
}
 
-   QUnit.expect( expectCount );
+   assert.expect( expectCount );
 } );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iade0f4eee42fb1a7dd806701aa78066466e80f0f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...Flow[master]: tests: Replace QUnit.expect with assert.expect

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386093 )

Change subject: tests: Replace QUnit.expect with assert.expect
..

tests: Replace QUnit.expect with assert.expect

Change-Id: Iade0f4eee42fb1a7dd806701aa78066466e80f0f
---
M tests/qunit/flow/dm/test_mw.flow.dm.Board.js
M tests/qunit/flow/dm/test_mw.flow.dm.Content.js
M tests/qunit/flow/dm/test_mw.flow.dm.Post.js
M tests/qunit/flow/dm/test_mw.flow.dm.System.js
M tests/qunit/flow/dm/test_mw.flow.dm.Topic.js
5 files changed, 6 insertions(+), 6 deletions(-)


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

diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.Board.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.Board.js
index cb1aa61..8993d39 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.Board.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.Board.js
@@ -173,5 +173,5 @@
}
}
 
-   QUnit.expect( expectCount );
+   assert.expect( expectCount );
 } );
diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.Content.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.Content.js
index 9c0bf34..5fa36b1 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.Content.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.Content.js
@@ -16,7 +16,7 @@
assert.equal( content.get(), 'content in default format (wikitext, for 
instance)' );
assert.equal( content.get( 'unknown format' ), null );
 
-   QUnit.expect( 4 );
+   assert.expect( 4 );
 } );
 
 QUnit.test( 'Behaves when empty', function ( assert ) {
@@ -25,5 +25,5 @@
assert.equal( content.get(), null );
assert.equal( content.get( 'whatever format' ), null );
 
-   QUnit.expect( 2 );
+   assert.expect( 2 );
 } );
diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.Post.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.Post.js
index e46f911..723a80b 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.Post.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.Post.js
@@ -508,5 +508,5 @@
assert.equal( replies[ 0 ].getWorkflowId(), topic.getId(), 'Replies: 
WorkflowId is topic Id' );
assert.equal( subreplies[ 0 ].getWorkflowId(), topic.getId(), 'Sub 
replies: WorkflowId is topic Id' );
 
-   QUnit.expect( 12 );
+   assert.expect( 12 );
 } );
diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.System.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.System.js
index 7387871..85e13c0 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.System.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.System.js
@@ -344,5 +344,5 @@
expectCounter++;
}
 
-   QUnit.expect( expectCounter );
+   assert.expect( expectCounter );
 } );
diff --git a/tests/qunit/flow/dm/test_mw.flow.dm.Topic.js 
b/tests/qunit/flow/dm/test_mw.flow.dm.Topic.js
index 6066a3b..95acc64 100644
--- a/tests/qunit/flow/dm/test_mw.flow.dm.Topic.js
+++ b/tests/qunit/flow/dm/test_mw.flow.dm.Topic.js
@@ -252,5 +252,5 @@
}
}
 
-   QUnit.expect( expectCount );
+   assert.expect( expectCount );
 } );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iade0f4eee42fb1a7dd806701aa78066466e80f0f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
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] mediawiki...Equivset[master]: Increase Test Coverage to 100%

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

Change subject: Increase Test Coverage to 100%
..


Increase Test Coverage to 100%

Update the code to support test cases and increase the code
coverage to 100%.

Bug: T177667
Change-Id: I1d8bbc5dc9469f72237f5bde36d5fbc6306bf985
---
M composer.json
M src/Command/GenerateEquivset.php
M src/Equivset.php
A src/EquivsetInterface.php
A tests/Command/GenerateEquivsetTest.php
M tests/EquivsetTest.php
6 files changed, 600 insertions(+), 139 deletions(-)

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



diff --git a/composer.json b/composer.json
index f3a4d76..9fad549 100644
--- a/composer.json
+++ b/composer.json
@@ -33,7 +33,8 @@
"symfony/var-dumper": "^3.3",
"phpunit/phpunit": "^4.8",
"jakub-onderka/php-parallel-lint": "^0.9.2",
-   "jakub-onderka/php-console-highlighter": "^0.3.2"
+   "jakub-onderka/php-console-highlighter": "^0.3.2",
+   "mikey179/vfsStream": "^1.6"
},
"scripts": {
"lint": [
diff --git a/src/Command/GenerateEquivset.php b/src/Command/GenerateEquivset.php
index 43edefb..7e2868e 100644
--- a/src/Command/GenerateEquivset.php
+++ b/src/Command/GenerateEquivset.php
@@ -29,6 +29,29 @@
 class GenerateEquivset extends Command {
 
/**
+* @var string
+*/
+   protected $dataDir;
+
+   /**
+* @var string
+*/
+   protected $distDir;
+
+   /**
+* Generate Equivset
+*
+* @param string $dataDir Data Directory
+* @param string $distDir Distrobution Directory
+*/
+   public function __construct( $dataDir = '', $distDir = '' ) {
+   parent::__construct();
+
+   $this->dataDir = $dataDir ? $dataDir : __DIR__ . '/../../data';
+   $this->distDir = $distDir ? $distDir : __DIR__ . '/../../dist';
+   }
+
+   /**
 * {@inheritdoc}
 */
protected function configure() {
@@ -44,10 +67,7 @@
 * @return int Return status.
 */
public function execute( InputInterface $input, OutputInterface $output 
) {
-   $dataDir = __DIR__ . '/../../data';
-   $distDir = __DIR__ . '/../../dist';
-
-   $lines = file( $dataDir . '/equivset.in' );
+   $lines = file( $this->dataDir . '/equivset.in' );
if ( !$lines ) {
throw new \Exception( "Unable to open equivset.in" );
}
@@ -80,7 +100,7 @@
$line, $m
)
) {
-   $output->writeln( "Error: invalid entry at line 
$lineNum: $line" );
+   $output->writeln( "Error: invalid entry 
at line $lineNum: $line" );
$exitStatus = 1;
continue;
}
@@ -92,11 +112,11 @@
$output->writeln( "Bytes: " . strlen( 
$m['charleft'] ) );
$output->writeln( bin2hex( $line ) );
$hexForm = bin2hex( $m['charleft'] );
-   $output->writeln( "Invalid UTF-8 
character \"{$m['charleft']}\" ($hexForm) at " .
-   "line $lineNum: $line" );
+   $output->writeln( "Invalid UTF-8 
character \"{$m['charleft']}\" ($hexForm) at " .
+   "line $lineNum: $line" 
);
} else {
-   $output->writeln( "Error: left number 
({$m['hexleft']}) does not match left " .
-   "character ($actual) at line 
$lineNum: $line" );
+   $output->writeln( "Error: left 
number ({$m['hexleft']}) does not match left " .
+   "character ($actual) at line 
$lineNum: $line" );
}
$error = true;
}
@@ -106,11 +126,11 @@
$actual = Utils::utf8ToCodepoint( 
$m['charright'] );
if ( $actual === false ) {
$hexForm = bin2hex( $m['charright'] );
-   $output->writeln( "Invalid UTF-8 
character \"{$m['charleft']}\" ($hexForm) at " .
-   "line $lineNum: $line" );
+   $output->writeln( "Invalid UTF-8 
character \"{$m['charleft']}\" ($hexForm) at " .
+   

[MediaWiki-commits] [Gerrit] mediawiki...ZeroPortal[master]: Document why ApiBase is overridden and add isInternal member

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

Change subject: Document why ApiBase is overridden and add isInternal member
..


Document why ApiBase is overridden and add isInternal member

Bug: T91456
Change-Id: I94cc6e9bc9da9ed0668aa42d4ce3f65a2dd40ba4
---
M includes/ApiZeroPortal.php
1 file changed, 11 insertions(+), 1 deletion(-)

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



diff --git a/includes/ApiZeroPortal.php b/includes/ApiZeroPortal.php
index 83def69..0d0a09f 100644
--- a/includes/ApiZeroPortal.php
+++ b/includes/ApiZeroPortal.php
@@ -14,7 +14,11 @@
 use ZeroBanner\ApiRawJsonPrinter;
 use ZeroBanner\ZeroConfig;
 
-/** @noinspection PhpInconsistentReturnPointsInspection */
+/** @noinspection PhpInconsistentReturnPointsInspection
+ * This class extends ApiBase in order to serve Wikipedia Zero
+ * configuration management portal experiences and ease the
+ * scheduled jobs synchronizing mobile operator IP addresses.
+ */
 class ApiZeroPortal extends ApiBase {
 
/**
@@ -365,4 +369,10 @@
}
}
 
+   /**
+* @inheritDoc
+*/
+   public function isInternal() {
+   return true;
+   }
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I94cc6e9bc9da9ed0668aa42d4ce3f65a2dd40ba4
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ZeroPortal
Gerrit-Branch: master
Gerrit-Owner: Dr0ptp4kt 
Gerrit-Reviewer: Anomie 
Gerrit-Reviewer: BBlack 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Joewalsh 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Yurik 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] search/MjoLniR[master]: Hyperopt doesn't work with networkx >= 2.0

2017-10-23 Thread EBernhardson (Code Review)
EBernhardson has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386088 )

Change subject: Hyperopt doesn't work with networkx >= 2.0
..

Hyperopt doesn't work with networkx >= 2.0

It doesn't say so in its packaging, but with
networkx >= 2.0 it will error out with:

assert order[-1] == expr
TypeError: 'generator' object has no attribute '__getitem__'

Help out hyperopt by limiting the version of
networkx supported by mjolnir.

Change-Id: I155f133a04724c9960e4e6c3387de543360e3dbd
---
M setup.py
1 file changed, 3 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/search/MjoLniR 
refs/changes/88/386088/1

diff --git a/setup.py b/setup.py
index 524d18d..4456776 100644
--- a/setup.py
+++ b/setup.py
@@ -7,10 +7,12 @@
 'clickmodels',
 'requests',
 'kafka',
+'hyperopt',
+# hyperopt requires networkx < 2.0, but doesn't say so
+'networkx<2.0',
 # pyspark requirements
 'py4j',
 'numpy',
-'hyperopt',
 ]
 
 test_requirements = [

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I155f133a04724c9960e4e6c3387de543360e3dbd
Gerrit-PatchSet: 1
Gerrit-Project: search/MjoLniR
Gerrit-Branch: master
Gerrit-Owner: EBernhardson 

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


[MediaWiki-commits] [Gerrit] mediawiki...ZeroBanner[master]: Document why ApiBase is overridden and add isInternal member

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

Change subject: Document why ApiBase is overridden and add isInternal member
..


Document why ApiBase is overridden and add isInternal member

Bug: T91456
Change-Id: I41c20e81238f40448e5ad6328c3a61673a3d5207
---
M includes/ApiZeroBanner.php
1 file changed, 13 insertions(+), 1 deletion(-)

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



diff --git a/includes/ApiZeroBanner.php b/includes/ApiZeroBanner.php
index 5c565e6..6e30bf0 100644
--- a/includes/ApiZeroBanner.php
+++ b/includes/ApiZeroBanner.php
@@ -7,7 +7,9 @@
 use ApiResult;
 
 /**
- * Utility class to avoid any warnings or any other additions by the API 
framework
+ * Utility class to avoid any warnings or any other additions by the
+ * API framework. This class extends ApiBase in order to shrink
+ * responses for clients.
  * Class ApiRawJsonPrinter
  * @package ZeroBanner
  */
@@ -41,6 +43,9 @@
/**
 * Override built-in handling of format parameter.
 * Only JSON is supported.
+* This class extends ApiBase in order to generate Wikipedia Zero
+* specific output, as used for example by native apps and
+* JavaScript-capable clients.
 * @return ApiFormatBase
 */
public function getCustomPrinter() {
@@ -207,4 +212,11 @@
=> 'apihelp-zeroconfig-example-2',
];
}
+
+   /**
+* @inheritDoc
+*/
+   public function isInternal() {
+   return true;
+   }
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I41c20e81238f40448e5ad6328c3a61673a3d5207
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ZeroBanner
Gerrit-Branch: master
Gerrit-Owner: Dr0ptp4kt 
Gerrit-Reviewer: Anomie 
Gerrit-Reviewer: BBlack 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Joewalsh 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Yurik 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki/vagrant[master]: Fix port handling in restbase/changeprop

2017-10-23 Thread Code Review
Gergő Tisza has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386089 )

Change subject: Fix port handling in restbase/changeprop
..

Fix port handling in restbase/changeprop

Internal requests must use forwarded_port which is the port
Apache will be listening on. External requests must use port_fragment
since that takes port proxying on Cloud VPS into account.

Change-Id: Ie0aeab8511b5df382f6a0fa72b40e23fcc8dc02a
---
M puppet/hieradata/common.yaml
M puppet/modules/changeprop/templates/config.yaml.erb
M puppet/modules/restbase/templates/config.yaml.erb
3 files changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/vagrant 
refs/changes/89/386089/1

diff --git a/puppet/hieradata/common.yaml b/puppet/hieradata/common.yaml
index fdf9553..fbb5f11 100644
--- a/puppet/hieradata/common.yaml
+++ b/puppet/hieradata/common.yaml
@@ -275,7 +275,7 @@
 
 parsoid::port: 8000
 parsoid::domain: "%{hiera('role::mediawiki::hostname')}"
-parsoid::uri: "http://localhost%{::port_fragment}/w/api.php;
+parsoid::uri: "http://localhost:<%= scope['::forwarded_port'] %>/w/api.php"
 parsoid::use_php_preprocessor: true
 parsoid::use_selser: true
 parsoid::allow_cors: '*'
diff --git a/puppet/modules/changeprop/templates/config.yaml.erb 
b/puppet/modules/changeprop/templates/config.yaml.erb
index 5664741..56a579c 100644
--- a/puppet/modules/changeprop/templates/config.yaml.erb
+++ b/puppet/modules/changeprop/templates/config.yaml.erb
@@ -15,7 +15,7 @@
   options:
 templates:
   mw_api:
-uri: 'http://localhost<%= scope['::port_fragment'] 
%>/w/api.php'
+uri: 'http://localhost:<%= scope['::forwarded_port'] 
%>/w/api.php'
 headers:
   host: '{{message.meta.domain}}'
 body:
diff --git a/puppet/modules/restbase/templates/config.yaml.erb 
b/puppet/modules/restbase/templates/config.yaml.erb
index 41eba30..c723a97 100644
--- a/puppet/modules/restbase/templates/config.yaml.erb
+++ b/puppet/modules/restbase/templates/config.yaml.erb
@@ -15,7 +15,7 @@
 parsoid:
   host: http://localhost:<%= scope['::parsoid::port'] %>
 action:
-  apiUriTemplate: "{{'http://localhost<%= scope['::port_fragment'] 
%>/w/api.php'}}"
+  apiUriTemplate: "{{'http://localhost:<%= scope['::forwarded_port'] 
%>/w/api.php'}}"
   baseUriTemplate: "{{'http://{domain}:7231/{domain}/v1'}}"
 graphoid:
   host: http://localhost:<%= @graphoid_port %>

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie0aeab8511b5df382f6a0fa72b40e23fcc8dc02a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/vagrant
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] mediawiki...CentralAuth[master]: Add "id" param to ApiQueryGlobalUserInfo

2017-10-23 Thread Ladsgroup (Code Review)
Ladsgroup has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386078 )

Change subject: Add "id" param to ApiQueryGlobalUserInfo
..

Add "id" param to ApiQueryGlobalUserInfo

It's useful and we can't get it any other way

Change-Id: I927fb7c480bc90230d4fabd2b45816df40aee1b2
---
M i18n/en.json
M i18n/qqq.json
M includes/api/ApiQueryGlobalUserInfo.php
3 files changed, 16 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CentralAuth 
refs/changes/78/386078/1

diff --git a/i18n/en.json b/i18n/en.json
index a4717e6..7e1dd77 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -537,7 +537,8 @@
"apihelp-query+globalgroups-example-2": "Show global groups with the 
rights they grant",
"apihelp-query+globaluserinfo-description": "Show information about a 
global user.",
"apihelp-query+globaluserinfo-summary": "Show information about a 
global user.",
-   "apihelp-query+globaluserinfo-param-user": "User to get information 
about. Defaults to the current user.",
+   "apihelp-query+globaluserinfo-param-user": "User to get information 
about. If user and id both are null, it defaults to the current user.",
+   "apihelp-query+globaluserinfo-param-id": "Global user id to get 
information about. If user and id both are null, it defaults to the current 
user.",
"apihelp-query+globaluserinfo-param-prop": "Which properties to 
get:\n;groups:Get a list of global groups this user belongs to.\n;rights:Get a 
list of global rights this user has.\n;merged:Get a list of merged 
accounts.\n;unattached:Get a list of unattached accounts.\n;editcount:Get the 
user's global edit count.",
"apihelp-query+globaluserinfo-example-1": "Get information about the 
current global user",
"apihelp-query+globaluserinfo-example-2": "Get information about global 
user [[User:Example|Example]]",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index f0ba049..fe01ce0 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -554,6 +554,7 @@
"apihelp-query+globaluserinfo-description": 
"{{doc-apihelp-description|query+globaluserinfo}}",
"apihelp-query+globaluserinfo-summary": 
"{{doc-apihelp-summary|query+globaluserinfo}}",
"apihelp-query+globaluserinfo-param-user": 
"{{doc-apihelp-param|query+globaluserinfo|user}}",
+   "apihelp-query+globaluserinfo-param-id": 
"{{doc-apihelp-param|query+globaluserinfo|id}}",
"apihelp-query+globaluserinfo-param-prop": 
"{{doc-apihelp-param|query+globaluserinfo|prop}}",
"apihelp-query+globaluserinfo-example-1": 
"{{doc-apihelp-example|query+globaluserinfo}}",
"apihelp-query+globaluserinfo-example-2": 
"{{doc-apihelp-example|query+globaluserinfo}}",
diff --git a/includes/api/ApiQueryGlobalUserInfo.php 
b/includes/api/ApiQueryGlobalUserInfo.php
index cafe92f..c317491 100644
--- a/includes/api/ApiQueryGlobalUserInfo.php
+++ b/includes/api/ApiQueryGlobalUserInfo.php
@@ -36,16 +36,19 @@
public function execute() {
$params = $this->extractRequestParams();
$prop = array_flip( (array)$params['prop'] );
-   if ( is_null( $params['user'] ) ) {
+   if ( is_null( $params['user'] ) && is_null( $params['id'] ) ) {
$params['user'] = $this->getUser()->getName();
}
 
-   $username = User::getCanonicalName( $params['user'] );
-   if ( $username === false ) {
-   $this->dieWithError( [ 'apierror-invaliduser', 
wfEscapeWikiText( $params['user'] ) ] );
+   if ( is_null( $params['user'] ) ) {
+   $user = CentralAuthUser::newFromId( $params['id'] );
+   } else {
+   $username = User::getCanonicalName( $params['user'] );
+   if ( $username === false ) {
+   $this->dieWithError( [ 'apierror-invaliduser', 
wfEscapeWikiText( $params['user'] ) ] );
+   }
+   $user = CentralAuthUser::getInstanceByName( $username );
}
-
-   $user = CentralAuthUser::getInstanceByName( $username );
 
// Add basic info
$result = $this->getResult();
@@ -144,7 +147,7 @@
}
 
public function getCacheMode( $params ) {
-   if ( !is_null( $params['user'] ) ) {
+   if ( !is_null( $params['user'] ) || !is_null( $params['id'] ) ) 
{
// URL determines user, public caching is fine
return 'public';
} else {
@@ -158,6 +161,9 @@
'user' => [
ApiBase::PARAM_TYPE => 'user',
],
+   'id' => [
+   self::PARAM_TYPE => 'integer',
+   ],
'prop' 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: beta: set cache::fe_transient_gb: 0

2017-10-23 Thread Hashar (Code Review)
Hashar has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386077 )

Change subject: beta: set cache::fe_transient_gb: 0
..

beta: set cache::fe_transient_gb: 0

Change-Id: I8e33fe82ef4eb09bd1ce1630b4028cb8d34e23ee
---
M hieradata/labs/deployment-prep/common.yaml
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/77/386077/1

diff --git a/hieradata/labs/deployment-prep/common.yaml 
b/hieradata/labs/deployment-prep/common.yaml
index b4f7436..a2fadc8 100644
--- a/hieradata/labs/deployment-prep/common.yaml
+++ b/hieradata/labs/deployment-prep/common.yaml
@@ -356,3 +356,5 @@
 
 thumbor::logstash_host: 'deployment-logstash2.deployment-prep.eqiad.wmflabs'
 thumbor::logstash_port: 11514
+
+cache::fe_transient_gb: 0

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...EventLogging[master]: tests: Make compatible with QUnit 2

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

Change subject: tests: Make compatible with QUnit 2
..


tests: Make compatible with QUnit 2

Bug: T170515
Change-Id: I7fb5b4172dea8610a37ca85aa135411e06070581
---
M tests/ext.eventLogging.tests.js
1 file changed, 9 insertions(+), 9 deletions(-)

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



diff --git a/tests/ext.eventLogging.tests.js b/tests/ext.eventLogging.tests.js
index 849e51f..a95589d 100644
--- a/tests/ext.eventLogging.tests.js
+++ b/tests/ext.eventLogging.tests.js
@@ -83,11 +83,13 @@
}
} ) );
 
-   QUnit.test( 'Configuration', 1, function ( assert ) {
+   QUnit.test( 'Configuration', function ( assert ) {
assert.ok( mw.config.exists( 'wgEventLoggingBaseUri' ), 'Global 
config var "wgEventLoggingBaseUri" exists' );
} );
 
-   QUnit.test( 'validate', validationCases.length + 1, function ( assert ) 
{
+   QUnit.test( 'validate', function ( assert ) {
+   assert.expect( validationCases.length + 1 );
+
var meta = mw.eventLog.getSchema( 'earthquake' ),
errors = mw.eventLog.validate( {
epicenter: 'Valdivia',
@@ -102,7 +104,7 @@
} );
} );
 
-   QUnit.test( 'inSample', 2, function ( assert ) {
+   QUnit.test( 'inSample', function ( assert ) {
assert.strictEqual( mw.eventLog.inSample( 0 ), false );
assert.strictEqual( mw.eventLog.inSample( 1 ), true );
 
@@ -110,7 +112,7 @@
// want consistency in this case
} );
 
-   QUnit.test( 'randomTokenMatch', 2, function ( assert ) {
+   QUnit.test( 'randomTokenMatch', function ( assert ) {
var i, results = { 'true': 0, 'false': 0 };
for ( i = 0; i < 100; i++ ) {
results[ mw.eventLog.randomTokenMatch( 10 ) ]++;
@@ -140,7 +142,7 @@
expected: 'Url exceeds maximum length'
}
}, function ( name, params ) {
-   QUnit.test( name, 1, function ( assert ) {
+   QUnit.test( name, function ( assert ) {
var url = new Array( params.size + 1 ).join( 'x' ),
result = mw.eventLog.checkUrlSize( 
'earthquake', url );
assert.deepEqual( result, params.expected, name );
@@ -165,7 +167,7 @@
.always( assert.async() );
} );
 
-   QUnit.test( 'setDefaults', 1, function ( assert ) {
+   QUnit.test( 'setDefaults', function ( assert ) {
var prepared;
 
mw.eventLog.setDefaults( 'earthquake', {
@@ -213,9 +215,7 @@
invalid: [ -1, {}, undefined ]
}
}, function ( type, cases ) {
-   var asserts = cases.valid.length + cases.invalid.length;
-
-   QUnit.test( type, asserts, function ( assert ) {
+   QUnit.test( type, function ( assert ) {
$.each( cases.valid, function ( index, value ) {
assert.strictEqual( mw.eventLog.isInstanceOf( 
value, type ), true,
JSON.stringify( value ) + ' is a ' + 
type );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7fb5b4172dea8610a37ca85aa135411e06070581
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/EventLogging
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
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] mediawiki...GuidedTour[master]: tests: Make compartible with QUnit 2

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

Change subject: tests: Make compartible with QUnit 2
..


tests: Make compartible with QUnit 2

Change-Id: I0a758d448de36f736c81e8c7ecf12f7a060871eb
---
M tests/qunit/ext.guidedTour.lib.tests.js
1 file changed, 26 insertions(+), 26 deletions(-)

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



diff --git a/tests/qunit/ext.guidedTour.lib.tests.js 
b/tests/qunit/ext.guidedTour.lib.tests.js
index 33c5e77..81f339a 100644
--- a/tests/qunit/ext.guidedTour.lib.tests.js
+++ b/tests/qunit/ext.guidedTour.lib.tests.js
@@ -64,7 +64,7 @@
}
} ) );
 
-   QUnit.test( 'makeTourId', 4, function ( assert ) {
+   QUnit.test( 'makeTourId', function ( assert ) {
assert.strictEqual(
gt.makeTourId( {
name: 'test',
@@ -93,7 +93,7 @@
);
} );
 
-   QUnit.test( 'parseTourId', 1, function ( assert ) {
+   QUnit.test( 'parseTourId', function ( assert ) {
var tourId = 'gt-test-2', expectedTourInfo;
expectedTourInfo = {
name: 'test',
@@ -106,7 +106,7 @@
);
} );
 
-   QUnit.test( 'isPage', 2, function ( assert ) {
+   QUnit.test( 'isPage', function ( assert ) {
var PAGE_NAME_TO_SKIP = 'TestPage',
OTHER_PAGE_NAME = 'WrongPage';
 
@@ -125,7 +125,7 @@
);
} );
 
-   QUnit.test( 'hasQuery', 7, function ( assert ) {
+   QUnit.test( 'hasQuery', function ( assert ) {
var paramMap,
PAGE_NAME_TO_SKIP = 'RightPage',
OTHER_PAGE_NAME = 'OtherPage';
@@ -183,7 +183,7 @@
);
} );
 
-   QUnit.test( 'getStepFromQuery', 2, function ( assert ) {
+   QUnit.test( 'getStepFromQuery', function ( assert ) {
var step;
this.sandbox.stub( mw.util, 'getParamValue', function () {
return step;
@@ -204,7 +204,7 @@
);
} );
 
-   QUnit.test( 'setTourCookie', 5, function ( assert ) {
+   QUnit.test( 'setTourCookie', function ( assert ) {
var firstTourName = 'foo',
secondTourName = 'bar',
numberStep = 5,
@@ -244,7 +244,7 @@
mw.cookie.set( cookieName, oldCookieValue, cookieParams );
} );
 
-   QUnit.test( 'shouldShow', 19, function ( assert ) {
+   QUnit.test( 'shouldShow', function ( assert ) {
var visualEditorArgs, wikitextArgs, mockOpenVE;
 
visualEditorArgs = {
@@ -543,7 +543,7 @@
);
} );
 
-   QUnit.test( 'defineTour', 13, function ( assert ) {
+   QUnit.test( 'defineTour', function ( assert ) {
var SPEC_MUST_BE_OBJECT = /Check your syntax. There must be 
exactly one argument, 'tourSpec', which must be an object\./,
NAME_MUST_BE_STRING = /'tourSpec.name' must be a 
string, the tour name\./,
STEPS_MUST_BE_ARRAY = /'tourSpec.steps' must be an 
array, a list of one or more steps/,
@@ -646,7 +646,7 @@
this.restoreWarnings();
} );
 
-   QUnit.test( 'StepBuilder.constructor', 5, function ( assert ) {
+   QUnit.test( 'StepBuilder.constructor', function ( assert ) {
var STEP_NAME_MUST_BE_STRING = /'stepSpec.name\' must be a 
string, the step name/;
 
assert.strictEqual(
@@ -685,7 +685,7 @@
);
} );
 
-   QUnit.test( 'StepBuilder.listenForMwHooks', 6, function ( assert ) {
+   QUnit.test( 'StepBuilder.listenForMwHooks', function ( assert ) {
var listenForMwHookSpy = this.spy( firstStepBuilder.step, 
'listenForMwHook' );
 
firstStepBuilder.listenForMwHooks();
@@ -723,7 +723,7 @@
);
} );
 
-   QUnit.test( 'StepBuilder.next', 14, function ( assert ) {
+   QUnit.test( 'StepBuilder.next', function ( assert ) {
var editStepBuilder, linkStepBuilder, previewStepBuilder, 
saveStepBuilder,
pointsInvalidNameStepBuilder, 
pointsOtherTourStepBuilder,
returnsInvalidNameCallbackStepBuilder,
@@ -863,7 +863,7 @@
);
} );
 
-   QUnit.test( 'StepBuilder.transition', 14, function ( assert ) {
+   QUnit.test( 'StepBuilder.transition', function ( assert ) {
var linkStepBuilder, editStepBuilder, previewStepBuilder,
returnsInvalidNameCallbackStepBuilder,
returnsOtherTourCallbackStepBuilder,
@@ -997,7 +997,7 @@
);
} );
 
-   QUnit.test( 'Step.constructor', 5, function ( assert ) {

[MediaWiki-commits] [Gerrit] mediawiki...NavigationTiming[master]: Do not filter out zero values.

2017-10-23 Thread Phedenskog (Code Review)
Phedenskog has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386074 )

Change subject: Do not filter out zero values.
..

Do not filter out zero values.

Bug: T178479
Change-Id: I0d178cf43c78c0c4db8ae137ce14c35fccddc1be
---
M modules/ext.navigationTiming.js
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/NavigationTiming 
refs/changes/74/386074/1

diff --git a/modules/ext.navigationTiming.js b/modules/ext.navigationTiming.js
index bca2a77..e5ffe15 100644
--- a/modules/ext.navigationTiming.js
+++ b/modules/ext.navigationTiming.js
@@ -120,13 +120,13 @@
'responseStart',
'secureConnectionStart'
], function ( i, marker ) {
-   // Verify the key exists and that it is above zero to 
avoid submit
-   // of invalid or negative values after subtracting 
navStart.
+   // Verify the key exists and that it is equal or above 
zero to avoid submit
+   // of invalid/negative values after subtracting 
navStart.
// While these keys are meant to be timestamps, they 
may be absent
// or 0 where the measured operation did not ocurr.
// E.g. secureConnectionStart is 0 when the connection 
is reused (T176105)
var value = timing[ marker ];
-   if ( typeof value === 'number' && value > 0 ) {
+   if ( typeof value === 'number' && value >= 0 ) {
timingData[ marker ] = value - navStart;
}
} );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0d178cf43c78c0c4db8ae137ce14c35fccddc1be
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/NavigationTiming
Gerrit-Branch: master
Gerrit-Owner: Phedenskog 

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


[MediaWiki-commits] [Gerrit] mediawiki...ZeroBanner[master]: tests: Use a better name so it's not confused with ZeroPortal

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

Change subject: tests: Use a better name so it's not confused with ZeroPortal
..


tests: Use a better name so it's not confused with ZeroPortal

Change-Id: I6cad7b3d06b2363b0a90d0a38037af936b5d7e20
---
M tests/qunit/test_zerobanner.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/tests/qunit/test_zerobanner.js b/tests/qunit/test_zerobanner.js
index e47e9e0..24965ac 100644
--- a/tests/qunit/test_zerobanner.js
+++ b/tests/qunit/test_zerobanner.js
@@ -1,5 +1,5 @@
 ( function ( M, $ ) {
-   QUnit.module( 'Zero' );
+   QUnit.module( 'ZeroBanner' );
 
QUnit.test( '#init', function ( assert ) {
assert.ok( mw.loader.getState( 'zerobanner' ) === 'ready',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6cad7b3d06b2363b0a90d0a38037af936b5d7e20
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ZeroBanner
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Yurik 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...parsoid[master]: Bump version to 0.8.0 for release

2017-10-23 Thread Arlolra (Code Review)
Arlolra has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386072 )

Change subject: Bump version to 0.8.0 for release
..

Bump version to 0.8.0 for release

Change-Id: I2279cbd8d56d3cd097a086b4f52741234a014346
---
M HISTORY.md
M lib/ext/Cite/index.js
M lib/ext/Gallery/index.js
M lib/ext/Gallery/modes.js
M lib/ext/JSON/index.js
M lib/ext/LST/index.js
M lib/ext/Nowiki/index.js
M lib/ext/Pre/index.js
M lib/ext/Translate/index.js
M npm-shrinkwrap.json
M package.json
M tests/parserTestsParserHook.js
12 files changed, 13 insertions(+), 11 deletions(-)


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

diff --git a/HISTORY.md b/HISTORY.md
index 941120a..4cfe418 100644
--- a/HISTORY.md
+++ b/HISTORY.md
@@ -20,6 +20,7 @@
 to control formatting of transclusions after VE edits
   * T153107: Fix unhandled detection of modified link content
   * T136653: Handle interwiki shortcuts
+  * T177784: Update reverse interwiki map to prefer language prefixes over 
others
   * Cleanup in separator handling in the wikitext serializer
   * Several bug fixes
 
@@ -37,6 +38,7 @@
   * Upgrade service-runner, mediawiki-title
   * Use uuid instead of node-uuid
   * Upgrade several dependencies to deal with security advisories
+  * Limit core-js shimming to what we need
 
   Infrastructure:
   * Migrate from jshint to eslint
diff --git a/lib/ext/Cite/index.js b/lib/ext/Cite/index.js
index bf704b2..658a243 100644
--- a/lib/ext/Cite/index.js
+++ b/lib/ext/Cite/index.js
@@ -7,7 +7,7 @@
 
 var domino = require('domino');
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 var Util = ParsoidExtApi.Util;
 var DU = ParsoidExtApi.DOMUtils;
 var Promise = ParsoidExtApi.Promise;
diff --git a/lib/ext/Gallery/index.js b/lib/ext/Gallery/index.js
index 63ac4be..6cdef35 100644
--- a/lib/ext/Gallery/index.js
+++ b/lib/ext/Gallery/index.js
@@ -9,7 +9,7 @@
 
 'use strict';
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 var Promise = ParsoidExtApi.Promise;
 var Util = ParsoidExtApi.Util;
 var DU = ParsoidExtApi.DOMUtils;
diff --git a/lib/ext/Gallery/modes.js b/lib/ext/Gallery/modes.js
index 230983d..14eea71 100644
--- a/lib/ext/Gallery/modes.js
+++ b/lib/ext/Gallery/modes.js
@@ -3,7 +3,7 @@
 var coreutil = require('util');
 var domino = require('domino');
 
-var ParsoidExtApi = 
module.parent.parent.require('./extapi.js').versionCheck('^0.7.0');
+var ParsoidExtApi = 
module.parent.parent.require('./extapi.js').versionCheck('^0.8.0');
 var DU = ParsoidExtApi.DOMUtils;
 var JSUtils = ParsoidExtApi.JSUtils;
 
diff --git a/lib/ext/JSON/index.js b/lib/ext/JSON/index.js
index 01e94f2..e07be0b 100644
--- a/lib/ext/JSON/index.js
+++ b/lib/ext/JSON/index.js
@@ -7,7 +7,7 @@
 
 'use strict';
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 var DU = ParsoidExtApi.DOMUtils;
 var Promise = ParsoidExtApi.Promise;
 var addMetaData = ParsoidExtApi.addMetaData;
diff --git a/lib/ext/LST/index.js b/lib/ext/LST/index.js
index 41e550e..394d4f7 100644
--- a/lib/ext/LST/index.js
+++ b/lib/ext/LST/index.js
@@ -1,6 +1,6 @@
 'use strict';
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 
 var DU = ParsoidExtApi.DOMUtils;
 var Promise = ParsoidExtApi.Promise;
diff --git a/lib/ext/Nowiki/index.js b/lib/ext/Nowiki/index.js
index 3af8836..1219853 100644
--- a/lib/ext/Nowiki/index.js
+++ b/lib/ext/Nowiki/index.js
@@ -9,7 +9,7 @@
 // functionality.  See T156099
 var PegTokenizer = require('../../wt2html/tokenizer.js').PegTokenizer;
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 var Promise = ParsoidExtApi.Promise;
 var Util = ParsoidExtApi.Util;
 var DU = ParsoidExtApi.DOMUtils;
diff --git a/lib/ext/Pre/index.js b/lib/ext/Pre/index.js
index 25ad27a..1e34ad8 100644
--- a/lib/ext/Pre/index.js
+++ b/lib/ext/Pre/index.js
@@ -5,7 +5,7 @@
 
 'use strict';
 
-var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.7.1');
+var ParsoidExtApi = 
module.parent.require('./extapi.js').versionCheck('^0.8.0');
 
 var Util = ParsoidExtApi.Util;
 var defines = ParsoidExtApi.defines;
diff --git a/lib/ext/Translate/index.js b/lib/ext/Translate/index.js
index e57f38e..48984fd 100644
--- a/lib/ext/Translate/index.js
+++ b/lib/ext/Translate/index.js
@@ -1,6 +1,6 @@
 'use strict';
 
-module.parent.require('./extapi.js').versionCheck('^0.7.1');

[MediaWiki-commits] [Gerrit] mediawiki...parsoid[master]: Bump version after release

2017-10-23 Thread Arlolra (Code Review)
Arlolra has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386073 )

Change subject: Bump version after release
..

Bump version after release

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


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

diff --git a/package.json b/package.json
index 6c1ddbc..f405822 100644
--- a/package.json
+++ b/package.json
@@ -1,7 +1,7 @@
 {
   "name": "parsoid",
   "description": "Mediawiki parser for the VisualEditor.",
-  "version": "0.8.0",
+  "version": "0.8.0+git",
   "license": "GPL-2.0+",
   "dependencies": {
 "async": "^0.9.2",

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I126679b695346cb79fd53237b504bca7e68a1fac
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/parsoid
Gerrit-Branch: master
Gerrit-Owner: Arlolra 

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


[MediaWiki-commits] [Gerrit] mediawiki...Thanks[master]: tests: Make compartible with QUnit 2

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

Change subject: tests: Make compartible with QUnit 2
..


tests: Make compartible with QUnit 2

Change-Id: I726d7f75e37a759e1b1f6372710cb06f754fc94b
---
M tests/qunit/test_ext.thanks.mobilediff.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/tests/qunit/test_ext.thanks.mobilediff.js 
b/tests/qunit/test_ext.thanks.mobilediff.js
index bb3f2d8..db51415 100644
--- a/tests/qunit/test_ext.thanks.mobilediff.js
+++ b/tests/qunit/test_ext.thanks.mobilediff.js
@@ -1,7 +1,7 @@
 ( function ( $, mw ) {
QUnit.module( 'Thanks mobilediff' );
 
-   QUnit.test( 'render button for logged in users', 1, function ( assert ) 
{
+   QUnit.test( 'render button for logged in users', function ( assert ) {
var $container = $( '' ),
$user = $( '' ).data( 'user-name', 'jon' )
.data( 'revision-id', 1 )

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I726d7f75e37a759e1b1f6372710cb06f754fc94b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Thanks
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Krinkle 
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] mediawiki...ZeroBanner[master]: tests: Make compartible with QUnit 2

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

Change subject: tests: Make compartible with QUnit 2
..


tests: Make compartible with QUnit 2

Change-Id: Ibd5db944e20c887dc44a984c2e7ae70e94b44b46
---
M tests/qunit/test_zerobanner.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/tests/qunit/test_zerobanner.js b/tests/qunit/test_zerobanner.js
index 859fe7c..e47e9e0 100644
--- a/tests/qunit/test_zerobanner.js
+++ b/tests/qunit/test_zerobanner.js
@@ -1,7 +1,7 @@
 ( function ( M, $ ) {
QUnit.module( 'Zero' );
 
-   QUnit.test( '#init', 1, function ( assert ) {
+   QUnit.test( '#init', function ( assert ) {
assert.ok( mw.loader.getState( 'zerobanner' ) === 'ready',
'check Zero banner module installed without problems' );
} );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibd5db944e20c887dc44a984c2e7ae70e94b44b46
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ZeroBanner
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...Flow[master]: tests: Make compartible with QUnit 2

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

Change subject: tests: Make compartible with QUnit 2
..


tests: Make compartible with QUnit 2

Change-Id: Id067022f009ac8d73291eee55d7c14ef4198e7e8
---
M tests/qunit/engine/misc/test_flow-handlebars.js
M tests/qunit/engine/misc/test_mw-ui.enhance.js
2 files changed, 12 insertions(+), 12 deletions(-)

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



diff --git a/tests/qunit/engine/misc/test_flow-handlebars.js 
b/tests/qunit/engine/misc/test_flow-handlebars.js
index 84c893e..94ae428 100644
--- a/tests/qunit/engine/misc/test_flow-handlebars.js
+++ b/tests/qunit/engine/misc/test_flow-handlebars.js
@@ -29,28 +29,28 @@
}
} );
 
-   QUnit.test( 'Handlebars.prototype.processTemplate', 1, function ( 
assert ) {
+   QUnit.test( 'Handlebars.prototype.processTemplate', function ( assert ) 
{
assert.strictEqual( this.handlebarsProto.processTemplate( 
'foo', { val: 'Hello' } ),
'Magic.', 'Getting a template works.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.processTemplateGetFragment', 1, 
function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.processTemplateGetFragment', function 
( assert ) {
assert.strictEqual( 
this.handlebarsProto.processTemplateGetFragment( 'foo', { val: 'Hello' } 
).childNodes.length,
1, 'Return a fragment with the div child node' );
} );
 
-   QUnit.test( 'Handlebars.prototype.getTemplate', 2, function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.getTemplate', function ( assert ) {
assert.strictEqual( this.handlebarsProto.getTemplate( 'foo' 
)(), 'Stubbed.', 'Getting a template works.' );
assert.strictEqual( this.handlebarsProto.getTemplate( 'foo' 
)(), 'Stubbed.', 'Getting a template from cache works.' );
} );
 
// Helpers
-   QUnit.test( 'Handlebars.prototype.callHelper', 1, function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.callHelper', function ( assert ) {
assert.strictEqual( this.handlebarsProto.callHelper( 
'_qunit_helper_test', 1, 2 ),
3, 'Check the helper was called.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.eachPost', 3, function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.eachPost', function ( assert ) {
var ctx = {
posts: {
1: [ 300 ],
@@ -67,7 +67,7 @@
assert.deepEqual( this.handlebarsProto.eachPost( ctx, 2, {} ), 
{ content: null }, 'Missing revision id.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.ifCond', 8, function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.ifCond', function ( assert ) {
assert.strictEqual( this.handlebarsProto.ifCond( 'foo', '===', 
'bar', this.opts ), 'nope', 'not equal' );
assert.strictEqual( this.handlebarsProto.ifCond( 'foo', '===', 
'foo', this.opts ), 'ok', 'equal' );
assert.strictEqual( this.handlebarsProto.ifCond( true, 'or', 
false, this.opts ), 'ok', 'true || false' );
@@ -78,17 +78,17 @@
assert.strictEqual( this.handlebarsProto.ifCond( 'foo', '!==', 
'bar', this.opts ), 'ok' );
} );
 
-   QUnit.test( 'Handlebars.prototype.ifAnonymous', 2, function () {
+   QUnit.test( 'Handlebars.prototype.ifAnonymous', function () {
strictEqual( this.handlebarsProto.ifAnonymous( this.opts ), 
'ok', 'User should be anonymous first time.' );
strictEqual( this.handlebarsProto.ifAnonymous( this.opts ), 
'nope', 'User should be logged in on second call.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.concat', 2, function () {
+   QUnit.test( 'Handlebars.prototype.concat', function () {
strictEqual( this.handlebarsProto.concat( 'a', 'b', 'c', 
this.opts ), 'abc', 'Check concat working fine.' );
strictEqual( this.handlebarsProto.concat( this.opts ), '', 
'Without arguments.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.progressiveEnhancement', 5, function 
() {
+   QUnit.test( 'Handlebars.prototype.progressiveEnhancement', function () {
var opts = $.extend( { hash: { type: 'insert', target: 'abc', 
id: 'def' } }, this.opts ),
$div = $( document.createElement( 'div' ) );
 
diff --git a/tests/qunit/engine/misc/test_mw-ui.enhance.js 
b/tests/qunit/engine/misc/test_mw-ui.enhance.js
index 8170df6..8397722 100644
--- a/tests/qunit/engine/misc/test_mw-ui.enhance.js
+++ b/tests/qunit/engine/misc/test_mw-ui.enhance.js
@@ -1,7 +1,7 @@
 ( function ( $ ) {
QUnit.module( 'ext.flow: mediawiki.ui.enhance' );
 
-   QUnit.test( 'Forms with required fields have 

[MediaWiki-commits] [Gerrit] operations/puppet[production]: Remove zeroes for non existing values

2017-10-23 Thread Phedenskog (Code Review)
Phedenskog has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386071 )

Change subject: Remove zeroes for non existing values
..

Remove zeroes for non existing values

This will be done in the frontend instead. The problem right now is
that it adds 0 to metrics that don't exists (browsers not supporting
the navigation timing API).

Bug: T178479
Change-Id: I6621cbe8ad140216e638e40236417d697111539b
---
M modules/webperf/files/navtiming.py
M modules/webperf/files/navtiming_expected.txt
2 files changed, 0 insertions(+), 435 deletions(-)


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

diff --git a/modules/webperf/files/navtiming.py 
b/modules/webperf/files/navtiming.py
index 512b194..099bcac 100755
--- a/modules/webperf/files/navtiming.py
+++ b/modules/webperf/files/navtiming.py
@@ -446,16 +446,10 @@
 # We miss out appCache since we don't have domainLookupStart
 if 'dnsLookup' in event:
 metrics_nav2['dns'] = event['dnsLookup']
-else:
-metrics_nav2['dns'] = 0
 if 'unload' in event:
 metrics_nav2['unload'] = event['unload']
-else:
-metrics_nav2['unload'] = 0
 if 'redirecting' in event:
 metrics_nav2['redirect'] = event['redirecting']
-else:
-metrics_nav2['redirect'] = 0
 
 # If one of the metrics are wrong, don't send them at all
 for metric, value in metrics_nav2.items():
diff --git a/modules/webperf/files/navtiming_expected.txt 
b/modules/webperf/files/navtiming_expected.txt
index d240ce5..f8e9c0d 100644
--- a/modules/webperf/files/navtiming_expected.txt
+++ b/modules/webperf/files/navtiming_expected.txt
@@ -2769,7 +2769,6 @@
 frontend.navtiming2.dns.by_browser.Chrome.45:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.49:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.50:0|ms
-frontend.navtiming2.dns.by_browser.Chrome.59:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
@@ -2791,7 +2790,6 @@
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.60:3|ms
-frontend.navtiming2.dns.by_browser.Chrome.all:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.all:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.all:0|ms
 frontend.navtiming2.dns.by_browser.Chrome.all:0|ms
@@ -2903,7 +2901,6 @@
 frontend.navtiming2.dns.by_continent.Europe:0|ms
 frontend.navtiming2.dns.by_continent.Europe:0|ms
 frontend.navtiming2.dns.by_continent.Europe:0|ms
-frontend.navtiming2.dns.by_continent.Europe:0|ms
 frontend.navtiming2.dns.by_continent.North_America:0|ms
 frontend.navtiming2.dns.by_continent.North_America:0|ms
 frontend.navtiming2.dns.by_continent.North_America:0|ms
@@ -2971,9 +2968,7 @@
 frontend.navtiming2.dns.desktop.authenticated:0|ms
 frontend.navtiming2.dns.desktop.authenticated:0|ms
 frontend.navtiming2.dns.desktop.authenticated:0|ms
-frontend.navtiming2.dns.desktop.authenticated:0|ms
 frontend.navtiming2.dns.desktop.authenticated:3|ms
-frontend.navtiming2.dns.desktop.overall:0|ms
 frontend.navtiming2.dns.desktop.overall:0|ms
 frontend.navtiming2.dns.desktop.overall:0|ms
 frontend.navtiming2.dns.desktop.overall:0|ms
@@ -3033,7 +3028,6 @@
 frontend.navtiming2.dns.mobile.overall:0|ms
 frontend.navtiming2.dns.mobile.overall:0|ms
 frontend.navtiming2.dns.mobile.overall:0|ms
-frontend.navtiming2.dns.overall:0|ms
 frontend.navtiming2.dns.overall:0|ms
 frontend.navtiming2.dns.overall:0|ms
 frontend.navtiming2.dns.overall:0|ms
@@ -5150,325 +5144,6 @@
 frontend.navtiming2.processing.overall:884|ms
 frontend.navtiming2.processing.overall:962|ms
 frontend.navtiming2.processing.overall:991|ms
-frontend.navtiming2.redirect.by_browser.Chrome.15:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.15:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.45:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.49:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.50:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.59:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms
-frontend.navtiming2.redirect.by_browser.Chrome.60:0|ms

[MediaWiki-commits] [Gerrit] mediawiki...Wikibase[master]: Treat NULL and 0 as equivalent for rev_parent_id

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

Change subject: Treat NULL and 0 as equivalent for rev_parent_id
..


Treat NULL and 0 as equivalent for rev_parent_id

The return value of Revision::getParentId is under-specified.
Calling code should treat null and 0 as equivalent.

Change-Id: Ia4e281c6b499441803b581ba81d3211e1a09789a
---
M client/includes/RecentChanges/RevisionData.php
M repo/Wikibase.hooks.php
2 files changed, 13 insertions(+), 4 deletions(-)

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



diff --git a/client/includes/RecentChanges/RevisionData.php 
b/client/includes/RecentChanges/RevisionData.php
index 48ab89d..7ab6d63 100644
--- a/client/includes/RecentChanges/RevisionData.php
+++ b/client/includes/RecentChanges/RevisionData.php
@@ -98,7 +98,7 @@
 * @return int
 */
public function getParentId() {
-   return $this->changeParams['parent_id'];
+   return intval( $this->changeParams['parent_id'] );
}
 
/**
diff --git a/repo/Wikibase.hooks.php b/repo/Wikibase.hooks.php
index aea60e9..253486e 100644
--- a/repo/Wikibase.hooks.php
+++ b/repo/Wikibase.hooks.php
@@ -192,12 +192,21 @@
self::notifyEntityStoreWatcherOnUpdate( $revision );
 
$notifier = 
WikibaseRepo::getDefaultInstance()->getChangeNotifier();
+   $parentId = $revision->getParentId();
 
-   if ( $revision->getParentId() === null ) {
+   if ( !$parentId ) {
$notifier->notifyOnPageCreated( $revision );
} else {
-   $parent = Revision::newFromId( 
$revision->getParentId() );
-   $notifier->notifyOnPageModified( $revision, 
$parent );
+   $parent = Revision::newFromId( $parentId );
+
+   if ( !$parent ) {
+   wfLogWarning(
+   __METHOD__ . ': Cannot notify 
on page modification: '
+   . 'failed to load parent 
revision with ID ' . $parentId
+   );
+   } else {
+   $notifier->notifyOnPageModified( 
$revision, $parent );
+   }
}
}
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia4e281c6b499441803b581ba81d3211e1a09789a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Daniel Kinzler 
Gerrit-Reviewer: Anomie 
Gerrit-Reviewer: Aude 
Gerrit-Reviewer: Ladsgroup 
Gerrit-Reviewer: Thiemo Mättig (WMDE) 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...ZeroBanner[master]: tests: Make compartible with QUnit 2

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386068 )

Change subject: tests: Make compartible with QUnit 2
..

tests: Make compartible with QUnit 2

Change-Id: Ibd5db944e20c887dc44a984c2e7ae70e94b44b46
---
M tests/qunit/test_zerobanner.js
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ZeroBanner 
refs/changes/68/386068/1

diff --git a/tests/qunit/test_zerobanner.js b/tests/qunit/test_zerobanner.js
index 859fe7c..e47e9e0 100644
--- a/tests/qunit/test_zerobanner.js
+++ b/tests/qunit/test_zerobanner.js
@@ -1,7 +1,7 @@
 ( function ( M, $ ) {
QUnit.module( 'Zero' );
 
-   QUnit.test( '#init', 1, function ( assert ) {
+   QUnit.test( '#init', function ( assert ) {
assert.ok( mw.loader.getState( 'zerobanner' ) === 'ready',
'check Zero banner module installed without problems' );
} );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ibd5db944e20c887dc44a984c2e7ae70e94b44b46
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ZeroBanner
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] mediawiki...ZeroBanner[master]: tests: Use a better name so it's not confused with ZeroPortal

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386069 )

Change subject: tests: Use a better name so it's not confused with ZeroPortal
..

tests: Use a better name so it's not confused with ZeroPortal

Change-Id: I6cad7b3d06b2363b0a90d0a38037af936b5d7e20
---
M tests/qunit/test_zerobanner.js
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ZeroBanner 
refs/changes/69/386069/1

diff --git a/tests/qunit/test_zerobanner.js b/tests/qunit/test_zerobanner.js
index e47e9e0..24965ac 100644
--- a/tests/qunit/test_zerobanner.js
+++ b/tests/qunit/test_zerobanner.js
@@ -1,5 +1,5 @@
 ( function ( M, $ ) {
-   QUnit.module( 'Zero' );
+   QUnit.module( 'ZeroBanner' );
 
QUnit.test( '#init', function ( assert ) {
assert.ok( mw.loader.getState( 'zerobanner' ) === 'ready',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6cad7b3d06b2363b0a90d0a38037af936b5d7e20
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ZeroBanner
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] mediawiki...Thanks[master]: tests: Make compartible with QUnit 2

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386067 )

Change subject: tests: Make compartible with QUnit 2
..

tests: Make compartible with QUnit 2

Change-Id: I726d7f75e37a759e1b1f6372710cb06f754fc94b
---
M tests/qunit/test_ext.thanks.mobilediff.js
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/tests/qunit/test_ext.thanks.mobilediff.js 
b/tests/qunit/test_ext.thanks.mobilediff.js
index bb3f2d8..db51415 100644
--- a/tests/qunit/test_ext.thanks.mobilediff.js
+++ b/tests/qunit/test_ext.thanks.mobilediff.js
@@ -1,7 +1,7 @@
 ( function ( $, mw ) {
QUnit.module( 'Thanks mobilediff' );
 
-   QUnit.test( 'render button for logged in users', 1, function ( assert ) 
{
+   QUnit.test( 'render button for logged in users', function ( assert ) {
var $container = $( '' ),
$user = $( '' ).data( 'user-name', 'jon' )
.data( 'revision-id', 1 )

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I726d7f75e37a759e1b1f6372710cb06f754fc94b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Thanks
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] mediawiki/core[fundraising/REL1_27]: Update DonationInterface submodule

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

Change subject: Update DonationInterface submodule
..


Update DonationInterface submodule

Change-Id: I82913fedd97357c80b9bfa2a8461f9940b1bdbc4
---
M extensions/DonationInterface
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/extensions/DonationInterface b/extensions/DonationInterface
index 2036093..5bb4e5f 16
--- a/extensions/DonationInterface
+++ b/extensions/DonationInterface
@@ -1 +1 @@
-Subproject commit 203609306ca9f95a04f01466e70b315e7f9739fc
+Subproject commit 5bb4e5ff640f0dc27c209107d22646e7b4cfab0c

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I82913fedd97357c80b9bfa2a8461f9940b1bdbc4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: fundraising/REL1_27
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: Ejegg 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mediawiki...Flow[master]: tests: Make compartible with QUnit 2

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386066 )

Change subject: tests: Make compartible with QUnit 2
..

tests: Make compartible with QUnit 2

Change-Id: Id067022f009ac8d73291eee55d7c14ef4198e7e8
---
M tests/qunit/engine/misc/test_flow-handlebars.js
M tests/qunit/engine/misc/test_mw-ui.enhance.js
2 files changed, 12 insertions(+), 12 deletions(-)


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

diff --git a/tests/qunit/engine/misc/test_flow-handlebars.js 
b/tests/qunit/engine/misc/test_flow-handlebars.js
index 84c893e..94ae428 100644
--- a/tests/qunit/engine/misc/test_flow-handlebars.js
+++ b/tests/qunit/engine/misc/test_flow-handlebars.js
@@ -29,28 +29,28 @@
}
} );
 
-   QUnit.test( 'Handlebars.prototype.processTemplate', 1, function ( 
assert ) {
+   QUnit.test( 'Handlebars.prototype.processTemplate', function ( assert ) 
{
assert.strictEqual( this.handlebarsProto.processTemplate( 
'foo', { val: 'Hello' } ),
'Magic.', 'Getting a template works.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.processTemplateGetFragment', 1, 
function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.processTemplateGetFragment', function 
( assert ) {
assert.strictEqual( 
this.handlebarsProto.processTemplateGetFragment( 'foo', { val: 'Hello' } 
).childNodes.length,
1, 'Return a fragment with the div child node' );
} );
 
-   QUnit.test( 'Handlebars.prototype.getTemplate', 2, function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.getTemplate', function ( assert ) {
assert.strictEqual( this.handlebarsProto.getTemplate( 'foo' 
)(), 'Stubbed.', 'Getting a template works.' );
assert.strictEqual( this.handlebarsProto.getTemplate( 'foo' 
)(), 'Stubbed.', 'Getting a template from cache works.' );
} );
 
// Helpers
-   QUnit.test( 'Handlebars.prototype.callHelper', 1, function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.callHelper', function ( assert ) {
assert.strictEqual( this.handlebarsProto.callHelper( 
'_qunit_helper_test', 1, 2 ),
3, 'Check the helper was called.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.eachPost', 3, function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.eachPost', function ( assert ) {
var ctx = {
posts: {
1: [ 300 ],
@@ -67,7 +67,7 @@
assert.deepEqual( this.handlebarsProto.eachPost( ctx, 2, {} ), 
{ content: null }, 'Missing revision id.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.ifCond', 8, function ( assert ) {
+   QUnit.test( 'Handlebars.prototype.ifCond', function ( assert ) {
assert.strictEqual( this.handlebarsProto.ifCond( 'foo', '===', 
'bar', this.opts ), 'nope', 'not equal' );
assert.strictEqual( this.handlebarsProto.ifCond( 'foo', '===', 
'foo', this.opts ), 'ok', 'equal' );
assert.strictEqual( this.handlebarsProto.ifCond( true, 'or', 
false, this.opts ), 'ok', 'true || false' );
@@ -78,17 +78,17 @@
assert.strictEqual( this.handlebarsProto.ifCond( 'foo', '!==', 
'bar', this.opts ), 'ok' );
} );
 
-   QUnit.test( 'Handlebars.prototype.ifAnonymous', 2, function () {
+   QUnit.test( 'Handlebars.prototype.ifAnonymous', function () {
strictEqual( this.handlebarsProto.ifAnonymous( this.opts ), 
'ok', 'User should be anonymous first time.' );
strictEqual( this.handlebarsProto.ifAnonymous( this.opts ), 
'nope', 'User should be logged in on second call.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.concat', 2, function () {
+   QUnit.test( 'Handlebars.prototype.concat', function () {
strictEqual( this.handlebarsProto.concat( 'a', 'b', 'c', 
this.opts ), 'abc', 'Check concat working fine.' );
strictEqual( this.handlebarsProto.concat( this.opts ), '', 
'Without arguments.' );
} );
 
-   QUnit.test( 'Handlebars.prototype.progressiveEnhancement', 5, function 
() {
+   QUnit.test( 'Handlebars.prototype.progressiveEnhancement', function () {
var opts = $.extend( { hash: { type: 'insert', target: 'abc', 
id: 'def' } }, this.opts ),
$div = $( document.createElement( 'div' ) );
 
diff --git a/tests/qunit/engine/misc/test_mw-ui.enhance.js 
b/tests/qunit/engine/misc/test_mw-ui.enhance.js
index 8170df6..8397722 100644
--- a/tests/qunit/engine/misc/test_mw-ui.enhance.js
+++ b/tests/qunit/engine/misc/test_mw-ui.enhance.js
@@ -1,7 +1,7 @@
 ( function ( $ ) {
QUnit.module( 'ext.flow: mediawiki.ui.enhance' );
 
-   QUnit.test( 'Forms with required 

[MediaWiki-commits] [Gerrit] mediawiki...MinervaNeue[master]: Disable print button on iOS

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

Change subject: Disable print button on iOS
..


Disable print button on iOS

As documented on the ticket, iOS does not provide PDF functionality
via print.

iOS 11 provides PDF generation but the resulting PDF is unreadable for
our content and missing styles (see T177215#3700576) and we do not know
of any way to invoke that just yet.

Bug: T177215
Change-Id: I7e195ae067625c7865dccee31fa7a2c3c0ee57e5
---
M resources/skins.minerva.scripts/init.js
1 file changed, 6 insertions(+), 1 deletion(-)

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



diff --git a/resources/skins.minerva.scripts/init.js 
b/resources/skins.minerva.scripts/init.js
index a267077..0b5a3cd 100644
--- a/resources/skins.minerva.scripts/init.js
+++ b/resources/skins.minerva.scripts/init.js
@@ -261,8 +261,13 @@
initHistoryLink( $( '.last-modifier-tagline a' ) );
M.on( 'resize', loadTabletModules );
loadTabletModules();
-   if ( config.get( 'wgMinervaDownloadIcon' ) && 
!page.isMainPage() ) {
 
+   if (
+   config.get( 'wgMinervaDownloadIcon' ) &&
+   !page.isMainPage() &&
+   // The iOS print dialog does not provide pdf 
functionality (see T177215)
+   !browser.isIos()
+   ) {
// Because the page actions are floated to the right, 
their order in the
// DOM is reversed in the display. The watchstar is 
last in the DOM and
// left-most in the display. Since we want the download 
button to be to

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7e195ae067625c7865dccee31fa7a2c3c0ee57e5
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/skins/MinervaNeue
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 
Gerrit-Reviewer: Phuedx 
Gerrit-Reviewer: Pmiazga 
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] operations/puppet[production]: Remove mediawiki::users::mwdeploy_pub_key, unused

2017-10-23 Thread Chad (Code Review)
Chad has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386065 )

Change subject: Remove mediawiki::users::mwdeploy_pub_key, unused
..

Remove mediawiki::users::mwdeploy_pub_key, unused

This is no longer needed with Scap3 + keyholder. Nothing references
this anymore

Bug: T145495
Change-Id: I581a76338b38800bff77910e5ba6c0925a36f662
---
M hieradata/labs/deployment-prep/common.yaml
1 file changed, 0 insertions(+), 1 deletion(-)


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

diff --git a/hieradata/labs/deployment-prep/common.yaml 
b/hieradata/labs/deployment-prep/common.yaml
index b4f7436..26d121f 100644
--- a/hieradata/labs/deployment-prep/common.yaml
+++ b/hieradata/labs/deployment-prep/common.yaml
@@ -204,7 +204,6 @@
 hosts:
   - deployment-restbase01.deployment-prep.eqiad.wmflabs
   - deployment-restbase02.deployment-prep.eqiad.wmflabs
-"mediawiki::users::mwdeploy_pub_key": 'ssh-rsa 
B3NzaC1yc2EDAQABAAABAQDFwlmBBBJAr1GI+vuYjFh5vq0YIVa5fqE5DZdpzUZISlQ0Kt+9bIr2qNHIj+Jl5Bc6ZY1mkh8l693tAHVx+8tayoiFWYNs9IVsxR+iHgOOhAdDIBXaHaUattdiye5bQmdvJVXaVegckNX2gbmUCOc09jvZvlk3blKFTSEpZRU8dmpXQzKdZgaAq2VTajAegoFnuN9FbC7hzBPA+1NxFNKn94eIeFPSlo5rWr44OEb5Uy3O0B5c6WPM+IgfiygetP+yGL4cKv7qEjZ0Sxok/Rh1lBh1vP1YQ/Mc6tMV0s+kOv7Wz+P88bfU1/uWvy479OZdfh3NQqDTrLzqHwVW1vef
 root@deployment-salt'
 
 "profile::etcd::tlsproxy::read_only": false
 

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...Configure[master]: Add missing qqq message documentation

2017-10-23 Thread Umherirrender (Code Review)
Umherirrender has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386064 )

Change subject: Add missing qqq message documentation
..

Add missing qqq message documentation

Activate banana checker

Remove unneeded keys from qqq.json to make banana happy

Change-Id: I511deafba3a469168b16a9576892211d81d440c8
---
M Gruntfile.js
M settings/i18n/qqq.json
2 files changed, 25 insertions(+), 51 deletions(-)


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

diff --git a/Gruntfile.js b/Gruntfile.js
index 0557be6..22f9149 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -21,8 +21,8 @@
]
},
banana: {
-   all: 'i18n/'
-   /*settings: 'settings/i18n/'*/
+   all: 'i18n/',
+   settings: 'settings/i18n/'
}
} );
 
diff --git a/settings/i18n/qqq.json b/settings/i18n/qqq.json
index 5c50e86..aa7bb00 100644
--- a/settings/i18n/qqq.json
+++ b/settings/i18n/qqq.json
@@ -24,7 +24,8 @@
"configure-setting-desc": "{{Optional}}",
"configure-setting-wgSitename": 
"{{config-wg|Sitename}}\n{{Identical|Sitename}}",
"configure-setting-wgActionPaths": "{{config-wg|ActionPaths}}",
-   "configure-setting-wgActionPaths-key": "{{Identical|Action}}",
+   "configure-setting-wgActionPaths-key": "A label 
message\n{{Identical|Action}}",
+   "configure-setting-wgActionPaths-value": "A label message",
"configure-setting-wgAllDBsAreLocalhost": 
"{{config-wg|AllDBsAreLocalhost}}",
"configure-setting-wgDBAvgStatusPoll": "{{config-wg|DBAvgStatusPoll}}",
"configure-setting-wgDBerrorLog": "{{config-wg|DBerrorLog}}",
@@ -51,7 +52,8 @@
"configure-setting-wgMaxAnimatedGifArea": 
"{{config-wg|MaxAnimatedGifArea}}",
"configure-setting-wgMaxImageArea": "{{config-wg|MaxImageArea}}",
"configure-setting-wgMediaHandlers": "{{config-wg|MediaHandlers}}",
-   "configure-setting-wgMediaHandlers-key": "{{Identical|MIME type}}",
+   "configure-setting-wgMediaHandlers-key": "A label 
message\n{{Identical|MIME type}}",
+   "configure-setting-wgMediaHandlers-value": "A label message",
"configure-setting-wgThumbnailScriptPath": 
"{{config-wg|ThumbnailScriptPath}}",
"configure-setting-wgThumbUpright": "{{config-wg|ThumbUpright}}",
"configure-setting-wgShowEXIF": "{{config-wg|ShowEXIF}}",
@@ -64,7 +66,6 @@
"configure-setting-wgImgAuthPublicTest": 
"{{config-wg|ImgAuthPublicTest}}",
"configure-setting-wgTiffThumbnailType": 
"{{config-wg|TiffThumbnailType}}",
"configure-setting-wgMainCacheType": "{{config-wg|MainCacheType}}",
-   "configure-setting-wgDBAhandler": "{{config-wg|DBAhandler}}",
"configure-setting-wgCacheEpoch": "{{config-wg|CacheEpoch}}",
"configure-setting-wgCachePages": "{{config-wg|CachePages}}",
"configure-setting-wgCachePrefix": "{{config-wg|CachePrefix}}",
@@ -110,7 +111,6 @@
"configure-setting-wgLoginLanguageSelector": 
"{{config-wg|LoginLanguageSelector}}",
"configure-setting-wgTranslateNumerals": 
"{{config-wg|TranslateNumerals}}",
"configure-setting-wgUseDatabaseMessages": 
"{{config-wg|UseDatabaseMessages}}",
-   "configure-setting-wgUseDynamicDates": "{{config-wg|UseDynamicDates}}",
"configure-setting-wgArticleRobotPolicies": 
"{{config-wg|ArticleRobotPolicies}}",
"configure-setting-wgArticleRobotPolicies-key": "{{Identical|Page 
title}}",
"configure-setting-wgArticleRobotPolicies-value": "{{Identical|Robot 
policy}}",
@@ -125,9 +125,7 @@
"configure-setting-wgExtraLanguageNames-key": "{{Identical|Language 
code}}",
"configure-setting-wgExtraLanguageNames-value": "{{Identical|Name}}",
"configure-setting-wgDisabledVariants": 
"{{config-wg|DisabledVariants}}",
-   "configure-setting-wgBetterDirectionality": 
"{{config-wg|BetterDirectionality}}",
"configure-setting-wgCanonicalLanguageLinks": 
"{{config-wg|CanonicalLanguageLinks}}",
-   "configure-setting-wgExtraRandompageSQL": 
"{{config-wg|ExtraRandompageSQL}}",
"configure-setting-wgExtraSubtitle": "{{config-wg|ExtraSubtitle}}",
"configure-setting-wgHideInterlanguageLinks": 
"{{config-wg|HideInterlanguageLinks}}",
"configure-setting-wgLegalTitleChars": 
"{{config-wg|LegalTitleChars}}\n\"regex\" stands for \"regular expression\".",
@@ -142,7 +140,6 @@
"configure-setting-wgStyleVersion": 
"{{config-wg|StyleVersion}}\n\n''Version'' can be thought as a both noun and 
verb, but the variable sets the specific version, so the noun usage might be 
more accurate.",
"configure-setting-wgUniversalEditButton": 
"{{config-wg|UniversalEditButton}}",
"configure-setting-wgUrlProtocols": "{{config-wg|UrlProtocols}}",
- 

[MediaWiki-commits] [Gerrit] mediawiki...GuidedTour[master]: tests: Make compartible with QUnit 2

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386063 )

Change subject: tests: Make compartible with QUnit 2
..

tests: Make compartible with QUnit 2

Change-Id: I0a758d448de36f736c81e8c7ecf12f7a060871eb
---
M tests/qunit/ext.guidedTour.lib.tests.js
1 file changed, 26 insertions(+), 26 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/GuidedTour 
refs/changes/63/386063/1

diff --git a/tests/qunit/ext.guidedTour.lib.tests.js 
b/tests/qunit/ext.guidedTour.lib.tests.js
index 33c5e77..81f339a 100644
--- a/tests/qunit/ext.guidedTour.lib.tests.js
+++ b/tests/qunit/ext.guidedTour.lib.tests.js
@@ -64,7 +64,7 @@
}
} ) );
 
-   QUnit.test( 'makeTourId', 4, function ( assert ) {
+   QUnit.test( 'makeTourId', function ( assert ) {
assert.strictEqual(
gt.makeTourId( {
name: 'test',
@@ -93,7 +93,7 @@
);
} );
 
-   QUnit.test( 'parseTourId', 1, function ( assert ) {
+   QUnit.test( 'parseTourId', function ( assert ) {
var tourId = 'gt-test-2', expectedTourInfo;
expectedTourInfo = {
name: 'test',
@@ -106,7 +106,7 @@
);
} );
 
-   QUnit.test( 'isPage', 2, function ( assert ) {
+   QUnit.test( 'isPage', function ( assert ) {
var PAGE_NAME_TO_SKIP = 'TestPage',
OTHER_PAGE_NAME = 'WrongPage';
 
@@ -125,7 +125,7 @@
);
} );
 
-   QUnit.test( 'hasQuery', 7, function ( assert ) {
+   QUnit.test( 'hasQuery', function ( assert ) {
var paramMap,
PAGE_NAME_TO_SKIP = 'RightPage',
OTHER_PAGE_NAME = 'OtherPage';
@@ -183,7 +183,7 @@
);
} );
 
-   QUnit.test( 'getStepFromQuery', 2, function ( assert ) {
+   QUnit.test( 'getStepFromQuery', function ( assert ) {
var step;
this.sandbox.stub( mw.util, 'getParamValue', function () {
return step;
@@ -204,7 +204,7 @@
);
} );
 
-   QUnit.test( 'setTourCookie', 5, function ( assert ) {
+   QUnit.test( 'setTourCookie', function ( assert ) {
var firstTourName = 'foo',
secondTourName = 'bar',
numberStep = 5,
@@ -244,7 +244,7 @@
mw.cookie.set( cookieName, oldCookieValue, cookieParams );
} );
 
-   QUnit.test( 'shouldShow', 19, function ( assert ) {
+   QUnit.test( 'shouldShow', function ( assert ) {
var visualEditorArgs, wikitextArgs, mockOpenVE;
 
visualEditorArgs = {
@@ -543,7 +543,7 @@
);
} );
 
-   QUnit.test( 'defineTour', 13, function ( assert ) {
+   QUnit.test( 'defineTour', function ( assert ) {
var SPEC_MUST_BE_OBJECT = /Check your syntax. There must be 
exactly one argument, 'tourSpec', which must be an object\./,
NAME_MUST_BE_STRING = /'tourSpec.name' must be a 
string, the tour name\./,
STEPS_MUST_BE_ARRAY = /'tourSpec.steps' must be an 
array, a list of one or more steps/,
@@ -646,7 +646,7 @@
this.restoreWarnings();
} );
 
-   QUnit.test( 'StepBuilder.constructor', 5, function ( assert ) {
+   QUnit.test( 'StepBuilder.constructor', function ( assert ) {
var STEP_NAME_MUST_BE_STRING = /'stepSpec.name\' must be a 
string, the step name/;
 
assert.strictEqual(
@@ -685,7 +685,7 @@
);
} );
 
-   QUnit.test( 'StepBuilder.listenForMwHooks', 6, function ( assert ) {
+   QUnit.test( 'StepBuilder.listenForMwHooks', function ( assert ) {
var listenForMwHookSpy = this.spy( firstStepBuilder.step, 
'listenForMwHook' );
 
firstStepBuilder.listenForMwHooks();
@@ -723,7 +723,7 @@
);
} );
 
-   QUnit.test( 'StepBuilder.next', 14, function ( assert ) {
+   QUnit.test( 'StepBuilder.next', function ( assert ) {
var editStepBuilder, linkStepBuilder, previewStepBuilder, 
saveStepBuilder,
pointsInvalidNameStepBuilder, 
pointsOtherTourStepBuilder,
returnsInvalidNameCallbackStepBuilder,
@@ -863,7 +863,7 @@
);
} );
 
-   QUnit.test( 'StepBuilder.transition', 14, function ( assert ) {
+   QUnit.test( 'StepBuilder.transition', function ( assert ) {
var linkStepBuilder, editStepBuilder, previewStepBuilder,
returnsInvalidNameCallbackStepBuilder,
returnsOtherTourCallbackStepBuilder,
@@ -997,7 +997,7 @@
);
} );
 
-   QUnit.test( 'Step.constructor', 5, 

[MediaWiki-commits] [Gerrit] mediawiki/core[fundraising/REL1_27]: Update DonationInterface submodule

2017-10-23 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386062 )

Change subject: Update DonationInterface submodule
..

Update DonationInterface submodule

Change-Id: I82913fedd97357c80b9bfa2a8461f9940b1bdbc4
---
M extensions/DonationInterface
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/extensions/DonationInterface b/extensions/DonationInterface
index 2036093..5bb4e5f 16
--- a/extensions/DonationInterface
+++ b/extensions/DonationInterface
@@ -1 +1 @@
-Subproject commit 203609306ca9f95a04f01466e70b315e7f9739fc
+Subproject commit 5bb4e5ff640f0dc27c209107d22646e7b4cfab0c

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I82913fedd97357c80b9bfa2a8461f9940b1bdbc4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: fundraising/REL1_27
Gerrit-Owner: Ejegg 

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


[MediaWiki-commits] [Gerrit] mediawiki...EventLogging[master]: tests: Make compartible with QUnit 2

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386061 )

Change subject: tests: Make compartible with QUnit 2
..

tests: Make compartible with QUnit 2

Change-Id: I7fb5b4172dea8610a37ca85aa135411e06070581
---
M tests/ext.eventLogging.tests.js
1 file changed, 9 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/EventLogging 
refs/changes/61/386061/1

diff --git a/tests/ext.eventLogging.tests.js b/tests/ext.eventLogging.tests.js
index 849e51f..a95589d 100644
--- a/tests/ext.eventLogging.tests.js
+++ b/tests/ext.eventLogging.tests.js
@@ -83,11 +83,13 @@
}
} ) );
 
-   QUnit.test( 'Configuration', 1, function ( assert ) {
+   QUnit.test( 'Configuration', function ( assert ) {
assert.ok( mw.config.exists( 'wgEventLoggingBaseUri' ), 'Global 
config var "wgEventLoggingBaseUri" exists' );
} );
 
-   QUnit.test( 'validate', validationCases.length + 1, function ( assert ) 
{
+   QUnit.test( 'validate', function ( assert ) {
+   assert.expect( validationCases.length + 1 );
+
var meta = mw.eventLog.getSchema( 'earthquake' ),
errors = mw.eventLog.validate( {
epicenter: 'Valdivia',
@@ -102,7 +104,7 @@
} );
} );
 
-   QUnit.test( 'inSample', 2, function ( assert ) {
+   QUnit.test( 'inSample', function ( assert ) {
assert.strictEqual( mw.eventLog.inSample( 0 ), false );
assert.strictEqual( mw.eventLog.inSample( 1 ), true );
 
@@ -110,7 +112,7 @@
// want consistency in this case
} );
 
-   QUnit.test( 'randomTokenMatch', 2, function ( assert ) {
+   QUnit.test( 'randomTokenMatch', function ( assert ) {
var i, results = { 'true': 0, 'false': 0 };
for ( i = 0; i < 100; i++ ) {
results[ mw.eventLog.randomTokenMatch( 10 ) ]++;
@@ -140,7 +142,7 @@
expected: 'Url exceeds maximum length'
}
}, function ( name, params ) {
-   QUnit.test( name, 1, function ( assert ) {
+   QUnit.test( name, function ( assert ) {
var url = new Array( params.size + 1 ).join( 'x' ),
result = mw.eventLog.checkUrlSize( 
'earthquake', url );
assert.deepEqual( result, params.expected, name );
@@ -165,7 +167,7 @@
.always( assert.async() );
} );
 
-   QUnit.test( 'setDefaults', 1, function ( assert ) {
+   QUnit.test( 'setDefaults', function ( assert ) {
var prepared;
 
mw.eventLog.setDefaults( 'earthquake', {
@@ -213,9 +215,7 @@
invalid: [ -1, {}, undefined ]
}
}, function ( type, cases ) {
-   var asserts = cases.valid.length + cases.invalid.length;
-
-   QUnit.test( type, asserts, function ( assert ) {
+   QUnit.test( type, function ( assert ) {
$.each( cases.valid, function ( index, value ) {
assert.strictEqual( mw.eventLog.isInstanceOf( 
value, type ), true,
JSON.stringify( value ) + ' is a ' + 
type );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7fb5b4172dea8610a37ca85aa135411e06070581
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/EventLogging
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] mediawiki...DonationInterface[master]: Redirect for Safari + multiskins

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

Change subject: Redirect for Safari + multiskins
..


Redirect for Safari + multiskins

Bug: T176913
Change-Id: Ifb16a8897b03de6d10e079fe5d1b03ab748ec2e9
---
M adyen_gateway/AdyenHostedSignature.php
M adyen_gateway/adyen.adapter.php
M adyen_gateway/adyen_gateway.body.php
M adyen_gateway/config/var_map.yaml
M adyen_gateway/forms/js/adyen.js
M gateway_common/DonationData.php
M gateway_common/donation.api.php
M gateway_common/i18n/interface/en.json
M gateway_common/i18n/interface/qqq.json
M gateway_forms/mustache/index.html.mustache
M modules/js/ext.donationInterface.forms.js
M tests/phpunit/DonationInterfaceTestCase.php
M tests/phpunit/TestConfiguration.php
13 files changed, 85 insertions(+), 25 deletions(-)

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



diff --git a/adyen_gateway/AdyenHostedSignature.php 
b/adyen_gateway/AdyenHostedSignature.php
index fbea66a..3ac51bd 100644
--- a/adyen_gateway/AdyenHostedSignature.php
+++ b/adyen_gateway/AdyenHostedSignature.php
@@ -45,9 +45,17 @@
ksort( $values, SORT_STRING );
$merged = array_merge( array_keys( $values ), array_values( 
$values ) );
$joined = implode( ':', $merged );
-   $secret = $adapter->getAccountConfig( 'SharedSecret' );
-   return base64_encode(
-   hash_hmac( 'sha256', $joined, pack( "H*", $secret ), 
true )
-   );
+   $skinCode = $values['skinCode'];
+   if ( array_key_exists( $skinCode, $adapter->getAccountConfig( 
'Skins' ) ) ) {
+   $secret = $adapter->getAccountConfig( 'Skins' 
)[$skinCode]['SharedSecret'];
+   return base64_encode(
+   hash_hmac( 'sha256', $joined, pack( "H*", 
$secret ), true )
+   );
+   } else {
+   throw new ResponseProcessingException(
+   'Skin code not configured',
+   ResponseCodes::BAD_SIGNATURE
+   );
+   }
}
 }
diff --git a/adyen_gateway/adyen.adapter.php b/adyen_gateway/adyen.adapter.php
index 022a2f0..7fae0dd 100644
--- a/adyen_gateway/adyen.adapter.php
+++ b/adyen_gateway/adyen.adapter.php
@@ -39,7 +39,7 @@
function defineAccountInfo() {
$this->accountInfo = array(
'merchantAccount' => $this->account_config[ 
'AccountName' ],
-   'skinCode' => $this->account_config[ 'SkinCode' ],
+   'skins' => $this->account_config[ 'Skins' ],
);
}
 
@@ -51,7 +51,7 @@
'merchantReference' => 'order_id',
'merchantReturnData' => 'return_data',
'pspReference' => 'gateway_txn_id',
-   'skinCode' => 'skin_code',
+   'skinCode' => 'processor_form',
);
}
 
@@ -122,7 +122,6 @@
'merchantAccount' => $this->accountInfo[ 
'merchantAccount' ],
'sessionValidity' => date( 'c', strtotime( '+2 
days' ) ),
'shipBeforeDate' => date( 'Y-M-d', strtotime( 
'+2 days' ) ),
-   'skinCode' => $this->accountInfo[ 'skinCode' ],
// 'shopperLocale' => language _ country
),
'check_required' => true,
@@ -183,6 +182,7 @@
// card entry iframe. If it's 
sorta-fraudy, the listener
// will leave it for manual review. If 
it's hella fraudy
// the listener will cancel it.
+
$this->addRequestData( array( 
'risk_score' => $this->risk_score ) );
 
$requestParams = 
$this->buildRequestParams();
diff --git a/adyen_gateway/adyen_gateway.body.php 
b/adyen_gateway/adyen_gateway.body.php
index ca4b450..33fc62b 100644
--- a/adyen_gateway/adyen_gateway.body.php
+++ b/adyen_gateway/adyen_gateway.body.php
@@ -23,4 +23,14 @@
 class AdyenGateway extends GatewayPage {
 
protected $gatewayIdentifier = AdyenAdapter::IDENTIFIER;
+
+   public function setClientVariables( &$vars ) {
+   parent::setClientVariables( $vars );
+   $skins = $this->adapter->getAccountConfig( 'Skins' );
+   $skinNames = array();
+   foreach ( $skins as $code => $skin ) {
+   $skinNames[$skin['Name']] = $code;
+   }
+   $vars['wgAdyenGatewaySkinNames'] = $skinNames;
+   }
 }
diff --git a/adyen_gateway/config/var_map.yaml 

[MediaWiki-commits] [Gerrit] translatewiki[master]: Rm numerous extensions

2017-10-23 Thread MacFan4000 (Code Review)
MacFan4000 has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386059 )

Change subject: Rm numerous extensions
..

Rm numerous extensions

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


  git pull ssh://gerrit.wikimedia.org:29418/translatewiki 
refs/changes/59/386059/1


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie65131bfee0f4080733a600aaa1708a7348334a4
Gerrit-PatchSet: 1
Gerrit-Project: translatewiki
Gerrit-Branch: master
Gerrit-Owner: MacFan4000 

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


[MediaWiki-commits] [Gerrit] search/MjoLniR[master]: Use absolute_import from __future__

2017-10-23 Thread EBernhardson (Code Review)
EBernhardson has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386060 )

Change subject: Use absolute_import from __future__
..

Use absolute_import from __future__

We were already pulling this in for some specific use cases,
lets use it everywhere. This basically means all imports must
either be fully qualified, or start with a period. This reduces
the ambiguity about what will be imported.

Change-Id: I249d2b8e5741b1eef5b039d1684395a40835a837
---
M mjolnir/__init__.py
M mjolnir/cirrus.py
M mjolnir/cli/data_pipeline.py
M mjolnir/cli/kafka_daemon.py
M mjolnir/cli/training_pipeline.py
M mjolnir/dbn.py
M mjolnir/es_hits.py
M mjolnir/feature_engineering.py
M mjolnir/features.py
M mjolnir/kafka/client.py
M mjolnir/kafka/daemon.py
M mjolnir/metrics.py
M mjolnir/norm_query.py
M mjolnir/sampling.py
M mjolnir/spark/__init__.py
M mjolnir/test/conftest.py
M mjolnir/test/test_dbn.py
M mjolnir/test/test_features.py
M mjolnir/test/test_metrics.py
M mjolnir/test/test_norm_query.py
M mjolnir/test/test_sampling.py
M mjolnir/test/test_spark.py
M mjolnir/test/training/test_hyperopt.py
M mjolnir/test/training/test_tuning.py
M mjolnir/test/training/test_xgboost.py
25 files changed, 25 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/search/MjoLniR 
refs/changes/60/386060/1

diff --git a/mjolnir/__init__.py b/mjolnir/__init__.py
index 1789d54..2fad765 100644
--- a/mjolnir/__init__.py
+++ b/mjolnir/__init__.py
@@ -1,3 +1,4 @@
+from __future__ import absolute_import
 from .about import (__author__, __author_email__, __description__, __name__,
 __url__, __version__)
 
diff --git a/mjolnir/cirrus.py b/mjolnir/cirrus.py
index 8532a86..860991a 100644
--- a/mjolnir/cirrus.py
+++ b/mjolnir/cirrus.py
@@ -3,6 +3,7 @@
 to make those queries against an elasticsearch cluster.
 """
 
+from __future__ import absolute_import
 import random
 import requests
 import urlparse
diff --git a/mjolnir/cli/data_pipeline.py b/mjolnir/cli/data_pipeline.py
index 96ce889..ab86ffe 100644
--- a/mjolnir/cli/data_pipeline.py
+++ b/mjolnir/cli/data_pipeline.py
@@ -10,6 +10,7 @@
 mjolnir/cli/data_pipeline.py
 """
 
+from __future__ import absolute_import
 import argparse
 from collections import OrderedDict
 import logging
diff --git a/mjolnir/cli/kafka_daemon.py b/mjolnir/cli/kafka_daemon.py
index b9240e9..1bbc4e6 100644
--- a/mjolnir/cli/kafka_daemon.py
+++ b/mjolnir/cli/kafka_daemon.py
@@ -4,6 +4,7 @@
 kafka.
 """
 
+from __future__ import absolute_import
 import argparse
 import logging
 import mjolnir.kafka.daemon
diff --git a/mjolnir/cli/training_pipeline.py b/mjolnir/cli/training_pipeline.py
index 7425e87..dc32bd7 100644
--- a/mjolnir/cli/training_pipeline.py
+++ b/mjolnir/cli/training_pipeline.py
@@ -9,6 +9,7 @@
 path/to/training_pipeline.py
 """
 
+from __future__ import absolute_import
 import argparse
 import logging
 import mjolnir.training.xgboost
diff --git a/mjolnir/dbn.py b/mjolnir/dbn.py
index a7ee154..536064e 100644
--- a/mjolnir/dbn.py
+++ b/mjolnir/dbn.py
@@ -3,6 +3,7 @@
 within spark
 """
 
+from __future__ import absolute_import
 from clickmodels.inference import DbnModel
 from clickmodels.input_reader import InputReader
 import json
diff --git a/mjolnir/es_hits.py b/mjolnir/es_hits.py
index 714c8ee..5f673c1 100644
--- a/mjolnir/es_hits.py
+++ b/mjolnir/es_hits.py
@@ -2,6 +2,7 @@
 Collect hit page ids for queries from elasticsearch
 """
 
+from __future__ import absolute_import
 import json
 import mjolnir.cirrus
 import mjolnir.spark
diff --git a/mjolnir/feature_engineering.py b/mjolnir/feature_engineering.py
index 9f86a53..d46ee55 100644
--- a/mjolnir/feature_engineering.py
+++ b/mjolnir/feature_engineering.py
@@ -1,4 +1,5 @@
 """Helpful utilities for feature engineering"""
+from __future__ import absolute_import
 import numpy as np
 import mjolnir.spark
 from pyspark.ml.linalg import Vectors, VectorUDT
diff --git a/mjolnir/features.py b/mjolnir/features.py
index 5cae635..13d069a 100644
--- a/mjolnir/features.py
+++ b/mjolnir/features.py
@@ -2,6 +2,7 @@
 Integration for collecting feature vectors from elasticsearch
 """
 
+from __future__ import absolute_import
 import base64
 from collections import defaultdict, namedtuple, OrderedDict
 import json
diff --git a/mjolnir/kafka/client.py b/mjolnir/kafka/client.py
index 60d4a37..7ef1f9a 100644
--- a/mjolnir/kafka/client.py
+++ b/mjolnir/kafka/client.py
@@ -4,6 +4,7 @@
 collection.
 """
 
+from __future__ import absolute_import
 import json
 import mjolnir.spark
 import mjolnir.kafka
diff --git a/mjolnir/kafka/daemon.py b/mjolnir/kafka/daemon.py
index 78d79de..3f8d698 100644
--- a/mjolnir/kafka/daemon.py
+++ b/mjolnir/kafka/daemon.py
@@ -4,6 +4,7 @@
 side of the network to have access to relforge servers.
 """
 
+from __future__ import absolute_import
 import json
 import kafka
 import kafka.common
diff --git a/mjolnir/metrics.py 

[MediaWiki-commits] [Gerrit] mediawiki/extensions[master]: Rm numorous extensions

2017-10-23 Thread MacFan4000 (Code Review)
MacFan4000 has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386054 )

Change subject: Rm numorous extensions
..

Rm numorous extensions

Bug:T178754
Bug:T178756
Bug:T178758
Bug:T178759
Bug:T178760
Bug:T178761
Bug:T178762
Bug:T178763
Bug:T178764
Bug:T178765
Bug:T178766
Bug:T178767
Bug:T178768
Bug:T178769
Bug:T178770
Bug:T178771
Change-Id: I143d20654916aa112519e634387f9afc85458528
---
M .gitmodules
D CommentPages
D FeedsFromPrivateWikis
D Foxway
D FundraisingChart
D FundraisingEmailUnsubscribe
D ImageLink
D Moodle
D PostEdit
D ReaderFeedback
D RevealEmail
D SecurePasswords
D SharedCssJs
D SimpleAntiSpam
D ThemeDesigner
D TwoFactorAuthentication
D WikiShare
17 files changed, 0 insertions(+), 80 deletions(-)


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

diff --git a/.gitmodules b/.gitmodules
index 8e0399f..41678bf 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -414,10 +414,6 @@
path = Collection
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Collection
branch = .
-[submodule "CommentPages"]
-   path = CommentPages
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/CommentPages
-   branch = .
 [submodule "CommentStreams"]
path = CommentStreams
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/CommentStreams
@@ -806,10 +802,6 @@
path = FeaturedFeeds
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/FeaturedFeeds
branch = .
-[submodule "FeedsFromPrivateWikis"]
-   path = FeedsFromPrivateWikis
-   url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FeedsFromPrivateWikis
-   branch = .
 [submodule "FileAnnotations"]
path = FileAnnotations
url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FileAnnotations
@@ -866,21 +858,9 @@
path = FormelApplet
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/FormelApplet
branch = .
-[submodule "Foxway"]
-   path = Foxway
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Foxway
-   branch = .
 [submodule "FundraiserLandingPage"]
path = FundraiserLandingPage
url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FundraiserLandingPage
-   branch = .
-[submodule "FundraisingChart"]
-   path = FundraisingChart
-   url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FundraisingChart
-   branch = .
-[submodule "FundraisingEmailUnsubscribe"]
-   path = FundraisingEmailUnsubscribe
-   url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/FundraisingEmailUnsubscribe
branch = .
 [submodule "FundraisingTranslateWorkflow"]
path = FundraisingTranslateWorkflow
@@ -1121,10 +1101,6 @@
 [submodule "IframePage"]
path = IframePage
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/IframePage
-   branch = .
-[submodule "ImageLink"]
-   path = ImageLink
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/ImageLink
branch = .
 [submodule "ImageMap"]
path = ImageMap
@@ -1477,10 +1453,6 @@
 [submodule "MolHandler"]
path = MolHandler
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/MolHandler
-   branch = .
-[submodule "Moodle"]
-   path = Moodle
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Moodle
branch = .
 [submodule "Mpdf"]
path = Mpdf
@@ -1942,10 +1914,6 @@
path = Popups
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Popups
branch = .
-[submodule "PostEdit"]
-   path = PostEdit
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/PostEdit
-   branch = .
 [submodule "Premoderation"]
path = Premoderation
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/Premoderation
@@ -2062,10 +2030,6 @@
path = RandomUsersWithAvatars
url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/RandomUsersWithAvatars
branch = .
-[submodule "ReaderFeedback"]
-   path = ReaderFeedback
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/ReaderFeedback
-   branch = .
 [submodule "ReadingLists"]
path = ReadingLists
url = https://gerrit.wikimedia.org/r/mediawiki/extensions/ReadingLists
@@ -2125,10 +2089,6 @@
 [submodule "RestBaseUpdateJobs"]
path = RestBaseUpdateJobs
url = 
https://gerrit.wikimedia.org/r/mediawiki/extensions/RestBaseUpdateJobs
-   branch = .
-[submodule "RevealEmail"]
-   path = RevealEmail
-   url = https://gerrit.wikimedia.org/r/mediawiki/extensions/RevealEmail
branch = .
 [submodule "RevisionCommentSupplement"]
path = RevisionCommentSupplement
@@ -2197,10 +2157,6 @@
 [submodule "SecureHTML"]
path = SecureHTML
url = 

[MediaWiki-commits] [Gerrit] apps...wikipedia[master]: Design tweaks in theme chooser dialog.

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

Change subject: Design tweaks in theme chooser dialog.
..


Design tweaks in theme chooser dialog.

Bug: T173407
Change-Id: I402f1c18e20a3d89701082a74de0632c75c57edf
---
M app/src/main/java/org/wikipedia/theme/ThemeChooserDialog.java
M app/src/main/java/org/wikipedia/views/DiscreteSeekBar.java
M app/src/main/res/drawable/ic_seek_bar_tick.xml
M app/src/main/res/layout/dialog_theme_chooser.xml
4 files changed, 24 insertions(+), 10 deletions(-)

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



diff --git a/app/src/main/java/org/wikipedia/theme/ThemeChooserDialog.java 
b/app/src/main/java/org/wikipedia/theme/ThemeChooserDialog.java
index 03cda02..385d94a 100644
--- a/app/src/main/java/org/wikipedia/theme/ThemeChooserDialog.java
+++ b/app/src/main/java/org/wikipedia/theme/ThemeChooserDialog.java
@@ -2,6 +2,7 @@
 
 import android.os.Bundle;
 import android.support.annotation.Nullable;
+import android.support.v4.content.ContextCompat;
 import android.support.v7.widget.SwitchCompat;
 import android.view.LayoutInflater;
 import android.view.View;
@@ -21,6 +22,7 @@
 import org.wikipedia.settings.Prefs;
 import org.wikipedia.util.DimenUtil;
 import org.wikipedia.util.FeedbackUtil;
+import org.wikipedia.util.ResourceUtil;
 import org.wikipedia.views.DiscreteSeekBar;
 
 import butterknife.BindView;
@@ -159,6 +161,9 @@
 private void updateDimImagesSwitch() {
 dimImagesSwitch.setChecked(Prefs.shouldDimDarkModeImages());
 dimImagesSwitch.setEnabled(app.getCurrentTheme() == Theme.DARK);
+dimImagesSwitch.setTextColor(dimImagesSwitch.isEnabled()
+? ResourceUtil.getThemedColor(getContext(), 
R.attr.section_title_color)
+: ContextCompat.getColor(getContext(), R.color.black26));
 }
 
 private final class ThemeButtonListener implements View.OnClickListener {
diff --git a/app/src/main/java/org/wikipedia/views/DiscreteSeekBar.java 
b/app/src/main/java/org/wikipedia/views/DiscreteSeekBar.java
index 5101d8f..b620e01 100644
--- a/app/src/main/java/org/wikipedia/views/DiscreteSeekBar.java
+++ b/app/src/main/java/org/wikipedia/views/DiscreteSeekBar.java
@@ -6,6 +6,7 @@
 import android.graphics.Canvas;
 import android.graphics.drawable.Drawable;
 import android.support.annotation.AttrRes;
+import android.support.annotation.NonNull;
 import android.support.annotation.Nullable;
 import android.support.v4.content.ContextCompat;
 import android.util.AttributeSet;
@@ -62,11 +63,18 @@
 
 @Override
 protected synchronized void onDraw(Canvas canvas) {
-drawTickMarks(canvas);
-super.onDraw(canvas);
+int value = getValue();
+if (value >= 0) {
+drawTickMarks(canvas, true, false);
+super.onDraw(canvas);
+drawTickMarks(canvas, false, true);
+} else {
+super.onDraw(canvas);
+drawTickMarks(canvas, true, true);
+}
 }
 
-void drawTickMarks(Canvas canvas) {
+void drawTickMarks(@NonNull Canvas canvas, boolean drawCenter, boolean 
drawOther) {
 int max = getMax() + min;
 int value = getValue();
 if (tickDrawable != null) {
@@ -83,10 +91,10 @@
 canvas.save();
 canvas.translate((float) getPaddingLeft(), (float) (getHeight() / 2));
 for (int i = min; i <= max; ++i) {
-if (tickDrawable != null && i > value) {
+if (drawOther && tickDrawable != null && i > value) {
 tickDrawable.draw(canvas);
 }
-if (i == 0 && centerDrawable != null) {
+if (drawCenter && i == 0 && centerDrawable != null) {
 centerDrawable.draw(canvas);
 }
 canvas.translate(tickSpacing, 0.0f);
diff --git a/app/src/main/res/drawable/ic_seek_bar_tick.xml 
b/app/src/main/res/drawable/ic_seek_bar_tick.xml
index 4ddc38d..5483148 100644
--- a/app/src/main/res/drawable/ic_seek_bar_tick.xml
+++ b/app/src/main/res/drawable/ic_seek_bar_tick.xml
@@ -6,5 +6,5 @@
 
+android:fillColor="?attr/chart_shade1"/>
 
diff --git a/app/src/main/res/layout/dialog_theme_chooser.xml 
b/app/src/main/res/layout/dialog_theme_chooser.xml
index f08bc8d..e3d0ec6 100644
--- a/app/src/main/res/layout/dialog_theme_chooser.xml
+++ b/app/src/main/res/layout/dialog_theme_chooser.xml
@@ -26,8 +26,8 @@
 
 
@@ -36,7 +36,6 @@
 android:id="@+id/text_size_percent"
 android:layout_width="match_parent"
 android:layout_height="wrap_content"
-android:layout_marginTop="12dp"
 android:gravity="center"
 android:textSize="16sp"
 android:textColor="?attr/secondary_text_color"
@@ -45,7 +44,7 @@
 
+android:layout_marginTop="4dp">
 
 
 

-- 
To view, visit 

[MediaWiki-commits] [Gerrit] integration/config[master]: castor in a container

2017-10-23 Thread Hashar (Code Review)
Hashar has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386053 )

Change subject: castor in a container
..

castor in a container

Poor animal :o(

Change-Id: I44d188430cbd8a9c6528ab0fba8bce560870ced9
---
A dockerfiles/castor/Dockerfile
A dockerfiles/castor/example-run.sh
A dockerfiles/castor/prebuild.sh
A dockerfiles/castor/run.bash
M jjb/castor.yaml
5 files changed, 78 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/53/386053/1

diff --git a/dockerfiles/castor/Dockerfile b/dockerfiles/castor/Dockerfile
new file mode 100644
index 000..a436629
--- /dev/null
+++ b/dockerfiles/castor/Dockerfile
@@ -0,0 +1,13 @@
+FROM docker-registry.wikimedia.org/wikimedia-stretch:latest
+
+RUN apt-get update \
+&& DEBIAN_FRONTEND=noninteractive apt-get install --yes \
+openssh-client \
+rsync \
+&& rm -rf /var/lib/apt/lists/*
+
+COPY src/ /castor
+COPY run.bash /run.bash
+
+USER nobody
+ENTRYPOINT ["/run.bash"]
diff --git a/dockerfiles/castor/example-run.sh 
b/dockerfiles/castor/example-run.sh
new file mode 100755
index 000..3b5775c
--- /dev/null
+++ b/dockerfiles/castor/example-run.sh
@@ -0,0 +1,26 @@
+#!/bin/bash
+
+set -e
+
+function assert() {
+expected=$1
+shift
+
+exec 3>&1
+actual=$("$@"|tee >(cat - >&3))
+
+if [ "$expected" = "$actual" ]; then
+echo "[OK] $expected"
+else
+echo "[FAILED] $expected"
+colordiff -u <(echo "$expected") <(echo "$actual")
+fi
+}
+
+assert $'Defined: CASTOR_NAMESPACE="mediawiki-core/master/dosomething"\r' 
docker run \
+--rm --tty \
+--env ZUUL_PROJECT=mediawiki/core \
+--env ZUUL_BRANCH=master \
+--env JOB_NAME=dosomething \
+wmfreleng/castor:latest \
+config
diff --git a/dockerfiles/castor/prebuild.sh b/dockerfiles/castor/prebuild.sh
new file mode 100755
index 000..badc5c8
--- /dev/null
+++ b/dockerfiles/castor/prebuild.sh
@@ -0,0 +1,6 @@
+#!/bin/bash
+
+set -e
+
+mkdir -p "$(dirname "$0")"/src
+cp -vf "$(dirname "$0")"/../../jjb/castor*.bash "$(dirname "$0")"/src
diff --git a/dockerfiles/castor/run.bash b/dockerfiles/castor/run.bash
new file mode 100755
index 000..c9c26bd
--- /dev/null
+++ b/dockerfiles/castor/run.bash
@@ -0,0 +1,23 @@
+#!/bin/bash
+set -e
+
+case ${1:-missing} in
+config)
+source castor/castor-define-namespace.bash
+;;
+save)
+source castor/castor-define-namespace.bash
+source castor/castor-save-sync.bash
+;;
+load)
+source castor/castor-define-namespace.bash
+source castor/castor-load-sync.bash
+;;
+*)
+echo "USAGE:"
+echo "  castor config"
+echo "  castor save"
+echo "  castor load"
+exit 1
+;;
+esac
diff --git a/jjb/castor.yaml b/jjb/castor.yaml
index c1ed0fb..ca98a79 100644
--- a/jjb/castor.yaml
+++ b/jjb/castor.yaml
@@ -46,6 +46,16 @@
 - castor-define-namespace.bash
 - castor-load-sync.bash
 
+- builder:
+name: docker-castor-load
+builders:
+- shell: |
+/usr/bin/env > .env
+docker run -rm --tty
+--env-file .env \
+--volume "$(WORKSPACE)/cache":/cache \
+wmfreleng/castor:latest \
+load
 
 # Job triggered on the central repository instance
 #

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

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

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


[MediaWiki-commits] [Gerrit] mediawiki...UserExport[master]: Remove my authorship

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

Change subject: Remove my authorship
..


Remove my authorship

No need to mention my name for simple changes.

Change-Id: Ie8022739c8dff581495720197a252c3700369cb1
---
M CHANGELOG.md
M UserExport.php
2 files changed, 2 insertions(+), 3 deletions(-)

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



diff --git a/CHANGELOG.md b/CHANGELOG.md
index e0ff01c..8b98bc0 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -14,8 +14,8 @@
 * Added support for MW 1.26+
 * Removed support for < MW 1.23.0
 * Removed I18n shim for php message files (by Kghbln)
-* Migrated registration of special pages to `SpecialPage::getGroupName` (by 
Umherirrender)
-* Fixed typos for special pages aliases (by Umherirrender)
+* Migrated registration of special pages to `SpecialPage::getGroupName`
+* Fixed typos for special pages aliases
 * Updated file documentation (by Kghbln)
 * Updated README (by Kgbhln)
 
diff --git a/UserExport.php b/UserExport.php
index f21f3f4..822e621 100644
--- a/UserExport.php
+++ b/UserExport.php
@@ -19,7 +19,6 @@
  * @author Karsten Hoffmeyer (Kghbln) 
  * @author Sam Reed (Reedy)
  * @author Samantha Nguyen (SamanthaNguyen)
- * @author Umherirrender (Umherirrender)
  *
  * @license https://www.gnu.org/licenses/gpl-2.0 GNU General Public License 
2.0 or later
  */

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie8022739c8dff581495720197a252c3700369cb1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/UserExport
Gerrit-Branch: master
Gerrit-Owner: Umherirrender 
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] mediawiki...UserExport[master]: Remove my authorship

2017-10-23 Thread Umherirrender (Code Review)
Umherirrender has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386052 )

Change subject: Remove my authorship
..

Remove my authorship

No need to mention my name for simple changes.

Change-Id: Ie8022739c8dff581495720197a252c3700369cb1
---
M CHANGELOG.md
M UserExport.php
2 files changed, 2 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/UserExport 
refs/changes/52/386052/1

diff --git a/CHANGELOG.md b/CHANGELOG.md
index e0ff01c..8b98bc0 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -14,8 +14,8 @@
 * Added support for MW 1.26+
 * Removed support for < MW 1.23.0
 * Removed I18n shim for php message files (by Kghbln)
-* Migrated registration of special pages to `SpecialPage::getGroupName` (by 
Umherirrender)
-* Fixed typos for special pages aliases (by Umherirrender)
+* Migrated registration of special pages to `SpecialPage::getGroupName`
+* Fixed typos for special pages aliases
 * Updated file documentation (by Kghbln)
 * Updated README (by Kgbhln)
 
diff --git a/UserExport.php b/UserExport.php
index f21f3f4..822e621 100644
--- a/UserExport.php
+++ b/UserExport.php
@@ -19,7 +19,6 @@
  * @author Karsten Hoffmeyer (Kghbln) 
  * @author Sam Reed (Reedy)
  * @author Samantha Nguyen (SamanthaNguyen)
- * @author Umherirrender (Umherirrender)
  *
  * @license https://www.gnu.org/licenses/gpl-2.0 GNU General Public License 
2.0 or later
  */

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie8022739c8dff581495720197a252c3700369cb1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/UserExport
Gerrit-Branch: master
Gerrit-Owner: Umherirrender 

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


[MediaWiki-commits] [Gerrit] mediawiki...deploy[master]: Update src to 6fd67276 for deb v0.8.0 pkg + update maintaine...

2017-10-23 Thread Subramanya Sastry (Code Review)
Subramanya Sastry has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386051 )

Change subject: Update src to 6fd67276 for deb v0.8.0 pkg + update maintainer 
info
..

Update src to 6fd67276 for deb v0.8.0 pkg + update maintainer info

Change-Id: I08a5e5975b6d8dc6afdd6442d05cc164f0d950c6
---
M debian/control
M src
2 files changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid/deploy 
refs/changes/51/386051/1

diff --git a/debian/control b/debian/control
index 39b604b..2fe8e2d 100644
--- a/debian/control
+++ b/debian/control
@@ -1,7 +1,7 @@
 Source: parsoid
 Section: web
 Priority: optional
-Maintainer: Gabriel Wicke 
+Maintainer: Parsing Team, Wikimedia Foundation 
 Build-Depends: debhelper (>= 8.0.0)
 Standards-Version: 3.9.4
 Homepage: http://www.mediawiki.org/wiki/Parsoid
diff --git a/src b/src
index 1cefef1..6fd6727 16
--- a/src
+++ b/src
@@ -1 +1 @@
-Subproject commit 1cefef127c51854952f8035ec4b17238a1eda96e
+Subproject commit 6fd67276f629344485146820514111a54fab41b5

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I08a5e5975b6d8dc6afdd6442d05cc164f0d950c6
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/parsoid/deploy
Gerrit-Branch: master
Gerrit-Owner: Subramanya Sastry 

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


[MediaWiki-commits] [Gerrit] mediawiki...parsoid[master]: Consolidate separator handling when emitting text

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

Change subject: Consolidate separator handling when emitting text
..


Consolidate separator handling when emitting text

Change-Id: If83d9b88c5e3e6947ba82266e479850e94b88822
---
M lib/html2wt/WikitextSerializer.js
1 file changed, 39 insertions(+), 52 deletions(-)

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



diff --git a/lib/html2wt/WikitextSerializer.js 
b/lib/html2wt/WikitextSerializer.js
index 95ad30d..6a4bfe7 100644
--- a/lib/html2wt/WikitextSerializer.js
+++ b/lib/html2wt/WikitextSerializer.js
@@ -838,10 +838,9 @@
 };
 
 /**
- * Serialize the content of a text node
+ * Consolidate separator handling when emitting text
  */
-WSP._serializeTextNode = Promise.method(function(node) {
-   var res = node.nodeValue;
+WSP._serializeText = function(res, node, omitEscaping) {
var state = this.state;
 
// Deal with trailing separator-like text (at least 1 newline and other 
whitespace)
@@ -855,32 +854,38 @@
state.setSep((state.sep.src || '') + match[0]);
res = res.substring(match[0].length);
}
-
-   var doubleNewlineMatch = 
res.match(this.separatorREs.doubleNewlineRE_G);
-   var doubleNewlineCount = doubleNewlineMatch && 
doubleNewlineMatch.length || 0;
-
-   // Don't strip two newlines for wikitext like this:
-   // foo
-   //
-   // bar
-   // The PHP parser won't create paragraphs on lines that also 
contain
-   // block-level tags.
-   if (!state.inHTMLPre &&
-   // These conditions are at least safe, given the above 
constraint
-   (!DU.allChildrenAreText(node.parentNode) || 
doubleNewlineCount > 1)) {
-   // Strip more than one consecutive newline
-   res = res.replace(this.separatorREs.doubleNewlineRE_G, 
'\n');
-   }
}
 
-   // Always escape entities
-   res = Util.escapeEntities(res);
+   if (omitEscaping) {
+   state.emitChunk(res, node);
+   } else {
+   if (!state.inIndentPre) {
+   var doubleNewlineMatch = 
res.match(this.separatorREs.doubleNewlineRE_G);
+   var doubleNewlineCount = doubleNewlineMatch && 
doubleNewlineMatch.length || 0;
 
-   // If not in pre context, escape wikitext
-   // XXX refactor: Handle this with escape handlers instead!
-   state.escapeText = (state.onSOL || !state.currNodeUnmodified) && 
!state.inHTMLPre;
-   state.emitChunk(res, node);
-   state.escapeText = false;
+   // Don't strip two newlines for wikitext like this:
+   // foo
+   //
+   // bar
+   // The PHP parser won't create paragraphs on lines that 
also contain
+   // block-level tags.
+   if (!state.inHTMLPre &&
+   // These conditions are at least safe, given 
the above constraint
+   (!DU.allChildrenAreText(node.parentNode) || 
doubleNewlineCount > 1)) {
+   // Strip more than one consecutive newline
+   res = 
res.replace(this.separatorREs.doubleNewlineRE_G, '\n');
+   }
+   }
+
+   // Always escape entities
+   res = Util.escapeEntities(res);
+
+   // If not in pre context, escape wikitext
+   // XXX refactor: Handle this with escape handlers instead!
+   state.escapeText = (state.onSOL || !state.currNodeUnmodified) 
&& !state.inHTMLPre;
+   state.emitChunk(res, node);
+   state.escapeText = false;
+   }
 
// Move trailing newlines into the next separator
if (newSepMatch) {
@@ -891,38 +896,20 @@
/* SSS FIXME: what are we doing with the stripped NLs?? 
*/
}
}
+};
+
+/**
+ * Serialize the content of a text node
+ */
+WSP._serializeTextNode = Promise.method(function(node) {
+   this._serializeText(node.nodeValue, node, false);
 });
 
 /**
  * Emit non-separator wikitext that does not need to be escaped
  */
 WSP.emitWikitext = function(res, node) {
-   var state = this.state;
-
-   // Deal with trailing separator-like text (at least 1 newline and other 
whitespace)
-   var newSepMatch = res.match(this.separatorREs.sepSuffixWithNlsRE);
-   res = res.replace(this.separatorREs.sepSuffixWithNlsRE, '');
-
-   if (!state.inIndentPre) {
-   // Strip leading newlines and other whitespace
-   var match = 

[MediaWiki-commits] [Gerrit] mediawiki...PipeEscape[master]: Provide license file and add file docu

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

Change subject: Provide license file and add file docu
..


Provide license file and add file docu

Bug: T123943
Change-Id: I287bd3ad8721b193174dd6b6b6d7d4039dcdccf0
---
A COPYING
M PipeEscape.php
2 files changed, 350 insertions(+), 5 deletions(-)

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



diff --git a/COPYING b/COPYING
new file mode 100644
index 000..d159169
--- /dev/null
+++ b/COPYING
@@ -0,0 +1,339 @@
+GNU GENERAL PUBLIC LICENSE
+   Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+Preamble
+
+  The licenses for most software are designed to take away your
+freedom to share and change it.  By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users.  This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it.  (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.)  You can apply it to
+your programs, too.
+
+  When we speak of free software, we are referring to freedom, not
+price.  Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+  To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+  For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have.  You must make sure that they, too, receive or can get the
+source code.  And you must show them these terms so they know their
+rights.
+
+  We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+  Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software.  If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+  Finally, any free program is threatened constantly by software
+patents.  We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary.  To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.
+
+GNU GENERAL PUBLIC LICENSE
+   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+  0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License.  The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language.  (Hereinafter, translation is included without limitation in
+the term "modification".)  Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope.  The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+  1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that 

[MediaWiki-commits] [Gerrit] labs/private[master]: Gerrit: Replace certificates with tokens for its-phabricator

2017-10-23 Thread Chad (Code Review)
Chad has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/384902 )

Change subject: Gerrit: Replace certificates with tokens for its-phabricator
..


Gerrit: Replace certificates with tokens for its-phabricator

Requires chad's +1 and for

https://gerrit-review.googlesource.com/?polygerrit=0#/c/plugins/its-phabricator/+/133790/

to be merged.

Bug: T178385
Change-Id: I5f3c9e76845a5582bf4aed293195c26fd217d51c
---
M modules/passwords/manifests/init.pp
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/modules/passwords/manifests/init.pp 
b/modules/passwords/manifests/init.pp
index 77b3e24..db1b0a0 100644
--- a/modules/passwords/manifests/init.pp
+++ b/modules/passwords/manifests/init.pp
@@ -152,7 +152,7 @@
 $gerrit_pass = ''
 $gerrit_db_pass = 'l5uCkoYX+zYtH'
 $gerrit_email_key = 'AsL1PruNcpXuSAIjcCLqT'
-$gerrit_phab_cert = 'UnknownValue'
+$gerrit_phab_token = 'cli-unknownvalue'
 }
 
 class passwords::civi {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I5f3c9e76845a5582bf4aed293195c26fd217d51c
Gerrit-PatchSet: 4
Gerrit-Project: labs/private
Gerrit-Branch: master
Gerrit-Owner: Paladox 
Gerrit-Reviewer: 20after4 
Gerrit-Reviewer: Chad 

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


[MediaWiki-commits] [Gerrit] VisualEditor/VisualEditor[master]: build: Bump unit test-related devDependencies

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386050 )

Change subject: build: Bump unit test-related devDependencies
..

build: Bump unit test-related devDependencies

 karma   1.1.2  →  1.7.1
 karma-chrome-launcher   1.0.1  →  2.2.0
 karma-firefox-launcher  1.0.0  →  1.0.1
 karma-mocha-reporter2.2.3  →  2.2.5

Change-Id: I7498d7a246cdce99d506abc8d70d435c6218e666
---
M package.json
1 file changed, 4 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/50/386050/1

diff --git a/package.json b/package.json
index b48b65b..1870110 100644
--- a/package.json
+++ b/package.json
@@ -35,11 +35,11 @@
 "grunt-karma": "2.0.0",
 "grunt-stylelint": "0.9.0",
 "grunt-tyops": "0.1.0",
-"karma": "1.1.2",
-"karma-chrome-launcher": "1.0.1",
-"karma-firefox-launcher": "1.0.0",
+"karma": "1.7.1",
+"karma-chrome-launcher": "2.2.0",
+"karma-firefox-launcher": "1.0.1",
 "karma-coverage": "1.1.1",
-"karma-mocha-reporter": "2.2.3",
+"karma-mocha-reporter": "2.2.5",
 "karma-qunit": "1.2.1",
 "qunitjs": "2.4.1",
 "stylelint": "7.8.0",

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7498d7a246cdce99d506abc8d70d435c6218e666
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/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] VisualEditor/VisualEditor[master]: build: Bump various devDependencies to latest

2017-10-23 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/386049 )

Change subject: build: Bump various devDependencies to latest
..

build: Bump various devDependencies to latest

 grunt-eslint20.0.0  →  20.1.0
 grunt-stylelint  0.8.0  →   0.9.0
 qunitjs  2.4.0  →   2.4.1

Change-Id: I81906c25f90a651f09d19ea9e8ce25c7029196d0
---
M package.json
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/49/386049/1

diff --git a/package.json b/package.json
index 710379c..b48b65b 100644
--- a/package.json
+++ b/package.json
@@ -30,10 +30,10 @@
 "grunt-contrib-watch": "1.0.0",
 "grunt-css-url-embed": "1.10.0",
 "grunt-cssjanus": "0.4.0",
-"grunt-eslint": "20.0.0",
+"grunt-eslint": "20.1.0",
 "grunt-jsonlint": "1.1.0",
 "grunt-karma": "2.0.0",
-"grunt-stylelint": "0.8.0",
+"grunt-stylelint": "0.9.0",
 "grunt-tyops": "0.1.0",
 "karma": "1.1.2",
 "karma-chrome-launcher": "1.0.1",
@@ -41,7 +41,7 @@
 "karma-coverage": "1.1.1",
 "karma-mocha-reporter": "2.2.3",
 "karma-qunit": "1.2.1",
-"qunitjs": "2.4.0",
+"qunitjs": "2.4.1",
 "stylelint": "7.8.0",
 "stylelint-config-wikimedia": "0.4.1"
   }

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

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

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


  1   2   3   4   >