[MediaWiki-commits] [Gerrit] Update dependencies - change (mediawiki...deploy)

2015-02-20 Thread GWicke (Code Review)
GWicke has submitted this change and it was merged.

Change subject: Update dependencies
..


Update dependencies

Change-Id: I09769e5641fdfeffcdb022f2e2bca0b5ef88b46b
---
M 
node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
M node_modules/istanbul/node_modules/async/package.json
M node_modules/istanbul/node_modules/mkdirp/package.json
M node_modules/mocha/node_modules/mkdirp/package.json
M node_modules/restbase-mod-table-cassandra/node_modules/async/package.json
M 
node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
M node_modules/service-runner/lib/heapwatch.js
M node_modules/service-runner/package.json
8 files changed, 16 insertions(+), 14 deletions(-)

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



diff --git 
a/node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
 
b/node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
index 754a114..3d69f4f 100644
--- 
a/node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
+++ 
b/node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
@@ -32,7 +32,7 @@
 "shasum": "b17d08d326b4423e568eff719f91b0b1cbdf69f1",
 "tarball": "http://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz";
   },
-  "_from": "inherits@2",
+  "_from": "inherits@~2.0.1",
   "_npmVersion": "1.3.8",
   "_npmUser": {
 "name": "isaacs",
diff --git a/node_modules/istanbul/node_modules/async/package.json 
b/node_modules/istanbul/node_modules/async/package.json
index bdbe740..9d15cd7 100644
--- a/node_modules/istanbul/node_modules/async/package.json
+++ b/node_modules/istanbul/node_modules/async/package.json
@@ -41,7 +41,7 @@
 "shasum": "ac3613b1da9bed1b47510bb4651b8931e47146c7",
 "tarball": "http://registry.npmjs.org/async/-/async-0.9.0.tgz";
   },
-  "_from": "async@~0.9.0",
+  "_from": "async@0.9.x",
   "_npmVersion": "1.4.3",
   "_npmUser": {
 "name": "caolan",
diff --git a/node_modules/istanbul/node_modules/mkdirp/package.json 
b/node_modules/istanbul/node_modules/mkdirp/package.json
index a6de8f3..b7fe466 100644
--- a/node_modules/istanbul/node_modules/mkdirp/package.json
+++ b/node_modules/istanbul/node_modules/mkdirp/package.json
@@ -39,7 +39,7 @@
 "shasum": "1d73076a6df986cd9344e15e71fcc05a4c9abf12",
 "tarball": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz";
   },
-  "_from": "mkdirp@~0.5.0",
+  "_from": "mkdirp@0.5.x",
   "_npmVersion": "1.4.3",
   "_npmUser": {
 "name": "substack",
diff --git a/node_modules/mocha/node_modules/mkdirp/package.json 
b/node_modules/mocha/node_modules/mkdirp/package.json
index a6de8f3..b7fe466 100644
--- a/node_modules/mocha/node_modules/mkdirp/package.json
+++ b/node_modules/mocha/node_modules/mkdirp/package.json
@@ -39,7 +39,7 @@
 "shasum": "1d73076a6df986cd9344e15e71fcc05a4c9abf12",
 "tarball": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz";
   },
-  "_from": "mkdirp@~0.5.0",
+  "_from": "mkdirp@0.5.x",
   "_npmVersion": "1.4.3",
   "_npmUser": {
 "name": "substack",
diff --git 
a/node_modules/restbase-mod-table-cassandra/node_modules/async/package.json 
b/node_modules/restbase-mod-table-cassandra/node_modules/async/package.json
index bdbe740..9d15cd7 100644
--- a/node_modules/restbase-mod-table-cassandra/node_modules/async/package.json
+++ b/node_modules/restbase-mod-table-cassandra/node_modules/async/package.json
@@ -41,7 +41,7 @@
 "shasum": "ac3613b1da9bed1b47510bb4651b8931e47146c7",
 "tarball": "http://registry.npmjs.org/async/-/async-0.9.0.tgz";
   },
-  "_from": "async@~0.9.0",
+  "_from": "async@0.9.x",
   "_npmVersion": "1.4.3",
   "_npmUser": {
 "name": "caolan",
diff --git 
a/node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
 
b/node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
index be2cfc9..2474729 100644
--- 
a/node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
+++ 
b/node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
@@ -31,7 +31,7 @@
 "shasum": "d82388ae9c960becbea0c73bb9eb79b6c6ce9aeb",
 "tarball": "http://registry.npmjs.org/lru-cache/-/lru-cache-2.5.0.tgz";
   },
-  "_from": "lru-cache@^2.5.0",
+  "_from": "lru-cache@2",
   "_npmVersion": "1.3.15",
   "_npmUser": {
 "name": "isaacs",
diff --git a/node_modules/service-runner/lib/heapwatch.js 
b/node_modules/service-runner/lib/heapwatch.js
index 533b828..58a276d 100644
--- a/node_modules/service-runner/lib/heapwatch.js
+++ b/node_modules/service-runner/lib/heapwatch.js
@@ -14,11 +14,13 @@
 HeapWatch.prototype.watch = function() {
 var usage = process.memoryUsage();
 
-// Report memory stats to statsd
+// Report memory stats to statsd.

[MediaWiki-commits] [Gerrit] Update dependencies - change (mediawiki...deploy)

2015-02-20 Thread GWicke (Code Review)
GWicke has uploaded a new change for review.

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

Change subject: Update dependencies
..

Update dependencies

Change-Id: I09769e5641fdfeffcdb022f2e2bca0b5ef88b46b
---
M 
node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
M node_modules/istanbul/node_modules/async/package.json
M node_modules/istanbul/node_modules/mkdirp/package.json
M node_modules/mocha/node_modules/mkdirp/package.json
M node_modules/restbase-mod-table-cassandra/node_modules/async/package.json
M 
node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
M node_modules/service-runner/lib/heapwatch.js
M node_modules/service-runner/package.json
8 files changed, 16 insertions(+), 14 deletions(-)


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

diff --git 
a/node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
 
b/node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
index 754a114..3d69f4f 100644
--- 
a/node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
+++ 
b/node_modules/busboy/node_modules/readable-stream/node_modules/inherits/package.json
@@ -32,7 +32,7 @@
 "shasum": "b17d08d326b4423e568eff719f91b0b1cbdf69f1",
 "tarball": "http://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz";
   },
-  "_from": "inherits@2",
+  "_from": "inherits@~2.0.1",
   "_npmVersion": "1.3.8",
   "_npmUser": {
 "name": "isaacs",
diff --git a/node_modules/istanbul/node_modules/async/package.json 
b/node_modules/istanbul/node_modules/async/package.json
index bdbe740..9d15cd7 100644
--- a/node_modules/istanbul/node_modules/async/package.json
+++ b/node_modules/istanbul/node_modules/async/package.json
@@ -41,7 +41,7 @@
 "shasum": "ac3613b1da9bed1b47510bb4651b8931e47146c7",
 "tarball": "http://registry.npmjs.org/async/-/async-0.9.0.tgz";
   },
-  "_from": "async@~0.9.0",
+  "_from": "async@0.9.x",
   "_npmVersion": "1.4.3",
   "_npmUser": {
 "name": "caolan",
diff --git a/node_modules/istanbul/node_modules/mkdirp/package.json 
b/node_modules/istanbul/node_modules/mkdirp/package.json
index a6de8f3..b7fe466 100644
--- a/node_modules/istanbul/node_modules/mkdirp/package.json
+++ b/node_modules/istanbul/node_modules/mkdirp/package.json
@@ -39,7 +39,7 @@
 "shasum": "1d73076a6df986cd9344e15e71fcc05a4c9abf12",
 "tarball": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz";
   },
-  "_from": "mkdirp@~0.5.0",
+  "_from": "mkdirp@0.5.x",
   "_npmVersion": "1.4.3",
   "_npmUser": {
 "name": "substack",
diff --git a/node_modules/mocha/node_modules/mkdirp/package.json 
b/node_modules/mocha/node_modules/mkdirp/package.json
index a6de8f3..b7fe466 100644
--- a/node_modules/mocha/node_modules/mkdirp/package.json
+++ b/node_modules/mocha/node_modules/mkdirp/package.json
@@ -39,7 +39,7 @@
 "shasum": "1d73076a6df986cd9344e15e71fcc05a4c9abf12",
 "tarball": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz";
   },
-  "_from": "mkdirp@~0.5.0",
+  "_from": "mkdirp@0.5.x",
   "_npmVersion": "1.4.3",
   "_npmUser": {
 "name": "substack",
diff --git 
a/node_modules/restbase-mod-table-cassandra/node_modules/async/package.json 
b/node_modules/restbase-mod-table-cassandra/node_modules/async/package.json
index bdbe740..9d15cd7 100644
--- a/node_modules/restbase-mod-table-cassandra/node_modules/async/package.json
+++ b/node_modules/restbase-mod-table-cassandra/node_modules/async/package.json
@@ -41,7 +41,7 @@
 "shasum": "ac3613b1da9bed1b47510bb4651b8931e47146c7",
 "tarball": "http://registry.npmjs.org/async/-/async-0.9.0.tgz";
   },
-  "_from": "async@~0.9.0",
+  "_from": "async@0.9.x",
   "_npmVersion": "1.4.3",
   "_npmUser": {
 "name": "caolan",
diff --git 
a/node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
 
b/node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
index be2cfc9..2474729 100644
--- 
a/node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
+++ 
b/node_modules/restbase-mod-table-cassandra/node_modules/restify/node_modules/lru-cache/package.json
@@ -31,7 +31,7 @@
 "shasum": "d82388ae9c960becbea0c73bb9eb79b6c6ce9aeb",
 "tarball": "http://registry.npmjs.org/lru-cache/-/lru-cache-2.5.0.tgz";
   },
-  "_from": "lru-cache@^2.5.0",
+  "_from": "lru-cache@2",
   "_npmVersion": "1.3.15",
   "_npmUser": {
 "name": "isaacs",
diff --git a/node_modules/service-runner/lib/heapwatch.js 
b/node_modules/service-runner/lib/heapwatch.js
index 533b828..58a276d 100644
--- a/node_modules/service-runner/lib/heapwatch.js
+++ b/node_modules/service-runner/lib/heapwatch.js
@@ -14,11 +14,13 @@
 HeapWatch.prototype.watch = function() {
 var usage = process.memoryUsage();

[MediaWiki-commits] [Gerrit] exec(line) of other packages is unexpected... - change (pywikibot/core)

2015-02-20 Thread Eranroz (Code Review)
Eranroz has uploaded a new change for review.

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

Change subject: exec(line) of other packages is unexpected...
..

exec(line) of other packages is unexpected...

Change-Id: I9b4b9334c5af52cd2cf869b6aac9a62c66578013
---
M pywikibot/version.py
1 file changed, 4 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/66/192066/1

diff --git a/pywikibot/version.py b/pywikibot/version.py
index 723a221..7f06fa1 100644
--- a/pywikibot/version.py
+++ b/pywikibot/version.py
@@ -274,7 +274,10 @@
 with codecs.open(fn, 'r', "utf-8") as f:
 for line in f.readlines():
 if line.find('__version__') == 0:
-exec(line)
+try:
+exec(line)
+except:
+pass
 break
 stat = os.stat(fn)
 mtime = datetime.datetime.fromtimestamp(stat.st_mtime).isoformat(' ')

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

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

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


[MediaWiki-commits] [Gerrit] Update Scribunto tests after I562e437e - change (mediawiki...Scribunto)

2015-02-20 Thread Polybuildr (Code Review)
Polybuildr has uploaded a new change for review.

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

Change subject: Update Scribunto tests after I562e437e
..

Update Scribunto tests after I562e437e

The parser's output was changed in I562e437e to add clickable anchors
for section headers which made Scribunto parser tests fail.

Bug: T90018
Change-Id: Ia74877e0641f2763d42be4a8fad1aa8ecffe449e
---
M tests/engines/LuaCommon/luaParserTests.txt
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Scribunto 
refs/changes/65/192065/1

diff --git a/tests/engines/LuaCommon/luaParserTests.txt 
b/tests/engines/LuaCommon/luaParserTests.txt
index ba9741d..fc399eb 100644
--- a/tests/engines/LuaCommon/luaParserTests.txt
+++ b/tests/engines/LuaCommon/luaParserTests.txt
@@ -335,8 +335,8 @@
 ==foo==
 {{#invoke:test|testExpandTemplateWithHeaders}}
 !! result
-foo[edit]
-bar[edit]
+§foo[edit]
+§bar[edit]
 
 !! end
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia74877e0641f2763d42be4a8fad1aa8ecffe449e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Scribunto
Gerrit-Branch: master
Gerrit-Owner: Polybuildr 

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


[MediaWiki-commits] [Gerrit] Build: Update devDependencies - change (oojs/core)

2015-02-20 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

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

Change subject: Build: Update devDependencies
..

Build: Update devDependencies

* jquery v1.11.1 -> v1.11.2
  http://blog.jquery.com/2014/12/18/jquery-1-11-2

* grunt-contrib-concat v0.5.0 -> v0.5.1
  https://github.com/gruntjs/grunt-contrib-concat/blob/v0.5.1/CHANGELOG

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


  git pull ssh://gerrit.wikimedia.org:29418/oojs/core refs/changes/64/192064/1

diff --git a/package.json b/package.json
index e73e6c8..050015b 100644
--- a/package.json
+++ b/package.json
@@ -29,12 +29,12 @@
   "devDependencies": {
 "grunt": "0.4.5",
 "grunt-contrib-clean": "0.6.0",
-"grunt-contrib-concat": "0.5.0",
+"grunt-contrib-concat": "0.5.1",
 "grunt-contrib-jshint": "0.11.0",
 "grunt-contrib-watch": "0.6.1",
 "grunt-jscs": "1.5.0",
 "grunt-karma": "0.10.1",
-"jquery": "1.11.1",
+"jquery": "1.11.2",
 "karma": "0.12.31",
 "karma-chrome-launcher": "0.1.7",
 "karma-coverage": "0.2.7",

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I72e56bbe4932ed5f7fdb3e02fd3db42cd64eccc5
Gerrit-PatchSet: 1
Gerrit-Project: oojs/core
Gerrit-Branch: master
Gerrit-Owner: Krinkle 

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


[MediaWiki-commits] [Gerrit] Build: Use jquery from npm instead of embedded in the repo - change (oojs/core)

2015-02-20 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

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

Change subject: Build: Use jquery from npm instead of embedded in the repo
..

Build: Use jquery from npm instead of embedded in the repo

Change-Id: Ice7fb77a46ef5eeedc671cfa48b5813d7a9f6901
---
M Gruntfile.js
D lib/jquery.js
M package.json
3 files changed, 2 insertions(+), 10,309 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/core refs/changes/63/192063/1


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ice7fb77a46ef5eeedc671cfa48b5813d7a9f6901
Gerrit-PatchSet: 1
Gerrit-Project: oojs/core
Gerrit-Branch: master
Gerrit-Owner: Krinkle 

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


[MediaWiki-commits] [Gerrit] Check Scribunto parser tests after I562e437e - change (mediawiki...Scribunto)

2015-02-20 Thread Polybuildr (Code Review)
Polybuildr has uploaded a new change for review.

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

Change subject: Check Scribunto parser tests after I562e437e
..

Check Scribunto parser tests after I562e437e

Change-Id: Ibf65a6cd048f0407e901b62a337358273fb5bb42
---
M tests/engines/LuaCommon/luaParserTests.txt
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/tests/engines/LuaCommon/luaParserTests.txt 
b/tests/engines/LuaCommon/luaParserTests.txt
index ba9741d..2b5245d 100644
--- a/tests/engines/LuaCommon/luaParserTests.txt
+++ b/tests/engines/LuaCommon/luaParserTests.txt
@@ -335,7 +335,7 @@
 ==foo==
 {{#invoke:test|testExpandTemplateWithHeaders}}
 !! result
-foo[edit]
+§foo[edit]
 bar[edit]
 
 !! end

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ibf65a6cd048f0407e901b62a337358273fb5bb42
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Scribunto
Gerrit-Branch: master
Gerrit-Owner: Polybuildr 

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


[MediaWiki-commits] [Gerrit] Use jsonchecker.py for jsonlint macro - change (integration/config)

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

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

Change subject: Use jsonchecker.py for jsonlint macro
..

Use jsonchecker.py for jsonlint macro

Depends upon Ife432a12932dcc1651cb6 in integration/jenkins

Bug: T73284
Change-Id: Ib030c8eb1ca4d0085c5b0f1cac4d68c4762375f1
---
M jjb/macro.yaml
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/60/192060/1

diff --git a/jjb/macro.yaml b/jjb/macro.yaml
index 7ddb6fc..c99542b 100644
--- a/jjb/macro.yaml
+++ b/jjb/macro.yaml
@@ -101,7 +101,7 @@
 - builder:
 name: jsonlint
 builders:
- - shell: /srv/deployment/integration/slave-scripts/bin/json-lint.php .
+ - shell: /srv/deployment/integration/slave-scripts/bin/jsonchecker.py . 
--quiet
 
 # Wrapper around cucumber
 # FIXME should be some shell scripts instead

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib030c8eb1ca4d0085c5b0f1cac4d68c4762375f1
Gerrit-PatchSet: 1
Gerrit-Project: integration/config
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] Add jsonchecker.py - change (integration/jenkins)

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

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

Change subject: Add jsonchecker.py
..

Add jsonchecker.py

Recursively scans directories for JSON files, verifies their syntax
and checks that they don't have any duplicate keys.

Upstream: https://github.com/legoktm/jsonchecker

Bug: T73284
Change-Id: Ife432a12932dcc1651cb6ef9d565d45f20501467
---
A bin/jsonchecker.py
1 file changed, 105 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/jenkins 
refs/changes/59/192059/1

diff --git a/bin/jsonchecker.py b/bin/jsonchecker.py
new file mode 100755
index 000..c69983b
--- /dev/null
+++ b/bin/jsonchecker.py
@@ -0,0 +1,105 @@
+#!/usr/bin/env python
+"""
+Recursive JSON syntax checker that also checks
+for duplicate keys.
+
+https://github.com/legoktm/jsonchecker v0.7.0
+
+Released into the public domain.
+"""
+from __future__ import print_function
+
+from collections import defaultdict
+import json
+import os
+import sys
+
+
+class DuplicateKeyFinder:
+def __init__(self, quiet=False):
+self.errors = defaultdict(list)
+self.invalids = {}
+self.quiet = quiet
+
+def mark_error(self, key, fname):
+self.errors[fname].append(key)
+
+def checker(self, seq, fname):
+d = {}
+for key, value in seq:
+if key in d:
+self.mark_error(key, fname)
+else:
+d[key] = value
+return d
+
+def check_directory(self, directory):
+if directory == '.':
+directory = os.getcwd()
+if os.path.isdir(directory):
+files = [os.path.join(directory, fname) for fname in 
os.listdir(directory)]
+else:
+files = [directory]
+for fname in files:
+if fname.startswith('.'):
+continue
+if os.path.isdir(fname):
+self.check_directory(fname)
+continue
+if not (os.path.isfile(fname) and fname.endswith('.json')):
+continue
+if self.quiet:
+print('.', end='')
+else:
+print('Checking %s...' % fname)
+self.check_file(fname)
+
+def check_file(self, fname):
+"""
+Check the contents of the given file
+"""
+with open(fname) as f:
+text = f.read()
+try:
+json.loads(text, object_pairs_hook=lambda seq: self.checker(seq, 
fname))
+except ValueError as e:
+self.invalids[fname] = str(e)
+
+def run(self, directories):
+for directory in directories:
+self.check_directory(directory)
+self.exit()
+
+def exit(self):
+if self.errors or self.invalids:
+if self.quiet:
+print('')
+for fname in self.errors:
+print('')
+print('Duplicate keys found in %s:' % fname)
+for key in self.errors[fname]:
+print('* %s' % key)
+for fname, tb in self.invalids.items():
+print('')
+print('Error while parsing %s:' % fname)
+print(tb)
+sys.exit(1)
+else:
+if self.quiet:
+print('')
+sys.exit(0)
+
+
+def main():
+finder = DuplicateKeyFinder(quiet='--quiet' in sys.argv)
+directories = []
+for arg in sys.argv[1:]:
+if not arg.startswith('--'):
+directories.append(arg)
+if not directories:
+print('No files or directories provided')
+sys.exit(1)
+finder.run(directories)
+
+if __name__ == '__main__':
+main()

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ife432a12932dcc1651cb6ef9d565d45f20501467
Gerrit-PatchSet: 1
Gerrit-Project: integration/jenkins
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] config.domainMap, cleanup - change (mediawiki...graphoid)

2015-02-20 Thread Yurik (Code Review)
Yurik has submitted this change and it was merged.

Change subject: config.domainMap, cleanup
..


config.domainMap, cleanup

Change-Id: Ifee3abe005f262523ed2c3b331bdeed077161d30
---
M graphoid-worker.js
1 file changed, 74 insertions(+), 32 deletions(-)



diff --git a/graphoid-worker.js b/graphoid-worker.js
index 1883866..65a960c 100644
--- a/graphoid-worker.js
+++ b/graphoid-worker.js
@@ -10,13 +10,9 @@
 console.log( ' - ' + instanceName + ' loading...' );
 
 var express = require('express'),
-   fs = require('fs'),
-   child_process = require('child_process'),
request = require('request-promise'),
Promise = require('promise'), // https://www.npmjs.com/package/promise
-   http = require('http'),
urllib = require('url'),
-   querystring = require('querystring'),
vega = null; // Visualization grammar - https://github.com/trifacta/vega
 
 
@@ -31,21 +27,50 @@
 // Get the config
 try {
config = require('./graphoid.config.json');
-   if (!config.hasOwnProperty('domains') || !(config.domains instanceof 
Array) || config.domains.length == 0) {
-   throw 'The config "domains" value must be a non-empty list of 
domains';
-   }
 } catch (err) {
console.error('Error loading graphoid.config.json');
console.error(err);
process.exit(1);
 }
 
-var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
config.domains.join('|') + ')$');
+// A list of allowed hosts
+config.domains = config.domains || [];
+
+// A set of 'oldHost' => 'newHost' mappings
+config.domainMap = config.domainMap || {};
+
+// For protocol-relative URLs  (they begin with //), which protocol should we 
use
+config.defaultProtocol = config.defaultProtocol || 'http:';
+
+// Limit request to 10 seconds by default
+config.timeout = config.timeout || 1;
+
+var validDomains = 
config.domains.concat(Object.getOwnPropertyNames(config.domainMap));
+
+if (validDomains.length == 0) {
+   console.error('Config must have non-empty "domains" (list) and/or 
"domainMap" (dict)');
+   process.exit(1);
+}
+
+var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
validDomains.join('|') + ')$');
 
 if (vega) {
vega.config.domainWhiteList = config.domains;
-   vega.config.defaultProtocol = config.defaultProtocol || 'http:';
+   vega.config.defaultProtocol = config.defaultProtocol;
vega.config.safeMode = true;
+   if (Object.getOwnPropertyNames(config.domainMap) > 0) {
+   var originalSanitize = vega.data.load.sanitizeUrl;
+   vega.data.load.sanitizeUrl = function(url) {
+   url = originalSanitize(url);
+   if (url) {
+   url = 
url.replace(/^(https?:\/\/)([-a-z0-9.]+)/, function(match, prot, host){
+   var repl = config.domainMap[host];
+   return repl ? prot + repl : match;
+   });
+   }
+   return url;
+   };
+   }
 }
 
 // NOTE: there are a few libraries that do this
@@ -81,26 +106,28 @@
}
if (body.hasOwnProperty('query') && 
body.query.hasOwnProperty('pages')) {
var pages = body.query.pages,
-   graph_spec = null;
+   graphData = null;
 
Object.getOwnPropertyNames(pages).some(function (k) {
var page = pages[k];
if (page.hasOwnProperty('pageprops') && 
page.pageprops.hasOwnProperty('graph_specs')) {
var gs = 
JSON.parse(page.pageprops.graph_specs);
if (gs.hasOwnProperty(id)) {
-   graph_spec = gs[id];
+   graphData = gs[id];
return true;
}
}
return false;
});
 
-   if (graph_spec) {
-   return graph_spec;
+   if (graphData) {
+   return graphData;
}
}
-   return body.hasOwnProperty('continue') ?
-   callApiInt(url, merge(qs, body.continue)) : false;
+   if (body.hasOwnProperty('continue')) {
+   callApiInt(url, merge(qs, body.continue));
+   }
+   throw 'Unable to find graph_specs with the given id';
};
 
callApiInt = function(url, options) {
@@ -125,14 +152,30 @@
 }
 
 function validateRequest(req) {
-   var query = urllib.parse(re

[MediaWiki-commits] [Gerrit] Test fixtures data: add partially overlapping heterogeneous ... - change (mediawiki...CentralNotice)

2015-02-20 Thread AndyRussG (Code Review)
AndyRussG has uploaded a new change for review.

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

Change subject: Test fixtures data: add partially overlapping heterogeneous case
..

Test fixtures data: add partially overlapping heterogeneous case

Change-Id: Id640616d969712b5dc2dd0f36fa6d7a6b71a51c9
---
M tests/data/AllocationsFixtures.json
1 file changed, 400 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CentralNotice 
refs/changes/58/192058/1

diff --git a/tests/data/AllocationsFixtures.json 
b/tests/data/AllocationsFixtures.json
index bf51f11..49e81ea 100644
--- a/tests/data/AllocationsFixtures.json
+++ b/tests/data/AllocationsFixtures.json
@@ -1611,6 +1611,406 @@
 }
 }
 },
+"multiple_partially_overlapping_heterogeneous": {
+"comment": "Multiple partially overlapping campaigns on a 
diversity of taregeting criteria",
+"setup": {
+"campaigns": [
+{
+"name": "c1",
+"enabled": 1,
+"start_days_from_now": 0,
+"end_days_from_now": 1,
+"preferred": 1,
+"throttle": 100,
+"geotargeted": false,
+"projects": ["test_project"],
+"languages": ["en"],
+"archived": false,
+"bucket_count": 1,
+"banners": [
+{
+"name": "b1",
+"weight": 25,
+"bucket": 0,
+"display_anon": true,
+"display_account": false,
+"fundraising": 1,
+"devices": [
+"desktop"
+ ]
+}
+]
+},
+{
+"name": "c2",
+"enabled": 1,
+"start_days_from_now": 0,
+"end_days_from_now": 1,
+"preferred": 1,
+"throttle": 100,
+"geotargeted": true,
+"countries": ["LU"],
+"projects": ["test_project"],
+"languages": ["en", "fr"],
+"archived": false,
+"bucket_count": 1,
+"banners": [
+{
+"name": "b2",
+"weight": 25,
+"bucket": 0,
+"display_anon": true,
+"display_account": false,
+"fundraising": 1,
+"devices": [
+"desktop"
+ ]
+}
+]
+},
+{
+"name": "c3",
+"enabled": 1,
+"start_days_from_now": 0,
+"end_days_from_now": 1,
+"preferred": 1,
+"throttle": 100,
+"geotargeted": true,
+"countries": ["LU"],
+"projects": ["test_project"],
+"languages": ["en"],
+"archived": false,
+"bucket_count": 1,
+"banners": [
+{
+"name": "b3",
+"weight": 25,
+"bucket": 0,
+"display_anon": true,
+"display_account": false,
+"fundraising": 1,
+"devices": [
+"desktop", "iphone"
+ ]
+}
+]
+}
+]
+},
+"contexts_and_outputs": {
+"targeted_by_c1_c2_c3": {
+"comment": "Targeted by all 3 campaigns",
+"context": {
+"project": "test_project",
+"language": "en",
+"country": "LU",
+"device": "desktop",
+"logged_in_status": "anonymous"
+},
+"choices": [
+  

[MediaWiki-commits] [Gerrit] Tests: one bugfix and minor improvements 'n' cleanup - change (mediawiki...CentralNotice)

2015-02-20 Thread AndyRussG (Code Review)
AndyRussG has uploaded a new change for review.

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

Change subject: Tests: one bugfix and minor improvements 'n' cleanup
..

Tests: one bugfix and minor improvements 'n' cleanup

Change-Id: I1e865c03c94609876c0119b4fbd361de37552d86
---
M tests/ApiCentralNoticeBannerChoiceDataTest.php
M tests/BannerChoiceDataProviderTest.php
M tests/CNBannerChoicesResourceLoaderModuleTest.php
M tests/CentralNoticeTestFixtures.php
M 
tests/qunit/ext.centralNotice.bannerController.lib/bannerController.lib.tests.js
5 files changed, 16 insertions(+), 15 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CentralNotice 
refs/changes/57/192057/1

diff --git a/tests/ApiCentralNoticeBannerChoiceDataTest.php 
b/tests/ApiCentralNoticeBannerChoiceDataTest.php
index 4ed70bb..2a5040d 100644
--- a/tests/ApiCentralNoticeBannerChoiceDataTest.php
+++ b/tests/ApiCentralNoticeBannerChoiceDataTest.php
@@ -27,16 +27,16 @@
 
$this->cnFixtures->setupTestCaseFromFixtureData( $testCase );
 
-   foreach ( $testCase['contexts_and_outputs'] as 
$context_and_output ) {
+   foreach ( $testCase['contexts_and_outputs'] as $cAndOName => 
$contextAndOutput ) {
 
$ret = $this->doApiRequest( array(
'action' => 'centralnoticebannerchoicedata',
-   'project' => 
$context_and_output['context']['project'],
-   'language' => 
$context_and_output['context']['language']
+   'project' => 
$contextAndOutput['context']['project'],
+   'language' => 
$contextAndOutput['context']['language']
) );
 
$this->cnFixtures->assertChoicesEqual(
-   $this, $context_and_output['choices'], 
$ret[0]['choices'] );
+   $this, $contextAndOutput['choices'], 
$ret[0]['choices'], $cAndOName );
}
}
 }
diff --git a/tests/BannerChoiceDataProviderTest.php 
b/tests/BannerChoiceDataProviderTest.php
index fad9fc3..a3f765c 100644
--- a/tests/BannerChoiceDataProviderTest.php
+++ b/tests/BannerChoiceDataProviderTest.php
@@ -27,17 +27,17 @@
 
$this->cnFixtures->setupTestCaseFromFixtureData( $testCase );
 
-   foreach ( $testCase['contexts_and_outputs'] as 
$context_and_output ) {
+   foreach ( $testCase['contexts_and_outputs'] as $cANdOName => 
$contextAndOutput ) {
 
$allocationsProvider = new BannerChoiceDataProvider(
-   $context_and_output['context']['project'],
-   $context_and_output['context']['language']
+   $contextAndOutput['context']['project'],
+   $contextAndOutput['context']['language']
);
 
$choices = $allocationsProvider->getChoices();
 
$this->cnFixtures->assertChoicesEqual(
-   $this, $context_and_output['choices'], $choices 
);
+   $this, $contextAndOutput['choices'], $choices, 
$cANdOName );
}
}
 }
diff --git a/tests/CNBannerChoicesResourceLoaderModuleTest.php 
b/tests/CNBannerChoicesResourceLoaderModuleTest.php
index 8440f2e..4406a78 100644
--- a/tests/CNBannerChoicesResourceLoaderModuleTest.php
+++ b/tests/CNBannerChoicesResourceLoaderModuleTest.php
@@ -55,17 +55,17 @@
 
$this->cnFixtures->setupTestCaseFromFixtureData( $testCase );
 
-   foreach ( $testCase['contexts_and_outputs'] as 
$context_and_output ) {
+   foreach ( $testCase['contexts_and_outputs'] as $cAndOName => 
$contextAndOutput ) {
 
$this->setMwGlobals( array(
'wgCentralNoticeChooseBannerOnClient' 
=> true,
-   'wgNoticeProject' => 
$context_and_output['context']['project']
+   'wgNoticeProject' => 
$contextAndOutput['context']['project']
) );
 
$fauxRequest = new FauxRequest( array(
'modules' => 
'ext.centralNotice.bannerChoiceData',
'skin' => 'fallback',
-   'uselang' => 
$context_and_output['context']['language']
+   'lang' => 
$contextAndOutput['context']['language']
) );
 
$rlContext = new ResourceLoaderContext( new 
ResourceLoader(), $fauxRequest );
@@ -73,7 +73,7 @@
$choices = $this->getProvider()->getChoicesForTesting( 
$rlContext );
 
$this->cnFixtures->assert

[MediaWiki-commits] [Gerrit] config.domainMap, cleanup - change (mediawiki...graphoid)

2015-02-20 Thread Yurik (Code Review)
Yurik has uploaded a new change for review.

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

Change subject: config.domainMap, cleanup
..

config.domainMap, cleanup

Change-Id: Ifee3abe005f262523ed2c3b331bdeed077161d30
---
M graphoid-worker.js
1 file changed, 74 insertions(+), 32 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/graphoid 
refs/changes/56/192056/1

diff --git a/graphoid-worker.js b/graphoid-worker.js
index 1883866..65a960c 100644
--- a/graphoid-worker.js
+++ b/graphoid-worker.js
@@ -10,13 +10,9 @@
 console.log( ' - ' + instanceName + ' loading...' );
 
 var express = require('express'),
-   fs = require('fs'),
-   child_process = require('child_process'),
request = require('request-promise'),
Promise = require('promise'), // https://www.npmjs.com/package/promise
-   http = require('http'),
urllib = require('url'),
-   querystring = require('querystring'),
vega = null; // Visualization grammar - https://github.com/trifacta/vega
 
 
@@ -31,21 +27,50 @@
 // Get the config
 try {
config = require('./graphoid.config.json');
-   if (!config.hasOwnProperty('domains') || !(config.domains instanceof 
Array) || config.domains.length == 0) {
-   throw 'The config "domains" value must be a non-empty list of 
domains';
-   }
 } catch (err) {
console.error('Error loading graphoid.config.json');
console.error(err);
process.exit(1);
 }
 
-var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
config.domains.join('|') + ')$');
+// A list of allowed hosts
+config.domains = config.domains || [];
+
+// A set of 'oldHost' => 'newHost' mappings
+config.domainMap = config.domainMap || {};
+
+// For protocol-relative URLs  (they begin with //), which protocol should we 
use
+config.defaultProtocol = config.defaultProtocol || 'http:';
+
+// Limit request to 10 seconds by default
+config.timeout = config.timeout || 1;
+
+var validDomains = 
config.domains.concat(Object.getOwnPropertyNames(config.domainMap));
+
+if (validDomains.length == 0) {
+   console.error('Config must have non-empty "domains" (list) and/or 
"domainMap" (dict)');
+   process.exit(1);
+}
+
+var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
validDomains.join('|') + ')$');
 
 if (vega) {
vega.config.domainWhiteList = config.domains;
-   vega.config.defaultProtocol = config.defaultProtocol || 'http:';
+   vega.config.defaultProtocol = config.defaultProtocol;
vega.config.safeMode = true;
+   if (Object.getOwnPropertyNames(config.domainMap) > 0) {
+   var originalSanitize = vega.data.load.sanitizeUrl;
+   vega.data.load.sanitizeUrl = function(url) {
+   url = originalSanitize(url);
+   if (url) {
+   url = 
url.replace(/^(https?:\/\/)([-a-z0-9.]+)/, function(match, prot, host){
+   var repl = config.domainMap[host];
+   return repl ? prot + repl : match;
+   });
+   }
+   return url;
+   };
+   }
 }
 
 // NOTE: there are a few libraries that do this
@@ -81,26 +106,28 @@
}
if (body.hasOwnProperty('query') && 
body.query.hasOwnProperty('pages')) {
var pages = body.query.pages,
-   graph_spec = null;
+   graphData = null;
 
Object.getOwnPropertyNames(pages).some(function (k) {
var page = pages[k];
if (page.hasOwnProperty('pageprops') && 
page.pageprops.hasOwnProperty('graph_specs')) {
var gs = 
JSON.parse(page.pageprops.graph_specs);
if (gs.hasOwnProperty(id)) {
-   graph_spec = gs[id];
+   graphData = gs[id];
return true;
}
}
return false;
});
 
-   if (graph_spec) {
-   return graph_spec;
+   if (graphData) {
+   return graphData;
}
}
-   return body.hasOwnProperty('continue') ?
-   callApiInt(url, merge(qs, body.continue)) : false;
+   if (body.hasOwnProperty('continue')) {
+   callApiInt(url, merge(qs, body.continue));
+   }
+   throw 'Unable to find graph_specs with the given id';
};
 
ca

[MediaWiki-commits] [Gerrit] Refactor moderation logging - change (mediawiki...Flow)

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

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

Change subject: Refactor moderation logging
..

Refactor moderation logging

* Move PostModerationLogger to Listener namespace/directory (since it
  is one) and rename.
* Rename Logger to ModerationLogger to reflect that's what it's for.
  Before this round, it already had a comment indicating it was
  specific to suppression:

  
https://git.wikimedia.org/blob/mediawiki%2Fextensions%2FFlow.git/253544059db40123b3629a95744350ba40f2addb/includes%2FLog%2FLogger.php#L48

  After https://gerrit.wikimedia.org/r/#/c/191543/ is merged, it
  will also explicitly use $post->getModerationTimestamp()

Change-Id: Ib7b9177522a0e238c1b15c8e8e13ff27f6cf89af
---
M FlowActions.php
M autoload.php
M container.php
R includes/Data/Listener/ModerationLoggingListener.php
R includes/Log/ModerationLogger.php
M maintenance/FlowAddMissingModerationLogs.php
6 files changed, 25 insertions(+), 24 deletions(-)


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

diff --git a/FlowActions.php b/FlowActions.php
index 28d5dce..bf6adc5 100644
--- a/FlowActions.php
+++ b/FlowActions.php
@@ -5,7 +5,7 @@
 use Flow\Model\PostSummary;
 use Flow\Model\Header;
 use Flow\RevisionActionPermissions;
-use Flow\Log\Logger;
+use Flow\Log\ModerationLogger;
 use Flow\Data\Listener\RecentChangesListener;
 
 /**
@@ -399,7 +399,7 @@
 
'restore-post' => array(
'performs-writes' => true,
-   'log_type' => function( PostRevision $revision, Logger $logger 
) {
+   'log_type' => function( PostRevision $revision, 
ModerationLogger $logger ) {
$post = $revision->getCollection();
$previousRevision = $post->getPrevRevision( $revision );
if ( $previousRevision ) {
@@ -452,7 +452,7 @@
 
'restore-topic' => array(
'performs-writes' => true,
-   'log_type' => function( PostRevision $revision, Logger $logger 
) {
+   'log_type' => function( PostRevision $revision, 
ModerationLogger $logger ) {
$post = $revision->getCollection();
$previousRevision = $post->getPrevRevision( $revision );
if ( $previousRevision ) {
diff --git a/autoload.php b/autoload.php
index 593efa1..76716b0 100644
--- a/autoload.php
+++ b/autoload.php
@@ -83,6 +83,7 @@
'Flow\\Data\\Listener\\DeferredInsertLifecycleHandler' => __DIR__ . 
'/includes/Data/Listener/DeferredInsertLifecycleHandler.php',
'Flow\\Data\\Listener\\EditCountListener' => __DIR__ . 
'/includes/Data/Listener/EditCountListener.php',
'Flow\\Data\\Listener\\ImmediateWatchTopicListener' => __DIR__ . 
'/includes/Data/Listener/WatchTopicListener.php',
+   'Flow\\Data\\Listener\\ModerationLoggingListener' => __DIR__ . 
'/includes/Data/Listener/ModerationLoggingListener.php',
'Flow\\Data\\Listener\\NotificationListener' => __DIR__ . 
'/includes/Data/Listener/NotificationListener.php',
'Flow\\Data\\Listener\\OccupationListener' => __DIR__ . 
'/includes/Data/Listener/OccupationListener.php',
'Flow\\Data\\Listener\\RecentChangesListener' => __DIR__ . 
'/includes/Data/Listener/RecentChangesListener.php',
@@ -224,9 +225,8 @@
'Flow\\Import\\Wikitext\\ImportSource' => __DIR__ . 
'/includes/Import/Wikitext/ImportSource.php',
'Flow\\LinksTableUpdater' => __DIR__ . 
'/includes/LinksTableUpdater.php',
'Flow\\Log\\ActionFormatter' => __DIR__ . 
'/includes/Log/ActionFormatter.php',
-   'Flow\\Log\\Logger' => __DIR__ . '/includes/Log/Logger.php',
'Flow\\Log\\LqtImportFormatter' => __DIR__ . 
'/includes/Log/LqtImportFormatter.php',
-   'Flow\\Log\\PostModerationLogger' => __DIR__ . 
'/includes/Log/PostModerationLogger.php',
+   'Flow\\Log\\ModerationLogger' => __DIR__ . 
'/includes/Log/ModerationLogger.php',
'Flow\\Model\\AbstractRevision' => __DIR__ . 
'/includes/Model/AbstractRevision.php',
'Flow\\Model\\AbstractSummary' => __DIR__ . 
'/includes/Model/AbstractSummary.php',
'Flow\\Model\\Anchor' => __DIR__ . '/includes/Model/Anchor.php',
diff --git a/container.php b/container.php
index dbe3f0a..798320a 100644
--- a/container.php
+++ b/container.php
@@ -529,9 +529,9 @@
$c['repository.tree']
);
 } );
-$c['storage.post.listeners.moderation_logger'] = $c->share( function( $c ) {
-   return new Flow\Log\PostModerationLogger(
-   $c['logger']
+$c['storage.post.listeners.moderation_logging'] = $c->share( function( $c ) {
+   return new Flow\Data\Listener\ModerationLoggingListener(
+   $c['logger.moderation']
);
 } );
 $c['storage.post.listeners.username'] = $c->share( function( $c ) {
@@ -569,7 +569,7 @@
$c['storage.post.listeners.us

[MediaWiki-commits] [Gerrit] config.domainMap, cleanup - change (mediawiki...graphoid)

2015-02-20 Thread Yurik (Code Review)
Yurik has uploaded a new change for review.

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

Change subject: config.domainMap, cleanup
..

config.domainMap, cleanup

Change-Id: Ic425f616e967f06caa858f4bbe6d2f60df993af1
---
M graphoid-worker.js
1 file changed, 74 insertions(+), 32 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/graphoid 
refs/changes/55/192055/1

diff --git a/graphoid-worker.js b/graphoid-worker.js
index 1883866..65a960c 100644
--- a/graphoid-worker.js
+++ b/graphoid-worker.js
@@ -10,13 +10,9 @@
 console.log( ' - ' + instanceName + ' loading...' );
 
 var express = require('express'),
-   fs = require('fs'),
-   child_process = require('child_process'),
request = require('request-promise'),
Promise = require('promise'), // https://www.npmjs.com/package/promise
-   http = require('http'),
urllib = require('url'),
-   querystring = require('querystring'),
vega = null; // Visualization grammar - https://github.com/trifacta/vega
 
 
@@ -31,21 +27,50 @@
 // Get the config
 try {
config = require('./graphoid.config.json');
-   if (!config.hasOwnProperty('domains') || !(config.domains instanceof 
Array) || config.domains.length == 0) {
-   throw 'The config "domains" value must be a non-empty list of 
domains';
-   }
 } catch (err) {
console.error('Error loading graphoid.config.json');
console.error(err);
process.exit(1);
 }
 
-var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
config.domains.join('|') + ')$');
+// A list of allowed hosts
+config.domains = config.domains || [];
+
+// A set of 'oldHost' => 'newHost' mappings
+config.domainMap = config.domainMap || {};
+
+// For protocol-relative URLs  (they begin with //), which protocol should we 
use
+config.defaultProtocol = config.defaultProtocol || 'http:';
+
+// Limit request to 10 seconds by default
+config.timeout = config.timeout || 1;
+
+var validDomains = 
config.domains.concat(Object.getOwnPropertyNames(config.domainMap));
+
+if (validDomains.length == 0) {
+   console.error('Config must have non-empty "domains" (list) and/or 
"domainMap" (dict)');
+   process.exit(1);
+}
+
+var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
validDomains.join('|') + ')$');
 
 if (vega) {
vega.config.domainWhiteList = config.domains;
-   vega.config.defaultProtocol = config.defaultProtocol || 'http:';
+   vega.config.defaultProtocol = config.defaultProtocol;
vega.config.safeMode = true;
+   if (Object.getOwnPropertyNames(config.domainMap) > 0) {
+   var originalSanitize = vega.data.load.sanitizeUrl;
+   vega.data.load.sanitizeUrl = function(url) {
+   url = originalSanitize(url);
+   if (url) {
+   url = 
url.replace(/^(https?:\/\/)([-a-z0-9.]+)/, function(match, prot, host){
+   var repl = config.domainMap[host];
+   return repl ? prot + repl : match;
+   });
+   }
+   return url;
+   };
+   }
 }
 
 // NOTE: there are a few libraries that do this
@@ -81,26 +106,28 @@
}
if (body.hasOwnProperty('query') && 
body.query.hasOwnProperty('pages')) {
var pages = body.query.pages,
-   graph_spec = null;
+   graphData = null;
 
Object.getOwnPropertyNames(pages).some(function (k) {
var page = pages[k];
if (page.hasOwnProperty('pageprops') && 
page.pageprops.hasOwnProperty('graph_specs')) {
var gs = 
JSON.parse(page.pageprops.graph_specs);
if (gs.hasOwnProperty(id)) {
-   graph_spec = gs[id];
+   graphData = gs[id];
return true;
}
}
return false;
});
 
-   if (graph_spec) {
-   return graph_spec;
+   if (graphData) {
+   return graphData;
}
}
-   return body.hasOwnProperty('continue') ?
-   callApiInt(url, merge(qs, body.continue)) : false;
+   if (body.hasOwnProperty('continue')) {
+   callApiInt(url, merge(qs, body.continue));
+   }
+   throw 'Unable to find graph_specs with the given id';
};
 
ca

[MediaWiki-commits] [Gerrit] config.domainMap, cleanup - change (mediawiki...graphoid)

2015-02-20 Thread Yurik (Code Review)
Yurik has submitted this change and it was merged.

Change subject: config.domainMap, cleanup
..


config.domainMap, cleanup

Change-Id: I07cc4f97d09d88d19bc86ea586a34ab07f5ce41d
---
M graphoid-worker.js
1 file changed, 74 insertions(+), 32 deletions(-)

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



diff --git a/graphoid-worker.js b/graphoid-worker.js
index 1883866..65a960c 100644
--- a/graphoid-worker.js
+++ b/graphoid-worker.js
@@ -10,13 +10,9 @@
 console.log( ' - ' + instanceName + ' loading...' );
 
 var express = require('express'),
-   fs = require('fs'),
-   child_process = require('child_process'),
request = require('request-promise'),
Promise = require('promise'), // https://www.npmjs.com/package/promise
-   http = require('http'),
urllib = require('url'),
-   querystring = require('querystring'),
vega = null; // Visualization grammar - https://github.com/trifacta/vega
 
 
@@ -31,21 +27,50 @@
 // Get the config
 try {
config = require('./graphoid.config.json');
-   if (!config.hasOwnProperty('domains') || !(config.domains instanceof 
Array) || config.domains.length == 0) {
-   throw 'The config "domains" value must be a non-empty list of 
domains';
-   }
 } catch (err) {
console.error('Error loading graphoid.config.json');
console.error(err);
process.exit(1);
 }
 
-var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
config.domains.join('|') + ')$');
+// A list of allowed hosts
+config.domains = config.domains || [];
+
+// A set of 'oldHost' => 'newHost' mappings
+config.domainMap = config.domainMap || {};
+
+// For protocol-relative URLs  (they begin with //), which protocol should we 
use
+config.defaultProtocol = config.defaultProtocol || 'http:';
+
+// Limit request to 10 seconds by default
+config.timeout = config.timeout || 1;
+
+var validDomains = 
config.domains.concat(Object.getOwnPropertyNames(config.domainMap));
+
+if (validDomains.length == 0) {
+   console.error('Config must have non-empty "domains" (list) and/or 
"domainMap" (dict)');
+   process.exit(1);
+}
+
+var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
validDomains.join('|') + ')$');
 
 if (vega) {
vega.config.domainWhiteList = config.domains;
-   vega.config.defaultProtocol = config.defaultProtocol || 'http:';
+   vega.config.defaultProtocol = config.defaultProtocol;
vega.config.safeMode = true;
+   if (Object.getOwnPropertyNames(config.domainMap) > 0) {
+   var originalSanitize = vega.data.load.sanitizeUrl;
+   vega.data.load.sanitizeUrl = function(url) {
+   url = originalSanitize(url);
+   if (url) {
+   url = 
url.replace(/^(https?:\/\/)([-a-z0-9.]+)/, function(match, prot, host){
+   var repl = config.domainMap[host];
+   return repl ? prot + repl : match;
+   });
+   }
+   return url;
+   };
+   }
 }
 
 // NOTE: there are a few libraries that do this
@@ -81,26 +106,28 @@
}
if (body.hasOwnProperty('query') && 
body.query.hasOwnProperty('pages')) {
var pages = body.query.pages,
-   graph_spec = null;
+   graphData = null;
 
Object.getOwnPropertyNames(pages).some(function (k) {
var page = pages[k];
if (page.hasOwnProperty('pageprops') && 
page.pageprops.hasOwnProperty('graph_specs')) {
var gs = 
JSON.parse(page.pageprops.graph_specs);
if (gs.hasOwnProperty(id)) {
-   graph_spec = gs[id];
+   graphData = gs[id];
return true;
}
}
return false;
});
 
-   if (graph_spec) {
-   return graph_spec;
+   if (graphData) {
+   return graphData;
}
}
-   return body.hasOwnProperty('continue') ?
-   callApiInt(url, merge(qs, body.continue)) : false;
+   if (body.hasOwnProperty('continue')) {
+   callApiInt(url, merge(qs, body.continue));
+   }
+   throw 'Unable to find graph_specs with the given id';
};
 
callApiInt = function(url, options) {
@@ -125,14 +152,30 @@
 }
 
 function 

[MediaWiki-commits] [Gerrit] config.domainMap, cleanup - change (mediawiki...graphoid)

2015-02-20 Thread Yurik (Code Review)
Yurik has uploaded a new change for review.

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

Change subject: config.domainMap, cleanup
..

config.domainMap, cleanup

Change-Id: I07cc4f97d09d88d19bc86ea586a34ab07f5ce41d
---
M graphoid-worker.js
1 file changed, 74 insertions(+), 32 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/graphoid 
refs/changes/53/192053/1

diff --git a/graphoid-worker.js b/graphoid-worker.js
index 1883866..65a960c 100644
--- a/graphoid-worker.js
+++ b/graphoid-worker.js
@@ -10,13 +10,9 @@
 console.log( ' - ' + instanceName + ' loading...' );
 
 var express = require('express'),
-   fs = require('fs'),
-   child_process = require('child_process'),
request = require('request-promise'),
Promise = require('promise'), // https://www.npmjs.com/package/promise
-   http = require('http'),
urllib = require('url'),
-   querystring = require('querystring'),
vega = null; // Visualization grammar - https://github.com/trifacta/vega
 
 
@@ -31,21 +27,50 @@
 // Get the config
 try {
config = require('./graphoid.config.json');
-   if (!config.hasOwnProperty('domains') || !(config.domains instanceof 
Array) || config.domains.length == 0) {
-   throw 'The config "domains" value must be a non-empty list of 
domains';
-   }
 } catch (err) {
console.error('Error loading graphoid.config.json');
console.error(err);
process.exit(1);
 }
 
-var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
config.domains.join('|') + ')$');
+// A list of allowed hosts
+config.domains = config.domains || [];
+
+// A set of 'oldHost' => 'newHost' mappings
+config.domainMap = config.domainMap || {};
+
+// For protocol-relative URLs  (they begin with //), which protocol should we 
use
+config.defaultProtocol = config.defaultProtocol || 'http:';
+
+// Limit request to 10 seconds by default
+config.timeout = config.timeout || 1;
+
+var validDomains = 
config.domains.concat(Object.getOwnPropertyNames(config.domainMap));
+
+if (validDomains.length == 0) {
+   console.error('Config must have non-empty "domains" (list) and/or 
"domainMap" (dict)');
+   process.exit(1);
+}
+
+var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
validDomains.join('|') + ')$');
 
 if (vega) {
vega.config.domainWhiteList = config.domains;
-   vega.config.defaultProtocol = config.defaultProtocol || 'http:';
+   vega.config.defaultProtocol = config.defaultProtocol;
vega.config.safeMode = true;
+   if (Object.getOwnPropertyNames(config.domainMap) > 0) {
+   var originalSanitize = vega.data.load.sanitizeUrl;
+   vega.data.load.sanitizeUrl = function(url) {
+   url = originalSanitize(url);
+   if (url) {
+   url = 
url.replace(/^(https?:\/\/)([-a-z0-9.]+)/, function(match, prot, host){
+   var repl = config.domainMap[host];
+   return repl ? prot + repl : match;
+   });
+   }
+   return url;
+   };
+   }
 }
 
 // NOTE: there are a few libraries that do this
@@ -81,26 +106,28 @@
}
if (body.hasOwnProperty('query') && 
body.query.hasOwnProperty('pages')) {
var pages = body.query.pages,
-   graph_spec = null;
+   graphData = null;
 
Object.getOwnPropertyNames(pages).some(function (k) {
var page = pages[k];
if (page.hasOwnProperty('pageprops') && 
page.pageprops.hasOwnProperty('graph_specs')) {
var gs = 
JSON.parse(page.pageprops.graph_specs);
if (gs.hasOwnProperty(id)) {
-   graph_spec = gs[id];
+   graphData = gs[id];
return true;
}
}
return false;
});
 
-   if (graph_spec) {
-   return graph_spec;
+   if (graphData) {
+   return graphData;
}
}
-   return body.hasOwnProperty('continue') ?
-   callApiInt(url, merge(qs, body.continue)) : false;
+   if (body.hasOwnProperty('continue')) {
+   callApiInt(url, merge(qs, body.continue));
+   }
+   throw 'Unable to find graph_specs with the given id';
};
 
ca

[MediaWiki-commits] [Gerrit] Move insert media button to top level toolbar - change (mediawiki...VisualEditor)

2015-02-20 Thread Alex Monk (Code Review)
Alex Monk has uploaded a new change for review.

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

Change subject: Move insert media button to top level toolbar
..

Move insert media button to top level toolbar

Bug: T90299
Change-Id: Idb361d1a64f630dd8f5eff7c459e4fee8a196ca4
---
M modules/ve-mw/init/ve.init.mw.Target.js
1 file changed, 4 insertions(+), 2 deletions(-)


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

diff --git a/modules/ve-mw/init/ve.init.mw.Target.js 
b/modules/ve-mw/init/ve.init.mw.Target.js
index 181964c..1746820 100644
--- a/modules/ve-mw/init/ve.init.mw.Target.js
+++ b/modules/ve-mw/init/ve.init.mw.Target.js
@@ -228,10 +228,12 @@
label: OO.ui.deferMsg( 'visualeditor-toolbar-insert' ),
indicator: 'down',
include: '*',
-   forceExpand: [ 'media', 'transclusion', 'insertTable' ],
-   promote: [ 'media', 'transclusion' ],
+   forceExpand: [ 'transclusion', 'insertTable' ],
+   promote: [ 'transclusion' ],
demote: [ 'specialcharacter' ]
},
+   // Media
+   { include: [ 'media' ] },
// Table
{
header: OO.ui.deferMsg( 'visualeditor-toolbar-table' ),

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idb361d1a64f630dd8f5eff7c459e4fee8a196ca4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 

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


[MediaWiki-commits] [Gerrit] Generate CommentNodes more leniently - change (VisualEditor/VisualEditor)

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

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

Change subject: Generate CommentNodes more leniently
..

Generate CommentNodes more leniently

Previously we only allowed them in the middle of text. Now we allow
them everywhere that they can be rendered.

* Extracted new method #isValidChildNodeType in ve.dm.Converter.
* Added more torture tests to 'comments.html' in standalone demo.

Bug: T73085
Change-Id: I9f5ee4a058b42f870154d489804ef52601bd7d1e
---
M demos/ve/pages/comments.html
M src/dm/nodes/ve.dm.CommentNode.js
M src/dm/ve.dm.Converter.js
3 files changed, 40 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/51/192051/1

diff --git a/demos/ve/pages/comments.html b/demos/ve/pages/comments.html
index 816bd27..02d2b2c 100644
--- a/demos/ve/pages/comments.html
+++ b/demos/ve/pages/comments.html
@@ -25,5 +25,24 @@
 --> Baz! Empty comment: 
 
 Lorem Ipsum is simply dummy text of the printing and typesetting industry. 
Lorem Ipsum has been the industry's standard dummy text ever  
since the 1500s, when an unknown printer took a galley of type and scrambled it 
to make a type specimen book. It has survived not only five centuries, but 
also 
the leap into electronic typesetting, remaining essentially unchanged.
+Paragraph text.
 Foo  Baz!
 Foo  Baz!
+
+
+
+List item one.
+List item two.
+
+List item three.
+
+
+
+
+
+Definition term
+Definition one.
+
+Definition two.
+
+
diff --git a/src/dm/nodes/ve.dm.CommentNode.js 
b/src/dm/nodes/ve.dm.CommentNode.js
index 67af0a9..1279916 100644
--- a/src/dm/nodes/ve.dm.CommentNode.js
+++ b/src/dm/nodes/ve.dm.CommentNode.js
@@ -38,9 +38,8 @@
domElements[0].data :
domElements[0].getAttribute( 'data-ve-comment' );
return {
-   // Only use CommentNode for comments in ContentBranchNodes; 
otherwise use
-   // CommentMetaItem
-   type: converter.isExpectingContent() && text !== '' ? 'comment' 
: 'commentMeta',
+   // Disallows comment nodes between table rows and such
+   type: converter.isValidChildNodeType( 'comment' ) && text !== 
'' ? 'comment' : 'commentMeta',
attributes: {
text: text
}
diff --git a/src/dm/ve.dm.Converter.js b/src/dm/ve.dm.Converter.js
index 025a3e3..300db97 100644
--- a/src/dm/ve.dm.Converter.js
+++ b/src/dm/ve.dm.Converter.js
@@ -275,6 +275,23 @@
 };
 
 /**
+ * Whether the converter can currently accept a child node with the given type.
+ *
+ * @method
+ * @param {string} nodeType
+ * @returns {boolean|null} Whether the node type is valid, or null if not 
converting
+ */
+ve.dm.Converter.prototype.isValidChildNodeType = function ( nodeType ) {
+   var childTypes,
+   context = this.getCurrentContext();
+   if ( !context ) {
+   return null;
+   }
+   childTypes = this.nodeFactory.getChildNodeTypes( context.branchType );
+   return ( childTypes === null || ve.indexOf( nodeType, childTypes ) !== 
-1 );
+};
+
+/**
  * Whether the conversion is currently inside a wrapper paragraph generated by 
the converter.
  * Note that this is specific to the current recursion level.
  *
@@ -580,7 +597,7 @@
return true;
}
 
-   var i, childNode, childNodes, childDataElements, text, childTypes, 
matches,
+   var i, childNode, childNodes, childDataElements, text, matches,
wrappingParagraph, prevElement, childAnnotations, modelName, 
modelClass,
annotation, childIsContent, aboutGroup, emptyParagraph,
modelRegistry = this.modelRegistry,
@@ -911,11 +928,10 @@
 
// If we're closing a node that doesn't have any children, but could 
contain a paragraph,
// add a paragraph. This prevents things like empty list items
-   childTypes = this.nodeFactory.getChildNodeTypes( context.branchType );
if ( context.branchType !== 'paragraph' && wrapperElement && 
data[data.length - 1] === wrapperElement &&
!context.inWrapper && !this.nodeFactory.canNodeContainContent( 
context.branchType ) &&
!this.nodeFactory.isNodeContent( context.branchType ) &&
-   ( childTypes === null || ve.indexOf( 'paragraph', childTypes ) 
!== -1 )
+   this.isValidChildNodeType( 'paragraph' )
) {
emptyParagraph = { type: 'paragraph', internal: { generated: 
'empty' } };
processNextWhitespace( emptyParagraph );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9f5ee4a058b42f870154d489804ef52601bd7d1e
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński 


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 90562b1..c6dbdc9 - change (mediawiki/extensions)

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

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

Change subject: Syncronize VisualEditor: 90562b1..c6dbdc9
..

Syncronize VisualEditor: 90562b1..c6dbdc9

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/50/192050/1

diff --git a/VisualEditor b/VisualEditor
index 90562b1..c6dbdc9 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 90562b1b8b949a7d7b70afd72a774fbc43640ec6
+Subproject commit c6dbdc92ea0fbced10043835771defb9fc2d95c2

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

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

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 90562b1..c6dbdc9 - change (mediawiki/extensions)

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

Change subject: Syncronize VisualEditor: 90562b1..c6dbdc9
..


Syncronize VisualEditor: 90562b1..c6dbdc9

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

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



diff --git a/VisualEditor b/VisualEditor
index 90562b1..c6dbdc9 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 90562b1b8b949a7d7b70afd72a774fbc43640ec6
+Subproject commit c6dbdc92ea0fbced10043835771defb9fc2d95c2

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

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

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


[MediaWiki-commits] [Gerrit] Don't try to route any events into schema.Edit if it's not a... - change (mediawiki...VisualEditor)

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

Change subject: Don't try to route any events into schema.Edit if it's not 
actually installed
..


Don't try to route any events into schema.Edit if it's not actually installed

E.g. no WikimediaEvents

Bug: T88667
Change-Id: I33a13abf22da0caa1282652fa1a078ffcae11e97
---
M modules/ve-mw/init/ve.init.mw.trackSubscriber.js
1 file changed, 5 insertions(+), 0 deletions(-)

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



diff --git a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js 
b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
index 3622100..c71c3e2 100644
--- a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
+++ b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
@@ -8,6 +8,11 @@
  */
 
 ( function () {
+   if ( mw.loader.getState( 'schema.Edit' ) === null ) {
+   // Only route any events into the Edit schema if the module is 
actually available.
+   // It won't be if EventLogging is installed but WikimediaEvents 
is not.
+   return;
+   }
 
var timing = {},
editingSessionId = mw.user.generateRandomSessionId();

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I33a13abf22da0caa1282652fa1a078ffcae11e97
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Make Citoid service npm job voting - change (integration/config)

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

Change subject: Make Citoid service npm job voting
..


Make Citoid service npm job voting

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

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



diff --git a/zuul/layout.yaml b/zuul/layout.yaml
index 62aed99..c27821d 100644
--- a/zuul/layout.yaml
+++ b/zuul/layout.yaml
@@ -1553,9 +1553,6 @@
   - name: mediawiki-vagrant-puppetlint-strict
 voting: false
 
-  - name: citoid-npm
-voting: false
-
   # Rejecting changes having trailing whitespaces cause too many false
   # positives. So only report the whitespace issues, but don't let it vote.
   - name: ^.*-whitespaces$

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3bcd3d17cb886740bd67b33b573aa25972ddb574
Gerrit-PatchSet: 3
Gerrit-Project: integration/config
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] Don't try to route any events into schema.Edit if it's not a... - change (mediawiki...VisualEditor)

2015-02-20 Thread Alex Monk (Code Review)
Alex Monk has uploaded a new change for review.

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

Change subject: Don't try to route any events into schema.Edit if it's not 
actually installed
..

Don't try to route any events into schema.Edit if it's not actually installed

E.g. no WikimediaEvents

Bug: T88667
Change-Id: I33a13abf22da0caa1282652fa1a078ffcae11e97
---
M modules/ve-mw/init/ve.init.mw.trackSubscriber.js
1 file changed, 5 insertions(+), 0 deletions(-)


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

diff --git a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js 
b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
index 3622100..c71c3e2 100644
--- a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
+++ b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
@@ -8,6 +8,11 @@
  */
 
 ( function () {
+   if ( mw.loader.getState( 'schema.Edit' ) === null ) {
+   // Only route any events into the Edit schema if the module is 
actually available.
+   // It won't be if EventLogging is installed but WikimediaEvents 
is not.
+   return;
+   }
 
var timing = {},
editingSessionId = mw.user.generateRandomSessionId();

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I33a13abf22da0caa1282652fa1a078ffcae11e97
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 

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


[MediaWiki-commits] [Gerrit] Move efGatherExtensionSetup() to Hooks.php to fix CI breakage - change (mediawiki...Gather)

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

Change subject: Move efGatherExtensionSetup() to Hooks.php to fix CI breakage
..


Move efGatherExtensionSetup() to Hooks.php to fix CI breakage

When extension.json is present, Gather.php is not loaded. Thus,
the function does not exist.

> Warning: Invalid argument: function: method 'efGatherExtensionSetup'
> not found in mediawiki/includes/Setup.php on line 671

Change-Id: I55d9e362e3c1bb69c8ec550127d136c5b8838a2b
---
M Gather.php
M includes/Gather.hooks.php
2 files changed, 9 insertions(+), 10 deletions(-)

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



diff --git a/Gather.php b/Gather.php
index 2a0141d..866e442 100644
--- a/Gather.php
+++ b/Gather.php
@@ -29,15 +29,6 @@
 $wgMessagesDirs['Gather'] = __DIR__ . '/i18n';
 $wgExtensionMessagesFiles['GatherAlias'] = __DIR__ . "/Gather.alias.php";
 
-function efGatherExtensionSetup() {
-   // FIXME: This doesn't do anything as if mobilefrontend is not present
-   // The reported error is "This requires Gather."
-   if ( !defined( 'MOBILEFRONTEND' ) ) {
-   echo "Gather extension requires MobileFrontend.\n";
-   die( -1 );
-   }
-}
-
 // autoload extension classes
 $autoloadClasses = array(
'Gather\Hooks' => 'Gather.hooks',
@@ -73,11 +64,11 @@
$wgAutoloadClasses[$className] = __DIR__ . 
"/includes/$classFilename.php";
 }
 
-$wgExtensionFunctions[] = 'efGatherExtensionSetup';
 
 $wgSpecialPages['Gather'] = 'Gather\SpecialGather';
 
 // Hooks
+$wgExtensionFunctions[] = 'Gather\Hooks::onExtensionSetup';
 $wgHooks['MobilePersonalTools'][] = 'Gather\Hooks::onMobilePersonalTools';
 $wgHooks['UnitTestsList'][] = 'Gather\Hooks::onUnitTestsList';
 
diff --git a/includes/Gather.hooks.php b/includes/Gather.hooks.php
index d123ef7..48e7c7e 100644
--- a/includes/Gather.hooks.php
+++ b/includes/Gather.hooks.php
@@ -18,6 +18,14 @@
  * onRequestContextCreateSkin()
  */
 class Hooks {
+   public static function onExtensionSetup() {
+   // FIXME: This doesn't do anything as if mobilefrontend is not 
present
+   // The reported error is "This requires Gather."
+   if ( !defined( 'MOBILEFRONTEND' ) ) {
+   echo "Gather extension requires MobileFrontend.\n";
+   die( -1 );
+   }
+   }
/**
 * Add collections link in personal tools menu
 * @param array &$items Items array to be added to menu

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I55d9e362e3c1bb69c8ec550127d136c5b8838a2b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Gather
Gerrit-Branch: master
Gerrit-Owner: Krinkle 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Move efGatherExtensionSetup() to Hooks.php to fix CI breakage - change (mediawiki...Gather)

2015-02-20 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

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

Change subject: Move efGatherExtensionSetup() to Hooks.php to fix CI breakage
..

Move efGatherExtensionSetup() to Hooks.php to fix CI breakage

When extension.json is present, Gather.php is not loaded. Thus,
the function does not exist.

> Warning: Invalid argument: function: method 'efGatherExtensionSetup'
> not found in mediawiki/includes/Setup.php on line 671

Change-Id: I55d9e362e3c1bb69c8ec550127d136c5b8838a2b
---
M Gather.php
M includes/Gather.hooks.php
2 files changed, 9 insertions(+), 10 deletions(-)


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

diff --git a/Gather.php b/Gather.php
index 2a0141d..866e442 100644
--- a/Gather.php
+++ b/Gather.php
@@ -29,15 +29,6 @@
 $wgMessagesDirs['Gather'] = __DIR__ . '/i18n';
 $wgExtensionMessagesFiles['GatherAlias'] = __DIR__ . "/Gather.alias.php";
 
-function efGatherExtensionSetup() {
-   // FIXME: This doesn't do anything as if mobilefrontend is not present
-   // The reported error is "This requires Gather."
-   if ( !defined( 'MOBILEFRONTEND' ) ) {
-   echo "Gather extension requires MobileFrontend.\n";
-   die( -1 );
-   }
-}
-
 // autoload extension classes
 $autoloadClasses = array(
'Gather\Hooks' => 'Gather.hooks',
@@ -73,11 +64,11 @@
$wgAutoloadClasses[$className] = __DIR__ . 
"/includes/$classFilename.php";
 }
 
-$wgExtensionFunctions[] = 'efGatherExtensionSetup';
 
 $wgSpecialPages['Gather'] = 'Gather\SpecialGather';
 
 // Hooks
+$wgExtensionFunctions[] = 'Gather\Hooks::onExtensionSetup';
 $wgHooks['MobilePersonalTools'][] = 'Gather\Hooks::onMobilePersonalTools';
 $wgHooks['UnitTestsList'][] = 'Gather\Hooks::onUnitTestsList';
 
diff --git a/includes/Gather.hooks.php b/includes/Gather.hooks.php
index d123ef7..48e7c7e 100644
--- a/includes/Gather.hooks.php
+++ b/includes/Gather.hooks.php
@@ -18,6 +18,14 @@
  * onRequestContextCreateSkin()
  */
 class Hooks {
+   public static function onExtensionSetup() {
+   // FIXME: This doesn't do anything as if mobilefrontend is not 
present
+   // The reported error is "This requires Gather."
+   if ( !defined( 'MOBILEFRONTEND' ) ) {
+   echo "Gather extension requires MobileFrontend.\n";
+   die( -1 );
+   }
+   }
/**
 * Add collections link in personal tools menu
 * @param array &$items Items array to be added to menu

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I55d9e362e3c1bb69c8ec550127d136c5b8838a2b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Gather
Gerrit-Branch: master
Gerrit-Owner: Krinkle 

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


[MediaWiki-commits] [Gerrit] Upgrade composer-merge-plugin to 1.0.0 - change (mediawiki/core)

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

Change subject: Upgrade composer-merge-plugin to 1.0.0
..


Upgrade composer-merge-plugin to 1.0.0

* Smaller install size
* Included files are processed recursively, with an option to disable

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

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



diff --git a/composer.json b/composer.json
index 75aed40..1650394 100644
--- a/composer.json
+++ b/composer.json
@@ -22,7 +22,7 @@
"php": ">=5.3.3",
"psr/log": "1.0.0",
"wikimedia/cdb": "1.0.1",
-   "wikimedia/composer-merge-plugin": "0.5.0",
+   "wikimedia/composer-merge-plugin": "1.0.0",
"zordius/lightncandy": "0.18"
},
"require-dev": {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I65bf1e0d0e972846ed9e30761738aaf3a2127c2f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: Daniel Friesen 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] mw.ViewPageTarget: Remove JS animations from transformPage() - change (mediawiki...VisualEditor)

2015-02-20 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

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

Change subject: mw.ViewPageTarget: Remove JS animations from transformPage()
..

mw.ViewPageTarget: Remove JS animations from transformPage()

Follows-up 62c1d64ad0.

* mw-indicators no longer animates opacity. Left-over from 62c1d64ad0.

* #siteNotice no longer slides. A transition would be justified here is
  avoid having the other content suddenly jump upwards. However there
  is no good CSS method of expanding/collapsing content without leaving
  the border box behind. We can look into bringing this back in a
  performant manner at later time.

* The toolbar now uses a CSS translate transition. This has the
  added bonus of also working when the page is scrolled down.
  When loading the editor from a section-edit link or when simply
  scrolling down during the activation, the toolbar will slide down
  from under the browser chrome.

Bug: T89543
Change-Id: I30a7b69b77b874d220f60ebe7f7e616cd77bcc36
---
M modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css
M modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js
2 files changed, 35 insertions(+), 36 deletions(-)


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

diff --git a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css 
b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css
index 73d0f37..764eaff 100644
--- a/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css
+++ b/modules/ve-mw/init/styles/ve.init.mw.ViewPageTarget.css
@@ -16,6 +16,8 @@
 
 .ve-activated #contentSub,
 .ve-activated #toc,
+.ve-activated #siteNotice,
+.ve-activated .mw-indicators,
 /* Most of bodyContent can be hidden as VE has an equivalent of most children
in ve-init-target (sibling of #bodyContent). However, we can't hide it
completely as #siteSub should remain visible (for persistence with read 
mode),
@@ -40,6 +42,21 @@
 
 /* Toolbar */
 
+.ve-activated #content,
+.ve-deactivating #content {
+   overflow: hidden;
+}
+.ve-available .oo-ui-toolbar-bar {
+   transition: transform 0.4s ease;
+   transform: translateY(-100%);
+}
+.ve-active .oo-ui-toolbar-bar {
+   transform: translateY(0);
+}
+.ve-deactivating .oo-ui-toolbar-bar {
+   transform: translateY(-100%);
+}
+
 .ve-init-mw-viewPageTarget-toolbar-utilities,
 .ve-init-mw-viewPageTarget-toolbar-actions {
display: inline-block;
diff --git a/modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js 
b/modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js
index 0614b97..b64755f 100644
--- a/modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js
+++ b/modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js
@@ -180,33 +180,25 @@
// Parent method
ve.init.mw.Target.prototype.setupToolbar.call( this, surface );
 
-   // Keep it hidden so that we can slide it down smoothly (avoids sudden
-   // offset flash when original content is hidden, and replaced in-place 
with a
-   // similar-looking surface).
-   // FIXME: This is not ideal, the parent class creates it and appends
-   // to target (visibly), only for us to hide it again 0ms later.
-   // Though we can't hide it by default because it needs visible 
dimensions
-   // to compute stuff during setup.
-   this.getToolbar().$bar.hide();
-
this.getToolbar().$element
.addClass( 've-init-mw-viewPageTarget-toolbar' );
 
+   this.getToolbar().$bar.on( 'transitionend', function () {
+   console.log( this, 'transed' );
+   } );
// Move the toolbar to top of target, before heading etc.
this.$element.prepend( this.getToolbar().$element );
 
ve.track( 'trace.setupToolbar.exit' );
 
-   this.getToolbar().$bar.slideDown( 'fast', function () {
-   // Check the surface wasn't torn down while the toolbar was 
animating
-   if ( target.getSurface() ) {
-   ve.track( 'trace.initializeToolbar.enter' );
-   target.getToolbar().initialize();
-   target.getSurface().getView().emit( 'position' );
-   target.getSurface().getContext().updateDimensions();
-   ve.track( 'trace.initializeToolbar.exit' );
-   }
-   } );
+   // Check the surface wasn't torn down while the toolbar was animating
+   if ( target.getSurface() ) {
+   ve.track( 'trace.initializeToolbar.enter' );
+   target.getToolbar().initialize();
+   target.getSurface().getView().emit( 'position' );
+   target.getSurface().getContext().updateDimensions();
+   ve.track( 'trace.initializeToolbar.exit' );
+   }
 };
 
 /**
@@ -1278,7 +1270,13 @@
  */
 ve.init.mw.ViewPageTarget.prototype.tearDownToolbar = function () {
var target = this;
-   return this.

[MediaWiki-commits] [Gerrit] Upgrade composer-merge-plugin to 1.0.0 - change (mediawiki/vendor)

2015-02-20 Thread BryanDavis (Code Review)
BryanDavis has submitted this change and it was merged.

Change subject: Upgrade composer-merge-plugin to 1.0.0
..


Upgrade composer-merge-plugin to 1.0.0

Change-Id: I65bf1e0d0e972846ed9e30761738aaf3a2127c2f
---
M composer.json
M composer.lock
M composer/installed.json
D wikimedia/composer-merge-plugin/.gitignore
D wikimedia/composer-merge-plugin/.scrutinizer.yml
D wikimedia/composer-merge-plugin/.travis.yml
M wikimedia/composer-merge-plugin/README.md
D wikimedia/composer-merge-plugin/example/.gitignore
D wikimedia/composer-merge-plugin/example/composer.json
D wikimedia/composer-merge-plugin/example/composer.local.json
D wikimedia/composer-merge-plugin/example/extensions/Foo/composer.json
D wikimedia/composer-merge-plugin/phpunit.xml.dist
M wikimedia/composer-merge-plugin/src/MergePlugin.php
D wikimedia/composer-merge-plugin/tests/phpunit/MergePluginTest.php
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testMergedRepositories/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testMergedRepositories/composer.local.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeNoConflicts/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeNoConflicts/composer.local.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeWithConflicts/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeWithConflicts/composer.local.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeWithConflicts/extensions/Foo/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testUpdateStabilityFlags/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testUpdateStabilityFlags/composer.local.json
23 files changed, 108 insertions(+), 641 deletions(-)

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



diff --git a/composer.json b/composer.json
index 2a75c03..c4bdd20 100644
--- a/composer.json
+++ b/composer.json
@@ -12,7 +12,7 @@
"ruflin/elastica": "1.3.0.0",
"oojs/oojs-ui": "0.8.0",
"wikimedia/cdb": "1.0.1",
-   "wikimedia/composer-merge-plugin": "0.5.0",
+   "wikimedia/composer-merge-plugin": "1.0.0",
"zordius/lightncandy": "0.18"
},
"prefer-stable": true,
diff --git a/composer.lock b/composer.lock
index a905c51..b79bf57 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,7 +4,7 @@
 "Read more about it at 
http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file";,
 "This file is @generated automatically"
 ],
-"hash": "065f42d5d65e22fae958a5759234888c",
+"hash": "6188811094b69e07d37639aa9419dcf1",
 "packages": [
 {
 "name": "cssjanus/cssjanus",
@@ -327,16 +327,16 @@
 },
 {
 "name": "wikimedia/composer-merge-plugin",
-"version": "v0.5.0",
+"version": "v1.0.0",
 "source": {
 "type": "git",
 "url": 
"https://github.com/wikimedia/composer-merge-plugin.git";,
-"reference": "08ad40053b14d564dcd2a02239f67caa20d9ea75"
+"reference": "ed426b785f9f786b33be4fd78584e43f4e962356"
 },
 "dist": {
 "type": "zip",
-"url": 
"https://api.github.com/repos/wikimedia/composer-merge-plugin/zipball/08ad40053b14d564dcd2a02239f67caa20d9ea75";,
-"reference": "08ad40053b14d564dcd2a02239f67caa20d9ea75",
+"url": 
"https://api.github.com/repos/wikimedia/composer-merge-plugin/zipball/ed426b785f9f786b33be4fd78584e43f4e962356";,
+"reference": "ed426b785f9f786b33be4fd78584e43f4e962356",
 "shasum": ""
 },
 "require": {
@@ -364,7 +364,7 @@
 "MIT"
 ],
 "description": "Composer plugin to merge multiple composer.json 
files",
-"time": "2014-12-29 20:05:19"
+"time": "2015-02-21 00:57:13"
 },
 {
 "name": "zordius/lightncandy",
diff --git a/composer/installed.json b/composer/installed.json
index 558d5d7..b3ac2a7 100644
--- a/composer/installed.json
+++ b/composer/installed.json
@@ -276,49 +276,6 @@
 ]
 },
 {
-"name": "wikimedia/composer-merge-plugin",
-"version": "v0.5.0",
-"version_normalized": "0.5.0.0",
-"source": {
-"type": "git",
-"url": "https://github.com/wikimedia/composer-merge-plugin.git";,
-"reference": "08ad40053b14d564dcd2a02239f67caa20d9ea75"
-},
-"dist": {
-"type": "zip",
-"url": 
"https://api.github.com/repos/wikimedia/composer-merge-plugin/zipball/08ad40053b14d564dcd2a02239f67caa20d9ea75";,
-"reference": "08ad40053b14d564dcd2a02239f67ca

[MediaWiki-commits] [Gerrit] Drop support for old 'normal' custom extension in favor of '... - change (utfnormal)

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

Change subject: Drop support for old 'normal' custom extension in favor of 
'intl'
..


Drop support for old 'normal' custom extension in favor of 'intl'

This doesn't seem to be used anymore in Wikimedia production, and 'intl'
wraps more of the ICU API so should be used instead anyway.

Bug: T90259
Change-Id: Ic071914a448413c086f1c4b75f7b609c41af6476
---
M README
M src/UtfNormal.php
2 files changed, 14 insertions(+), 25 deletions(-)

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



diff --git a/README b/README
index fa70c63..8b0874e 100644
--- a/README
+++ b/README
@@ -20,6 +20,8 @@
 
 == Regenerating data tables ==
 
+[section needs update]
+
 UtfNormalData.inc and UtfNormalDataK.inc are generated from the Unicode
 Character Database by the script UtfNormalGenerate.php. On a *nix system
 'make' should fetch the necessary files and regenerate it if the scripts
@@ -27,6 +29,8 @@
 
 
 == Testing ==
+
+[section needs update]
 
 'make test' will run the conformance test (UtfNormalTest.php), fetching the
 data from the net if necessary. If it reports failure, something is
@@ -39,6 +43,8 @@
 
 == Benchmarks ==
 
+[section needs update]
+
 Run 'make bench' to download some sample texts from Wikipedia and run some
 cheap benchmarks of some of the functions. Take all numbers with large
 grains of salt.
@@ -46,14 +52,12 @@
 
 == PHP module extension ==
 
-There's an experimental PHP extension module which wraps the ICU library's
-normalization functions. This is *MUCH* faster than doing this work in pure
-PHP code. This is at 
https://git.wikimedia.org/summary/mediawiki%2Fextensions%2Fnormal.git.
-It is used by the WMF, which currently runs PHP 5.3.10 on Linux.  It hasn't 
been
-thoroughly tested on other configurations, but may work.
+If the 'intl' PHP extension is present, ICU library functions are used which
+are *MUCH* faster than doing this work in pure PHP code.
 
-If the php_normal.so module is loaded in php.ini, the normalization functions
-will automatically use it. If you can't (or don't want to) load it in php.ini,
-you may be able to load it using the dl() function before the inclusion of
-UtfNormal.php, and it will be picked up.
+It is strongly recommended to enable this module if possible:
+http://php.net/manual/en/intro.intl.php
 
+Older versions of this library supported a one-off custom PHP extension,
+which has been dropped. If you were using this, please migrate to the
+intl extension.
diff --git a/src/UtfNormal.php b/src/UtfNormal.php
index 54ff397..1a73412 100644
--- a/src/UtfNormal.php
+++ b/src/UtfNormal.php
@@ -29,7 +29,6 @@
  * @defgroup UtfNormal UtfNormal
  */
 
-define( 'NORMALIZE_ICU', function_exists( 'utf8_normalize' ) );
 define( 'NORMALIZE_INTL', function_exists( 'normalizer_normalize' ) );
 
 /**
@@ -77,13 +76,7 @@
 * @return string a clean, shiny, normalized UTF-8 string
 */
static function cleanUp( $string ) {
-   if ( NORMALIZE_ICU ) {
-   $string = self::replaceForNativeNormalize( $string );
-
-   # UnicodeString constructor fails if the string ends 
with a
-   # head byte. Add a junk char at the end, we'll strip it 
off.
-   return rtrim( utf8_normalize( $string . "\x01", 
self::UNORM_NFC ), "\x01" );
-   } elseif ( NORMALIZE_INTL ) {
+   if ( NORMALIZE_INTL ) {
$string = self::replaceForNativeNormalize( $string );
$norm = normalizer_normalize( $string, 
Normalizer::FORM_C );
if ( $norm === null || $norm === false ) {
@@ -120,8 +113,6 @@
static function toNFC( $string ) {
if ( NORMALIZE_INTL )
return normalizer_normalize( $string, 
Normalizer::FORM_C );
-   elseif ( NORMALIZE_ICU )
-   return utf8_normalize( $string, self::UNORM_NFC );
elseif ( UtfNormal::quickIsNFC( $string ) )
return $string;
else
@@ -138,8 +129,6 @@
static function toNFD( $string ) {
if ( NORMALIZE_INTL )
return normalizer_normalize( $string, 
Normalizer::FORM_D );
-   elseif ( NORMALIZE_ICU )
-   return utf8_normalize( $string, self::UNORM_NFD );
elseif ( preg_match( '/[\x80-\xff]/', $string ) )
return UtfNormal::NFD( $string );
else
@@ -157,8 +146,6 @@
static function toNFKC( $string ) {
if ( NORMALIZE_INTL )
return normalizer_normalize( $string, 
Normalizer::FORM_KC );
-   elseif ( NORMALIZE_ICU )
-   return utf8_normalize( $string, self::UNORM_NFKC );
elseif ( preg_match( '/[\x80-\xff

[MediaWiki-commits] [Gerrit] Upgrade composer-merge-plugin to 1.0.0 - change (mediawiki/vendor)

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

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

Change subject: Upgrade composer-merge-plugin to 1.0.0
..

Upgrade composer-merge-plugin to 1.0.0

Change-Id: I65bf1e0d0e972846ed9e30761738aaf3a2127c2f
---
M composer.json
M composer.lock
M composer/ClassLoader.php
M composer/installed.json
D wikimedia/composer-merge-plugin/.gitignore
D wikimedia/composer-merge-plugin/.scrutinizer.yml
D wikimedia/composer-merge-plugin/.travis.yml
M wikimedia/composer-merge-plugin/README.md
D wikimedia/composer-merge-plugin/example/.gitignore
D wikimedia/composer-merge-plugin/example/composer.json
D wikimedia/composer-merge-plugin/example/composer.local.json
D wikimedia/composer-merge-plugin/example/extensions/Foo/composer.json
D wikimedia/composer-merge-plugin/phpunit.xml.dist
M wikimedia/composer-merge-plugin/src/MergePlugin.php
D wikimedia/composer-merge-plugin/tests/phpunit/MergePluginTest.php
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testMergedRepositories/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testMergedRepositories/composer.local.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeNoConflicts/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeNoConflicts/composer.local.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeWithConflicts/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeWithConflicts/composer.local.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testOneMergeWithConflicts/extensions/Foo/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testUpdateStabilityFlags/composer.json
D 
wikimedia/composer-merge-plugin/tests/phpunit/fixtures/testUpdateStabilityFlags/composer.local.json
24 files changed, 108 insertions(+), 668 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/vendor 
refs/changes/46/192046/1

diff --git a/composer.json b/composer.json
index 2a75c03..c4bdd20 100644
--- a/composer.json
+++ b/composer.json
@@ -12,7 +12,7 @@
"ruflin/elastica": "1.3.0.0",
"oojs/oojs-ui": "0.8.0",
"wikimedia/cdb": "1.0.1",
-   "wikimedia/composer-merge-plugin": "0.5.0",
+   "wikimedia/composer-merge-plugin": "1.0.0",
"zordius/lightncandy": "0.18"
},
"prefer-stable": true,
diff --git a/composer.lock b/composer.lock
index a905c51..4a177b1 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,7 +4,7 @@
 "Read more about it at 
http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file";,
 "This file is @generated automatically"
 ],
-"hash": "065f42d5d65e22fae958a5759234888c",
+"hash": "6188811094b69e07d37639aa9419dcf1",
 "packages": [
 {
 "name": "cssjanus/cssjanus",
@@ -327,16 +327,16 @@
 },
 {
 "name": "wikimedia/composer-merge-plugin",
-"version": "v0.5.0",
+"version": "v1.0.0",
 "source": {
 "type": "git",
 "url": 
"https://github.com/wikimedia/composer-merge-plugin.git";,
-"reference": "08ad40053b14d564dcd2a02239f67caa20d9ea75"
+"reference": "ed426b785f9f786b33be4fd78584e43f4e962356"
 },
 "dist": {
 "type": "zip",
-"url": 
"https://api.github.com/repos/wikimedia/composer-merge-plugin/zipball/08ad40053b14d564dcd2a02239f67caa20d9ea75";,
-"reference": "08ad40053b14d564dcd2a02239f67caa20d9ea75",
+"url": 
"https://api.github.com/repos/wikimedia/composer-merge-plugin/zipball/ed426b785f9f786b33be4fd78584e43f4e962356";,
+"reference": "ed426b785f9f786b33be4fd78584e43f4e962356",
 "shasum": ""
 },
 "require": {
@@ -364,7 +364,7 @@
 "MIT"
 ],
 "description": "Composer plugin to merge multiple composer.json 
files",
-"time": "2014-12-29 20:05:19"
+"time": "2015-02-21 00:57:13"
 },
 {
 "name": "zordius/lightncandy",
@@ -419,7 +419,6 @@
 "minimum-stability": "stable",
 "stability-flags": [],
 "prefer-stable": true,
-"prefer-lowest": false,
 "platform": {
 "php": ">=5.3.3"
 },
diff --git a/composer/ClassLoader.php b/composer/ClassLoader.php
index 5e1469e..70d78bc 100644
--- a/composer/ClassLoader.php
+++ b/composer/ClassLoader.php
@@ -54,8 +54,6 @@
 private $useIncludePath = false;
 private $classMap = array();
 
-private $classMapAuthoritative = false;
-
 public function getPrefixes()
 {
 if (!empty($this->prefixesPsr0)) {
@@ -251,27 +249,6 @@
 }
 
 /**
- * Turns off searching the prefix and fallback directories for classes
-

[MediaWiki-commits] [Gerrit] Upgrade composer-merge-plugin to 1.0.0 - change (mediawiki/core)

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

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

Change subject: Upgrade composer-merge-plugin to 1.0.0
..

Upgrade composer-merge-plugin to 1.0.0

* Smaller install size
* Included files are processed recursively, with an option to disable

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/45/192045/1

diff --git a/composer.json b/composer.json
index 75aed40..1650394 100644
--- a/composer.json
+++ b/composer.json
@@ -22,7 +22,7 @@
"php": ">=5.3.3",
"psr/log": "1.0.0",
"wikimedia/cdb": "1.0.1",
-   "wikimedia/composer-merge-plugin": "0.5.0",
+   "wikimedia/composer-merge-plugin": "1.0.0",
"zordius/lightncandy": "0.18"
},
"require-dev": {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I65bf1e0d0e972846ed9e30761738aaf3a2127c2f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
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] Repair infinite scroll behaviour - change (mediawiki...Flow)

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

Change subject: Repair infinite scroll behaviour
..


Repair infinite scroll behaviour

A recent patch to give the TOC some breathing room ended up
breaking the infinite scroll behaviour.  Looks to be an
unintentional change of that patch.  The variable in question
is already resolved to a number, so requesting .top gives undefined
and using it in an equation gets NaN, which always gives a comparison
result of false and does not click the loadmore button.

Bug: T90295
Change-Id: I2ad5de7b3e266879a48ecef90fd59a1820473238
---
M modules/engine/components/board/features/flow-board-loadmore.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/modules/engine/components/board/features/flow-board-loadmore.js 
b/modules/engine/components/board/features/flow-board-loadmore.js
index 75b3581..e1f190c 100644
--- a/modules/engine/components/board/features/flow-board-loadmore.js
+++ b/modules/engine/components/board/features/flow-board-loadmore.js
@@ -488,7 +488,7 @@
// also shouldn't be triggered if it's still behind TOC!
 
// Is this element in the viewport?
-   if ( nodeOffset - nodeHeight <= 
calculationContainerThreshold.top + calculationContainerHeight ) {
+   if ( nodeOffset - nodeHeight <= 
calculationContainerThreshold + calculationContainerHeight ) {
// Element is almost in viewport, click it.
$( this ).trigger( 'click' );
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2ad5de7b3e266879a48ecef90fd59a1820473238
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: EBernhardson 
Gerrit-Reviewer: Mattflaschen 
Gerrit-Reviewer: Matthias Mullie 
Gerrit-Reviewer: SG 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] ve#track: refactor callback calling convention - change (VisualEditor/VisualEditor)

2015-02-20 Thread Ori.livneh (Code Review)
Ori.livneh has submitted this change and it was merged.

Change subject: ve#track: refactor callback calling convention
..


ve#track: refactor callback calling convention

It's a bit weird to call ve#track subscribers with a custom context object that
only supplies one useful property (this.timeStamp). So instead pass the
timestamp as the third parameter, and make the context null.

Change-Id: I8e82acc1219fb91181d2df3593baaedb54fe0b21
---
M src/ve.track.js
1 file changed, 3 insertions(+), 5 deletions(-)

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



diff --git a/src/ve.track.js b/src/ve.track.js
index 3358064..0cc7220 100644
--- a/src/ve.track.js
+++ b/src/ve.track.js
@@ -30,10 +30,8 @@
 * Register a handler for subset of analytic events, specified by topic
 *
 * Handlers will be called once for each tracked event, including any 
events that fired before the
-* handler was registered; 'this' is set to a plain object with a 
'timeStamp' property indicating
-* the exact time at which the event fired, a string 'topic' property 
naming the event, and a
-* 'data' property which is an object of event-specific data. The event 
topic and event data are
-* also passed to the callback as the first and second arguments, 
respectively.
+* handler was registered, with the topic, event data payload, and 
event timestamp as the first,
+* second, and third arguments, respectively.
 *
 * @member ve
 * @param {string} topic Handle events whose name starts with this 
string prefix
@@ -47,7 +45,7 @@
for ( ; seen < queue.length; seen++ ) {
event = queue[ seen ];
if ( event.topic.indexOf( topic ) === 0 ) {
-   callback.call( event, event.topic, 
event.data );
+   callback( event.topic, event.data, 
event.timeStamp );
}
}
} );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8e82acc1219fb91181d2df3593baaedb54fe0b21
Gerrit-PatchSet: 3
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Ori.livneh 
Gerrit-Reviewer: Catrope 
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] T90309: Ensure that implicitly-added output hav... - change (mediawiki...parsoid)

2015-02-20 Thread Subramanya Sastry (Code Review)
Subramanya Sastry has uploaded a new change for review.

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

Change subject: T90309: Ensure that implicitly-added  output have 
unique ids
..

T90309: Ensure that implicitly-added  output have unique ids

* Fixed parser test output of one test to add unique ids. Output for
  other parser tests modified in 5189bcb7 still need fixing up.
  Left for a separate patch.

Change-Id: I04546c2a590930121d960239a1954b26771e9c80
---
M lib/ext.Cite.js
M tests/parserTests.txt
2 files changed, 4 insertions(+), 5 deletions(-)


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

diff --git a/lib/ext.Cite.js b/lib/ext.Cite.js
index 2eaee36..e9fa7ee 100644
--- a/lib/ext.Cite.js
+++ b/lib/ext.Cite.js
@@ -484,7 +484,6 @@
 
 References.prototype.insertMissingReferencesIntoDOM = function (env, node) {
var doc = node.ownerDocument,
-   referencesId = env.newAboutId(),
self = this;
 
this.refGroups.forEach(function (refsData, refsGroup) {
@@ -493,7 +492,7 @@
DU.addAttributes(ol, {
'class': 'references',
typeof: 'mw:Extension/references',
-   about: referencesId
+   about: env.newAboutId()
});
// The new references come out of "nowhere", so to make selser 
work
// propertly, add a zero-sized DSR pointing to the end of the 
document.
diff --git a/tests/parserTests.txt b/tests/parserTests.txt
index fc37f96..81a8276 100644
--- a/tests/parserTests.txt
+++ b/tests/parserTests.txt
@@ -20178,11 +20178,11 @@
 A foo
 B bar
 !! html
-A [1] B [inexistent 1]
-
+A [1] B [inexistent 1]
+
 ↑ foo
 
-
+
 ↑ bar
 
 !! end

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I04546c2a590930121d960239a1954b26771e9c80
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/parsoid
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] Analyze failure rates by type - change (analytics/limn-edit-data)

2015-02-20 Thread Milimetric (Code Review)
Milimetric has submitted this change and it was merged.

Change subject: Analyze failure rates by type
..


Analyze failure rates by type

Main trouble right now is no way to pivot and display the results by
type of failure, as would be very easy on a modern db...

Change-Id: I74faf8aa59a991ae9e5a44096ae4152547dd7052
---
A edit/failure_rates_by_type.sql
A static/adhoc.html
M static/funnel-prototype.html
M static/funnel-prototype.js
A static/util.js
5 files changed, 180 insertions(+), 44 deletions(-)

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



diff --git a/edit/failure_rates_by_type.sql b/edit/failure_rates_by_type.sql
new file mode 100644
index 000..3c0395a
--- /dev/null
+++ b/edit/failure_rates_by_type.sql
@@ -0,0 +1,67 @@
+set @from_time  = '{from_timestamp}';
+set @to_time= '{to_timestamp}';
+set @wiki   = '{wiki}';
+
+set @from_time  = '2014120300';
+set @to_time= '2015020100';
+set @wiki   = null;
+
+ select day,
+sum(if(actions like '%saveAttempt%saveFailure%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'total',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%userBadToken%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'bad-token',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%userNewUser%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'new-user',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%extensionAbuseFilter%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'abuse-filter',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%extensionCaptcha%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'captcha',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%extensionSpamBlacklist%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'spam-blacklist',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%responseEmpty%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'response-empty',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%responseUnknown%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 
'response-unknown',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%editPageDeleted%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'page-deleted',
+sum(if(actions like '%saveAttempt%saveFailure%' and failures like 
'%editConflict%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as 'conflict'
+   from (select date(timestamp) as day,
+actions,
+failures,
+count(*) as repeated
+   from (select timestamp,
+event_editingSessionId,
+wiki,
+group_concat(event_action order by timestamp, 
action_order.ord separator '-') as actions,
+group_concat(`event_action.saveFailure.type` order by 
timestamp separator '-') as failures
+   from staging.milimetric_edit
+inner join
+(select 'init' as action, 0 as ord
+union all
+ select 'ready' as action, 1 as ord
+union all
+ select 'saveIntent' as action, 2 as ord
+union all
+ select 'saveAttempt' as action, 3 as ord
+union all
+ select 'saveFailure' as action, 4 as ord
+union all
+ select 'saveSuccess' as action, 5 as ord
+union all
+ select 'abort' as action, 6 as ord
+) action_order  on action = 
staging.milimetric_edit.event_action
+  where event_editor = 'visualeditor'
+and timestamp between @from_time and @to_time
+and (@wiki is null or wiki = @wiki)
+  group by clientIp, event_editingSessionId
+ # this purposefully ignores sessions that start before 
"from_timestamp",
+ # as well as some other sessions that legitimately do not 
have an "init"
+ # as well as sessions that have an "init" after "ready"
+ having actions like 'init%'
+) sessions
+  group by day, actions, failures
+) actions
+  group by day
+;
diff --git a/static/adhoc.html b/static/adhoc.html
new file mode 100644
index 000

[MediaWiki-commits] [Gerrit] Json user page storage for a collection - change (mediawiki...Gather)

2015-02-20 Thread Robmoen (Code Review)
Robmoen has uploaded a new change for review.

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

Change subject: Json user page storage for a collection
..

Json user page storage for a collection

Example json format can be put in User:Rob/GatherCollections/1.json
https://gist.github.com/rmoen/677928f77df085ff356d

Change-Id: I6ee685d6890b6be2700e24ab9e87bab87952304c
---
M Gather.php
M includes/models/CollectionBase.php
M includes/specials/SpecialGather.php
M includes/stores/Collection.php
A includes/stores/UserPageCollection.php
M includes/stores/WatchlistCollection.php
6 files changed, 157 insertions(+), 43 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather 
refs/changes/43/192043/1

diff --git a/Gather.php b/Gather.php
index 2a0141d..38f43d0 100644
--- a/Gather.php
+++ b/Gather.php
@@ -52,6 +52,7 @@
'Gather\stores\WatchlistCollection' => 'stores/WatchlistCollection',
'Gather\stores\CollectionsList' => 'stores/CollectionsList',
'Gather\stores\DumbWatchlistOnlyCollectionsList' => 
'stores/DumbWatchlistOnlyCollectionsList',
+   'Gather\stores\UserPageCollection' => 'stores/UserPageCollection',
'Gather\stores\UserPageCollectionsList' => 
'stores/UserPageCollectionsList',
'Gather\stores\ItemExtracts' => 'stores/ItemExtracts',
'Gather\stores\ItemImages' => 'stores/ItemImages',
diff --git a/includes/models/CollectionBase.php 
b/includes/models/CollectionBase.php
index 4d62372..0fd6ff2 100644
--- a/includes/models/CollectionBase.php
+++ b/includes/models/CollectionBase.php
@@ -39,6 +39,13 @@
protected $description;
 
/**
+* Image that represents the collection.
+*
+* @var File
+*/
+   protected $image;
+
+   /**
 * Whether collection is public or private
 * Collection by default is true
 *
@@ -53,11 +60,12 @@
 * @param string $description Description of the collection
 * @param boolean $public Whether the collection is public or private
 */
-   public function __construct( $id = null, User $user, $title = '', 
$description = '', $public = true ) {
+   public function __construct( $id = null, User $user, $title = '', 
$description = '', $image = null, $public = true ) {
$this->id = $id;
$this->owner = $user;
$this->title = $title;
$this->description = $description;
+   $this->image = $image;
$this->public = $public;
}
 
@@ -97,13 +105,6 @@
public function isPublic() {
return $this->public;
}
-
-   /**
-* Image that represents the collection.
-*
-* @var File
-*/
-   protected $image;
 
/**
 * Returns items count
diff --git a/includes/specials/SpecialGather.php 
b/includes/specials/SpecialGather.php
index eecee4c..b0e3f12 100644
--- a/includes/specials/SpecialGather.php
+++ b/includes/specials/SpecialGather.php
@@ -76,12 +76,22 @@
$watchlistStore = new 
stores\WatchlistCollection( $user );
$this->render( new views\Collection( 
$watchlistStore->getCollection() ) );
} else {
-   // FIXME: No permissions to visit this. Showing 
not found ATM.
+   // FIXME: No permission.  Rendering not found
$this->renderNotFoundError();
}
} else {
-   // FIXME: Not rendering other collections yet. Render 
not found ATM.
-   $this->renderNotFoundError();
+   $userPageCollectionStore = new 
stores\UserPageCollection( $user, (int)$id );
+   $collection = $userPageCollectionStore->getCollection();
+   
+   // Render if collection is public or current user is 
the owner
+   if (
+   $collection->isPublic() ||
+   $this->getUser()-getName() === 
$collection->getOwner()->getName()
+   ) {
+   $this->render( new views\Collection( 
$collection ) );   
+   } else {
+   $this->renderNotFoundError();   
+   }
}
}
 
diff --git a/includes/stores/Collection.php b/includes/stores/Collection.php
index 2d03183..4d36d36 100644
--- a/includes/stores/Collection.php
+++ b/includes/stores/Collection.php
@@ -1,15 +1,58 @@
 user = $user;
+   $this->id = $id;
+   $this->loadCollection();
+   }
+
+   public function getCollection() {
+   return $this->collection;
+   }
+
+   public function getId() {
+   return $thi

[MediaWiki-commits] [Gerrit] Corrected Style/GuardClause RuboCop offenses - change (mediawiki/selenium)

2015-02-20 Thread Dduvall (Code Review)
Dduvall has uploaded a new change for review.

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

Change subject: Corrected Style/GuardClause RuboCop offenses
..

Corrected Style/GuardClause RuboCop offenses

Change-Id: I589f967b940a9ae15841e5d2d859c8408564cd9a
---
M .rubocop_todo.yml
M lib/mediawiki_selenium/warnings_formatter.rb
2 files changed, 12 insertions(+), 17 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/selenium 
refs/changes/42/192042/1

diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml
index e6e52e4..2749d85 100644
--- a/.rubocop_todo.yml
+++ b/.rubocop_todo.yml
@@ -6,11 +6,6 @@
 # versions of RuboCop, may require this file to be generated again.
 
 # Offense count: 2
-# Configuration parameters: MinBodyLength.
-Style/GuardClause:
-  Enabled: false
-
-# Offense count: 2
 # Cop supports --auto-correct.
 Style/LeadingCommentSpace:
   Enabled: false
diff --git a/lib/mediawiki_selenium/warnings_formatter.rb 
b/lib/mediawiki_selenium/warnings_formatter.rb
index cc88ff0..ad6fe67 100644
--- a/lib/mediawiki_selenium/warnings_formatter.rb
+++ b/lib/mediawiki_selenium/warnings_formatter.rb
@@ -10,23 +10,23 @@
 end
 
 def after_feature(feature)
-  if feature.mw_warnings.any?
-feature.mw_warnings.each do |type, messages|
-  messages.each { |msg| @io.puts format_string(msg, :pending) }
-  @warning_counts[type] += messages.length
-end
+  return unless feature.mw_warnings.any?
 
-@io.puts
+  feature.mw_warnings.each do |type, messages|
+messages.each { |msg| @io.puts format_string(msg, :pending) }
+@warning_counts[type] += messages.length
   end
+
+  @io.puts
 end
 
 def after_features(*)
-  if @warning_counts.any?
-@warning_counts.each do |type, count|
-  message = "#{count} warning#{count > 1 ? "s" : ""}"
-  message += " due to #{type}" unless type == :default
-  @io.puts format_string(message, :pending)
-end
+  return unless @warning_counts.any?
+
+  @warning_counts.each do |type, count|
+message = "#{count} warning#{count > 1 ? "s" : ""}"
+message += " due to #{type}" unless type == :default
+@io.puts format_string(message, :pending)
   end
 end
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I589f967b940a9ae15841e5d2d859c8408564cd9a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/selenium
Gerrit-Branch: master
Gerrit-Owner: Dduvall 

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


[MediaWiki-commits] [Gerrit] Consistency tweaks in preparation for adding to translatewik... - change (mediawiki...OAuthAuthentication)

2015-02-20 Thread CSteipp (Code Review)
CSteipp has submitted this change and it was merged.

Change subject: Consistency tweaks in preparation for adding to 
translatewiki.net
..


Consistency tweaks in preparation for adding to translatewiki.net

* Move description message to i18n file
* Tweak en messages a bit (remove upper case, add punctation)
* Tweak qqq a bit (documantation instead of message itself, typo)

Change-Id: I6ff49fac9b60133ad756b6a68369ea33d145d564
---
M OAuthAuthentication.php
M i18n/en.json
M i18n/qqq.json
3 files changed, 8 insertions(+), 6 deletions(-)

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



diff --git a/OAuthAuthentication.php b/OAuthAuthentication.php
index a0e68d6..a38aef9 100644
--- a/OAuthAuthentication.php
+++ b/OAuthAuthentication.php
@@ -10,7 +10,7 @@
 $wgExtensionCredits['other'][] = array(
'path'   => __FILE__,
'name'   => 'OAuthAuthentication',
-   'description'=> 'This extension allows wikis to delegate their 
authentication to anther wiki',
+   'descriptionmsg' => 'oauthauth-desc',
'author' => array( 'Chris Steipp' ),
'url'=> 
'https://www.mediawiki.org/wiki/Extension:OAuthAuthentication',
'version'=> '0.1.0'
diff --git a/i18n/en.json b/i18n/en.json
index 460f488..1b04fbf 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -4,16 +4,17 @@
"CSteipp"
]
},
+   "oauthauth-desc": "Allows wikis to delegate their authentication to 
anther wiki",
"oauthauth-already-logged-in": "You are already logged in. $1 to 
continue",
-   "oauthauth-error": "OAuth Login Error",
+   "oauthauth-error": "OAuth login error",
"ouathauth-logout": "Logout",
-   "oauthauth-failed-handshake": "There was an OAuth protocol error 
logging you in. The remote wiki may be experiencing technical issues",
+   "oauthauth-failed-handshake": "There was an OAuth protocol error 
logging you in. The remote wiki may be experiencing technical issues.",
"oauthauth-csrf-detected": "OAuth session mismatch. Please try logging 
in again.",
"oauthauth-create-noname": "OAuth error logging you in. The username on 
the remote wiki isn't valid on this wiki.",
"oauthauth-create-userexists": "OAuth error logging you in. The 
username on the remote wiki already exists on this wiki. You must contact a 
bureaucrat to usurp the account.",
"oauthauth-login-noname": "The OAuth user is connected, but the name 
isn't valid on this wiki.",
"oauthauth-login": "Log in on $1",
-   "oauthauth-login-usernotexists": "The OAuth user listed as connected, 
but the user doesn't exist on this wiki",
+   "oauthauth-login-usernotexists": "The OAuth user listed as connected, 
but the user doesn't exist on this wiki.",
"oauthauth-nologin-policy": "This wiki's policy will not let you 
login.",
"oauthauth-localuser-not-allowed": "The site administrator has disabled 
local account creation. You should $1 to create an account with OAuth.",
"oauthauth-loggout-policy": "You have been logged out because the site 
policy no longer allows you to be logged in."
diff --git a/i18n/qqq.json b/i18n/qqq.json
index d4c8872..77dc192 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -4,7 +4,8 @@
"CSteipp"
]
},
-   "oauthauth-already-logged-in": "You are already logged in. $1 to 
continue",
+   "oauthauth-desc": "{{desc|name=OAuth 
Authentication|url=https://www.mediawiki.org/wiki/Extension:OAuthAuthentication}}";,
+   "oauthauth-already-logged-in": "Error message when user is logged in 
already",
"oauthauth-error": "Title for OAuth login page errors",
"ouathauth-logout": "Link text for logout link",
"oauthauth-failed-handshake": "Error message to users when an unknown 
issue occured.",
@@ -14,7 +15,7 @@
"oauthauth-login-noname": "Error when the username on the OAuth-server 
wiki isn't valid on this client wiki.",
"oauthauth-login": "Text for link to login on remote 
wiki.\n\nParameters:\n* $1 - the name of the remote wiki where the user will 
log in.",
"oauthauth-login-usernotexists": "Error when the user logs in with an 
account that was attached on this wiki, but no longer exists.",
-   "oauthauth-nologin-policy": "Error the user sees hwne the local wiki's 
administrator has prevented their login with a policy.",
+   "oauthauth-nologin-policy": "Error the user sees when the local wiki's 
administrator has prevented their login with a policy.",
"oauthauth-localuser-not-allowed": "Error when the user attempts to 
create an account, but the wiki isn't configured to allow it, and instructing 
the user to login via OAuth.\n\nParameters:\n* $1 - link text {{msg-mw|login}}. 
A link to login.",
"oauthauth-loggout-policy": "Error message when a user is lo

[MediaWiki-commits] [Gerrit] build: Include 'lib' and 'dist' in jsduck output - change (oojs/ui)

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

Change subject: build: Include 'lib' and 'dist' in jsduck output
..


build: Include 'lib' and 'dist' in jsduck output

This fixes Live Preview functionality triggered by @example,
which is currently broken due to 404 Not Found errors.

* Copy 'lib' and 'dist' using a grunt task.

  In a similar situation in VisualEditor we opted for a bash
  script but that makes maintenance from CI harder. Implementing
  an entry point 'npm doc' instead makes things more flexible
  and uniform.

  We could make it part of the test pipeline, but leaving that
  for another commit since Jenkins is currently configured to
  do that in a separate job already.

* Move eg-iframe.html to jsduck.eg-iframe.html.

* Add basic css normalisation so that we don't have a serif font.
  (Taken from demo.)

Bug: T90120
Change-Id: Ic3896a396d85c90860d88647954039e4d54057fb
---
M Gruntfile.js
R jsduck.eg-iframe.html
M jsduck.json
M package.json
4 files changed, 29 insertions(+), 5 deletions(-)

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



diff --git a/Gruntfile.js b/Gruntfile.js
index c4ea5e9..d61ac82 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -227,6 +227,11 @@
dest: 'dist/',
expand: true,
rename: strip( 'dist/tmp/' )
+   },
+   jsduck: {
+   src: '{lib,dist}/**/*',
+   dest: 'docs/',
+   expand: true
}
},
colorizeSvg: {
@@ -362,6 +367,17 @@
} );
} );
 
+   grunt.registerTask( 'jsduck', function () {
+   var done = this.async(),
+   spawn = require( 'child_process' ).spawn,
+   jsduck = spawn( 'jsduck', [ '--color' ] );
+   jsduck.stdout.pipe( process.stdout );
+   jsduck.stderr.pipe( process.stderr );
+   jsduck.on( 'close', function ( code ) {
+   done( code === 0 );
+   } );
+   } );
+
grunt.registerTask( 'build-code', [ 'concat:js', 'uglify' ] );
grunt.registerTask( 'build-styling', [
'copy:lessTemp', 'colorizeSvg', 'less', 'copy:svg', 
'copy:imagesCommon',
@@ -384,6 +400,7 @@
 
grunt.registerTask( 'lint', [ 'jshint', 'jscs', 'csslint', 'banana' ] );
grunt.registerTask( 'test', [ 'pre-test', 'git-build', 'lint', 
'karma:main', 'karma:other' ] );
+   grunt.registerTask( 'doc', [ 'build', 'jsduck', 'copy:jsduck' ] );
 
grunt.registerTask( 'default', 'test' );
 };
diff --git a/eg-iframe.html b/jsduck.eg-iframe.html
similarity index 71%
rename from eg-iframe.html
rename to jsduck.eg-iframe.html
index b62efa5..c4a8e8f 100644
--- a/eg-iframe.html
+++ b/jsduck.eg-iframe.html
@@ -5,13 +5,19 @@
OOjs UI example


+   
+   body {
+   font-size: 100%;
+   font-family: sans-serif;
+   }
+   

 
 
-   
-   
-   
-   
+   
+   
+   
+   

[MediaWiki-commits] [Gerrit] Fix typo: contian → contain - change (oojs/ui)

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

Change subject: Fix typo: contian → contain
..


Fix typo: contian → contain

Change-Id: I3b7a71c63ef7ed1454bdce5a884ca9a47817f316
---
M build/typos.json
M demos/demo.js
2 files changed, 4 insertions(+), 3 deletions(-)

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



diff --git a/build/typos.json b/build/typos.json
index 4554e3b..5916d77 100644
--- a/build/typos.json
+++ b/build/typos.json
@@ -11,6 +11,7 @@
[ "\bteh\b", "the" ],
[ "intialization", "initialization" ],
[ "durring", "during" ],
+   [ "contian", "contain" ],
[ "occured", "occurred" ]
]
 }
diff --git a/demos/demo.js b/demos/demo.js
index 8bc9b0e..dd8cdfc 100644
--- a/demos/demo.js
+++ b/demos/demo.js
@@ -89,7 +89,7 @@
 /**
  * Available themes.
  *
- * List of theme descriptions, each contianing a `fileSuffix` property used 
for linking to the
+ * List of theme descriptions, each containing a `fileSuffix` property used 
for linking to the
  * correct stylesheet file and a `theme` property containing a theme class
  *
  * @static
@@ -109,7 +109,7 @@
 /**
  * Available graphics formats.
  *
- * List of graphics format descriptions, each contianing a `fileSuffix` 
property used for linking
+ * List of graphics format descriptions, each containing a `fileSuffix` 
property used for linking
  * to the correct stylesheet file.
  *
  * @static
@@ -124,7 +124,7 @@
 /**
  * Available text directions.
  *
- * List of text direction descriptions, each contianing a `fileSuffix` 
property used for linking to
+ * List of text direction descriptions, each containing a `fileSuffix` 
property used for linking to
  * the correct stylesheet file.
  *
  * @static

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3b7a71c63ef7ed1454bdce5a884ca9a47817f316
Gerrit-PatchSet: 3
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Corrected Style/GlobalVars RuboCop offense - change (mediawiki/selenium)

2015-02-20 Thread Dduvall (Code Review)
Dduvall has uploaded a new change for review.

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

Change subject: Corrected Style/GlobalVars RuboCop offense
..

Corrected Style/GlobalVars RuboCop offense

Refactored using a class attribute of `Cucumber::Formatter::Sauce`.

Change-Id: I44a63578466af7ed5092b8cf8c666d426c7cdc3a
---
M .rubocop_todo.yml
M lib/mediawiki_selenium/remote_browser_factory.rb
M lib/mediawiki_selenium/support/sauce.rb
3 files changed, 13 insertions(+), 10 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/selenium 
refs/changes/41/192041/1

diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml
index 8975744..e6e52e4 100644
--- a/.rubocop_todo.yml
+++ b/.rubocop_todo.yml
@@ -6,11 +6,6 @@
 # versions of RuboCop, may require this file to be generated again.
 
 # Offense count: 2
-# Configuration parameters: AllowedVariables.
-Style/GlobalVars:
-  Enabled: false
-
-# Offense count: 2
 # Configuration parameters: MinBodyLength.
 Style/GuardClause:
   Enabled: false
diff --git a/lib/mediawiki_selenium/remote_browser_factory.rb 
b/lib/mediawiki_selenium/remote_browser_factory.rb
index 28a3a33..f448c3c 100644
--- a/lib/mediawiki_selenium/remote_browser_factory.rb
+++ b/lib/mediawiki_selenium/remote_browser_factory.rb
@@ -1,3 +1,5 @@
+require "mediawiki_selenium/support/sauce"
+
 require "rest_client"
 require "uri"
 
@@ -58,6 +60,8 @@
 build: env.lookup(:build_number, default: nil),
   }.to_json
 )
+
+Cucumber::Formatter::Sauce.current_session_id = sid
   end
 end
 
diff --git a/lib/mediawiki_selenium/support/sauce.rb 
b/lib/mediawiki_selenium/support/sauce.rb
index bf99f91..1f540a5 100644
--- a/lib/mediawiki_selenium/support/sauce.rb
+++ b/lib/mediawiki_selenium/support/sauce.rb
@@ -3,18 +3,22 @@
 module Cucumber::Formatter
   class Sauce < Junit
 
+class << self
+  attr_accessor :current_session_id
+end
+
 private
 
 def format_exception(exception)
   if ENV["HEADLESS"] == "true"
-sauce_job_page = ""
-  elsif $session_id
-sauce_job_page = "Sauce Labs job URL: 
http://saucelabs.com/jobs/#{$session_id}\n";
+job_url = ""
+  elsif self.class.current_session_id
+job_url = "Sauce Labs job URL: 
http://saucelabs.com/jobs/#{self.class.current_session_id}\n";
   else
-sauce_job_page = "Uh-oh. Could not find link to Sauce Labs job URL."
+job_url = "Uh-oh. Could not find link to Sauce Labs job URL."
   end
 
-  msgs = [sauce_job_page] + ["#{exception.message} (#{exception.class})"] 
+ exception.backtrace
+  msgs = [job_url] + ["#{exception.message} (#{exception.class})"] + 
exception.backtrace
 
   msgs.join("\n")
 end

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I44a63578466af7ed5092b8cf8c666d426c7cdc3a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/selenium
Gerrit-Branch: master
Gerrit-Owner: Dduvall 

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


[MediaWiki-commits] [Gerrit] fix some indentation and test if gerrit works - change (operations/dns)

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

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

Change subject: fix some indentation and test if gerrit works
..

fix some indentation and test if gerrit works

Change-Id: I2a241d8e84c6ca2c14ac1d654434708b9f6a4e1a
---
M templates/10.in-addr.arpa
1 file changed, 14 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/dns 
refs/changes/40/192040/1

diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa
index a3d592a..99da0da 100644
--- a/templates/10.in-addr.arpa
+++ b/templates/10.in-addr.arpa
@@ -35,12 +35,20 @@
 23  1H  IN PTR  bits.svc.eqiad.wmnet.
 24  1H  IN PTR  upload.svc.eqiad.wmnet.
 25  1H  IN PTR  text.svc.eqiad.wmnet.
-26  1H  IN PTR  mobile.svc.eqiad.wmnet.
-27  1H  IN PTR  ms-fe.svc.eqiad.wmnet.
-28  1H  IN PTR  parsoid.svc.eqiad.wmnet.
-29  1H  IN PTR  parsoidcache.svc.eqiad.wmnet.
-30  1H  IN PTR  search.svc.eqiad.wmnet.
-31  1H  IN PTR  ocg.svc.eqiad.wmnet.
+26  1H  IN PTR  mobile.svc.eqiad.wmnet.
+27  1H  IN PTR  ms-fe.svc.eqiad.wmnet.
+28  1H  IN PTR  parsoid.svc.eqiad.wmnet.
+29  1H  IN PTR  parsoidcache.svc.eqiad.wmnet.
+30  1H  IN PTR  search.svc.eqiad.wmnet.
+31  1H  IN PTR  ocg.svc.eqiad.wmnet.
+26  1H  IN PTR  mobile.svc.eqiad.wmnet.
+27  1H  IN PTR  ms-fe.svc.eqiad.wmnet.
+28  1H  IN PTR  parsoid.svc.eqiad.wmnet.
+29  1H  IN PTR  parsoidcache.svc.eqiad.wmnet.
+30  1H  IN PTR  search.svc.eqiad.wmnet.
+31  1H  IN PTR  ocg.svc.eqiad.wmnet.
+32  1H  IN PTR  zotero.svc.eqiad.wmnet.
+>>> 004a491... fix some indentation and test if gerrit works
 
 ; esams svc ips
 

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

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

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


[MediaWiki-commits] [Gerrit] Fix typo: contian › contain - change (oojs/ui)

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

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

Change subject: Fix typo: contian › contain
..

Fix typo: contian › contain

Change-Id: I3b7a71c63ef7ed1454bdce5a884ca9a47817f316
---
M build/typos.json
M demos/demo.js
2 files changed, 4 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/ui refs/changes/39/192039/1

diff --git a/build/typos.json b/build/typos.json
index 4554e3b..5916d77 100644
--- a/build/typos.json
+++ b/build/typos.json
@@ -11,6 +11,7 @@
[ "\bteh\b", "the" ],
[ "intialization", "initialization" ],
[ "durring", "during" ],
+   [ "contian", "contain" ],
[ "occured", "occurred" ]
]
 }
diff --git a/demos/demo.js b/demos/demo.js
index ba1b1f5..a4d638c 100644
--- a/demos/demo.js
+++ b/demos/demo.js
@@ -89,7 +89,7 @@
 /**
  * Available themes.
  *
- * List of theme descriptions, each contianing a `fileSuffix` property used 
for linking to the
+ * List of theme descriptions, each containing a `fileSuffix` property used 
for linking to the
  * correct stylesheet file and a `theme` property containing a theme class
  *
  * @static
@@ -124,7 +124,7 @@
 /**
  * Available graphics formats.
  *
- * List of graphics format descriptions, each contianing a `fileSuffix` 
property used for linking
+ * List of graphics format descriptions, each containing a `fileSuffix` 
property used for linking
  * to the correct stylesheet file.
  *
  * @static
@@ -139,7 +139,7 @@
 /**
  * Available text directions.
  *
- * List of text direction descriptions, each contianing a `fileSuffix` 
property used for linking to
+ * List of text direction descriptions, each containing a `fileSuffix` 
property used for linking to
  * the correct stylesheet file.
  *
  * @static

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

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

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


[MediaWiki-commits] [Gerrit] Configured Style/FileName RuboCop excludes - change (mediawiki/selenium)

2015-02-20 Thread Dduvall (Code Review)
Dduvall has uploaded a new change for review.

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

Change subject: Configured Style/FileName RuboCop excludes
..

Configured Style/FileName RuboCop excludes

Change-Id: I1a9baed48b1025789e8280028a2121ee40ee5404
---
M .rubocop.yml
1 file changed, 3 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/selenium 
refs/changes/38/192038/1

diff --git a/.rubocop.yml b/.rubocop.yml
index e2c647c..dde895d 100644
--- a/.rubocop.yml
+++ b/.rubocop.yml
@@ -15,5 +15,8 @@
 Style/DotPosition:
   EnforcedStyle: trailing
 
+Style/FileName:
+  Exclude: ['bin/*']
+
 Style/SignalException:
   Enabled: false

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1a9baed48b1025789e8280028a2121ee40ee5404
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/selenium
Gerrit-Branch: master
Gerrit-Owner: Dduvall 

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


[MediaWiki-commits] [Gerrit] Convert to use extension registration - change (mediawiki...TemplateData)

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

Change subject: Convert to use extension registration
..


Convert to use extension registration

Bug: T87977
Change-Id: Ie1b822636289f9d7a1ec0a0b8175255441357cd3
---
A extension.json
1 file changed, 166 insertions(+), 0 deletions(-)

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



diff --git a/extension.json b/extension.json
new file mode 100644
index 000..4513b34
--- /dev/null
+++ b/extension.json
@@ -0,0 +1,166 @@
+{
+   "name": "TemplateData",
+   "version": "0.1.1",
+   "author": [
+   "Timo Tijhof",
+   "Moriel Schottlender",
+   "James D. Forrester",
+   "Trevor Parscal",
+   "Bartosz Dziewoński",
+   "Marielle Volz",
+   "..."
+   ],
+   "url": "https://www.mediawiki.org/wiki/Extension:TemplateData";,
+   "descriptionmsg": "templatedata-desc",
+   "license-name": "GPLv2",
+   "type": "parserhook",
+   "ExtensionMessagesFiles": {
+   "TemplateData": "TemplateData.i18n.php"
+   },
+   "APIModules": {
+   "templatedata": "ApiTemplateData"
+   },
+   "Hooks": {
+   "ParserFirstCallInit": [
+   "TemplateDataHooks::onParserFirstCallInit"
+   ],
+   "PageContentSave": [
+   "TemplateDataHooks::onPageContentSave"
+   ],
+   "UnitTestsList": [
+   "TemplateDataHooks::onUnitTestsList"
+   ],
+   "ResourceLoaderTestModules": [
+   "TemplateDataHooks::onResourceLoaderTestModules"
+   ],
+   "ResourceLoaderRegisterModules": [
+   "TemplateDataHooks::onResourceLoaderRegisterModules"
+   ],
+   "EditPage::showEditForm:initial": [
+   "TemplateDataHooks::onEditPage"
+   ]
+   },
+   "MessagesDirs": {
+   "TemplateData": [
+   "i18n"
+   ]
+   },
+   "config": {
+   "TemplateDataUseGUI": true
+   },
+   "ResourceModules": {
+   "ext.templateData": {
+   "styles": "resources/ext.templateData.css",
+   "position": "top"
+   },
+   "ext.templateDataGenerator.editPage": {
+   "scripts": [
+   "modules/ext.templateDataGenerator.editPage.js"
+   ],
+   "dependencies": [
+   "ext.templateDataGenerator.ui"
+   ],
+   "messages": [
+   "templatedata-editbutton",
+   "templatedata-helplink",
+   "templatedata-helplink-target",
+   "templatedata-errormsg-jsonbadformat"
+   ]
+   },
+   "ext.templateDataGenerator.data": {
+   "scripts": [
+   "modules/ext.templateDataGenerator.js",
+   "modules/ext.templateDataGenerator.data.js"
+   ],
+   "dependencies": [
+   "oojs"
+   ]
+   },
+   "ext.templateDataGenerator.ui": {
+   "styles": "modules/ext.templateDataGenerator.ui.css",
+   "scripts": [
+   "modules/ext.templateDataGenerator.ui.js",
+   
"modules/widgets/ext.templateDataGenerator.optionWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.optionImportWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.languageResultWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.languageSearchWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.dragDropItemWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.dragDropWidget.js",
+   
"modules/ext.templateDataGenerator.ui.tdDialog.js"
+   ],
+   "dependencies": [
+   "oojs-ui",
+   "ext.templateDataGenerator.data",
+   "jquery.uls.data"
+   ],
+   "messages": [
+   "comma-separator",
+   "templatedata-doc-no-params-set",
+   "templatedata-exists-on-related-page",
+   "templatedata-modal-button-add-language",

[MediaWiki-commits] [Gerrit] Corrected Style/EmptyLineBetweenDefs RuboCop offenses - change (mediawiki/selenium)

2015-02-20 Thread Dduvall (Code Review)
Dduvall has uploaded a new change for review.

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

Change subject: Corrected Style/EmptyLineBetweenDefs RuboCop offenses
..

Corrected Style/EmptyLineBetweenDefs RuboCop offenses

Change-Id: I3a6e5137cdf9217f701b352fdf6eba93b747d496
---
M .rubocop_todo.yml
M lib/mediawiki_selenium/support/pages/login_page.rb
2 files changed, 1 insertion(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/selenium 
refs/changes/37/192037/1

diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml
index 52ab5ea..9786a2a 100644
--- a/.rubocop_todo.yml
+++ b/.rubocop_todo.yml
@@ -6,12 +6,6 @@
 # versions of RuboCop, may require this file to be generated again.
 
 # Offense count: 1
-# Cop supports --auto-correct.
-# Configuration parameters: AllowAdjacentOneLineDefs.
-Style/EmptyLineBetweenDefs:
-  Enabled: false
-
-# Offense count: 1
 # Configuration parameters: Exclude.
 Style/FileName:
   Enabled: false
diff --git a/lib/mediawiki_selenium/support/pages/login_page.rb 
b/lib/mediawiki_selenium/support/pages/login_page.rb
index f84b688..b070ecb 100644
--- a/lib/mediawiki_selenium/support/pages/login_page.rb
+++ b/lib/mediawiki_selenium/support/pages/login_page.rb
@@ -17,6 +17,7 @@
   def logged_in_as_element
 @browser.div(id: "mw-content-text").p.b
   end
+
   def login_with(username, password, wait_for_logout_element = true)
 self.username_element.when_present.send_keys(username)
 self.password_element.when_present.send_keys(password)

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3a6e5137cdf9217f701b352fdf6eba93b747d496
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/selenium
Gerrit-Branch: master
Gerrit-Owner: Dduvall 

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


[MediaWiki-commits] [Gerrit] Configured Style/DotPosition RuboCop style - change (mediawiki/selenium)

2015-02-20 Thread Dduvall (Code Review)
Dduvall has uploaded a new change for review.

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

Change subject: Configured Style/DotPosition RuboCop style
..

Configured Style/DotPosition RuboCop style

Change-Id: I982c4409c12cd560e7ddbb8c4a03232a32c66fce
---
M .rubocop.yml
M .rubocop_todo.yml
2 files changed, 3 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/selenium 
refs/changes/36/192036/1

diff --git a/.rubocop.yml b/.rubocop.yml
index 56bdb56..e2c647c 100644
--- a/.rubocop.yml
+++ b/.rubocop.yml
@@ -12,5 +12,8 @@
 Style/Alias:
   Enabled: false
 
+Style/DotPosition:
+  EnforcedStyle: trailing
+
 Style/SignalException:
   Enabled: false
diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml
index 6929611..52ab5ea 100644
--- a/.rubocop_todo.yml
+++ b/.rubocop_todo.yml
@@ -5,12 +5,6 @@
 # Note that changes in the inspected code, or installation of new
 # versions of RuboCop, may require this file to be generated again.
 
-# Offense count: 12
-# Cop supports --auto-correct.
-# Configuration parameters: EnforcedStyle, SupportedStyles.
-Style/DotPosition:
-  Enabled: false
-
 # Offense count: 1
 # Cop supports --auto-correct.
 # Configuration parameters: AllowAdjacentOneLineDefs.

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I982c4409c12cd560e7ddbb8c4a03232a32c66fce
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/selenium
Gerrit-Branch: master
Gerrit-Owner: Dduvall 

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


[MediaWiki-commits] [Gerrit] Corrected Style/BlockComments RuboCop offenses - change (mediawiki/selenium)

2015-02-20 Thread Dduvall (Code Review)
Dduvall has uploaded a new change for review.

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

Change subject: Corrected Style/BlockComments RuboCop offenses
..

Corrected Style/BlockComments RuboCop offenses

Change-Id: I5119a0f92d4fb6d56f9ec7da58cf437fb84b762f
---
M .rubocop_todo.yml
M lib/mediawiki_selenium.rb
M lib/mediawiki_selenium/step_definitions/login_steps.rb
M lib/mediawiki_selenium/step_definitions/navigation_steps.rb
M lib/mediawiki_selenium/step_definitions/preferences_steps.rb
M lib/mediawiki_selenium/step_definitions/resource_loader_steps.rb
M lib/mediawiki_selenium/support/env.rb
M lib/mediawiki_selenium/support/hooks.rb
M lib/mediawiki_selenium/support/sauce.rb
M lib/mediawiki_selenium/version.rb
10 files changed, 0 insertions(+), 104 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/selenium 
refs/changes/35/192035/1

diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml
index b75ad2a..6929611 100644
--- a/.rubocop_todo.yml
+++ b/.rubocop_todo.yml
@@ -5,11 +5,6 @@
 # Note that changes in the inspected code, or installation of new
 # versions of RuboCop, may require this file to be generated again.
 
-# Offense count: 9
-# Cop supports --auto-correct.
-Style/BlockComments:
-  Enabled: false
-
 # Offense count: 12
 # Cop supports --auto-correct.
 # Configuration parameters: EnforcedStyle, SupportedStyles.
diff --git a/lib/mediawiki_selenium.rb b/lib/mediawiki_selenium.rb
index b3ad51c..7f1185b 100644
--- a/lib/mediawiki_selenium.rb
+++ b/lib/mediawiki_selenium.rb
@@ -1,14 +1,3 @@
-=begin
-This file is subject to the license terms in the LICENSE file found in the
-mediawiki_selenium top-level directory and at
-https://git.wikimedia.org/blob/mediawiki%2Fselenium/HEAD/LICENSE. No part of
-mediawiki_selenium, including this file, may be copied, modified, propagated, 
or
-distributed except according to the terms contained in the LICENSE file.
-Copyright 2013 by the Mediawiki developers. See the CREDITS file in the
-mediawiki_selenium top-level directory and at
-https://git.wikimedia.org/blob/mediawiki%2Fselenium/HEAD/CREDITS.
-=end
-
 module MediawikiSelenium
   autoload :VERSION, "mediawiki_selenium/version"
   autoload :ApiHelper, "mediawiki_selenium/support/modules/api_helper"
diff --git a/lib/mediawiki_selenium/step_definitions/login_steps.rb 
b/lib/mediawiki_selenium/step_definitions/login_steps.rb
index 9a0d7e5..fb55c91 100644
--- a/lib/mediawiki_selenium/step_definitions/login_steps.rb
+++ b/lib/mediawiki_selenium/step_definitions/login_steps.rb
@@ -1,14 +1,3 @@
-=begin
-This file is subject to the license terms in the LICENSE file found in the
-mediawiki_selenium top-level directory and at
-https://git.wikimedia.org/blob/mediawiki%2Fselenium/HEAD/LICENSE. No part of
-mediawiki_selenium, including this file, may be copied, modified, propagated, 
or
-distributed except according to the terms contained in the LICENSE file.
-Copyright 2013 by the Mediawiki developers. See the CREDITS file in the
-mediawiki_selenium top-level directory and at
-https://git.wikimedia.org/blob/mediawiki%2Fselenium/HEAD/CREDITS.
-=end
-
 Given(/^I am logged in(?: as (\w+))$/) do |user|
   as_user(user) do |user, password|
 visit(LoginPage).login_with(user, password)
diff --git a/lib/mediawiki_selenium/step_definitions/navigation_steps.rb 
b/lib/mediawiki_selenium/step_definitions/navigation_steps.rb
index 1b66f24..d9edf3e 100644
--- a/lib/mediawiki_selenium/step_definitions/navigation_steps.rb
+++ b/lib/mediawiki_selenium/step_definitions/navigation_steps.rb
@@ -1,14 +1,3 @@
-=begin
-This file is subject to the license terms in the LICENSE file found in the
-mediawiki_selenium top-level directory and at
-https://git.wikimedia.org/blob/mediawiki%2Fselenium/HEAD/LICENSE. No part of
-mediawiki_selenium, including this file, may be copied, modified, propagated, 
or
-distributed except according to the terms contained in the LICENSE file.
-Copyright 2013 by the Mediawiki developers. See the CREDITS file in the
-mediawiki_selenium top-level directory and at
-https://git.wikimedia.org/blob/mediawiki%2Fselenium/HEAD/CREDITS.
-=end
-
 Given(/^I am at a random page.*$/) do
   visit RandomPage
 end
diff --git a/lib/mediawiki_selenium/step_definitions/preferences_steps.rb 
b/lib/mediawiki_selenium/step_definitions/preferences_steps.rb
index 0bbd6c7..45bc94f 100644
--- a/lib/mediawiki_selenium/step_definitions/preferences_steps.rb
+++ b/lib/mediawiki_selenium/step_definitions/preferences_steps.rb
@@ -1,14 +1,3 @@
-=begin
-This file is subject to the license terms in the LICENSE file found in the
-mediawiki_selenium top-level directory and at
-https://git.wikimedia.org/blob/mediawiki%2Fselenium/HEAD/LICENSE. No part of
-mediawiki_selenium, including this file, may be copied, modified, propagated, 
or
-distributed except according to the terms contained in the LICENSE file.
-Copyright 2013 by the Mediawiki developers. See the CREDITS file in the

[MediaWiki-commits] [Gerrit] build: Include 'lib' and 'dist' in jsduck output - change (oojs/ui)

2015-02-20 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

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

Change subject: build: Include 'lib' and 'dist' in jsduck output
..

build: Include 'lib' and 'dist' in jsduck output

This fixes Live Preview functionality triggered by @example,
which is currently broken due to 404 Not Found errors.

* Copy 'lib' and 'dist' using a grunt task.

  In a similar situation in VisualEditor we opted for a bash
  script but that makes maintenance from CI harder. Implementing
  an entry point 'npm doc' instead makes things more flexible
  and uniform.

  We could make it part of the test pipeline, but leaving that
  for another commit since Jenkins is currently configured to
  do that in a separate job already.

* Move eg-iframe.html to jsduck.eg-iframe.html.

* Add basic css normalisation so that we don't have a serif font.
  (Taken from demo.)

Bug: T90120
Change-Id: Ic3896a396d85c90860d88647954039e4d54057fb
---
M Gruntfile.js
R jsduck.eg-iframe.html
M jsduck.json
M package.json
4 files changed, 29 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/ui refs/changes/34/192034/1

diff --git a/Gruntfile.js b/Gruntfile.js
index c4ea5e9..d61ac82 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -227,6 +227,11 @@
dest: 'dist/',
expand: true,
rename: strip( 'dist/tmp/' )
+   },
+   jsduck: {
+   src: '{lib,dist}/**/*',
+   dest: 'docs/',
+   expand: true
}
},
colorizeSvg: {
@@ -362,6 +367,17 @@
} );
} );
 
+   grunt.registerTask( 'jsduck', function () {
+   var done = this.async(),
+   spawn = require( 'child_process' ).spawn,
+   jsduck = spawn( 'jsduck', [ '--color' ] );
+   jsduck.stdout.pipe( process.stdout );
+   jsduck.stderr.pipe( process.stderr );
+   jsduck.on( 'close', function ( code ) {
+   done( code === 0 );
+   } );
+   } );
+
grunt.registerTask( 'build-code', [ 'concat:js', 'uglify' ] );
grunt.registerTask( 'build-styling', [
'copy:lessTemp', 'colorizeSvg', 'less', 'copy:svg', 
'copy:imagesCommon',
@@ -384,6 +400,7 @@
 
grunt.registerTask( 'lint', [ 'jshint', 'jscs', 'csslint', 'banana' ] );
grunt.registerTask( 'test', [ 'pre-test', 'git-build', 'lint', 
'karma:main', 'karma:other' ] );
+   grunt.registerTask( 'doc', [ 'build', 'jsduck', 'copy:jsduck' ] );
 
grunt.registerTask( 'default', 'test' );
 };
diff --git a/eg-iframe.html b/jsduck.eg-iframe.html
similarity index 71%
rename from eg-iframe.html
rename to jsduck.eg-iframe.html
index b62efa5..c4a8e8f 100644
--- a/eg-iframe.html
+++ b/jsduck.eg-iframe.html
@@ -5,13 +5,19 @@
OOjs UI example


+   
+   body {
+   font-size: 100%;
+   font-family: sans-serif;
+   }
+   

 
 
-   
-   
-   
-   
+   
+   
+   
+   

[MediaWiki-commits] [Gerrit] Enable $wgTemplateDataUseGUI by default - change (mediawiki...TemplateData)

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

Change subject: Enable $wgTemplateDataUseGUI by default
..


Enable $wgTemplateDataUseGUI by default

It's stable enough now.

Change-Id: I45fd4d1f0d4eda4f9e55aeffb1dae4cc5c4ef553
---
M TemplateData.php
1 file changed, 2 insertions(+), 3 deletions(-)

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



diff --git a/TemplateData.php b/TemplateData.php
index 21f6bb8..8b361c2 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -163,6 +163,5 @@
 
 /* Configuration */
 
-// Set this to true to use the template documentation
-// editor feature
-$wgTemplateDataUseGUI = false;
+// Set this to false to disable the template documentation editor feature
+$wgTemplateDataUseGUI = true;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I45fd4d1f0d4eda4f9e55aeffb1dae4cc5c4ef553
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TemplateData
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Mooeypoo 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Update MultimediaViewer submodule - change (mediawiki/core)

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

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

Change subject: Update MultimediaViewer submodule
..

Update MultimediaViewer submodule

Adds Id53cd9c176528da33b393e5ed807d6f2e0886413 (Fix canvas height
calculation)

Change-Id: I62b67af6d7384b369c262164b28a97efc0225b3d
---
M extensions/MultimediaViewer
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/33/192033/1

diff --git a/extensions/MultimediaViewer b/extensions/MultimediaViewer
index 76059f7..7e1dcc7 16
--- a/extensions/MultimediaViewer
+++ b/extensions/MultimediaViewer
-Subproject commit 76059f73460539ebeded1181a394b36a70ba434a
+Subproject commit 7e1dcc77f776fca90d8ad69f11d31592baac0bc4

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I62b67af6d7384b369c262164b28a97efc0225b3d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.25wmf17
Gerrit-Owner: Gergő Tisza 

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


[MediaWiki-commits] [Gerrit] Update MultimediaViewer submodule - change (mediawiki/core)

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

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

Change subject: Update MultimediaViewer submodule
..

Update MultimediaViewer submodule

Adds Id53cd9c176528da33b393e5ed807d6f2e0886413 (Fix canvas height
calculation)

Change-Id: Iceec7856cb5e438fd498e619fafc70d85177f667
---
M extensions/MultimediaViewer
1 file changed, 0 insertions(+), 0 deletions(-)


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

diff --git a/extensions/MultimediaViewer b/extensions/MultimediaViewer
index 008ab6e..e3da4d9 16
--- a/extensions/MultimediaViewer
+++ b/extensions/MultimediaViewer
-Subproject commit 008ab6ec9888080e9813ece9119f8249ae4c1999
+Subproject commit e3da4d9094ee178cfedcd123a9953365c854857b

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iceec7856cb5e438fd498e619fafc70d85177f667
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.25wmf18
Gerrit-Owner: Gergő Tisza 

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


[MediaWiki-commits] [Gerrit] fix Xcodeproj code signing - change (apps...wikipedia)

2015-02-20 Thread Dr0ptp4kt (Code Review)
Dr0ptp4kt has submitted this change and it was merged.

Change subject: fix Xcodeproj code signing
..


fix Xcodeproj code signing

Use "Developer" identity for Debug and "Distribution" for release, and
select the provisioning profile automatically.

bumped to 4.0.7 (4.0.7.1)

Change-Id: Ief9fca18dedf2982845ee960a6c076567112c70a
---
M Wikipedia.xcodeproj/project.pbxproj
M Wikipedia.xcodeproj/xcshareddata/xcschemes/Wikipedia.xcscheme
M wikipedia/Wikipedia-Info.plist
3 files changed, 4 insertions(+), 10 deletions(-)

Approvals:
  Dr0ptp4kt: Verified; Looks good to me, approved
  Mhurd: Looks good to me, but someone else must approve



diff --git a/Wikipedia.xcodeproj/project.pbxproj 
b/Wikipedia.xcodeproj/project.pbxproj
index 42de168..87b495c 100644
--- a/Wikipedia.xcodeproj/project.pbxproj
+++ b/Wikipedia.xcodeproj/project.pbxproj
@@ -3166,7 +3166,6 @@
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
-   "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone 
Developer";
COPY_PHASE_STRIP = NO;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
@@ -3205,7 +3204,6 @@
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
-   "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone 
Developer";
COPY_PHASE_STRIP = YES;
ENABLE_NS_ASSERTIONS = NO;
GCC_C_LANGUAGE_STANDARD = gnu99;
@@ -3233,7 +3231,6 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = 
LaunchImage;
CODE_SIGN_IDENTITY = "iPhone Developer";
-   "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone 
Developer";
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = 
"wikipedia/Wikipedia-Prefix.pch";
HEADER_SEARCH_PATHS = (
@@ -3249,7 +3246,6 @@
LIBRARY_SEARCH_PATHS = "$(inherited)";
OTHER_LDFLAGS = "$(inherited)";
PRODUCT_NAME = Wikipedia;
-   PROVISIONING_PROFILE = "";
WARNING_CFLAGS = (
"$(inherited)",
"-Werror=switch",
@@ -3266,8 +3262,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = 
LaunchImage;
-   CODE_SIGN_IDENTITY = "iPhone Developer";
-   "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone 
Developer";
+   CODE_SIGN_IDENTITY = "iPhone Distribution";
GCC_OPTIMIZATION_LEVEL = 3;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = 
"wikipedia/Wikipedia-Prefix.pch";
@@ -3284,7 +3279,6 @@
LIBRARY_SEARCH_PATHS = "$(inherited)";
OTHER_LDFLAGS = "$(inherited)";
PRODUCT_NAME = Wikipedia;
-   PROVISIONING_PROFILE = "";
WARNING_CFLAGS = (
"$(inherited)",
"-Werror=switch",
diff --git a/Wikipedia.xcodeproj/xcshareddata/xcschemes/Wikipedia.xcscheme 
b/Wikipedia.xcodeproj/xcshareddata/xcschemes/Wikipedia.xcscheme
index e9ba8ff..a33c7a0 100644
--- a/Wikipedia.xcodeproj/xcshareddata/xcschemes/Wikipedia.xcscheme
+++ b/Wikipedia.xcodeproj/xcshareddata/xcschemes/Wikipedia.xcscheme
@@ -14,7 +14,7 @@
 buildForAnalyzing = "YES">
 
diff --git a/wikipedia/Wikipedia-Info.plist b/wikipedia/Wikipedia-Info.plist
index c13bee5..29e4b68 100644
--- a/wikipedia/Wikipedia-Info.plist
+++ b/wikipedia/Wikipedia-Info.plist
@@ -17,11 +17,11 @@
CFBundlePackageType
APPL
CFBundleShortVersionString
-   4.0.6
+   4.0.7
CFBundleSignature

CFBundleVersion
-   4.0.6.0
+   4.0.7.1
LSRequiresIPhoneOS

NSLocationWhenInUseUsageDescription

-- 
To view, visit https://gerrit.wikimedia.org/r/191763
To unsubscribe, visit https://gerrit.wikim

[MediaWiki-commits] [Gerrit] Work around Firefox bug allowing cursor in cE=false - change (VisualEditor/VisualEditor)

2015-02-20 Thread Catrope (Code Review)
Catrope has uploaded a new change for review.

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

Change subject: Work around Firefox bug allowing cursor in cE=false
..

Work around Firefox bug allowing cursor in cE=false

Firefox allows the cursor to move into a cE=false node if it's
moving from a different cE=true container than the one that
contains the node. See https://bugzilla.mozilla.org/show_bug.cgi?id=1132768

Setting -moz-user-select: none; stops this from happening.

Bug: T70537
Change-Id: I428e2dbbf3be73834919e8ab31d3f4160e27ff8e
---
M src/ce/styles/nodes/ve.ce.FocusableNode.css
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/31/192031/1

diff --git a/src/ce/styles/nodes/ve.ce.FocusableNode.css 
b/src/ce/styles/nodes/ve.ce.FocusableNode.css
index 0a3559c..f0fe696 100644
--- a/src/ce/styles/nodes/ve.ce.FocusableNode.css
+++ b/src/ce/styles/nodes/ve.ce.FocusableNode.css
@@ -24,6 +24,8 @@
 
 .ve-ce-focusableNode {
cursor: default;
+   /* T70537: work around Firefox bug */
+   -moz-user-select: none;
 }
 
 .ve-ce-focusableNode-dropMarker {

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

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

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


[MediaWiki-commits] [Gerrit] Enable $wgTemplateDataUseGUI by default - change (mediawiki...TemplateData)

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

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

Change subject: Enable $wgTemplateDataUseGUI by default
..

Enable $wgTemplateDataUseGUI by default

It's stable enough now.

Change-Id: I45fd4d1f0d4eda4f9e55aeffb1dae4cc5c4ef553
---
M TemplateData.php
1 file changed, 2 insertions(+), 3 deletions(-)


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

diff --git a/TemplateData.php b/TemplateData.php
index 21f6bb8..8b361c2 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -163,6 +163,5 @@
 
 /* Configuration */
 
-// Set this to true to use the template documentation
-// editor feature
-$wgTemplateDataUseGUI = false;
+// Set this to false to disable the template documentation editor feature
+$wgTemplateDataUseGUI = true;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I45fd4d1f0d4eda4f9e55aeffb1dae4cc5c4ef553
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TemplateData
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] [WIP] Analyze failure rates by type - change (analytics/limn-edit-data)

2015-02-20 Thread Milimetric (Code Review)
Milimetric has uploaded a new change for review.

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

Change subject: [WIP] Analyze failure rates by type
..

[WIP] Analyze failure rates by type

Main trouble right now is no way to pivot and display the results by
type of failure, as would be very easy on a modern db...

Change-Id: I74faf8aa59a991ae9e5a44096ae4152547dd7052
---
A edit/failure_rates_by_type.sql
1 file changed, 49 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/limn-edit-data 
refs/changes/29/192029/1

diff --git a/edit/failure_rates_by_type.sql b/edit/failure_rates_by_type.sql
new file mode 100644
index 000..fa2dcb5
--- /dev/null
+++ b/edit/failure_rates_by_type.sql
@@ -0,0 +1,49 @@
+set @from_time  = '{from_timestamp}';
+set @to_time= '{to_timestamp}';
+set @wiki   = '{wiki}';
+
+set @from_time  = '2014121500';
+set @to_time= '2014121900';
+set @wiki   = 'rowiki';
+
+ select day,
+sum(if(actions like '%saveAttempt%saveFailure%', repeated, 0)) /
+sum(if(actions like '%saveAttempt%', repeated, 0)) as failureRate
+   from (select date(timestamp) as day,
+actions,
+failures,
+count(*) as repeated
+   from (select timestamp,
+event_editingSessionId,
+wiki,
+group_concat(event_action order by timestamp, 
action_order.ord separator '-') as actions,
+group_concat(`event_action.saveFailure.type` order by 
timestamp separator '-') as failures
+   from staging.milimetric_edit
+inner join
+(select 'init' as action, 0 as ord
+union all
+ select 'ready' as action, 1 as ord
+union all
+ select 'saveIntent' as action, 2 as ord
+union all
+ select 'saveAttempt' as action, 3 as ord
+union all
+ select 'saveFailure' as action, 4 as ord
+union all
+ select 'saveSuccess' as action, 5 as ord
+union all
+ select 'abort' as action, 6 as ord
+) action_order  on action = 
staging.milimetric_edit.event_action
+  where event_editor = 'visualeditor'
+and timestamp between @from_time and @to_time
+and (@wiki is null or wiki = @wiki)
+  group by clientIp, event_editingSessionId
+ # this purposefully ignores sessions that start before 
"from_timestamp",
+ # as well as some other sessions that legitimately do not 
have an "init"
+ # as well as sessions that have an "init" after "ready"
+ having actions like 'init%'
+) sessions
+  group by day, actions, failures
+) actions
+  group by day
+;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I74faf8aa59a991ae9e5a44096ae4152547dd7052
Gerrit-PatchSet: 1
Gerrit-Project: analytics/limn-edit-data
Gerrit-Branch: master
Gerrit-Owner: Milimetric 

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


[MediaWiki-commits] [Gerrit] Kill reference to $wgPageProps - change (mediawiki...TemplateData)

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

Change subject: Kill reference to $wgPageProps
..


Kill reference to $wgPageProps

Apparently it hasn't existed since 2010.

Change-Id: I34ee6b0d2b95f1dbdf778585c3d6ef5ba3eeed64
---
M TemplateData.php
1 file changed, 0 insertions(+), 3 deletions(-)

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



diff --git a/TemplateData.php b/TemplateData.php
index 92ff324..8ab8717 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -41,9 +41,6 @@
 // Register APIs
 $wgAPIModules['templatedata'] = 'ApiTemplateData';
 
-// Register page properties
-$wgPageProps['templatedata'] = 'Content of  tag';
-
 // Register modules
 $wgResourceModules['ext.templateData'] = array(
'styles' => 'resources/ext.templateData.css',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I34ee6b0d2b95f1dbdf778585c3d6ef5ba3eeed64
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TemplateData
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Fix canvas height calculation - change (mediawiki...MultimediaViewer)

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

Change subject: Fix canvas height calculation
..


Fix canvas height calculation

Canvas height is calculated as viewport height minus above-the-fold
height but the latter did not take into account the padding. This
was probably broken last autumn when the above-the-fold contents
were rearranged, but the max-height rule on the image masked the
error so we did not notice until that rule was dropped.

Bug: T89631
Change-Id: Id53cd9c176528da33b393e5ed807d6f2e0886413
(cherry picked from commit 3bb2b8185a45fbc0c01ad53f8810fdf9ed7ca4e7)
---
M resources/mmv/ui/mmv.ui.canvas.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/resources/mmv/ui/mmv.ui.canvas.js 
b/resources/mmv/ui/mmv.ui.canvas.js
index 2a58d17..2ed1f2f 100644
--- a/resources/mmv/ui/mmv.ui.canvas.js
+++ b/resources/mmv/ui/mmv.ui.canvas.js
@@ -372,7 +372,7 @@
// Depending on what the wrapper contains, its size can 
be 0 on some browsers.
// Therefore, we calculate the available space manually
availableWidth = $window.width(),
-   availableHeight = $window.height() - ( isFullscreened ? 
0 : $aboveFold.height() );
+   availableHeight = $window.height() - ( isFullscreened ? 
0 : $aboveFold.outerHeight() );
 
if ( forFullscreen ) {
return {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id53cd9c176528da33b393e5ed807d6f2e0886413
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: wmf/1.25wmf18
Gerrit-Owner: Gergő Tisza 
Gerrit-Reviewer: Gergő Tisza 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Update author credits - change (mediawiki...TemplateData)

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

Change subject: Update author credits
..


Update author credits

Change-Id: I93e2dd5ec4cdfad15a0ef150eb3a358f3f414f99
---
M TemplateData.php
1 file changed, 6 insertions(+), 0 deletions(-)

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



diff --git a/TemplateData.php b/TemplateData.php
index 92ff324..653ad28 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -11,6 +11,12 @@
'name' => 'TemplateData',
'author' => array(
'Timo Tijhof',
+   'Moriel Schottlender',
+   'James D. Forrester',
+   'Trevor Parscal',
+   'Bartosz Dziewoński',
+   'Marielle Volz',
+   '...'
),
'version' => '0.1.1',
'url' => 'https://www.mediawiki.org/wiki/Extension:TemplateData',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I93e2dd5ec4cdfad15a0ef150eb3a358f3f414f99
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/TemplateData
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
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] Fix canvas height calculation - change (mediawiki...MultimediaViewer)

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

Change subject: Fix canvas height calculation
..


Fix canvas height calculation

Canvas height is calculated as viewport height minus above-the-fold
height but the latter did not take into account the padding. This
was probably broken last autumn when the above-the-fold contents
were rearranged, but the max-height rule on the image masked the
error so we did not notice until that rule was dropped.

Bug: T89631
Change-Id: Id53cd9c176528da33b393e5ed807d6f2e0886413
(cherry picked from commit 3bb2b8185a45fbc0c01ad53f8810fdf9ed7ca4e7)
---
M resources/mmv/ui/mmv.ui.canvas.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/resources/mmv/ui/mmv.ui.canvas.js 
b/resources/mmv/ui/mmv.ui.canvas.js
index 2a58d17..2ed1f2f 100644
--- a/resources/mmv/ui/mmv.ui.canvas.js
+++ b/resources/mmv/ui/mmv.ui.canvas.js
@@ -372,7 +372,7 @@
// Depending on what the wrapper contains, its size can 
be 0 on some browsers.
// Therefore, we calculate the available space manually
availableWidth = $window.width(),
-   availableHeight = $window.height() - ( isFullscreened ? 
0 : $aboveFold.height() );
+   availableHeight = $window.height() - ( isFullscreened ? 
0 : $aboveFold.outerHeight() );
 
if ( forFullscreen ) {
return {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id53cd9c176528da33b393e5ed807d6f2e0886413
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: wmf/1.25wmf17
Gerrit-Owner: Gergő Tisza 
Gerrit-Reviewer: Gergő Tisza 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Kill reference to $wgPageProps - change (mediawiki...TemplateData)

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

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

Change subject: Kill reference to $wgPageProps
..

Kill reference to $wgPageProps

Apparently it hasn't existed since 2010.

Change-Id: I34ee6b0d2b95f1dbdf778585c3d6ef5ba3eeed64
---
M TemplateData.php
1 file changed, 0 insertions(+), 3 deletions(-)


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

diff --git a/TemplateData.php b/TemplateData.php
index 92ff324..8ab8717 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -41,9 +41,6 @@
 // Register APIs
 $wgAPIModules['templatedata'] = 'ApiTemplateData';
 
-// Register page properties
-$wgPageProps['templatedata'] = 'Content of  tag';
-
 // Register modules
 $wgResourceModules['ext.templateData'] = array(
'styles' => 'resources/ext.templateData.css',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I34ee6b0d2b95f1dbdf778585c3d6ef5ba3eeed64
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TemplateData
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] Fixing links on NoLocalSettings page - change (mediawiki/core)

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

Change subject: Fixing links on NoLocalSettings page
..


Fixing links on NoLocalSettings page

This fixes a regression caused by change I28cd13d4d.

Change-Id: Iff30f08688d17da2d690c5e798c43489b1cafc7e
---
M includes/templates/NoLocalSettings.mustache
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/includes/templates/NoLocalSettings.mustache 
b/includes/templates/NoLocalSettings.mustache
index 1649e3b..8a4616c 100644
--- a/includes/templates/NoLocalSettings.mustache
+++ b/includes/templates/NoLocalSettings.mustache
@@ -28,10 +28,10 @@
{{^localSettingsExists}}
LocalSettings.php not found.
{{#installerStarted}}
-   Please complete the installation and 
download LocalSettings.php.
+   Please complete the installation and 
download LocalSettings.php.
{{/installerStarted}}
{{^installerStarted}}
-   Please set up the wiki first!
+   Please set up the wiki first!
{{/installerStarted}}
{{/localSettingsExists}}


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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iff30f08688d17da2d690c5e798c43489b1cafc7e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Kaldari 
Gerrit-Reviewer: Cscott 
Gerrit-Reviewer: Jackmcbarn 
Gerrit-Reviewer: Jjanes 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: MaxSem 
Gerrit-Reviewer: Phuedx 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Move to wfUseMW for compatibility detection - change (mediawiki...TemplateData)

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

Change subject: Move to wfUseMW for compatibility detection
..


Move to wfUseMW for compatibility detection

Change-Id: I46f9c148ec14eae557c4c9c44832a368e2d72e82
---
M TemplateData.hooks.php
M TemplateData.php
2 files changed, 4 insertions(+), 5 deletions(-)

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



diff --git a/TemplateData.hooks.php b/TemplateData.hooks.php
index 3cc8d21..3d1d6dd 100644
--- a/TemplateData.hooks.php
+++ b/TemplateData.hooks.php
@@ -7,6 +7,9 @@
  */
 
 class TemplateDataHooks {
+   public static function onSetup() {
+   wfUseMW( '1.22wmf18' );
+   }
 
/**
 * Register parser hooks
diff --git a/TemplateData.php b/TemplateData.php
index c83a5af..92ff324 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -6,11 +6,6 @@
  * @ingroup Extensions
  */
 
-if ( version_compare( $wgVersion, '1.22wmf18', '<' ) ) {
-   echo "Extension:TemplateData requires MediaWiki 1.22 or higher.\n";
-   exit( 1 );
-}
-
 $wgExtensionCredits['parserhook'][] = array(
'path' => __FILE__,
'name' => 'TemplateData',
@@ -41,6 +36,7 @@
 $wgHooks['ResourceLoaderTestModules'][] = 
'TemplateDataHooks::onResourceLoaderTestModules';
 $wgHooks['ResourceLoaderRegisterModules'][] = 
'TemplateDataHooks::onResourceLoaderRegisterModules';
 $wgHooks['EditPage::showEditForm:initial'][] = 'TemplateDataHooks::onEditPage';
+$wgExtensionFunctions[] = 'TemplateDataHooks::onSetup';
 
 // Register APIs
 $wgAPIModules['templatedata'] = 'ApiTemplateData';

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I46f9c148ec14eae557c4c9c44832a368e2d72e82
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/TemplateData
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
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] Fix canvas height calculation - change (mediawiki...MultimediaViewer)

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

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

Change subject: Fix canvas height calculation
..

Fix canvas height calculation

Canvas height is calculated as viewport height minus above-the-fold
height but the latter did not take into account the padding. This
was probably broken last autumn when the above-the-fold contents
were rearranged, but the max-height rule on the image masked the
error so we did not notice until that rule was dropped.

Bug: T89631
Change-Id: Id53cd9c176528da33b393e5ed807d6f2e0886413
(cherry picked from commit 3bb2b8185a45fbc0c01ad53f8810fdf9ed7ca4e7)
---
M resources/mmv/ui/mmv.ui.canvas.js
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/resources/mmv/ui/mmv.ui.canvas.js 
b/resources/mmv/ui/mmv.ui.canvas.js
index 2a58d17..2ed1f2f 100644
--- a/resources/mmv/ui/mmv.ui.canvas.js
+++ b/resources/mmv/ui/mmv.ui.canvas.js
@@ -372,7 +372,7 @@
// Depending on what the wrapper contains, its size can 
be 0 on some browsers.
// Therefore, we calculate the available space manually
availableWidth = $window.width(),
-   availableHeight = $window.height() - ( isFullscreened ? 
0 : $aboveFold.height() );
+   availableHeight = $window.height() - ( isFullscreened ? 
0 : $aboveFold.outerHeight() );
 
if ( forFullscreen ) {
return {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id53cd9c176528da33b393e5ed807d6f2e0886413
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: wmf/1.25wmf17
Gerrit-Owner: Gergő Tisza 

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


[MediaWiki-commits] [Gerrit] Fixing links on NoLocalSettings page - change (mediawiki/core)

2015-02-20 Thread Kaldari (Code Review)
Kaldari has uploaded a new change for review.

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

Change subject: Fixing links on NoLocalSettings page
..

Fixing links on NoLocalSettings page

This fixes a regression caused by change I28cd13d4d.

Change-Id: Iff30f08688d17da2d690c5e798c43489b1cafc7e
---
M includes/templates/NoLocalSettings.mustache
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/26/192026/1

diff --git a/includes/templates/NoLocalSettings.mustache 
b/includes/templates/NoLocalSettings.mustache
index 1649e3b..8a4616c 100644
--- a/includes/templates/NoLocalSettings.mustache
+++ b/includes/templates/NoLocalSettings.mustache
@@ -28,10 +28,10 @@
{{^localSettingsExists}}
LocalSettings.php not found.
{{#installerStarted}}
-   Please complete the installation and 
download LocalSettings.php.
+   Please complete the installation and 
download LocalSettings.php.
{{/installerStarted}}
{{^installerStarted}}
-   Please set up the wiki first!
+   Please set up the wiki first!
{{/installerStarted}}
{{/localSettingsExists}}


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

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

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


[MediaWiki-commits] [Gerrit] Fix canvas height calculation - change (mediawiki...MultimediaViewer)

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

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

Change subject: Fix canvas height calculation
..

Fix canvas height calculation

Canvas height is calculated as viewport height minus above-the-fold
height but the latter did not take into account the padding. This
was probably broken last autumn when the above-the-fold contents
were rearranged, but the max-height rule on the image masked the
error so we did not notice until that rule was dropped.

Bug: T89631
Change-Id: Id53cd9c176528da33b393e5ed807d6f2e0886413
(cherry picked from commit 3bb2b8185a45fbc0c01ad53f8810fdf9ed7ca4e7)
---
M resources/mmv/ui/mmv.ui.canvas.js
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/resources/mmv/ui/mmv.ui.canvas.js 
b/resources/mmv/ui/mmv.ui.canvas.js
index 2a58d17..2ed1f2f 100644
--- a/resources/mmv/ui/mmv.ui.canvas.js
+++ b/resources/mmv/ui/mmv.ui.canvas.js
@@ -372,7 +372,7 @@
// Depending on what the wrapper contains, its size can 
be 0 on some browsers.
// Therefore, we calculate the available space manually
availableWidth = $window.width(),
-   availableHeight = $window.height() - ( isFullscreened ? 
0 : $aboveFold.height() );
+   availableHeight = $window.height() - ( isFullscreened ? 
0 : $aboveFold.outerHeight() );
 
if ( forFullscreen ) {
return {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id53cd9c176528da33b393e5ed807d6f2e0886413
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: wmf/1.25wmf18
Gerrit-Owner: Gergő Tisza 

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


[MediaWiki-commits] [Gerrit] Update author credits - change (mediawiki...TemplateData)

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

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

Change subject: Update author credits
..

Update author credits

Change-Id: I93e2dd5ec4cdfad15a0ef150eb3a358f3f414f99
---
M TemplateData.php
1 file changed, 6 insertions(+), 0 deletions(-)


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

diff --git a/TemplateData.php b/TemplateData.php
index 92ff324..653ad28 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -11,6 +11,12 @@
'name' => 'TemplateData',
'author' => array(
'Timo Tijhof',
+   'Moriel Schottlender',
+   'James D. Forrester',
+   'Trevor Parscal',
+   'Bartosz Dziewoński',
+   'Marielle Volz',
+   '...'
),
'version' => '0.1.1',
'url' => 'https://www.mediawiki.org/wiki/Extension:TemplateData',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I93e2dd5ec4cdfad15a0ef150eb3a358f3f414f99
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TemplateData
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] Move to wfUseMW for comptaibility detection - change (mediawiki...TemplateData)

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

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

Change subject: Move to wfUseMW for comptaibility detection
..

Move to wfUseMW for comptaibility detection

Change-Id: I46f9c148ec14eae557c4c9c44832a368e2d72e82
---
M TemplateData.hooks.php
M TemplateData.php
2 files changed, 4 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TemplateData 
refs/changes/22/192022/1

diff --git a/TemplateData.hooks.php b/TemplateData.hooks.php
index 3cc8d21..3d1d6dd 100644
--- a/TemplateData.hooks.php
+++ b/TemplateData.hooks.php
@@ -7,6 +7,9 @@
  */
 
 class TemplateDataHooks {
+   public static function onSetup() {
+   wfUseMW( '1.22wmf18' );
+   }
 
/**
 * Register parser hooks
diff --git a/TemplateData.php b/TemplateData.php
index c83a5af..92ff324 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -6,11 +6,6 @@
  * @ingroup Extensions
  */
 
-if ( version_compare( $wgVersion, '1.22wmf18', '<' ) ) {
-   echo "Extension:TemplateData requires MediaWiki 1.22 or higher.\n";
-   exit( 1 );
-}
-
 $wgExtensionCredits['parserhook'][] = array(
'path' => __FILE__,
'name' => 'TemplateData',
@@ -41,6 +36,7 @@
 $wgHooks['ResourceLoaderTestModules'][] = 
'TemplateDataHooks::onResourceLoaderTestModules';
 $wgHooks['ResourceLoaderRegisterModules'][] = 
'TemplateDataHooks::onResourceLoaderRegisterModules';
 $wgHooks['EditPage::showEditForm:initial'][] = 'TemplateDataHooks::onEditPage';
+$wgExtensionFunctions[] = 'TemplateDataHooks::onSetup';
 
 // Register APIs
 $wgAPIModules['templatedata'] = 'ApiTemplateData';

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I46f9c148ec14eae557c4c9c44832a368e2d72e82
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/TemplateData
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] Convert to use extension registration - change (mediawiki...TemplateData)

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

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

Change subject: Convert to use extension registration
..

Convert to use extension registration

Bug: T87977
Change-Id: Ie1b822636289f9d7a1ec0a0b8175255441357cd3
---
A extension.json
1 file changed, 169 insertions(+), 0 deletions(-)


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

diff --git a/extension.json b/extension.json
new file mode 100644
index 000..f59c628
--- /dev/null
+++ b/extension.json
@@ -0,0 +1,169 @@
+{
+   "name": "TemplateData",
+   "version": "0.1.1",
+   "author": [
+   "Timo Tijhof",
+   "Moriel Schottlender",
+   "James D. Forrester",
+   "Trevor Parscal",
+   "Bartosz Dziewoński",
+   "Marielle Volz",
+   "..."
+   ],
+   "url": "https://www.mediawiki.org/wiki/Extension:TemplateData";,
+   "descriptionmsg": "templatedata-desc",
+   "license-name": "GPLv2",
+   "type": "parserhook",
+   "ExtensionMessagesFiles": {
+   "TemplateData": "TemplateData.i18n.php"
+   },
+   "APIModules": {
+   "templatedata": "ApiTemplateData"
+   },
+   "Hooks": {
+   "ParserFirstCallInit": [
+   "TemplateDataHooks::onParserFirstCallInit"
+   ],
+   "PageContentSave": [
+   "TemplateDataHooks::onPageContentSave"
+   ],
+   "UnitTestsList": [
+   "TemplateDataHooks::onUnitTestsList"
+   ],
+   "ResourceLoaderTestModules": [
+   "TemplateDataHooks::onResourceLoaderTestModules"
+   ],
+   "ResourceLoaderRegisterModules": [
+   "TemplateDataHooks::onResourceLoaderRegisterModules"
+   ],
+   "EditPage::showEditForm:initial": [
+   "TemplateDataHooks::onEditPage"
+   ]
+   },
+   "MessagesDirs": {
+   "TemplateData": [
+   "i18n"
+   ]
+   },
+   "config": {
+   "TemplateDataUseGUI": false,
+   "PageProps": {
+   "templatedata": "Content of  tag"
+   }
+   },
+   "ResourceModules": {
+   "ext.templateData": {
+   "styles": "resources/ext.templateData.css",
+   "position": "top"
+   },
+   "ext.templateDataGenerator.editPage": {
+   "scripts": [
+   "modules/ext.templateDataGenerator.editPage.js"
+   ],
+   "dependencies": [
+   "ext.templateDataGenerator.ui"
+   ],
+   "messages": [
+   "templatedata-editbutton",
+   "templatedata-helplink",
+   "templatedata-helplink-target",
+   "templatedata-errormsg-jsonbadformat"
+   ]
+   },
+   "ext.templateDataGenerator.data": {
+   "scripts": [
+   "modules/ext.templateDataGenerator.js",
+   "modules/ext.templateDataGenerator.data.js"
+   ],
+   "dependencies": [
+   "oojs"
+   ]
+   },
+   "ext.templateDataGenerator.ui": {
+   "styles": "modules/ext.templateDataGenerator.ui.css",
+   "scripts": [
+   "modules/ext.templateDataGenerator.ui.js",
+   
"modules/widgets/ext.templateDataGenerator.optionWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.optionImportWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.languageResultWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.languageSearchWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.dragDropItemWidget.js",
+   
"modules/widgets/ext.templateDataGenerator.dragDropWidget.js",
+   
"modules/ext.templateDataGenerator.ui.tdDialog.js"
+   ],
+   "dependencies": [
+   "oojs-ui",
+   "ext.templateDataGenerator.data",
+   "jquery.uls.data"
+   ],
+   "messages": [
+   "comma-separator",
+

[MediaWiki-commits] [Gerrit] config.domainMap, cleanup - change (mediawiki...graphoid)

2015-02-20 Thread Yurik (Code Review)
Yurik has submitted this change and it was merged.

Change subject: config.domainMap, cleanup
..


config.domainMap, cleanup

Change-Id: If0f9de09547c5cd8268370d4d3d58fad3878057e
---
M graphoid-worker.js
1 file changed, 74 insertions(+), 32 deletions(-)

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



diff --git a/graphoid-worker.js b/graphoid-worker.js
index 1883866..65a960c 100644
--- a/graphoid-worker.js
+++ b/graphoid-worker.js
@@ -10,13 +10,9 @@
 console.log( ' - ' + instanceName + ' loading...' );
 
 var express = require('express'),
-   fs = require('fs'),
-   child_process = require('child_process'),
request = require('request-promise'),
Promise = require('promise'), // https://www.npmjs.com/package/promise
-   http = require('http'),
urllib = require('url'),
-   querystring = require('querystring'),
vega = null; // Visualization grammar - https://github.com/trifacta/vega
 
 
@@ -31,21 +27,50 @@
 // Get the config
 try {
config = require('./graphoid.config.json');
-   if (!config.hasOwnProperty('domains') || !(config.domains instanceof 
Array) || config.domains.length == 0) {
-   throw 'The config "domains" value must be a non-empty list of 
domains';
-   }
 } catch (err) {
console.error('Error loading graphoid.config.json');
console.error(err);
process.exit(1);
 }
 
-var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
config.domains.join('|') + ')$');
+// A list of allowed hosts
+config.domains = config.domains || [];
+
+// A set of 'oldHost' => 'newHost' mappings
+config.domainMap = config.domainMap || {};
+
+// For protocol-relative URLs  (they begin with //), which protocol should we 
use
+config.defaultProtocol = config.defaultProtocol || 'http:';
+
+// Limit request to 10 seconds by default
+config.timeout = config.timeout || 1;
+
+var validDomains = 
config.domains.concat(Object.getOwnPropertyNames(config.domainMap));
+
+if (validDomains.length == 0) {
+   console.error('Config must have non-empty "domains" (list) and/or 
"domainMap" (dict)');
+   process.exit(1);
+}
+
+var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
validDomains.join('|') + ')$');
 
 if (vega) {
vega.config.domainWhiteList = config.domains;
-   vega.config.defaultProtocol = config.defaultProtocol || 'http:';
+   vega.config.defaultProtocol = config.defaultProtocol;
vega.config.safeMode = true;
+   if (Object.getOwnPropertyNames(config.domainMap) > 0) {
+   var originalSanitize = vega.data.load.sanitizeUrl;
+   vega.data.load.sanitizeUrl = function(url) {
+   url = originalSanitize(url);
+   if (url) {
+   url = 
url.replace(/^(https?:\/\/)([-a-z0-9.]+)/, function(match, prot, host){
+   var repl = config.domainMap[host];
+   return repl ? prot + repl : match;
+   });
+   }
+   return url;
+   };
+   }
 }
 
 // NOTE: there are a few libraries that do this
@@ -81,26 +106,28 @@
}
if (body.hasOwnProperty('query') && 
body.query.hasOwnProperty('pages')) {
var pages = body.query.pages,
-   graph_spec = null;
+   graphData = null;
 
Object.getOwnPropertyNames(pages).some(function (k) {
var page = pages[k];
if (page.hasOwnProperty('pageprops') && 
page.pageprops.hasOwnProperty('graph_specs')) {
var gs = 
JSON.parse(page.pageprops.graph_specs);
if (gs.hasOwnProperty(id)) {
-   graph_spec = gs[id];
+   graphData = gs[id];
return true;
}
}
return false;
});
 
-   if (graph_spec) {
-   return graph_spec;
+   if (graphData) {
+   return graphData;
}
}
-   return body.hasOwnProperty('continue') ?
-   callApiInt(url, merge(qs, body.continue)) : false;
+   if (body.hasOwnProperty('continue')) {
+   callApiInt(url, merge(qs, body.continue));
+   }
+   throw 'Unable to find graph_specs with the given id';
};
 
callApiInt = function(url, options) {
@@ -125,14 +152,30 @@
 }
 
 function 

[MediaWiki-commits] [Gerrit] config.domainMap, cleanup - change (mediawiki...graphoid)

2015-02-20 Thread Yurik (Code Review)
Yurik has uploaded a new change for review.

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

Change subject: config.domainMap, cleanup
..

config.domainMap, cleanup

Change-Id: If0f9de09547c5cd8268370d4d3d58fad3878057e
---
M graphoid-worker.js
1 file changed, 74 insertions(+), 32 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/graphoid 
refs/changes/21/192021/1

diff --git a/graphoid-worker.js b/graphoid-worker.js
index 1883866..65a960c 100644
--- a/graphoid-worker.js
+++ b/graphoid-worker.js
@@ -10,13 +10,9 @@
 console.log( ' - ' + instanceName + ' loading...' );
 
 var express = require('express'),
-   fs = require('fs'),
-   child_process = require('child_process'),
request = require('request-promise'),
Promise = require('promise'), // https://www.npmjs.com/package/promise
-   http = require('http'),
urllib = require('url'),
-   querystring = require('querystring'),
vega = null; // Visualization grammar - https://github.com/trifacta/vega
 
 
@@ -31,21 +27,50 @@
 // Get the config
 try {
config = require('./graphoid.config.json');
-   if (!config.hasOwnProperty('domains') || !(config.domains instanceof 
Array) || config.domains.length == 0) {
-   throw 'The config "domains" value must be a non-empty list of 
domains';
-   }
 } catch (err) {
console.error('Error loading graphoid.config.json');
console.error(err);
process.exit(1);
 }
 
-var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
config.domains.join('|') + ')$');
+// A list of allowed hosts
+config.domains = config.domains || [];
+
+// A set of 'oldHost' => 'newHost' mappings
+config.domainMap = config.domainMap || {};
+
+// For protocol-relative URLs  (they begin with //), which protocol should we 
use
+config.defaultProtocol = config.defaultProtocol || 'http:';
+
+// Limit request to 10 seconds by default
+config.timeout = config.timeout || 1;
+
+var validDomains = 
config.domains.concat(Object.getOwnPropertyNames(config.domainMap));
+
+if (validDomains.length == 0) {
+   console.error('Config must have non-empty "domains" (list) and/or 
"domainMap" (dict)');
+   process.exit(1);
+}
+
+var serverRe = new RegExp('^([-a-z0-9]+\\.)?(m\\.|zero\\.)?(' + 
validDomains.join('|') + ')$');
 
 if (vega) {
vega.config.domainWhiteList = config.domains;
-   vega.config.defaultProtocol = config.defaultProtocol || 'http:';
+   vega.config.defaultProtocol = config.defaultProtocol;
vega.config.safeMode = true;
+   if (Object.getOwnPropertyNames(config.domainMap) > 0) {
+   var originalSanitize = vega.data.load.sanitizeUrl;
+   vega.data.load.sanitizeUrl = function(url) {
+   url = originalSanitize(url);
+   if (url) {
+   url = 
url.replace(/^(https?:\/\/)([-a-z0-9.]+)/, function(match, prot, host){
+   var repl = config.domainMap[host];
+   return repl ? prot + repl : match;
+   });
+   }
+   return url;
+   };
+   }
 }
 
 // NOTE: there are a few libraries that do this
@@ -81,26 +106,28 @@
}
if (body.hasOwnProperty('query') && 
body.query.hasOwnProperty('pages')) {
var pages = body.query.pages,
-   graph_spec = null;
+   graphData = null;
 
Object.getOwnPropertyNames(pages).some(function (k) {
var page = pages[k];
if (page.hasOwnProperty('pageprops') && 
page.pageprops.hasOwnProperty('graph_specs')) {
var gs = 
JSON.parse(page.pageprops.graph_specs);
if (gs.hasOwnProperty(id)) {
-   graph_spec = gs[id];
+   graphData = gs[id];
return true;
}
}
return false;
});
 
-   if (graph_spec) {
-   return graph_spec;
+   if (graphData) {
+   return graphData;
}
}
-   return body.hasOwnProperty('continue') ?
-   callApiInt(url, merge(qs, body.continue)) : false;
+   if (body.hasOwnProperty('continue')) {
+   callApiInt(url, merge(qs, body.continue));
+   }
+   throw 'Unable to find graph_specs with the given id';
};
 
ca

[MediaWiki-commits] [Gerrit] Collection session: protect against 'enabled' key being unset - change (mediawiki...Collection)

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

Change subject: Collection session: protect against 'enabled' key being unset
..


Collection session: protect against 'enabled' key being unset

Change-Id: I0055f0bdd873dd653b36aec698dcdcde29d97560
---
M Collection.session.php
1 file changed, 2 insertions(+), 1 deletion(-)

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



diff --git a/Collection.session.php b/Collection.session.php
index c099a83..8e83ce0 100644
--- a/Collection.session.php
+++ b/Collection.session.php
@@ -80,7 +80,8 @@
 * @return bool
 */
static function isEnabled() {
-   return ( self::hasSession() && 
$_SESSION['wsCollection']['enabled'] );
+   return self::hasSession() && isset( 
$_SESSION['wsCollection']['enabled'] ) &&
+   $_SESSION['wsCollection']['enabled'];
}
 
/**

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I0055f0bdd873dd653b36aec698dcdcde29d97560
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Collection
Gerrit-Branch: master
Gerrit-Owner: Chad 
Gerrit-Reviewer: Aaron Schulz 
Gerrit-Reviewer: Cscott 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Fix JS error caused by typo - change (mediawiki...Citoid)

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

Change subject: Fix JS error caused by typo
..


Fix JS error caused by typo

Bug: T90297
Change-Id: I838190bd5b242185cca7bf35c55a0b893f1011ca
---
M modules/ve.ui.CiteFromIDDialogTool.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/modules/ve.ui.CiteFromIDDialogTool.js 
b/modules/ve.ui.CiteFromIDDialogTool.js
index de89706..0186129 100644
--- a/modules/ve.ui.CiteFromIDDialogTool.js
+++ b/modules/ve.ui.CiteFromIDDialogTool.js
@@ -29,7 +29,7 @@
ve.ui.CiteFromIDDialogTool.static.title = mw.msg( 
'citoid-citeFromIDTool-title' );
ve.ui.CiteFromIDDialogTool.static.group = 'cite';
ve.ui.CiteFromIDDialogTool.static.commandName = 'citefromid';
-   ve.ui.CiteFromIDDiologTool.static.autoAddToCatchall = false;
+   ve.ui.CiteFromIDDialogTool.static.autoAddToCatchall = false;
 
ve.ui.commandRegistry.register(
new ve.ui.Command(

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I838190bd5b242185cca7bf35c55a0b893f1011ca
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Citoid
Gerrit-Branch: master
Gerrit-Owner: Catrope 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Fix JS error caused by typo - change (mediawiki...Citoid)

2015-02-20 Thread Catrope (Code Review)
Catrope has uploaded a new change for review.

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

Change subject: Fix JS error caused by typo
..

Fix JS error caused by typo

Bug: T90297
Change-Id: I838190bd5b242185cca7bf35c55a0b893f1011ca
---
M modules/ve.ui.CiteFromIDDialogTool.js
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Citoid 
refs/changes/20/192020/1

diff --git a/modules/ve.ui.CiteFromIDDialogTool.js 
b/modules/ve.ui.CiteFromIDDialogTool.js
index de89706..0186129 100644
--- a/modules/ve.ui.CiteFromIDDialogTool.js
+++ b/modules/ve.ui.CiteFromIDDialogTool.js
@@ -29,7 +29,7 @@
ve.ui.CiteFromIDDialogTool.static.title = mw.msg( 
'citoid-citeFromIDTool-title' );
ve.ui.CiteFromIDDialogTool.static.group = 'cite';
ve.ui.CiteFromIDDialogTool.static.commandName = 'citefromid';
-   ve.ui.CiteFromIDDiologTool.static.autoAddToCatchall = false;
+   ve.ui.CiteFromIDDialogTool.static.autoAddToCatchall = false;
 
ve.ui.commandRegistry.register(
new ve.ui.Command(

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I838190bd5b242185cca7bf35c55a0b893f1011ca
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Citoid
Gerrit-Branch: master
Gerrit-Owner: Catrope 

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


[MediaWiki-commits] [Gerrit] Use EDIT_TOKEN_SUFFIX constant instead of global define - change (mediawiki...ContactPageFundraiser)

2015-02-20 Thread Chad (Code Review)
Chad has uploaded a new change for review.

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

Change subject: Use EDIT_TOKEN_SUFFIX constant instead of global define
..

Use EDIT_TOKEN_SUFFIX constant instead of global define

Change-Id: I4a9e471d8f61cf468af61be8cede26f4356c5b21
---
M SpecialContactFundraiser.php
1 file changed, 2 insertions(+), 2 deletions(-)


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

diff --git a/SpecialContactFundraiser.php b/SpecialContactFundraiser.php
index b3c8f58..ea1c1a2 100644
--- a/SpecialContactFundraiser.php
+++ b/SpecialContactFundraiser.php
@@ -76,7 +76,7 @@
if( $this->getUser()->isAnon() ) {
# Anonymous users may not have a session
# open. Check for suffix anyway.
-   $tokenOk = ( EDIT_TOKEN_SUFFIX == $token );
+   $tokenOk = ( User::EDIT_TOKEN_SUFFIX == $token 
);
} else {
$tokenOk = $this->getUser()->matchEditToken( 
$token );
}
@@ -186,7 +186,7 @@
 
$titleObj = SpecialPage::getTitleFor( "Contact" );
$action = htmlspecialchars( $titleObj->getLocalURL( 
"action=submit" ) );
-   $token = $wgUser->isAnon() ? EDIT_TOKEN_SUFFIX : 
$wgUser->getEditToken(); //this kind of sucks, really...
+   $token = $wgUser->isAnon() ? User::EDIT_TOKEN_SUFFIX : 
$wgUser->getEditToken(); //this kind of sucks, really...
$token = htmlspecialchars( $token );
 
$wgOut->addHTML( "

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4a9e471d8f61cf468af61be8cede26f4356c5b21
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContactPageFundraiser
Gerrit-Branch: master
Gerrit-Owner: Chad 

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


[MediaWiki-commits] [Gerrit] Repair infinite scroll behaviour - change (mediawiki...Flow)

2015-02-20 Thread EBernhardson (Code Review)
EBernhardson has uploaded a new change for review.

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

Change subject: Repair infinite scroll behaviour
..

Repair infinite scroll behaviour

A recent patch to give the TOC some breathing room ended up
breaking the infinite scroll behaviour.  Looks to be an
unintentional change of that patch.  The variable in question
is already resolved to a number, so requesting .top gives undefined
and using it in an equation gets NaN, which always gives a comparison
result of false and does not click the loadmore button.

Bug: T90295
Change-Id: I2ad5de7b3e266879a48ecef90fd59a1820473238
---
M modules/engine/components/board/features/flow-board-loadmore.js
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/modules/engine/components/board/features/flow-board-loadmore.js 
b/modules/engine/components/board/features/flow-board-loadmore.js
index 75b3581..e1f190c 100644
--- a/modules/engine/components/board/features/flow-board-loadmore.js
+++ b/modules/engine/components/board/features/flow-board-loadmore.js
@@ -488,7 +488,7 @@
// also shouldn't be triggered if it's still behind TOC!
 
// Is this element in the viewport?
-   if ( nodeOffset - nodeHeight <= 
calculationContainerThreshold.top + calculationContainerHeight ) {
+   if ( nodeOffset - nodeHeight <= 
calculationContainerThreshold + calculationContainerHeight ) {
// Element is almost in viewport, click it.
$( this ).trigger( 'click' );
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2ad5de7b3e266879a48ecef90fd59a1820473238
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
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] Collection session: protect against 'enabled' key being unset - change (mediawiki...Collection)

2015-02-20 Thread Chad (Code Review)
Chad has uploaded a new change for review.

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

Change subject: Collection session: protect against 'enabled' key being unset
..

Collection session: protect against 'enabled' key being unset

Change-Id: I0055f0bdd873dd653b36aec698dcdcde29d97560
---
M Collection.session.php
1 file changed, 2 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Collection 
refs/changes/17/192017/1

diff --git a/Collection.session.php b/Collection.session.php
index c099a83..8e83ce0 100644
--- a/Collection.session.php
+++ b/Collection.session.php
@@ -80,7 +80,8 @@
 * @return bool
 */
static function isEnabled() {
-   return ( self::hasSession() && 
$_SESSION['wsCollection']['enabled'] );
+   return self::hasSession() && isset( 
$_SESSION['wsCollection']['enabled'] ) &&
+   $_SESSION['wsCollection']['enabled'];
}
 
/**

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0055f0bdd873dd653b36aec698dcdcde29d97560
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Collection
Gerrit-Branch: master
Gerrit-Owner: Chad 

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


[MediaWiki-commits] [Gerrit] zotero: require 'firefox'; get rid of shell wrapper - change (operations/puppet)

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

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

Change subject: zotero: require 'firefox'; get rid of shell wrapper
..

zotero: require 'firefox'; get rid of shell wrapper

* 'run_translation-server.sh' just adds indirection and mystery; instead we can
  have the Upstart job set LD_LIBRARY_PATH and invoke xpcshell by itself.
* Add a dependency on firefox package. It will pull in the libraries that
  zotero depends on, per https://phabricator.wikimedia.org/T76308#1055620
* Use the default Upstart logging rather than redirecting to /var/log/citoid.
  Upstart-managed log files get rotated automatically.

Change-Id: I42f70e38e7262b569ea9088846f72e08e3706a63
---
M modules/citoid/manifests/init.pp
M modules/citoid/templates/upstart-zotero.erb
2 files changed, 3 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/16/192016/1

diff --git a/modules/citoid/manifests/init.pp b/modules/citoid/manifests/init.pp
index c849a92..710d1c2 100644
--- a/modules/citoid/manifests/init.pp
+++ b/modules/citoid/manifests/init.pp
@@ -9,6 +9,7 @@
 #
 class citoid( $port = 1970 ) {
 require_package('nodejs')
+require_package('firefox')
 
 package { 'citoid/deploy':
 provider => 'trebuchet',
diff --git a/modules/citoid/templates/upstart-zotero.erb 
b/modules/citoid/templates/upstart-zotero.erb
index 7ec994e..c5ef91e 100644
--- a/modules/citoid/templates/upstart-zotero.erb
+++ b/modules/citoid/templates/upstart-zotero.erb
@@ -16,5 +16,6 @@
 # wait 60 seconds for a graceful restart before killing the master
 kill timeout 60
 
+env LD_LIBRARY_PATH="/srv/deployment/citoid/deploy/translation-server"
 chdir /srv/deployment/citoid/deploy/translation-server
-exec ./run_translation-server.sh >> /var/log/citoid/zotero.log 2>&1
+exec /srv/deployment/citoid/deploy/translation-server/xpcshell -v 180 -mn 
translation-server/init.js

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I42f70e38e7262b569ea9088846f72e08e3706a63
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh 

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


[MediaWiki-commits] [Gerrit] Update VisualEditor for cherry-picks - change (mediawiki/core)

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

Change subject: Update VisualEditor for cherry-picks
..


Update VisualEditor for cherry-picks

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

Approvals:
  Ori.livneh: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/extensions/VisualEditor b/extensions/VisualEditor
index e468dd4..ff6cd0f 16
--- a/extensions/VisualEditor
+++ b/extensions/VisualEditor
-Subproject commit e468dd45547e15506f5642345437333e7cd4dd02
+Subproject commit ff6cd0faff043075341614ce56a8e9bf88b471c3

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6f9b85ba118691af628e48a5454c42e22415de75
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.25wmf18
Gerrit-Owner: Ori.livneh 
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] Update VisualEditor for cherry-picks - change (mediawiki/core)

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

Change subject: Update VisualEditor for cherry-picks
..


Update VisualEditor for cherry-picks

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

Approvals:
  Ori.livneh: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/extensions/VisualEditor b/extensions/VisualEditor
index 549615f..ca916c1 16
--- a/extensions/VisualEditor
+++ b/extensions/VisualEditor
-Subproject commit 549615fbe2daaf4b8fa8309f1e4fc0b777175568
+Subproject commit ca916c1d9c2477867eb20fe372f172b3eaf3b7f4

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I00181c1eab5020b6b33480c813048f72b29b4003
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.25wmf17
Gerrit-Owner: Ori.livneh 
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] Use EDIT_TOKEN_SUFFIX constant instead of global define - change (mediawiki...DonationInterface)

2015-02-20 Thread Chad (Code Review)
Chad has uploaded a new change for review.

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

Change subject: Use EDIT_TOKEN_SUFFIX constant instead of global define
..

Use EDIT_TOKEN_SUFFIX constant instead of global define

Change-Id: Ia4ef0876a7769e5153163792a300364a7e664b39
---
M gateway_common/gateway.adapter.php
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/gateway_common/gateway.adapter.php 
b/gateway_common/gateway.adapter.php
index d111f55..d45af22 100644
--- a/gateway_common/gateway.adapter.php
+++ b/gateway_common/gateway.adapter.php
@@ -3189,7 +3189,7 @@
$salt = implode( "|", $salt );
}
 
-   $salted = md5( $clear_token . $salt ) . EDIT_TOKEN_SUFFIX;
+   $salted = md5( $clear_token . $salt ) . User::EDIT_TOKEN_SUFFIX;
return $salted;
}
 

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

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

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


[MediaWiki-commits] [Gerrit] Add 'width' and 'height' to the list of attributes corrupted... - change (VisualEditor/VisualEditor)

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

Change subject: Add 'width' and 'height' to the list of attributes corrupted by 
IE
..


Add 'width' and 'height' to the list of attributes corrupted by IE

Change-Id: I49d42822ad227a1d2500c99fc14a488149b4d0d3
---
M src/ve.utils.js
1 file changed, 6 insertions(+), 3 deletions(-)

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



diff --git a/src/ve.utils.js b/src/ve.utils.js
index 0dad84d..6f8d677 100644
--- a/src/ve.utils.js
+++ b/src/ve.utils.js
@@ -872,8 +872,9 @@
  * Helper function for #transformStyleAttributes.
  *
  * Normalize an attribute value. In compliant browsers, this should be
- * a no-op, but in IE style attributes are normalized on all elements and
- * bgcolor attributes are normalized on some elements (like ``).
+ * a no-op, but in IE style attributes are normalized on all elements,
+ * color and bgcolor attributes are normalized on some elements (like ``),
+ * and width and height attributes are normalized on some elements( like 
``).
  *
  * @param {string} name Attribute name
  * @param {string} value Attribute value
@@ -904,7 +905,9 @@
maskAttrs = [
'style', // IE normalizes 'color:#ffd' to 'color: 
rgb(255, 255, 221);'
'bgcolor', // IE normalizes '#FFDEAD' to '#ffdead'
-   'color' // IE normalized 'Red' to 'red'
+   'color', // IE normalizes 'Red' to 'red'
+   'width', // IE normalizes '240px' to '240'
+   'height' // Same as width
];
 
// Parse the HTML into an XML DOM

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I49d42822ad227a1d2500c99fc14a488149b4d0d3
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Catrope 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Update VisualEditor for cherry-picks - change (mediawiki/core)

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

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

Change subject: Update VisualEditor for cherry-picks
..

Update VisualEditor for cherry-picks

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


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

diff --git a/extensions/VisualEditor b/extensions/VisualEditor
index 549615f..ca916c1 16
--- a/extensions/VisualEditor
+++ b/extensions/VisualEditor
-Subproject commit 549615fbe2daaf4b8fa8309f1e4fc0b777175568
+Subproject commit ca916c1d9c2477867eb20fe372f172b3eaf3b7f4

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I00181c1eab5020b6b33480c813048f72b29b4003
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.25wmf17
Gerrit-Owner: Ori.livneh 

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


[MediaWiki-commits] [Gerrit] Update VisualEditor for cherry-picks - change (mediawiki/core)

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

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

Change subject: Update VisualEditor for cherry-picks
..

Update VisualEditor for cherry-picks

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


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

diff --git a/extensions/VisualEditor b/extensions/VisualEditor
index e468dd4..ff6cd0f 16
--- a/extensions/VisualEditor
+++ b/extensions/VisualEditor
-Subproject commit e468dd45547e15506f5642345437333e7cd4dd02
+Subproject commit ff6cd0faff043075341614ce56a8e9bf88b471c3

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6f9b85ba118691af628e48a5454c42e22415de75
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.25wmf18
Gerrit-Owner: Ori.livneh 

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


[MediaWiki-commits] [Gerrit] Fix ve.init.mw.trackSubscriber.js - change (mediawiki...VisualEditor)

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

Change subject: Fix ve.init.mw.trackSubscriber.js
..


Fix ve.init.mw.trackSubscriber.js

* Use the event's timeStamp rather than the current time in the event
  subscriber.
* Instead of using ve.trackSubscribeAll() and then branching on the topic
  prefix, just use ve.trackSubscribe( prefix, ... ) to bind prefix-specific
  handlers.
* Round timing measurements after performing arithmetic, and use Math#round
  rather than Math#floor.
* Rename 'getDefaultTiming' to 'computeDuration'.

Change-Id: I27ff1622ecea9b82d414f871441f127fc2dbd2cc
(cherry picked from commit 9b582485f951152648eec235d706e87e77b80ff6)
---
M modules/ve-mw/init/ve.init.mw.trackSubscriber.js
1 file changed, 53 insertions(+), 53 deletions(-)

Approvals:
  Ori.livneh: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js 
b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
index b23bc77..3622100 100644
--- a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
+++ b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
@@ -9,24 +9,28 @@
 
 ( function () {
 
-   var lastEventWithAction = {},
+   var timing = {},
editingSessionId = mw.user.generateRandomSessionId();
 
-   function getDefaultTiming( action, data, now ) {
+   function computeDuration( action, event, timeStamp ) {
+   if ( event.timing !== undefined ) {
+   return event.timing;
+   }
+
switch ( action ) {
case 'init':
// Account for second opening
-   return now - Math.max(
-   Math.floor( window.mediaWikiLoadStart ),
-   lastEventWithAction.saveSuccess || 0,
-   lastEventWithAction.abort || 0
+   return timeStamp - Math.max(
+   window.mediaWikiLoadStart,
+   timing.saveSuccess || 0,
+   timing.abort || 0
);
case 'ready':
-   return now - lastEventWithAction.init;
+   return timeStamp - timing.init;
case 'saveIntent':
-   return now - lastEventWithAction.ready;
+   return timeStamp - timing.ready;
case 'saveAttempt':
-   return now - lastEventWithAction.saveIntent;
+   return timeStamp - timing.saveIntent;
case 'saveSuccess':
case 'saveFailure':
// HERE BE DRAGONS: the caller must compute 
these themselves
@@ -35,49 +39,39 @@
mw.log.warn( 've.init.mw.trackSubscriber: Do 
not rely on default timing value for saveSuccess/saveFailure' );
return -1;
case 'abort':
-   switch ( data.type ) {
+   switch ( event.type ) {
case 'preinit':
-   return now - 
lastEventWithAction.init;
+   return timeStamp - timing.init;
case 'nochange':
case 'switchwith':
case 'switchwithout':
case 'abandon':
-   return now - 
lastEventWithAction.ready;
+   return timeStamp - timing.ready;
case 'abandonMidsave':
-   return now - 
lastEventWithAction.saveAttempt;
+   return timeStamp - 
timing.saveAttempt;
}
}
mw.log.warn( 've.init.mw.trackSubscriber: Unrecognized action', 
action );
return -1;
}
 
-   ve.trackSubscribeAll( function ( topic, data ) {
-   data = data || {};
-   var newData, action,
-   now = Math.floor( ve.now() ),
-   prefix = topic.slice( 0, topic.indexOf( '.' ) );
+   ve.trackSubscribe( 'mwedit.', function ( topic, data, timeStamp ) {
+   var action = topic.split( '.' )[1],
+   event;
 
-   if ( prefix === 'mwtiming' ) {
-   // Add type for save errors; not in the topic for 
stupid historical reasons
-   

[MediaWiki-commits] [Gerrit] Fix ve.init.mw.trackSubscriber.js - change (mediawiki...VisualEditor)

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

Change subject: Fix ve.init.mw.trackSubscriber.js
..


Fix ve.init.mw.trackSubscriber.js

* Use the event's timeStamp rather than the current time in the event
  subscriber.
* Instead of using ve.trackSubscribeAll() and then branching on the topic
  prefix, just use ve.trackSubscribe( prefix, ... ) to bind prefix-specific
  handlers.
* Round timing measurements after performing arithmetic, and use Math#round
  rather than Math#floor.
* Rename 'getDefaultTiming' to 'computeDuration'.

Change-Id: I27ff1622ecea9b82d414f871441f127fc2dbd2cc
(cherry picked from commit 9b582485f951152648eec235d706e87e77b80ff6)
---
M modules/ve-mw/init/ve.init.mw.trackSubscriber.js
1 file changed, 53 insertions(+), 53 deletions(-)

Approvals:
  Ori.livneh: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js 
b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
index b23bc77..3622100 100644
--- a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
+++ b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
@@ -9,24 +9,28 @@
 
 ( function () {
 
-   var lastEventWithAction = {},
+   var timing = {},
editingSessionId = mw.user.generateRandomSessionId();
 
-   function getDefaultTiming( action, data, now ) {
+   function computeDuration( action, event, timeStamp ) {
+   if ( event.timing !== undefined ) {
+   return event.timing;
+   }
+
switch ( action ) {
case 'init':
// Account for second opening
-   return now - Math.max(
-   Math.floor( window.mediaWikiLoadStart ),
-   lastEventWithAction.saveSuccess || 0,
-   lastEventWithAction.abort || 0
+   return timeStamp - Math.max(
+   window.mediaWikiLoadStart,
+   timing.saveSuccess || 0,
+   timing.abort || 0
);
case 'ready':
-   return now - lastEventWithAction.init;
+   return timeStamp - timing.init;
case 'saveIntent':
-   return now - lastEventWithAction.ready;
+   return timeStamp - timing.ready;
case 'saveAttempt':
-   return now - lastEventWithAction.saveIntent;
+   return timeStamp - timing.saveIntent;
case 'saveSuccess':
case 'saveFailure':
// HERE BE DRAGONS: the caller must compute 
these themselves
@@ -35,49 +39,39 @@
mw.log.warn( 've.init.mw.trackSubscriber: Do 
not rely on default timing value for saveSuccess/saveFailure' );
return -1;
case 'abort':
-   switch ( data.type ) {
+   switch ( event.type ) {
case 'preinit':
-   return now - 
lastEventWithAction.init;
+   return timeStamp - timing.init;
case 'nochange':
case 'switchwith':
case 'switchwithout':
case 'abandon':
-   return now - 
lastEventWithAction.ready;
+   return timeStamp - timing.ready;
case 'abandonMidsave':
-   return now - 
lastEventWithAction.saveAttempt;
+   return timeStamp - 
timing.saveAttempt;
}
}
mw.log.warn( 've.init.mw.trackSubscriber: Unrecognized action', 
action );
return -1;
}
 
-   ve.trackSubscribeAll( function ( topic, data ) {
-   data = data || {};
-   var newData, action,
-   now = Math.floor( ve.now() ),
-   prefix = topic.slice( 0, topic.indexOf( '.' ) );
+   ve.trackSubscribe( 'mwedit.', function ( topic, data, timeStamp ) {
+   var action = topic.split( '.' )[1],
+   event;
 
-   if ( prefix === 'mwtiming' ) {
-   // Add type for save errors; not in the topic for 
stupid historical reasons
-   

[MediaWiki-commits] [Gerrit] Fix ve.init.mw.trackSubscriber.js - change (mediawiki...VisualEditor)

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

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

Change subject: Fix ve.init.mw.trackSubscriber.js
..

Fix ve.init.mw.trackSubscriber.js

* Use the event's timeStamp rather than the current time in the event
  subscriber.
* Instead of using ve.trackSubscribeAll() and then branching on the topic
  prefix, just use ve.trackSubscribe( prefix, ... ) to bind prefix-specific
  handlers.
* Round timing measurements after performing arithmetic, and use Math#round
  rather than Math#floor.
* Rename 'getDefaultTiming' to 'computeDuration'.

Change-Id: I27ff1622ecea9b82d414f871441f127fc2dbd2cc
(cherry picked from commit 9b582485f951152648eec235d706e87e77b80ff6)
---
M modules/ve-mw/init/ve.init.mw.trackSubscriber.js
1 file changed, 53 insertions(+), 53 deletions(-)


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

diff --git a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js 
b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
index b23bc77..3622100 100644
--- a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
+++ b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
@@ -9,24 +9,28 @@
 
 ( function () {
 
-   var lastEventWithAction = {},
+   var timing = {},
editingSessionId = mw.user.generateRandomSessionId();
 
-   function getDefaultTiming( action, data, now ) {
+   function computeDuration( action, event, timeStamp ) {
+   if ( event.timing !== undefined ) {
+   return event.timing;
+   }
+
switch ( action ) {
case 'init':
// Account for second opening
-   return now - Math.max(
-   Math.floor( window.mediaWikiLoadStart ),
-   lastEventWithAction.saveSuccess || 0,
-   lastEventWithAction.abort || 0
+   return timeStamp - Math.max(
+   window.mediaWikiLoadStart,
+   timing.saveSuccess || 0,
+   timing.abort || 0
);
case 'ready':
-   return now - lastEventWithAction.init;
+   return timeStamp - timing.init;
case 'saveIntent':
-   return now - lastEventWithAction.ready;
+   return timeStamp - timing.ready;
case 'saveAttempt':
-   return now - lastEventWithAction.saveIntent;
+   return timeStamp - timing.saveIntent;
case 'saveSuccess':
case 'saveFailure':
// HERE BE DRAGONS: the caller must compute 
these themselves
@@ -35,49 +39,39 @@
mw.log.warn( 've.init.mw.trackSubscriber: Do 
not rely on default timing value for saveSuccess/saveFailure' );
return -1;
case 'abort':
-   switch ( data.type ) {
+   switch ( event.type ) {
case 'preinit':
-   return now - 
lastEventWithAction.init;
+   return timeStamp - timing.init;
case 'nochange':
case 'switchwith':
case 'switchwithout':
case 'abandon':
-   return now - 
lastEventWithAction.ready;
+   return timeStamp - timing.ready;
case 'abandonMidsave':
-   return now - 
lastEventWithAction.saveAttempt;
+   return timeStamp - 
timing.saveAttempt;
}
}
mw.log.warn( 've.init.mw.trackSubscriber: Unrecognized action', 
action );
return -1;
}
 
-   ve.trackSubscribeAll( function ( topic, data ) {
-   data = data || {};
-   var newData, action,
-   now = Math.floor( ve.now() ),
-   prefix = topic.slice( 0, topic.indexOf( '.' ) );
+   ve.trackSubscribe( 'mwedit.', function ( topic, data, timeStamp ) {
+   var action = topic.split( '.' )[1],
+   event;
 
-   if ( prefix === 'mwtiming' ) {
-   // Add type for save e

[MediaWiki-commits] [Gerrit] wtp2001-2020 entries had bad quoting - change (operations/puppet)

2015-02-20 Thread RobH (Code Review)
RobH has submitted this change and it was merged.

Change subject: wtp2001-2020 entries had bad quoting
..


wtp2001-2020 entries had bad quoting

had to fix the lack of quotes in my jessie filename lines

T90271

Change-Id: I4e2e662e632626d55ce9790a19f528ef142401b9
---
M modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
1 file changed, 40 insertions(+), 40 deletions(-)

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



diff --git a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
index 0d7eb1e..ddb6c9f 100644
--- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -4777,141 +4777,141 @@
 host wtp2001 {
hardware ethernet B0:83:FE:E7:F2:80;
fixed-address wtp2001.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2002 {
hardware ethernet B0:83:FE:DE:F1:15;
fixed-address wtp2002.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2003 {
hardware ethernet B0:83:FE:DB:C5:38;
fixed-address wtp2003.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2004 {
hardware ethernet B0:83:FE:DB:ED:BE;
fixed-address wtp2004.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2005 {
hardware ethernet B0:83:FE:E7:D8:34;
fixed-address wtp2005.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2006 {
hardware ethernet B0:83:FE:DB:C9:7D;
fixed-address wtp2006.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2007 {
hardware ethernet B0:83:FE:DE:FA:90;
fixed-address wtp2007.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2008 {
hardware ethernet B0:83:FE:DB:DC:C6;
fixed-address wtp2008.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2009 {
hardware ethernet B0:83:FE:DA:84:A9;
fixed-address wtp2009.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2010 {
hardware ethernet B0:83:FE:DB:D7:E3;
fixed-address wtp2010.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2011 {
hardware ethernet B0:83:FE:DB:D3:F7;
fixed-address wtp2011.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2012 {
hardware ethernet B0:83:FE:DB:D6:86;
fixed-address wtp2012.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   

[MediaWiki-commits] [Gerrit] Avoid "recent-contributors" queries that cause timeouts - change (mediawiki...AbuseFilter)

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

Change subject: Avoid "recent-contributors" queries that cause timeouts
..


Avoid "recent-contributors" queries that cause timeouts

* This works by only scanning the last 100 edits

bug: T90036
Change-Id: I803b06f9eb7a4a61bcb0248520b4144158963983
---
M AbuseFilterVariableHolder.php
1 file changed, 10 insertions(+), 4 deletions(-)

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



diff --git a/AbuseFilterVariableHolder.php b/AbuseFilterVariableHolder.php
index 5783804..f77c1b9 100644
--- a/AbuseFilterVariableHolder.php
+++ b/AbuseFilterVariableHolder.php
@@ -488,14 +488,20 @@
}
 
$dbr = wfGetDB( DB_SLAVE );
-   $res = $dbr->select( 'revision',
-   'DISTINCT rev_user_text',
+   $sqlTmp = $dbr->selectSQLText(
+   'revision',
+   array( 'rev_user_text', 'rev_timestamp' 
),
array(
'rev_page' => 
$title->getArticleID(),
-   'rev_timestamp<' . 
$dbr->addQuotes( $dbr->timestamp( $cutOff ) )
+   'rev_timestamp < ' . 
$dbr->addQuotes( $dbr->timestamp( $cutOff ) )
),
__METHOD__,
-   array( 'ORDER BY' => 'rev_timestamp 
DESC', 'LIMIT' => 10 )
+   // Some pages have < 10 authors but 
many revisions (e.g. bot pages)
+   array( 'ORDER BY' => 'rev_timestamp 
DESC', 'LIMIT' => 100 )
+   );
+   $res = $dbr->query(
+   "SELECT rev_user_text FROM ($sqlTmp) AS 
tmp " .
+   "GROUP BY rev_user_text ORDER BY 
MAX(rev_timestamp) DESC LIMIT 10"
);
 
$users = array();

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I803b06f9eb7a4a61bcb0248520b4144158963983
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/AbuseFilter
Gerrit-Branch: master
Gerrit-Owner: Aaron Schulz 
Gerrit-Reviewer: Chad 
Gerrit-Reviewer: Jackmcbarn 
Gerrit-Reviewer: Se4598 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Fix ve.init.mw.trackSubscriber.js - change (mediawiki...VisualEditor)

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

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

Change subject: Fix ve.init.mw.trackSubscriber.js
..

Fix ve.init.mw.trackSubscriber.js

* Use the event's timeStamp rather than the current time in the event
  subscriber.
* Instead of using ve.trackSubscribeAll() and then branching on the topic
  prefix, just use ve.trackSubscribe( prefix, ... ) to bind prefix-specific
  handlers.
* Round timing measurements after performing arithmetic, and use Math#round
  rather than Math#floor.
* Rename 'getDefaultTiming' to 'computeDuration'.

Change-Id: I27ff1622ecea9b82d414f871441f127fc2dbd2cc
(cherry picked from commit 9b582485f951152648eec235d706e87e77b80ff6)
---
M modules/ve-mw/init/ve.init.mw.trackSubscriber.js
1 file changed, 53 insertions(+), 53 deletions(-)


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

diff --git a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js 
b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
index b23bc77..3622100 100644
--- a/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
+++ b/modules/ve-mw/init/ve.init.mw.trackSubscriber.js
@@ -9,24 +9,28 @@
 
 ( function () {
 
-   var lastEventWithAction = {},
+   var timing = {},
editingSessionId = mw.user.generateRandomSessionId();
 
-   function getDefaultTiming( action, data, now ) {
+   function computeDuration( action, event, timeStamp ) {
+   if ( event.timing !== undefined ) {
+   return event.timing;
+   }
+
switch ( action ) {
case 'init':
// Account for second opening
-   return now - Math.max(
-   Math.floor( window.mediaWikiLoadStart ),
-   lastEventWithAction.saveSuccess || 0,
-   lastEventWithAction.abort || 0
+   return timeStamp - Math.max(
+   window.mediaWikiLoadStart,
+   timing.saveSuccess || 0,
+   timing.abort || 0
);
case 'ready':
-   return now - lastEventWithAction.init;
+   return timeStamp - timing.init;
case 'saveIntent':
-   return now - lastEventWithAction.ready;
+   return timeStamp - timing.ready;
case 'saveAttempt':
-   return now - lastEventWithAction.saveIntent;
+   return timeStamp - timing.saveIntent;
case 'saveSuccess':
case 'saveFailure':
// HERE BE DRAGONS: the caller must compute 
these themselves
@@ -35,49 +39,39 @@
mw.log.warn( 've.init.mw.trackSubscriber: Do 
not rely on default timing value for saveSuccess/saveFailure' );
return -1;
case 'abort':
-   switch ( data.type ) {
+   switch ( event.type ) {
case 'preinit':
-   return now - 
lastEventWithAction.init;
+   return timeStamp - timing.init;
case 'nochange':
case 'switchwith':
case 'switchwithout':
case 'abandon':
-   return now - 
lastEventWithAction.ready;
+   return timeStamp - timing.ready;
case 'abandonMidsave':
-   return now - 
lastEventWithAction.saveAttempt;
+   return timeStamp - 
timing.saveAttempt;
}
}
mw.log.warn( 've.init.mw.trackSubscriber: Unrecognized action', 
action );
return -1;
}
 
-   ve.trackSubscribeAll( function ( topic, data ) {
-   data = data || {};
-   var newData, action,
-   now = Math.floor( ve.now() ),
-   prefix = topic.slice( 0, topic.indexOf( '.' ) );
+   ve.trackSubscribe( 'mwedit.', function ( topic, data, timeStamp ) {
+   var action = topic.split( '.' )[1],
+   event;
 
-   if ( prefix === 'mwtiming' ) {
-   // Add type for save e

[MediaWiki-commits] [Gerrit] wtp2001-2020 entries had bad quoting - change (operations/puppet)

2015-02-20 Thread RobH (Code Review)
RobH has uploaded a new change for review.

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

Change subject: wtp2001-2020 entries had bad quoting
..

wtp2001-2020 entries had bad quoting

had to fix the lack of quotes in my jessie filename lines

T90271

Change-Id: I4e2e662e632626d55ce9790a19f528ef142401b9
---
M modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
1 file changed, 40 insertions(+), 40 deletions(-)


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

diff --git a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
index 0d7eb1e..ddb6c9f 100644
--- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -4777,141 +4777,141 @@
 host wtp2001 {
hardware ethernet B0:83:FE:E7:F2:80;
fixed-address wtp2001.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2002 {
hardware ethernet B0:83:FE:DE:F1:15;
fixed-address wtp2002.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2003 {
hardware ethernet B0:83:FE:DB:C5:38;
fixed-address wtp2003.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2004 {
hardware ethernet B0:83:FE:DB:ED:BE;
fixed-address wtp2004.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2005 {
hardware ethernet B0:83:FE:E7:D8:34;
fixed-address wtp2005.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2006 {
hardware ethernet B0:83:FE:DB:C9:7D;
fixed-address wtp2006.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2007 {
hardware ethernet B0:83:FE:DE:FA:90;
fixed-address wtp2007.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2008 {
hardware ethernet B0:83:FE:DB:DC:C6;
fixed-address wtp2008.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2009 {
hardware ethernet B0:83:FE:DA:84:A9;
fixed-address wtp2009.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2010 {
hardware ethernet B0:83:FE:DB:D7:E3;
fixed-address wtp2010.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2011 {
hardware ethernet B0:83:FE:DB:D3:F7;
fixed-address wtp2011.codfw.wmnet;
-   option pxelinux.pathprefix jessie-installer/;
-   filename jessie-installer/debian-installer/amd64/pxelinux.0;
+   option pxelinux.pathprefix "jessie-installer/";
+   filename "jessie-installer/debian-installer/amd64/pxelinux.0";
 }
 
 host wtp2012 {
hardware ethernet B0:83:FE:DB:D6:86;
fixed-address wtp2012.codfw.wmnet;
-   opti

[MediaWiki-commits] [Gerrit] Revert "phab update security extensions for access-request" - change (operations/puppet)

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

Change subject: Revert "phab update security extensions for access-request"
..


Revert "phab update security extensions for access-request"

This reverts commit eebde3bd1102d2d6821a7cbbc8192cbdb6ad9a28.

Change-Id: Icaad63997f1dd07cbe67a60c080617737d583c16
---
M manifests/role/phabricator.pp
M modules/phabricator/data/fixed_settings.yaml
2 files changed, 7 insertions(+), 2 deletions(-)

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



diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp
index 74bcb6b..7c25302 100644
--- a/manifests/role/phabricator.pp
+++ b/manifests/role/phabricator.pp
@@ -31,7 +31,7 @@
 mysql_admin_pass => $role::phabricator::config::mysql_adminpass,
 auth_type=> 'dual',
 sprint_tag   => 'release/2015-02-18',
-security_tag => 'release/2015-02-18/2',
+security_tag => 'release/2015-01-13/1',
 libraries=> ['/srv/phab/libext/Sprint/src',
  '/srv/phab/libext/security/src'],
 extension_tag=> 'HEAD',
diff --git a/modules/phabricator/data/fixed_settings.yaml 
b/modules/phabricator/data/fixed_settings.yaml
index 6c1a2f8..5b38470 100644
--- a/modules/phabricator/data/fixed_settings.yaml
+++ b/modules/phabricator/data/fixed_settings.yaml
@@ -81,7 +81,12 @@
   default: 'None'
   security-bug: 'Software security bug'
   sensitive: 'Other confidential issue'
-  ops-access-request: 'Operations Access Request'
+
+# Security/Operations Macro's for enabling
+# as we rollout to RT and bugzilla.
+#ops-access-request: 'Operations Access Request'
+#ops-sensitive: 'Operations Sensitive'
+#sensitive: 'Another Private Issue'
 
 maniphest.statuses:
   open:

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Icaad63997f1dd07cbe67a60c080617737d583c16
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Rush 
Gerrit-Reviewer: Rush 

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


[MediaWiki-commits] [Gerrit] Revert "phab update security extensions for access-request" - change (operations/puppet)

2015-02-20 Thread Rush (Code Review)
Rush has uploaded a new change for review.

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

Change subject: Revert "phab update security extensions for access-request"
..

Revert "phab update security extensions for access-request"

This reverts commit eebde3bd1102d2d6821a7cbbc8192cbdb6ad9a28.

Change-Id: Icaad63997f1dd07cbe67a60c080617737d583c16
---
M manifests/role/phabricator.pp
M modules/phabricator/data/fixed_settings.yaml
2 files changed, 7 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/09/192009/1

diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp
index 74bcb6b..7c25302 100644
--- a/manifests/role/phabricator.pp
+++ b/manifests/role/phabricator.pp
@@ -31,7 +31,7 @@
 mysql_admin_pass => $role::phabricator::config::mysql_adminpass,
 auth_type=> 'dual',
 sprint_tag   => 'release/2015-02-18',
-security_tag => 'release/2015-02-18/2',
+security_tag => 'release/2015-01-13/1',
 libraries=> ['/srv/phab/libext/Sprint/src',
  '/srv/phab/libext/security/src'],
 extension_tag=> 'HEAD',
diff --git a/modules/phabricator/data/fixed_settings.yaml 
b/modules/phabricator/data/fixed_settings.yaml
index 6c1a2f8..5b38470 100644
--- a/modules/phabricator/data/fixed_settings.yaml
+++ b/modules/phabricator/data/fixed_settings.yaml
@@ -81,7 +81,12 @@
   default: 'None'
   security-bug: 'Software security bug'
   sensitive: 'Other confidential issue'
-  ops-access-request: 'Operations Access Request'
+
+# Security/Operations Macro's for enabling
+# as we rollout to RT and bugzilla.
+#ops-access-request: 'Operations Access Request'
+#ops-sensitive: 'Operations Sensitive'
+#sensitive: 'Another Private Issue'
 
 maniphest.statuses:
   open:

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

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

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


[MediaWiki-commits] [Gerrit] Amend wt2html namepacing - change (mediawiki...parsoid)

2015-02-20 Thread Memeht (Code Review)
Memeht has uploaded a new change for review.

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

Change subject: Amend wt2html namepacing
..

Amend wt2html namepacing

Amend all instances of 'wt2html.serialize.partial' to
'wt2html.serialize.selser'. See Change-Id:
Ifbe1b7191fd17830074672217a33f777131f8c37

Change-Id: I082d41ee73174e93ca66c9f020c65934b0f1fea6
---
M lib/mediawiki.SelectiveSerializer.js
1 file changed, 3 insertions(+), 3 deletions(-)


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

diff --git a/lib/mediawiki.SelectiveSerializer.js 
b/lib/mediawiki.SelectiveSerializer.js
index 4167674..13ca11b 100644
--- a/lib/mediawiki.SelectiveSerializer.js
+++ b/lib/mediawiki.SelectiveSerializer.js
@@ -76,7 +76,7 @@
// Use provided diff-marked DOM (used during testing)
// or generate one (used in production)
if ( this.timer ) {
-   startTimers.set( 'html2wt.serialize.partial', 
Date.now() );
+   startTimers.set( 'html2wt.serialize.selser', Date.now() 
);
startTimers.set( 'html2wt.domDiff', Date.now() );
}
 
@@ -103,8 +103,8 @@
this.wts.serializeDOM( body, cb, true, finalcb );
 
if ( this.timer ) {
-   this.timer.timing( 'html2wt.serialize.partial', 
'', startTimers.get( 'html2wt.serialize.partial' ) );
-   this.timer.count( 
'html2wt.serialize.partial.count', '' );
+   this.timer.timing( 'html2wt.serialize.selser', 
'', startTimers.get( 'html2wt.serialize.selser' ) );
+   this.timer.count( 
'html2wt.serialize.selser.count', '' );
}
} else {
// Nothing was modified, just re-use the original source

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

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

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


[MediaWiki-commits] [Gerrit] Add collection-owner icon - change (mediawiki...Gather)

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

Change subject: Add collection-owner icon
..


Add collection-owner icon

To user profile link when viewing a collection page.

Also:
 * Fix Resources.php icon paths
 * Remove duplicated useless icons folder

Change-Id: Id027a6f4baaa45d1fddcc3cb9cb01700bdc32430
---
M extension.json
D images/icons/next.svg
M includes/Resources.php
M includes/views/Collection.php
M resources/ext.collections.styles/collections.less
M resources/ext.collections.styles/icons.less
A resources/ext.collections.styles/images/icons/user.svg
7 files changed, 25 insertions(+), 15 deletions(-)

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



diff --git a/extension.json b/extension.json
index 5e8c2f3..f90d6a9 100644
--- a/extension.json
+++ b/extension.json
@@ -57,7 +57,8 @@
"prefix": "mw-ui",
"images": {
"icon": {
-   "collections-read-more:before": 
"images/icons/next.svg"
+   "collections-read-more:before": 
"ext.collections.styles/images/icons/next.svg",
+   "collection-owner:before": 
"ext.collections.styles/images/icons/user.svg"
}
}
},
diff --git a/images/icons/next.svg b/images/icons/next.svg
deleted file mode 100644
index 5b2290e..000
--- a/images/icons/next.svg
+++ /dev/null
@@ -1,8 +0,0 @@
-
-http://www.w3.org/2000/svg"; viewBox="0 0 17.5 26" 
enable-background="new 0 0 17.5 26">
-
-
-
-
-
-
diff --git a/includes/Resources.php b/includes/Resources.php
index e7a901b..8a2da78 100644
--- a/includes/Resources.php
+++ b/includes/Resources.php
@@ -57,7 +57,8 @@
'images' => array(
// FIXME: ':before' suffix should be configurable in 
image module.
'icon' => array(
-   'collections-read-more:before' => 
'images/icons/next.svg',
+   'collections-read-more:before' => 
'ext.collections.styles/images/icons/next.svg',
+   'collection-owner:before' => 
'ext.collections.styles/images/icons/user.svg',
),
),
),
diff --git a/includes/views/Collection.php b/includes/views/Collection.php
index 7627265..58da4fa 100644
--- a/includes/views/Collection.php
+++ b/includes/views/Collection.php
@@ -54,9 +54,11 @@
 */
private function getOwnerHtml( $owner ) {
return Html::openElement( 'a', array(
-   'href' => SpecialPage::getTitleFor( 
'UserProfile', $owner->getName() )->getLocalUrl() ) ) .
+   'href' => SpecialPage::getTitleFor( 
'UserProfile', $owner->getName() )->getLocalUrl(),
+   'class' => 'collection-owner',
+   ) ) .
Html::element( 'span', array(
-   'class' => CSS::iconClass( 'user', 'before', 
'collections-owner' ) ) ) .
+   'class' => CSS::iconClass( 'collection-owner', 
'before', 'collection-owner-icon' ) ) ) .
$owner->getName() .
Html::closeElement( 'a' );
}
diff --git a/resources/ext.collections.styles/collections.less 
b/resources/ext.collections.styles/collections.less
index f08898e..252598a 100644
--- a/resources/ext.collections.styles/collections.less
+++ b/resources/ext.collections.styles/collections.less
@@ -47,9 +47,10 @@
}
 
.collection-owner {
-   &.mw-ui-icon-before:before {
-   margin-right: 0.5em;
-   width: 1em;
+   .collection-owner-icon {
+   vertical-align: top;
+   width: 1.7em;
+   min-width: 1.7em;
}
}
 
diff --git a/resources/ext.collections.styles/icons.less 
b/resources/ext.collections.styles/icons.less
index e698ed0..edb4def 100644
--- a/resources/ext.collections.styles/icons.less
+++ b/resources/ext.collections.styles/icons.less
@@ -3,7 +3,16 @@
 @import "minerva.mixins";
 @import "mediawiki.mixins";
 
+span.mw-ui-icon {
+  display: inline-block;
+}
+
 .mw-ui-icon-collections-read-more {
.m-background-image-svg-quick( 'images/icons/next' );
 }
 
+.mw-ui-icon-collection-owner {
+   .m-background-image-svg-quick( 'images/icons/user' );
+}
+
+
diff --git a/resources/ext.collections.styles/images/icons/user.svg 
b/resources/ext.collections.styles/images/icons/user.svg
new file mode 100644
index 000..9fb090e
--- /dev/null
+++ b/resources/

[MediaWiki-commits] [Gerrit] Add unit tests support - change (mediawiki...Gather)

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

Change subject: Add unit tests support
..


Add unit tests support

No php unit tests yet, though.

Change-Id: Id271a589b2d4c3d33592810400b33a6780c73405
---
M Gather.php
M includes/Gather.hooks.php
2 files changed, 14 insertions(+), 0 deletions(-)

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



diff --git a/Gather.php b/Gather.php
index 0520a90..ec6d96d 100644
--- a/Gather.php
+++ b/Gather.php
@@ -75,6 +75,7 @@
 
 // Hooks
 $wgHooks['MobilePersonalTools'][] = 'Gather\Hooks::onMobilePersonalTools';
+$wgHooks['UnitTestsList'][] = 'Gather\Hooks::onUnitTestsList';
 
 // ResourceLoader modules
 require_once __DIR__ . "/includes/Resources.php";
diff --git a/includes/Gather.hooks.php b/includes/Gather.hooks.php
index 14f0fa0..d123ef7 100644
--- a/includes/Gather.hooks.php
+++ b/includes/Gather.hooks.php
@@ -42,4 +42,17 @@
$items = $itemArray;
}
}
+
+   /**
+* UnitTestsList hook handler
+* @see https://www.mediawiki.org/wiki/Manual:Hooks/UnitTestsList
+*
+* @param array $files
+* @return bool
+*/
+   public static function onUnitTestsList( &$files ) {
+   $files[] = __DIR__ . '/../tests/phpunit';
+
+   return true;
+   }
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id271a589b2d4c3d33592810400b33a6780c73405
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Gather
Gerrit-Branch: master
Gerrit-Owner: Jhernandez 
Gerrit-Reviewer: Robmoen 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Hygiene: Rename views\ItemImage to views\Image - change (mediawiki...Gather)

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

Change subject: Hygiene: Rename views\ItemImage to views\Image
..


Hygiene: Rename views\ItemImage to views\Image

No need to have item in the name if not necessary. This works with anything
that uses the WithImage interface.

Change-Id: I75b1583c9873ce62e3046eba7b72855b56673cf4
---
M Gather.php
M extension.json
M includes/views/CollectionItemCard.php
M includes/views/CollectionsListItemCard.php
R includes/views/Image.php
5 files changed, 8 insertions(+), 8 deletions(-)

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



diff --git a/Gather.php b/Gather.php
index cea45ba..5b36587 100644
--- a/Gather.php
+++ b/Gather.php
@@ -60,7 +60,7 @@
'Gather\views\NotFound' => 'views/NotFound',
'Gather\views\Collection' => 'views/Collection',
'Gather\views\CollectionItemCard' => 'views/CollectionItemCard',
-   'Gather\views\ItemImage' => 'views/ItemImage',
+   'Gather\views\Image' => 'views/Image',
'Gather\views\CollectionsList' => 'views/CollectionsList',
'Gather\views\CollectionsListItemCard' => 
'views/CollectionsListItemCard',
 
diff --git a/extension.json b/extension.json
index 3e99dc5..5e8c2f3 100644
--- a/extension.json
+++ b/extension.json
@@ -41,7 +41,7 @@
"Gather\\views\\NotFound": "includes/views/NotFound.php",
"Gather\\views\\Collection": "includes/views/Collection.php",
"Gather\\views\\CollectionItemCard": 
"includes/views/CollectionItemCard.php",
-   "Gather\\views\\ItemImage": "includes/views/ItemImage.php",
+   "Gather\\views\\Image": "includes/views/Image.php",
"Gather\\views\\CollectionsList": 
"includes/views/CollectionsList.php",
"Gather\\views\\CollectionsListItemCard": 
"includes/views/CollectionsListItemCard.php",
"Gather\\views\\helpers\\CSS": "includes/views/helpers/CSS.php",
diff --git a/includes/views/CollectionItemCard.php 
b/includes/views/CollectionItemCard.php
index fdf50b8..d3a511c 100644
--- a/includes/views/CollectionItemCard.php
+++ b/includes/views/CollectionItemCard.php
@@ -19,7 +19,7 @@
protected $item;
 
/**
-* @var ItemImage view for the item image
+* @var Image view for the item image
 */
protected $image;
 
@@ -29,7 +29,7 @@
 */
public function __construct( models\CollectionItem $item ) {
$this->item = $item;
-   $this->image = new ItemImage( $item );
+   $this->image = new Image( $item );
}
 
/**
diff --git a/includes/views/CollectionsListItemCard.php 
b/includes/views/CollectionsListItemCard.php
index dcdeddb..cd1ebb7 100644
--- a/includes/views/CollectionsListItemCard.php
+++ b/includes/views/CollectionsListItemCard.php
@@ -18,7 +18,7 @@
 */
public function __construct( models\CollectionInfo $collection ) {
$this->collection = $collection;
-   $this->image = new ItemImage( $collection );
+   $this->image = new Image( $collection );
}
 
/**
@@ -27,7 +27,7 @@
protected $collection;
 
/**
-* @var ItemImage view for the collection image
+* @var Image view for the collection image
 */
protected $image;
 
diff --git a/includes/views/ItemImage.php b/includes/views/Image.php
similarity index 97%
rename from includes/views/ItemImage.php
rename to includes/views/Image.php
index 36b2394..b8123fc 100644
--- a/includes/views/ItemImage.php
+++ b/includes/views/Image.php
@@ -1,6 +1,6 @@
 https://gerrit.wikimedia.org/r/190802
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I75b1583c9873ce62e3046eba7b72855b56673cf4
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/Gather
Gerrit-Branch: master
Gerrit-Owner: Jhernandez 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Robmoen 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Clean up flow-menus to use section delimiters - change (mediawiki...Flow)

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

Change subject: Clean up flow-menus to use section delimiters
..


Clean up flow-menus to use section delimiters

Bug: T86936
Change-Id: I58b99f5675802c8035357dbf0ddfab27c54e1891
---
M handlebars/compiled/flow_block_board-history.handlebars.php
M handlebars/compiled/flow_block_topic.handlebars.php
M handlebars/compiled/flow_block_topic_moderate_post.handlebars.php
M handlebars/compiled/flow_block_topic_moderate_topic.handlebars.php
M handlebars/compiled/flow_block_topiclist.handlebars.php
M handlebars/compiled/flow_post.handlebars.php
M handlebars/flow_block_board-history.handlebars
M handlebars/flow_moderation_actions_list.handlebars
M modules/styles/board/menu.less
M modules/styles/common.less
10 files changed, 681 insertions(+), 662 deletions(-)

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




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

Gerrit-MessageType: merged
Gerrit-Change-Id: I58b99f5675802c8035357dbf0ddfab27c54e1891
Gerrit-PatchSet: 24
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: SG 
Gerrit-Reviewer: EBernhardson 
Gerrit-Reviewer: Mattflaschen 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Check CommonsMetadata tests after I562e437e - change (mediawiki...CommonsMetadata)

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

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

Change subject: Check CommonsMetadata tests after I562e437e
..

Check CommonsMetadata tests after I562e437e

Bug: T90018
Change-Id: I9f633448dad692b7c90c3d30d4a0dfa3682bd59c
---
0 files changed, 0 insertions(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CommonsMetadata 
refs/changes/07/192007/1


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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9f633448dad692b7c90c3d30d4a0dfa3682bd59c
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/CommonsMetadata
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza 

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


  1   2   3   4   >