[MediaWiki-commits] [Gerrit] Add variant rewrites for zhwikivoyage - change (operations/apache-config)

2014-02-25 Thread Faidon Liambotis (Code Review)
Faidon Liambotis has submitted this change and it was merged.

Change subject: Add variant rewrites for zhwikivoyage
..


Add variant rewrites for zhwikivoyage

Bug: 60473
Change-Id: I16d961e0774f43ac8902378d4b7af2f120f43e49
---
M main.conf
1 file changed, 10 insertions(+), 0 deletions(-)

Approvals:
  Byfserag: Looks good to me, but someone else must approve
  Zhuyifei1999: Looks good to me, but someone else must approve
  Faidon Liambotis: Verified; Looks good to me, approved
  Liangent: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/main.conf b/main.conf
index cd8cee1..8e86bf6 100644
--- a/main.conf
+++ b/main.conf
@@ -726,6 +726,16 @@
 /IfModule
 /Directory
 
+# Variant aliases
+Alias /zh /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
+Alias /zh-hans /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
+Alias /zh-hant /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
+Alias /zh-cn /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
+Alias /zh-hk /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
+Alias /zh-mo /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
+Alias /zh-my /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
+Alias /zh-sg /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
+Alias /zh-tw /usr/local/apache/common/docroot/wikivoyage.org/w/index.php
 /VirtualHost
 
 LoadModule deflate_module /usr/lib/apache2/modules/mod_deflate.so

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I16d961e0774f43ac8902378d4b7af2f120f43e49
Gerrit-PatchSet: 2
Gerrit-Project: operations/apache-config
Gerrit-Branch: master
Gerrit-Owner: TTO at.li...@live.com.au
Gerrit-Reviewer: Byfserag john_k...@sina.cn
Gerrit-Reviewer: Dzahn dz...@wikimedia.org
Gerrit-Reviewer: Ebe123 beauleetien...@gmail.com
Gerrit-Reviewer: Faidon Liambotis fai...@wikimedia.org
Gerrit-Reviewer: Jeremyb jer...@tuxmachine.com
Gerrit-Reviewer: Liangent liang...@gmail.com
Gerrit-Reviewer: Liuxinyu970226 541329...@qq.com
Gerrit-Reviewer: Reedy re...@wikimedia.org
Gerrit-Reviewer: TTO at.li...@live.com.au
Gerrit-Reviewer: Tim Starling tstarl...@wikimedia.org
Gerrit-Reviewer: Zhuyifei1999 zhuyifei1...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] text varnishes: require geoip; set enable_geoiplookup for fr... - change (operations/puppet)

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

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

Change subject: text varnishes: require geoip; set enable_geoiplookup for 
frontend
..

text varnishes: require geoip; set enable_geoiplookup for frontend

Follow-up for Ic4d2fccbc, which adds GeoIP processing logic to the text
frontends.

Change-Id: If1a3994c57e100587fddf06c29c713f6c1fbc056
---
M manifests/role/cache.pp
1 file changed, 5 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/46/115346/1

diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp
index b5dbba2..ad09b46 100644
--- a/manifests/role/cache.pp
+++ b/manifests/role/cache.pp
@@ -557,6 +557,8 @@
 
 system::role { role::cache::text: description = text Varnish cache 
server }
 
+require geoip
+
 class { 'lvs::realserver': realserver_ips = 
$lvs::configuration::lvs_service_ips[$::realm]['text'][$::site] }
 
 $varnish_be_directors = {
@@ -670,6 +672,9 @@
 'probe' = varnish,
 'weight' = $backend_weight,
 }],
+cluster_options = {
+'enable_geoiplookup' = true,
+},
 }
 
 include role::cache::varnish::logging

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: If1a3994c57e100587fddf06c29c713f6c1fbc056
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh o...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Add visibility to DifferenceEngine methods - change (mediawiki/core)

2014-02-25 Thread Aude (Code Review)
Aude has uploaded a new change for review.

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

Change subject: Add visibility to DifferenceEngine methods
..

Add visibility to DifferenceEngine methods

Change-Id: I415719442ca1778be36f173067d4b090fbe9265a
---
M includes/diff/DifferenceEngine.php
1 file changed, 26 insertions(+), 26 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/47/115347/1

diff --git a/includes/diff/DifferenceEngine.php 
b/includes/diff/DifferenceEngine.php
index d6cf694..244e16e 100644
--- a/includes/diff/DifferenceEngine.php
+++ b/includes/diff/DifferenceEngine.php
@@ -104,7 +104,7 @@
 * @param $refreshCache boolean If set, refreshes the diff cache
 * @param $unhide boolean If set, allow viewing deleted revs
 */
-   function __construct( $context = null, $old = 0, $new = 0, $rcid = 0,
+   public function __construct( $context = null, $old = 0, $new = 0, $rcid 
= 0,
$refreshCache = false, $unhide = false
) {
if ( $context instanceof IContextSource ) {
@@ -122,14 +122,14 @@
/**
 * @param $value bool
 */
-   function setReducedLineNumbers( $value = true ) {
+   public function setReducedLineNumbers( $value = true ) {
$this-mReducedLineNumbers = $value;
}
 
/**
 * @return Language
 */
-   function getDiffLang() {
+   public function getDiffLang() {
if ( $this-mDiffLang === null ) {
# Default language in which the diff text is written.
$this-mDiffLang = $this-getTitle()-getPageLanguage();
@@ -141,14 +141,14 @@
/**
 * @return bool
 */
-   function wasCacheHit() {
+   public function wasCacheHit() {
return $this-mCacheHit;
}
 
/**
 * @return int
 */
-   function getOldid() {
+   public function getOldid() {
$this-loadRevisionIds();
 
return $this-mOldid;
@@ -157,7 +157,7 @@
/**
 * @return Bool|int
 */
-   function getNewid() {
+   public function getNewid() {
$this-loadRevisionIds();
 
return $this-mNewid;
@@ -170,7 +170,7 @@
 * @param int $id revision ID
 * @return mixed URL or false
 */
-   function deletedLink( $id ) {
+   public function deletedLink( $id ) {
if ( $this-getUser()-isAllowed( 'deletedhistory' ) ) {
$dbr = wfGetDB( DB_SLAVE );
$row = $dbr-selectRow( 'archive', '*',
@@ -196,7 +196,7 @@
 * @param int $id revision ID
 * @return string wikitext fragment
 */
-   function deletedIdMarker( $id ) {
+   public function deletedIdMarker( $id ) {
$link = $this-deletedLink( $id );
if ( $link ) {
return [$link $id];
@@ -225,7 +225,7 @@
$this-getLanguage()-listToText( $missing ), count( 
$missing ) );
}
 
-   function showDiffPage( $diffOnly = false ) {
+   public function showDiffPage( $diffOnly = false ) {
wfProfileIn( __METHOD__ );
 
# Allow frames except in certain special cases
@@ -533,7 +533,7 @@
/**
 * Show the new revision of the page.
 */
-   function renderNewRevision() {
+   public function renderNewRevision() {
wfProfileIn( __METHOD__ );
$out = $this-getOutput();
$revHeader = $this-getRevisionHeader( $this-mNewRev );
@@ -616,7 +616,7 @@
 *
 * @return bool
 */
-   function showDiff( $otitle, $ntitle, $notice = '' ) {
+   public function showDiff( $otitle, $ntitle, $notice = '' ) {
$diff = $this-getDiff( $otitle, $ntitle, $notice );
if ( $diff === false ) {
$this-showMissingRevision();
@@ -633,7 +633,7 @@
/**
 * Add style sheets and supporting JS for diff display.
 */
-   function showDiffStyle() {
+   public function showDiffStyle() {
$this-getOutput()-addModuleStyles( 
'mediawiki.action.history.diff' );
}
 
@@ -645,7 +645,7 @@
 * @param string $notice HTML between diff header and body
 * @return mixed
 */
-   function getDiff( $otitle, $ntitle, $notice = '' ) {
+   public function getDiff( $otitle, $ntitle, $notice = '' ) {
$body = $this-getDiffBody();
if ( $body === false ) {
return false;
@@ -778,7 +778,7 @@
 * @since 1.21
 * @throws MWException if $old or $new are not instances of TextContent.
 */
-   function generateContentDiffBody( Content $old, Content $new ) {
+   public function 

[MediaWiki-commits] [Gerrit] text varnishes: require geoip; set enable_geoiplookup for fr... - change (operations/puppet)

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

Change subject: text varnishes: require geoip; set enable_geoiplookup for 
frontend
..


text varnishes: require geoip; set enable_geoiplookup for frontend

Follow-up for Ic4d2fccbc, which adds GeoIP processing logic to the text
frontends.

Change-Id: If1a3994c57e100587fddf06c29c713f6c1fbc056
---
M manifests/role/cache.pp
1 file changed, 5 insertions(+), 0 deletions(-)

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



diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp
index b5dbba2..ad09b46 100644
--- a/manifests/role/cache.pp
+++ b/manifests/role/cache.pp
@@ -557,6 +557,8 @@
 
 system::role { role::cache::text: description = text Varnish cache 
server }
 
+require geoip
+
 class { 'lvs::realserver': realserver_ips = 
$lvs::configuration::lvs_service_ips[$::realm]['text'][$::site] }
 
 $varnish_be_directors = {
@@ -670,6 +672,9 @@
 'probe' = varnish,
 'weight' = $backend_weight,
 }],
+cluster_options = {
+'enable_geoiplookup' = true,
+},
 }
 
 include role::cache::varnish::logging

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If1a3994c57e100587fddf06c29c713f6c1fbc056
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh o...@wikimedia.org
Gerrit-Reviewer: BBlack bbl...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Document $wgResourceLoaderMaxage in DefaultSettings.php - change (mediawiki/core)

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

Change subject: Document $wgResourceLoaderMaxage in DefaultSettings.php
..


Document $wgResourceLoaderMaxage in DefaultSettings.php

To have a start and to remove the todo.

Change-Id: I62421f1399c0f3e77238c39322028b969c0e925f
---
M includes/DefaultSettings.php
1 file changed, 12 insertions(+), 3 deletions(-)

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



diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php
index b0ed35b..029ef97 100644
--- a/includes/DefaultSettings.php
+++ b/includes/DefaultSettings.php
@@ -3159,14 +3159,23 @@
 
 /**
  * Maximum time in seconds to cache resources served by the resource loader.
+ * Used to set last modified headers (max-age/s-maxage).
  *
- * @todo Document array structure
+ * Following options to distinguish:
+ * - versioned: Used for modules with a version, because changing version
+ *   numbers causes cache misses. This normally has a long expiry time.
+ * - unversioned: Used for modules without a version to propagate changes
+ *   quickly to clients. Also used for modules with errors to recover quickly.
+ *   This normally has a short expiry time.
+ *
+ * Expiry time for the options to distinguish:
+ * - server: Squid/Varnish but also any other public proxy cache between the
+ *   client and MediaWiki.
+ * - client: On the client side (e.g. in the browser cache).
  */
 $wgResourceLoaderMaxage = array(
'versioned' = array(
-   // Squid/Varnish but also any other public proxy cache between 
the client and MediaWiki
'server' = 30 * 24 * 60 * 60, // 30 days
-   // On the client side (e.g. in the browser cache).
'client' = 30 * 24 * 60 * 60, // 30 days
),
'unversioned' = array(

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I62421f1399c0f3e77238c39322028b969c0e925f
Gerrit-PatchSet: 6
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Umherirrender umherirrender_de...@web.de
Gerrit-Reviewer: Catrope roan.katt...@gmail.com
Gerrit-Reviewer: Hoo man h...@online.de
Gerrit-Reviewer: IAlex coderev...@emsenhuber.ch
Gerrit-Reviewer: Krinkle krinklem...@gmail.com
Gerrit-Reviewer: Reedy re...@wikimedia.org
Gerrit-Reviewer: Trevor Parscal tpars...@wikimedia.org
Gerrit-Reviewer: Umherirrender umherirrender_de...@web.de
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Correction in dummy sentence segmenter - change (mediawiki...ContentTranslation)

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

Change subject: Correction in dummy sentence segmenter
..


Correction in dummy sentence segmenter

Split using period+space instead of period.

Change-Id: I2eabba15bd616f0777ded4332fe8d177bbfeb112
---
M server/segmentation/sentenceSegmenter.js
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/server/segmentation/sentenceSegmenter.js 
b/server/segmentation/sentenceSegmenter.js
index 2500104..77955a3 100644
--- a/server/segmentation/sentenceSegmenter.js
+++ b/server/segmentation/sentenceSegmenter.js
@@ -27,7 +27,7 @@
 
 SentenceSegmenter.prototype.segment = function () {
var i, segmentId, linkSegmenter,
-   sentences = this.content.split( '.' );
+   sentences = this.content.split( '. ' );
 
this.segmentCount += sentences.length;
for ( i = 0; i this.segmentCount; i++ ) {
@@ -37,7 +37,7 @@
linkSegmenter.segment();
this.links = $.extend( this.links, linkSegmenter.getSegments() 
);
this.segments[segmentId] = {
-   source: linkSegmenter.toHTML() + '.'
+   source: linkSegmenter.toHTML() + '. '
};
// We need this lookup to keep the order of segments
// while constructing the segmented content using

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2eabba15bd616f0777ded4332fe8d177bbfeb112
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: KartikMistry kartik.mis...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Add PageLoaders - change (mediawiki...ContentTranslation)

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

Change subject: Add PageLoaders
..


Add PageLoaders

Examples:
ParsoidPageLoader = require( './pageloader/ParsoidPageLoader' 
).ParsoidPageLoader
l = new ParsoidPageLoader( 'http://parsoid.wmflabs.org', 'enwiki' );
promise = l.load( 'Food' )
promise.then( function ( x ) { console.log( x ); } );
promise.done();

MediaWikiApiPageLoader = require( './pageloader/MediaWikiApiPageLoader' 
).MediaWikiApiPageLoader
l = new MediaWikiApiPageLoader( 'http://en.wikipedia.org/w/api.php' );
promise = l.load( 'Food' )
promise.then( function ( x ) { console.log( x ); } );
promise.done();

Change-Id: Iddc35275dbf71ecf549fb834528722242800ce96
---
M server/package.json
A server/pageloader/MediaWikiApiPageLoader.js
A server/pageloader/ParsoidPageLoader.js
3 files changed, 88 insertions(+), 1 deletion(-)

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



diff --git a/server/package.json b/server/package.json
index e99e683..2add13e 100644
--- a/server/package.json
+++ b/server/package.json
@@ -4,7 +4,9 @@
version: 0.1.0,
dependencies: {
express: 3.x,
-   socket.io: 0.9.x
+   socket.io: 0.9.x,
+   q: *,
+   request: *
},
devDependencies: {
colors: ~0.6.2,
diff --git a/server/pageloader/MediaWikiApiPageLoader.js 
b/server/pageloader/MediaWikiApiPageLoader.js
new file mode 100644
index 000..0311f6b
--- /dev/null
+++ b/server/pageloader/MediaWikiApiPageLoader.js
@@ -0,0 +1,42 @@
+/**
+ * Loads html for pages to translate via MediaWiki API
+ *
+ * @file
+ * @copyright See AUTHORS.txt
+ * @license GPL-2.0+
+ */
+
+'use strict';
+
+var request = require( 'request' ),
+   Q = require( 'q' );
+
+/**
+ * @class MediaWikiApiPageLoader
+ */
+function MediaWikiApiPageLoader( api ) {
+   this.api = api;
+}
+
+MediaWikiApiPageLoader.prototype.load = function ( documentId ) {
+   var deferred = Q.defer();
+
+   request(
+   this.api + '?action=parseformat=jsonpage=' + 
encodeURIComponent( documentId ),
+   function ( error, response, body ) {
+   if ( error ) {
+   deferred.reject( error );
+   }
+
+   if ( response.statusCode !== 200 ) {
+   deferred.reject( response.statusCode );
+   }
+
+   deferred.resolve( JSON.parse( body ).parse.text['*'] );
+   }
+   );
+
+   return deferred.promise;
+};
+
+module.exports.MediaWikiApiPageLoader = MediaWikiApiPageLoader;
diff --git a/server/pageloader/ParsoidPageLoader.js 
b/server/pageloader/ParsoidPageLoader.js
new file mode 100644
index 000..61eeb7d
--- /dev/null
+++ b/server/pageloader/ParsoidPageLoader.js
@@ -0,0 +1,43 @@
+/**
+ * Loads html for pages to translate form Parsoid service
+ *
+ * @file
+ * @copyright See AUTHORS.txt
+ * @license GPL-2.0+
+ */
+
+'use strict';
+
+var request = require( 'request' ),
+   Q = require( 'q' );
+
+/**
+ * @class ParsoidPageLoader
+ */
+function ParsoidPageLoader( host, wikiId ) {
+   this.host = host;
+   this.wikiId = wikiId;
+}
+
+ParsoidPageLoader.prototype.load = function ( documentId ) {
+   var deferred = Q.defer();
+
+   request(
+   this.host + '/' + this.wikiId + '/' + documentId,
+   function ( error, response, body ) {
+   if ( error ) {
+   deferred.reject( error );
+   }
+
+   if ( response.statusCode !== 200 ) {
+   deferred.reject( response.statusCode );
+   }
+
+   deferred.resolve( body );
+   }
+   );
+
+   return deferred.promise;
+};
+
+module.exports.ParsoidPageLoader = ParsoidPageLoader;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iddc35275dbf71ecf549fb834528722242800ce96
Gerrit-PatchSet: 8
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: Divec da...@sheetmusic.org.uk
Gerrit-Reviewer: KartikMistry kartik.mis...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Add a geoip::dev class to use for VCL compilation - change (operations/puppet)

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

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

Change subject: Add a geoip::dev class to use for VCL compilation
..

Add a geoip::dev class to use for VCL compilation

Change-Id: If14bd5af70773c4412257df940bf5f04588d420f
---
M manifests/role/cache.pp
A modules/geoip/manifests/dev.pp
2 files changed, 10 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/48/115348/1

diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp
index ad09b46..40ac762 100644
--- a/manifests/role/cache.pp
+++ b/manifests/role/cache.pp
@@ -558,6 +558,7 @@
 system::role { role::cache::text: description = text Varnish cache 
server }
 
 require geoip
+require geoip::dev # for VCL compilation using libGeoIP
 
 class { 'lvs::realserver': realserver_ips = 
$lvs::configuration::lvs_service_ips[$::realm]['text'][$::site] }
 
@@ -878,6 +879,7 @@
 system::role { role::cache::bits: description = bits Varnish cache 
server }
 
 require geoip
+require geoip::dev # for VCL compilation using libGeoIP
 
 include standard,
 nrpe
diff --git a/modules/geoip/manifests/dev.pp b/modules/geoip/manifests/dev.pp
new file mode 100644
index 000..64f1eae
--- /dev/null
+++ b/modules/geoip/manifests/dev.pp
@@ -0,0 +1,8 @@
+# == Class geoip::dev
+# Installs the MaxMind library headers
+#
+class geoip::dev {
+  package { 'libgeoip-dev':
+ensure = present,
+  }
+}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: If14bd5af70773c4412257df940bf5f04588d420f
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: BBlack bbl...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Wrapper for page loader to choose one based on configuration - change (mediawiki...ContentTranslation)

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

Change subject: Wrapper for page loader to choose one based on configuration
..


Wrapper for page loader to choose one based on configuration

Change-Id: I4a0434b5c77f23fe16831799c19ed88de8dfd93b
---
A server/pageloader/PageLoader.js
1 file changed, 54 insertions(+), 0 deletions(-)

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



diff --git a/server/pageloader/PageLoader.js b/server/pageloader/PageLoader.js
new file mode 100644
index 000..fe53526
--- /dev/null
+++ b/server/pageloader/PageLoader.js
@@ -0,0 +1,54 @@
+/**
+ * Loads html for pages to translate
+ *
+ * @file
+ * @copyright See AUTHORS.txt
+ * @license GPL-2.0+
+ */
+
+'use strict';
+
+var config;
+
+try {
+   // TODO: Have an example configuration file.
+   config = require( __dirname + '/../config.js' );
+} catch ( e ) {
+   // TODO: define this configuration in betterway
+   config = {
+   pageloaderservice: 'parsoid',
+   parsoid: {
+   api: 'http://parsoid.wmflabs.org'
+   },
+   mediawiki: {
+   api: 'http://en.wikipedia.org/w/api.php'
+   }
+   };
+}
+
+/**
+/**
+ * @class ParsoidPageLoader
+ */
+function PageLoader( page ) {
+   this.page = page;
+}
+
+PageLoader.prototype.load = function () {
+   var loader, promise, ParsoidPageLoader, MediaWikiApiPageLoader, title;
+
+   title = this.page.split( '/' ).pop();
+   if ( config.pageloaderservice === 'parsoid' ) {
+   ParsoidPageLoader = require( __dirname + 
'/ParsoidPageLoader.js' ).ParsoidPageLoader;
+   loader = new ParsoidPageLoader( config.parsoid.api, 'enwiki' ); 
//FIXME
+   promise = loader.load( title );
+   }
+   if ( config.pageloaderservice === 'mediawiki' ) {
+   MediaWikiApiPageLoader = require( __dirname + 
'/MediaWikiApiPageLoader.js' ).MediaWikiApiPageLoader;
+   loader = new MediaWikiApiPageLoader( config.mediawiki.api );
+   promise = loader.load( title );
+   }
+   return promise;
+};
+
+module.exports.PageLoader = PageLoader;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I4a0434b5c77f23fe16831799c19ed88de8dfd93b
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: KartikMistry kartik.mis...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Add a geoip::dev class to use for VCL compilation - change (operations/puppet)

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

Change subject: Add a geoip::dev class to use for VCL compilation
..


Add a geoip::dev class to use for VCL compilation

Change-Id: If14bd5af70773c4412257df940bf5f04588d420f
---
M manifests/role/cache.pp
A modules/geoip/manifests/dev.pp
2 files changed, 10 insertions(+), 0 deletions(-)

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



diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp
index ad09b46..40ac762 100644
--- a/manifests/role/cache.pp
+++ b/manifests/role/cache.pp
@@ -558,6 +558,7 @@
 system::role { role::cache::text: description = text Varnish cache 
server }
 
 require geoip
+require geoip::dev # for VCL compilation using libGeoIP
 
 class { 'lvs::realserver': realserver_ips = 
$lvs::configuration::lvs_service_ips[$::realm]['text'][$::site] }
 
@@ -878,6 +879,7 @@
 system::role { role::cache::bits: description = bits Varnish cache 
server }
 
 require geoip
+require geoip::dev # for VCL compilation using libGeoIP
 
 include standard,
 nrpe
diff --git a/modules/geoip/manifests/dev.pp b/modules/geoip/manifests/dev.pp
new file mode 100644
index 000..64f1eae
--- /dev/null
+++ b/modules/geoip/manifests/dev.pp
@@ -0,0 +1,8 @@
+# == Class geoip::dev
+# Installs the MaxMind library headers
+#
+class geoip::dev {
+  package { 'libgeoip-dev':
+ensure = present,
+  }
+}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If14bd5af70773c4412257df940bf5f04588d420f
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: BBlack bbl...@wikimedia.org
Gerrit-Reviewer: BBlack bbl...@wikimedia.org
Gerrit-Reviewer: Ori.livneh o...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Workaround for scrolling bug in IE8 - change (mediawiki...WikiEditor)

2014-02-25 Thread Gerrit Patch Uploader (Code Review)
Gerrit Patch Uploader has uploaded a new change for review.

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

Change subject: Workaround for scrolling bug in IE8
..

Workaround for scrolling bug in IE8

Bug: 19334
Change-Id: I69dbfa267b26916628181553b213f05add909c99
---
M modules/jquery.wikiEditor.js
1 file changed, 7 insertions(+), 0 deletions(-)


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

diff --git a/modules/jquery.wikiEditor.js b/modules/jquery.wikiEditor.js
index 8c0afcd..2c406bd 100644
--- a/modules/jquery.wikiEditor.js
+++ b/modules/jquery.wikiEditor.js
@@ -481,6 +481,13 @@
};
 
/**
+* Workaround for scrolling bug in IE8
+*/
+   if ( $.client.profile().name === 'msie' ) {
+   context.$textarea.css( 'height', context.$textarea.height() );
+   }
+
+   /**
 * Base UI Construction
 *
 * The UI is built from several containers, the outer-most being a div 
classed as wikiEditor-ui. These containers

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I69dbfa267b26916628181553b213f05add909c99
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikiEditor
Gerrit-Branch: master
Gerrit-Owner: Gerrit Patch Uploader gerritpatchuploa...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] text varnishes: set enable_geoiplookup to false - change (operations/puppet)

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

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

Change subject: text varnishes: set enable_geoiplookup to false
..

text varnishes: set enable_geoiplookup to false

Using geoip causes segfaults all over the place.

Change-Id: I6b4649b13246532edd557b3a645b2094cbe6e202
---
M manifests/role/cache.pp
M templates/varnish/text-frontend.inc.vcl.erb
2 files changed, 3 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/50/115350/1

diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp
index 40ac762..2e438a2 100644
--- a/manifests/role/cache.pp
+++ b/manifests/role/cache.pp
@@ -674,7 +674,7 @@
 'weight' = $backend_weight,
 }],
 cluster_options = {
-'enable_geoiplookup' = true,
+'enable_geoiplookup' = false,
 },
 }
 
diff --git a/templates/varnish/text-frontend.inc.vcl.erb 
b/templates/varnish/text-frontend.inc.vcl.erb
index 1c2d37a..cf429ec 100644
--- a/templates/varnish/text-frontend.inc.vcl.erb
+++ b/templates/varnish/text-frontend.inc.vcl.erb
@@ -129,8 +129,10 @@
 req.url !~ (?i)bcache=1) {
set resp.http.Cache-Control = private, s-maxage=0, max-age=0, 
must-revalidate;
}
+% if cluster_options.fetch( enable_geoiplookup, false ) -%
/* Perform GeoIP look-up and send the result as a session cookie */
if (req.http.Cookie !~ (^|;\s*)GeoIP=[^;]) {
call geoip_cookie;
}
+% end -%
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6b4649b13246532edd557b3a645b2094cbe6e202
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh o...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] text varnishes: set enable_geoiplookup to false - change (operations/puppet)

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

Change subject: text varnishes: set enable_geoiplookup to false
..


text varnishes: set enable_geoiplookup to false

Using geoip causes segfaults all over the place.

Change-Id: I6b4649b13246532edd557b3a645b2094cbe6e202
---
M manifests/role/cache.pp
M templates/varnish/text-frontend.inc.vcl.erb
2 files changed, 3 insertions(+), 1 deletion(-)

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



diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp
index 40ac762..2e438a2 100644
--- a/manifests/role/cache.pp
+++ b/manifests/role/cache.pp
@@ -674,7 +674,7 @@
 'weight' = $backend_weight,
 }],
 cluster_options = {
-'enable_geoiplookup' = true,
+'enable_geoiplookup' = false,
 },
 }
 
diff --git a/templates/varnish/text-frontend.inc.vcl.erb 
b/templates/varnish/text-frontend.inc.vcl.erb
index 1c2d37a..cf429ec 100644
--- a/templates/varnish/text-frontend.inc.vcl.erb
+++ b/templates/varnish/text-frontend.inc.vcl.erb
@@ -129,8 +129,10 @@
 req.url !~ (?i)bcache=1) {
set resp.http.Cache-Control = private, s-maxage=0, max-age=0, 
must-revalidate;
}
+% if cluster_options.fetch( enable_geoiplookup, false ) -%
/* Perform GeoIP look-up and send the result as a session cookie */
if (req.http.Cookie !~ (^|;\s*)GeoIP=[^;]) {
call geoip_cookie;
}
+% end -%
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6b4649b13246532edd557b3a645b2094cbe6e202
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh o...@wikimedia.org
Gerrit-Reviewer: BBlack bbl...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] toolbareditgroup: Registering cancel event handler in getB... - change (mediawiki...Wikibase)

2014-02-25 Thread Henning Snater (Code Review)
Henning Snater has uploaded a new change for review.

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

Change subject: toolbareditgroup: Registering cancel event handler in 
getButton()
..

toolbareditgroup: Registering cancel event handler in getButton()

Change-Id: I3bbce46dd75752145aa37d50cb60d30dcb589d5f
---
M lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js
1 file changed, 25 insertions(+), 5 deletions(-)


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

diff --git a/lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js 
b/lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js
index 9bbcedd..ba2f526 100644
--- a/lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js
+++ b/lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js
@@ -203,11 +203,12 @@
self._trigger( 'remove' );
break;
case self._buttons.cancel.get( 0 ):
-   self._trigger( 'cancel', null, [ 
function() {
-   if( self.element.data( 
'toolbareditgroup' ) ) {
-   self.toNonEditMode();
-   }
-   } ] );
+// FIXME: Cancel button's event handler should be registered here and not in 
getButton.
+// self._trigger( 'cancel', null, [ 
function() {
+// if( self.element.data( 
'toolbareditgroup' ) ) {
+// self.toNonEditMode();
+// }
+// } ] );
break;
}
} );
@@ -304,6 +305,25 @@
if( buttonCharacteristics.disabled ) {
this._buttons[buttonName].data( 'toolbarbutton' 
).disable();
}
+
+   // FIXME: Handling the cancel button's action should be 
attached to the
+   // toolbareditgroup widget's node just like for the 
other buttons. However, due to the
+   // node replacing taking place in EditableAliases (see
+   // 
wikibase.ui.PropertyEditTool.EditableAliases._destroy() ), the event handler 
needs
+   // to be attached directly to the button since the 
cancel button's reference to the
+   // toolbareditgroup is removed via the event handler 
attached in
+   // wikibase.ui.AliasEditTool._buildSingleValueToolbar().
+   var self = this;
+   if( buttonName === 'cancel' ) {
+   this._buttons[buttonName]
+   .on( 'toolbarbuttonaction.' + this.widgetName, 
function( event ) {
+   self._trigger( 'cancel', null, [ 
function() {
+   if( self.element.data( 
'toolbareditgroup' ) ) {
+   self.toNonEditMode();
+   }
+   } ] );
+   } );
+   }
}
 
return this._buttons[buttonName];

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3bbce46dd75752145aa37d50cb60d30dcb589d5f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Henning Snater henning.sna...@wikimedia.de

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


[MediaWiki-commits] [Gerrit] toolbareditgroup: Registering cancel event handler in getB... - change (mediawiki...Wikibase)

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

Change subject: toolbareditgroup: Registering cancel event handler in 
getButton()
..


toolbareditgroup: Registering cancel event handler in getButton()

Change-Id: I3bbce46dd75752145aa37d50cb60d30dcb589d5f
---
M lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js
1 file changed, 25 insertions(+), 5 deletions(-)

Approvals:
  Tobias Gritschacher: Looks good to me, approved
  WikidataJenkins: Verified
  jenkins-bot: Verified



diff --git a/lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js 
b/lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js
index 9bbcedd..ba2f526 100644
--- a/lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js
+++ b/lib/resources/jquery.wikibase/toolbar/toolbareditgroup.js
@@ -203,11 +203,12 @@
self._trigger( 'remove' );
break;
case self._buttons.cancel.get( 0 ):
-   self._trigger( 'cancel', null, [ 
function() {
-   if( self.element.data( 
'toolbareditgroup' ) ) {
-   self.toNonEditMode();
-   }
-   } ] );
+// FIXME: Cancel button's event handler should be registered here and not in 
getButton.
+// self._trigger( 'cancel', null, [ 
function() {
+// if( self.element.data( 
'toolbareditgroup' ) ) {
+// self.toNonEditMode();
+// }
+// } ] );
break;
}
} );
@@ -304,6 +305,25 @@
if( buttonCharacteristics.disabled ) {
this._buttons[buttonName].data( 'toolbarbutton' 
).disable();
}
+
+   // FIXME: Handling the cancel button's action should be 
attached to the
+   // toolbareditgroup widget's node just like for the 
other buttons. However, due to the
+   // node replacing taking place in EditableAliases (see
+   // 
wikibase.ui.PropertyEditTool.EditableAliases._destroy() ), the event handler 
needs
+   // to be attached directly to the button since the 
cancel button's reference to the
+   // toolbareditgroup is removed via the event handler 
attached in
+   // wikibase.ui.AliasEditTool._buildSingleValueToolbar().
+   var self = this;
+   if( buttonName === 'cancel' ) {
+   this._buttons[buttonName]
+   .on( 'toolbarbuttonaction.' + this.widgetName, 
function( event ) {
+   self._trigger( 'cancel', null, [ 
function() {
+   if( self.element.data( 
'toolbareditgroup' ) ) {
+   self.toNonEditMode();
+   }
+   } ] );
+   } );
+   }
}
 
return this._buttons[buttonName];

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3bbce46dd75752145aa37d50cb60d30dcb589d5f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Henning Snater henning.sna...@wikimedia.de
Gerrit-Reviewer: Tobias Gritschacher tobias.gritschac...@wikimedia.de
Gerrit-Reviewer: WikidataJenkins wikidata-servi...@wikimedia.de
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Add license information - change (mediawiki...wikihiero)

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

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

Change subject: Add license information
..

Add license information

Change-Id: I5e44da15dadff1d47bbe92fb6eb50c448ccbf96d
---
A COPYING
M wikihiero.php
2 files changed, 340 insertions(+), 0 deletions(-)


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

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

[MediaWiki-commits] [Gerrit] fix reference to WikibaseRepo in client - change (mediawiki...Wikibase)

2014-02-25 Thread Aude (Code Review)
Aude has uploaded a new change for review.

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

Change subject: fix reference to WikibaseRepo in client
..

fix reference to WikibaseRepo in client

Change-Id: Ie0242d804143991ab3eb02bac52a50567fd10f00
---
M client/includes/store/sql/DirectSqlStore.php
1 file changed, 3 insertions(+), 3 deletions(-)


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

diff --git a/client/includes/store/sql/DirectSqlStore.php 
b/client/includes/store/sql/DirectSqlStore.php
index eb74c22..2381681 100644
--- a/client/includes/store/sql/DirectSqlStore.php
+++ b/client/includes/store/sql/DirectSqlStore.php
@@ -5,7 +5,7 @@
 use Language;
 use Site;
 use ObjectCache;
-use Wikibase\Repo\WikibaseRepo;
+use Wikibase\Client\WikibaseClient;
 
 /**
  * Implementation of the client store interface using direct access to the 
repository's
@@ -87,7 +87,7 @@
$this-repoWiki = $repoWiki;
$this-language = $wikiLanguage;
 
-   $settings = WikibaseRepo::getDefaultInstance()-getSettings();
+   $settings = WikibaseClient::getDefaultInstance()-getSettings();
$cachePrefix = $settings-getSetting( 'sharedCacheKeyPrefix' );
$cacheDuration = $settings-getSetting( 'sharedCacheDuration' );
$cacheType = $settings-getSetting( 'sharedCacheType' );
@@ -313,7 +313,7 @@
 * @return PropertyInfoTable
 */
protected function newPropertyInfoTable() {
-   $usePropertyInfoTable = WikibaseRepo::getDefaultInstance()
+   $usePropertyInfoTable = WikibaseClient::getDefaultInstance()
-getSettings()-getSetting( 'usePropertyInfoTable' );
 
if ( $usePropertyInfoTable ) {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie0242d804143991ab3eb02bac52a50567fd10f00
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Aude aude.w...@gmail.com

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


[MediaWiki-commits] [Gerrit] Use snprintf to synthesize GeoIP cookie, rather than VRT_Wrk... - change (operations/puppet)

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

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

Change subject: Use snprintf to synthesize GeoIP cookie, rather than 
VRT_WrkString
..

Use snprintf to synthesize GeoIP cookie, rather than VRT_WrkString

A bit of a shot in the dark.

Change-Id: I0038f675f19197c37824a6260d120b6113e0f345
---
M templates/varnish/geoip.inc.vcl.erb
1 file changed, 12 insertions(+), 13 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/54/115354/1

diff --git a/templates/varnish/geoip.inc.vcl.erb 
b/templates/varnish/geoip.inc.vcl.erb
index 424234e..99ed7ae 100644
--- a/templates/varnish/geoip.inc.vcl.erb
+++ b/templates/varnish/geoip.inc.vcl.erb
@@ -134,8 +134,8 @@
 sub geoip_cookie {
C{
GeoIPRecord *record;
-   char *set_cookie_header, *cookie;
-   char latlon[20];
+   char *set_cookie_header;
+   char geo_cookie[255];
 
char *ip = geo_get_xff_ip(sp);
int af = geo_get_addr_family(ip);
@@ -149,27 +149,26 @@
 
if (record) {
/* Set-Cookie: 
GeoIP=US:San_Francisco:37.7749:-122.4194:v4; path=/ */
-   snprintf(latlon, sizeof(latlon), %.4f:%.4f, 
record-latitude, record-longitude);
-   cookie = VRT_WrkString(sp, GeoIP=,
-   record-country_code,   :,
-   geo_sanitize_for_cookie(record-city),  :,
-   latlon, :,
-   (af == AF_INET6) ? v6 : v4, ; 
path=/,
-   vrt_magic_string_end);
+   snprintf(geo_cookie, sizeof(geo_cookie), 
GeoIP=%s:%s:%.4f:%.4f:%s; path=/,
+   geo_sanitize_for_cookie(record-country_code),
+   geo_sanitize_for_cookie(record-city),
+   record-latitude,
+   record-longitude,
+   (af == AF_INET6) ? v6 : v4
+   );
GeoIPRecord_delete(record);
} else {
/* Set-Cookie: GeoIP=v6; path=/ */
-   cookie = VRT_WrkString(sp, GeoIP=, (af == 
AF_INET6) ? v6 : v4,
-   ; path=/, vrt_magic_string_end);
+   snprintf(geo_cookie, sizeof(geo_cookie), GeoIP=%s; 
path=/, (af == AF_INET6) ? v6 : v4);
}
 
set_cookie_header = VRT_GetHdr(sp, HDR_RESP, \013set-cookie:);
if (set_cookie_header == NULL) {
// New header
-   VRT_SetHdr(sp, HDR_RESP, \013Set-Cookie:, cookie, 
vrt_magic_string_end);
+   VRT_SetHdr(sp, HDR_RESP, \013Set-Cookie:, geo_cookie, 
vrt_magic_string_end);
} else {
// Append to existing header
-   VRT_SetHdr(sp, HDR_RESP, \013Set-Cookie:, 
set_cookie_header, ; , cookie, vrt_magic_string_end);
+   VRT_SetHdr(sp, HDR_RESP, \013Set-Cookie:, 
set_cookie_header, ; , geo_cookie, vrt_magic_string_end);
}
}C
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0038f675f19197c37824a6260d120b6113e0f345
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh o...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Adds a beginning of parser tests - change (mediawiki...ProofreadPage)

2014-02-25 Thread Tpt (Code Review)
Tpt has uploaded a new change for review.

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

Change subject: Adds a beginning of parser tests
..

Adds a beginning of parser tests

Change-Id: I5518ae938faca86449c202d720b65f945f7db05c
---
M ProofreadPage.body.php
M ProofreadPage.php
A tests/parser/pages.txt
3 files changed, 187 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ProofreadPage 
refs/changes/56/115356/1

diff --git a/ProofreadPage.body.php b/ProofreadPage.body.php
index 46fca8e..3bd8889 100644
--- a/ProofreadPage.body.php
+++ b/ProofreadPage.body.php
@@ -797,6 +797,16 @@
}
 
/**
+* @param array $tables
+* @return bool
+*/
+   public static function onParserTestTables( array $tables ) {
+   $tables[] = 'pr_index';
+
+   return true;
+   }
+
+   /**
 * Add the links to previous, next, index page and scan image to Page: 
pages.
 * @param $skin SkinTemplate object
 * @param $links array structured navigation links
diff --git a/ProofreadPage.php b/ProofreadPage.php
index 9434478..ad80840 100644
--- a/ProofreadPage.php
+++ b/ProofreadPage.php
@@ -193,6 +193,8 @@
 $wgHooks['ContentHandlerDefaultModelFor'][] = 
'ProofreadPage::onContentHandlerDefaultModelFor';
 $wgHooks['APIEditBeforeSave'][] = 'ProofreadPage::onAPIEditBeforeSave';
 $wgHooks['EditFormPreloadText'][] = 'ProofreadPage::onEditFormPreloadText';
+$wgHooks['ParserTestTables'][] = 'ProofreadPage::onParserTestTables';
+
 
 
 /**
@@ -219,6 +221,9 @@
return true;
 };
 
+//Parser tests
+$wgParserTestFiles[] = __DIR__ . '/tests/parser/pages.txt';
+
 //Handlers
 $wgContentHandlers[CONTENT_MODEL_PROOFREAD_PAGE] = 
'ProofreadPageContentHandler';
 
diff --git a/tests/parser/pages.txt b/tests/parser/pages.txt
new file mode 100644
index 000..caede83
--- /dev/null
+++ b/tests/parser/pages.txt
@@ -0,0 +1,172 @@
+!! hooks
+pages
+!! endhooks
+
+!!article
+MediaWiki:Proofreadpage pagenum template
+!!text
+[[{{{page}}}|{{{num}}}]]
+!!endarticle
+
+!!article
+MediaWiki:Proofreadpage header template
+!!text
+{{{title}}} -- {{{author}}}
+{{{from}}} -- {{{to}}}
+{{{prev}}} -- {{{next}}}
+!!endarticle
+
+!!article
+Index:Test
+!!text
+{{
+|Title=Title
+|Pages=[[Page:Test 1.jpg|TOC]] [[Page:Test 2.tiff|1]] [[Page:Test 3.png|2]]
+|Author=[[Author:Me]]
+|TOC=* [[Test/Chapter 1]]
+* [[Test/Chapter 2|Chapter 2]]
+* [[Test/Chapter 3|Chapter 3]]
+}}
+!!endarticle
+
+!!article
+Page:Test 1.jpg
+!!text
+Test 1
+!!endarticle
+
+!!article
+Page:Test 2.tiff
+!!text
+Test 2
+!!endarticle
+
+!!article
+Page:Test 3.png
+!!text
+nowiki /
+
+Test 3
+!!endarticle
+
+!!article
+Author:Me
+!!text
+!!endarticle
+
+!!article
+Test/Chapter 1
+!!text
+!!endarticle
+
+!!article
+Test/Chapter 2
+!!text
+!!endarticle
+
+!!article
+Test/Chapter 3
+!!text
+!!endarticle
+
+!! test
+pages: without index
+!! input
+pages /
+!! result
+pstrong class=errorError: Index expected/strong
+/p
+!! end
+
+!! test
+pages: with non existing index
+!! input
+pages index=RootOf42 /
+!! result
+pstrong class=errorError: No such index/strong
+/p
+!! end
+
+!! test
+pages: without file: Simple transclusion
+!! input
+pages index=Test from=Test 1.jpg to=Test 3.png /
+!! result
+div
+pspana href=/wiki/Page:Test_1.jpg title=Page:Test 1.jpg 
class=prp-pagequality-1TOC/a/spanTest 1#32;spana 
href=/wiki/Page:Test_2.tiff title=Page:Test 2.tiff 
class=prp-pagequality-11/a/spanTest 2#32;spana 
href=/wiki/Page:Test_3.png title=Page:Test 3.png 
class=prp-pagequality-12/a/span
+/ppTest 3#32;
+/p
+/div
+
+!! end
+
+!! test
+pages: without file: Simple transclusion without from
+!! input
+pages index=Test to=Test 2.tiff /
+!! result
+div
+pspana href=/wiki/Page:Test_1.jpg title=Page:Test 1.jpg 
class=prp-pagequality-1TOC/a/spanTest 1#32;spana 
href=/wiki/Page:Test_2.tiff title=Page:Test 2.tiff 
class=prp-pagequality-11/a/spanTest 2#32;
+/p
+/div
+
+!! end
+
+!! test
+pages: without file: Simple transclusion without to
+!! input
+pages index=Test from=Test 2.tiff /
+!! result
+div
+pspana href=/wiki/Page:Test_2.tiff title=Page:Test 2.tiff 
class=prp-pagequality-11/a/spanTest 2#32;spana 
href=/wiki/Page:Test_3.png title=Page:Test 3.png 
class=prp-pagequality-12/a/span
+/ppTest 3#32;
+/p
+/div
+
+!! end
+
+!! test
+pages: without file: Header
+!! options
+title=Test/Chapter 2
+!! input
+pages index=Test from=Test 1.jpg to=Test 2.tiff header=1 /
+!! result
+div
+pTitle -- a href=/wiki/Author:Me title=Author:MeAuthor:Me/a
+TOC -- 1
+a href=/wiki/Test/Chapter_3 title=Test/Chapter 3Chapter 3/a -- 
{{{next}}}spana href=/wiki/Page:Test_1.jpg title=Page:Test 1.jpg 
class=prp-pagequality-1TOC/a/spanTest 1#32;spana 
href=/wiki/Page:Test_2.tiff title=Page:Test 2.tiff 
class=prp-pagequality-11/a/spanTest 2#32;
+/p
+/div
+
+!! end
+
+!! test
+pages: without file: TOC
+!! options
+title=Test
+!! input
+pages index=Test /
+!! 

[MediaWiki-commits] [Gerrit] Pass page URL instead of content to get the data model - change (mediawiki...ContentTranslation)

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

Change subject: Pass page URL instead of content to get the data model
..


Pass page URL instead of content to get the data model

Change-Id: I3fdb99732b94a9b593d426e7f87c7607e6944402
---
M server/ContentTranslationService.js
M server/public/index.html
M server/public/js/main.js
3 files changed, 53 insertions(+), 34 deletions(-)

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



diff --git a/server/ContentTranslationService.js 
b/server/ContentTranslationService.js
index a0d2f50..ea87685 100644
--- a/server/ContentTranslationService.js
+++ b/server/ContentTranslationService.js
@@ -26,20 +26,27 @@
 // socket.io connection establishment
 io.sockets.on( 'connection', function ( socket ) {
var datamodelManager,
+   PageLoader,
CXDataModelManager;
console.log( '[CX] Client connected to worker(' + process.pid + '). 
Socket: ' + socket.id );
socket.on( 'cx.init', function ( data ) {
+   var pageloader;
CXDataModelManager = require(  __dirname + 
'/models/dataModelManager.js').CXDataModelManager;
context = {
sourceLanguage: data.sourceLanguage,
targetLanguage: data.targetLanguage,
-   sourceText: data.sourceText,
+   sourcePage: data.sourcePage,
socket: socket
};
-   // Inject the session context to dataModelManager
-   // It should take care of managing the data model and pushing
-   // it to the client through socket.
-   datamodelManager = new CXDataModelManager( context );
+   PageLoader  = require(  __dirname + 
'/pageloader/PageLoader.js').PageLoader;
+   pageloader = new PageLoader( context.sourcePage );
+   pageloader.load().done( function ( data ) {
+   context.sourceText = data;
+   // Inject the session context to dataModelManager
+   // It should take care of managing the data model and 
pushing
+   // it to the client through socket.
+   datamodelManager = new CXDataModelManager( context );
+   } );
} );
 } );
 
diff --git a/server/public/index.html b/server/public/index.html
index da8c352..7a8351d 100644
--- a/server/public/index.html
+++ b/server/public/index.html
@@ -8,20 +8,25 @@
width: 80%;
margin-left: 10%;
}
+
label {
-   float: left;
width: 20%;
}
+
input {
+   width: 40%;
+   padding: 5px;
+   }
+
+   .lang {
+   width: 5%;
+   }
+
+   button {
width: 10%;
padding: 5px;
}
-   button {
-   width: 10%;
-   margin-left: 40%;
-   padding: 10px;
-   margin-bottom: 20px;
-   }
+
.status {
position: fixed;
bottom: 0;
@@ -33,6 +38,7 @@
color: green;
font-size: 0.8em;
}
+
.cx-segment:hover {
background-color: #ccc;
}
@@ -41,28 +47,32 @@
background-color: #aaa;
}
 
-   .sourceText {
-   clear: both;
+   .form {
+   border: 1px solid #000;
+   padding: 10px;
+   }
+
+   .info {
+   color: #555;
}
/style
 /head
 
 body
h1Content Translation Server/h1
-   form
-   label for=sourceLanguageTranslate from/label
-   input name=sourceLanguage value=en /
-   br/
-   label for=targetLanguageTranslate to/label
-   input name=targetLanguage value=cy /
-   br/
-   div contenteditable class=sourceText
-   pbHydrogen/b is a a 
href=/wiki/Chemical_element title=Chemical elementchemical element/a 
with a href=/wiki/Chemical_symbol title=Chemical symbol 
class=mw-redirectchemical symbol/anbsp;bH/b and a 
href=/wiki/Atomic_number title=Atomic numberatomic number/anbsp;1. With 
an a href=/wiki/Atomic_weight title=Atomic weight 
class=mw-redirectatomic weight/a of span 
style=white-space:nowrap1.00794nbsp;a href=/wiki/Atomic_mass_unit 
title=Atomic mass unitu/a/span, hydrogen is the lightest element on the 
a href=/wiki/Periodic_table 

[MediaWiki-commits] [Gerrit] Create job operations-debs-archiva-debian-glue - change (integration/jenkins-job-builder-config)

2014-02-25 Thread Hashar (Code Review)
Hashar has uploaded a new change for review.

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

Change subject: Create job operations-debs-archiva-debian-glue
..

Create job operations-debs-archiva-debian-glue

Change-Id: I37d3ba6ddd1997f6af33872b645f27bd3cba1ebe
---
M operations-debs.yaml
1 file changed, 5 insertions(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/integration/jenkins-job-builder-config 
refs/changes/57/115357/1

diff --git a/operations-debs.yaml b/operations-debs.yaml
index 070dfac..6786a3a 100644
--- a/operations-debs.yaml
+++ b/operations-debs.yaml
@@ -139,6 +139,11 @@
  - python-jobs
 
 - project:
+name: 'operations-debs-archiva'
+jobs:
+ - '{name}-debian-glue'
+
+- project:
 name: 'operations-debs-gerrit'
 jobs:
  - '{name}-debian-glue'

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I37d3ba6ddd1997f6af33872b645f27bd3cba1ebe
Gerrit-PatchSet: 1
Gerrit-Project: integration/jenkins-job-builder-config
Gerrit-Branch: master
Gerrit-Owner: Hashar has...@free.fr

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


[MediaWiki-commits] [Gerrit] Create job operations-debs-archiva-debian-glue - change (integration/jenkins-job-builder-config)

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

Change subject: Create job operations-debs-archiva-debian-glue
..


Create job operations-debs-archiva-debian-glue

Change-Id: I37d3ba6ddd1997f6af33872b645f27bd3cba1ebe
---
M operations-debs.yaml
1 file changed, 5 insertions(+), 0 deletions(-)

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



diff --git a/operations-debs.yaml b/operations-debs.yaml
index 070dfac..6786a3a 100644
--- a/operations-debs.yaml
+++ b/operations-debs.yaml
@@ -139,6 +139,11 @@
  - python-jobs
 
 - project:
+name: 'operations-debs-archiva'
+jobs:
+ - '{name}-debian-glue'
+
+- project:
 name: 'operations-debs-gerrit'
 jobs:
  - '{name}-debian-glue'

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I37d3ba6ddd1997f6af33872b645f27bd3cba1ebe
Gerrit-PatchSet: 1
Gerrit-Project: integration/jenkins-job-builder-config
Gerrit-Branch: master
Gerrit-Owner: Hashar has...@free.fr
Gerrit-Reviewer: Hashar has...@free.fr
Gerrit-Reviewer: Ottomata o...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Trigger operations-debs-archiva-debian-glue - change (integration/zuul-config)

2014-02-25 Thread Hashar (Code Review)
Hashar has uploaded a new change for review.

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

Change subject: Trigger operations-debs-archiva-debian-glue
..

Trigger operations-debs-archiva-debian-glue

Change-Id: I94a4a07a420a35a47188c1d4403ce941f7298887
---
M layout.yaml
1 file changed, 4 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/zuul-config 
refs/changes/58/115358/1

diff --git a/layout.yaml b/layout.yaml
index d064219..1a06066 100644
--- a/layout.yaml
+++ b/layout.yaml
@@ -1050,6 +1050,10 @@
   - name: 'python-lint'
 prefix: 'operations-debs-adminbot'
 
+  - name: operations/debs/archiva
+test:
+ - operations-debs-archiva-debian-glue
+
   - name: operations/debs/buck
 test:
  - operations-debs-buck-debian-glue

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I94a4a07a420a35a47188c1d4403ce941f7298887
Gerrit-PatchSet: 1
Gerrit-Project: integration/zuul-config
Gerrit-Branch: master
Gerrit-Owner: Hashar has...@free.fr

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


[MediaWiki-commits] [Gerrit] Trigger operations-debs-archiva-debian-glue - change (integration/zuul-config)

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

Change subject: Trigger operations-debs-archiva-debian-glue
..


Trigger operations-debs-archiva-debian-glue

Change-Id: I94a4a07a420a35a47188c1d4403ce941f7298887
---
M layout.yaml
1 file changed, 4 insertions(+), 0 deletions(-)

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



diff --git a/layout.yaml b/layout.yaml
index d064219..1a06066 100644
--- a/layout.yaml
+++ b/layout.yaml
@@ -1050,6 +1050,10 @@
   - name: 'python-lint'
 prefix: 'operations-debs-adminbot'
 
+  - name: operations/debs/archiva
+test:
+ - operations-debs-archiva-debian-glue
+
   - name: operations/debs/buck
 test:
  - operations-debs-buck-debian-glue

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I94a4a07a420a35a47188c1d4403ce941f7298887
Gerrit-PatchSet: 1
Gerrit-Project: integration/zuul-config
Gerrit-Branch: master
Gerrit-Owner: Hashar has...@free.fr
Gerrit-Reviewer: Hashar has...@free.fr
Gerrit-Reviewer: Ottomata o...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Jenkins validation (DO NOT SUBMIT) - change (operations...archiva)

2014-02-25 Thread Hashar (Code Review)
Hashar has uploaded a new change for review.

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

Change subject: Jenkins validation (DO NOT SUBMIT)
..

Jenkins validation (DO NOT SUBMIT)

Change-Id: Icad159fa934d6f0a89711971714449f0905602da
---
A JENKINS
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/debs/archiva 
refs/changes/59/115359/1

diff --git a/JENKINS b/JENKINS
new file mode 100644
index 000..e69de29
--- /dev/null
+++ b/JENKINS

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Icad159fa934d6f0a89711971714449f0905602da
Gerrit-PatchSet: 1
Gerrit-Project: operations/debs/archiva
Gerrit-Branch: debian
Gerrit-Owner: Hashar has...@free.fr

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


[MediaWiki-commits] [Gerrit] Add some labs management scripts. - change (operations/puppet)

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

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

Change subject: Add some labs management scripts.
..

Add some labs management scripts.

Most of these have been hanging around for a long time, and
are important.  Puppetizing so that they're backed up and
we have to document changes.

Change-Id: I7339f13d198e1adf6cf22b7d21ec7ed3ba9aae04
---
A files/openstack/folsom/virtscripts/cold-migrate
A files/openstack/folsom/virtscripts/dc-migrate
A files/openstack/folsom/virtscripts/logstat.py
A files/openstack/folsom/virtscripts/prod.sh
A files/openstack/havana/virtscripts/cold-migrate
A files/openstack/havana/virtscripts/dc-migrate
A files/openstack/havana/virtscripts/logstat.py
A files/openstack/havana/virtscripts/prod.sh
M manifests/role/nova.pp
9 files changed, 867 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/60/115360/1

diff --git a/files/openstack/folsom/virtscripts/cold-migrate 
b/files/openstack/folsom/virtscripts/cold-migrate
new file mode 100755
index 000..7c6bd16
--- /dev/null
+++ b/files/openstack/folsom/virtscripts/cold-migrate
@@ -0,0 +1,43 @@
+#!/bin/bash
+ssh-add -l  /dev/null
+if [ $? != 0 ]
+then
+   echo You must have a forwarded agent to use this script
+   exit 1
+fi
+INSTANCENAME=$1
+TOHOST=$2
+PROJECT=$3
+FROMHOST=`OS_TENANT_NAME=${PROJECT} nova show ${INSTANCENAME} | grep 
'OS-EXT-SRV-ATTR:host' | awk '{ print $4 }'`
+INSTANCE=`OS_TENANT_NAME=${PROJECT} nova show ${INSTANCENAME} | grep 
'OS-EXT-SRV-ATTR:instance_name' | awk '{ print $4 }'`
+echo Migrating $INSTANCE from $FROMHOST to $TOHOST
+echo 
+echo Destroying instance on $FROMHOST
+echo 
+ssh $FROMHOST.pmtpa.wmnet virsh destroy ${INSTANCE}
+echo 
+echo Rsyncing instance from $FROMHOST to $TOHOST
+echo 
+ssh -A $FROMHOST.pmtpa.wmnet rsync -S -av /var/lib/nova/instances/${INSTANCE} 
${TOHOST}.pmtpa.wmnet:/var/lib/nova/instances/
+echo 
+echo Defining the instance on $TOHOST
+echo 
+ssh $TOHOST.pmtpa.wmnet virsh define 
/var/lib/nova/instances/${INSTANCE}/libvirt.xml
+echo 
+echo Undefining the instance on $FROMHOST
+echo 
+ssh $FROMHOST.pmtpa.wmnet virsh undefine ${INSTANCE}
+echo
+echo Defining the network filter on $TOHOST
+echo
+ssh $FROMHOST.pmtpa.wmnet cat 
/etc/libvirt/nwfilter/nova-instance-${INSTANCE}-* | \
+   ssh $TOHOST.pmtpa.wmnet virsh nwfilter-define /proc/self/fd/0
+echo 
+echo Updating the instance's host in the database
+echo 
+mysql -uroot nova -e update instances set host=\${TOHOST}\ where 
hostname=\${INSTANCENAME}\;
+mysql -uroot nova -e update instances set host=\${TOHOST}\ where 
hostname=\${INSTANCE}\;
+echo 
+echo Rebooting the instance
+echo 
+OS_TENANT_NAME=${PROJECT} nova reboot ${INSTANCENAME}
diff --git a/files/openstack/folsom/virtscripts/dc-migrate 
b/files/openstack/folsom/virtscripts/dc-migrate
new file mode 100755
index 000..5b8bc7e
--- /dev/null
+++ b/files/openstack/folsom/virtscripts/dc-migrate
@@ -0,0 +1,73 @@
+#!/bin/bash
+#set -x
+ssh-add -l  /dev/null
+if [ $? != 0 ]
+then
+   echo You must have a forwarded agent to use this script
+   exit 1
+fi
+INSTANCENAME=$1
+PROJECT=$2
+FROMREGION='pmtpa'
+TOREGION='eqiad'
+FROMAUTH=http://virt0.wikimedia.org:35357/v2.0;
+TOAUTH=http://virt1000.wikimedia.org:35357/v2.0;
+FROMPUPPETMASTER=virt0.wikimedia.org
+TOPUPPETMASTER=virt1000.wikimedia.org
+TOINSTANCE=`OS_TENANT_NAME=${PROJECT} OS_AUTH_URL=${TOAUTH} nova --os-region 
${TOREGION} show ${INSTANCENAME} | grep ' id ' | awk '{ print $4 }'`
+if [ -n $TOINSTANCE ]; then
+   echo Name conflict!  ${INSTANCENAME} already exists in ${TOREGION} 
with ID \${TOINSTANCE}\
+   exit 1
+fi
+echo (That error was a good thing.)
+echo 
+FROMIMAGE=`OS_TENANT_NAME=${PROJECT} OS_AUTH_URL=${FROMAUTH} nova --os-region 
${FROMREGION} show ${INSTANCENAME} | grep ' image ' | awk '{gsub ( [()], ) 
; print $(NF-1) }'`
+FROMFLAVOR=`OS_TENANT_NAME=${PROJECT} OS_AUTH_URL=${FROMAUTH} nova --os-region 
${FROMREGION} show ${INSTANCENAME} | grep ' flavor ' | awk '{gsub ( [()], ) 
; print $5 }'`
+FROMSECURITYRAW=`OS_TENANT_NAME=${PROJECT} OS_AUTH_URL=${FROMAUTH} nova 
--os-region ${FROMREGION} show ${INSTANCENAME} | grep ' security_groups ' | awk 
 -F | '{ print $3 }'`
+FROMSECURITY=`python -c print ','.join([o['name'] for o in 
${FROMSECURITYRAW}])`
+FROMHOST=`OS_TENANT_NAME=${PROJECT} OS_AUTH_URL=${FROMAUTH} nova --os-region 
${FROMREGION} show ${INSTANCENAME} | grep 'OS-EXT-SRV-ATTR:host' | awk '{ print 
$4 }'`
+FROMINSTANCENAME=`OS_TENANT_NAME=${PROJECT} OS_AUTH_URL=${FROMAUTH} nova 
--os-region ${FROMREGION} show ${INSTANCENAME} | grep 
'OS-EXT-SRV-ATTR:instance_name' | awk '{ print $4 }'`
+FROMINSTANCE=$FROMINSTANCENAME
+echo Creating initial image in $TOREGION
+cd /srv/org/wikimedia/controller/wikis/w  php 
./extensions/OpenStackManager/maintenance/createInstance.php --image 
${FROMIMAGE} --flavor ${FROMFLAVOR} --instance 

[MediaWiki-commits] [Gerrit] [CentralCssJs] Register central wiki part of the extension - change (translatewiki)

2014-02-25 Thread Raimond Spekking (Code Review)
Raimond Spekking has submitted this change and it was merged.

Change subject: [CentralCssJs] Register central wiki part of the extension
..


[CentralCssJs] Register central wiki part of the extension

Change-Id: Ie98639bb4876823b9ef186927297f33b9c0829a2
---
M groups/MediaWiki/mediawiki-defines.txt
1 file changed, 9 insertions(+), 0 deletions(-)

Approvals:
  Raimond Spekking: Verified; Looks good to me, approved



diff --git a/groups/MediaWiki/mediawiki-defines.txt 
b/groups/MediaWiki/mediawiki-defines.txt
index ed38da4..bd478ef 100644
--- a/groups/MediaWiki/mediawiki-defines.txt
+++ b/groups/MediaWiki/mediawiki-defines.txt
@@ -11,6 +11,10 @@
 
 Account Audit
 
+Account Info
+aliasfile = AccountInfo/AccountInfo.alias.php
+ignored=accountinfo-none
+
 # Active Abstract : No real extension. Plugin for dumpBackup.php
 
 Ad Manager
@@ -664,6 +668,11 @@
 
 Global Css Js
 
+Global Css Js - central wiki
+id = ext-globalcssjs-centralwiki
+file = GlobalCssJs/GlobalCssJs.central.i18n.php
+optional = global.css, global.js
+
 Global Preferences
 descmsg = globalprefs-desc
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie98639bb4876823b9ef186927297f33b9c0829a2
Gerrit-PatchSet: 1
Gerrit-Project: translatewiki
Gerrit-Branch: master
Gerrit-Owner: Raimond Spekking raimond.spekk...@gmail.com
Gerrit-Reviewer: Raimond Spekking raimond.spekk...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] [CentralCssJs] Register central wiki part of the extension - change (translatewiki)

2014-02-25 Thread Raimond Spekking (Code Review)
Raimond Spekking has uploaded a new change for review.

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

Change subject: [CentralCssJs] Register central wiki part of the extension
..

[CentralCssJs] Register central wiki part of the extension

Change-Id: Ie98639bb4876823b9ef186927297f33b9c0829a2
---
M groups/MediaWiki/mediawiki-defines.txt
1 file changed, 9 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/translatewiki 
refs/changes/61/115361/1

diff --git a/groups/MediaWiki/mediawiki-defines.txt 
b/groups/MediaWiki/mediawiki-defines.txt
index ed38da4..bd478ef 100644
--- a/groups/MediaWiki/mediawiki-defines.txt
+++ b/groups/MediaWiki/mediawiki-defines.txt
@@ -11,6 +11,10 @@
 
 Account Audit
 
+Account Info
+aliasfile = AccountInfo/AccountInfo.alias.php
+ignored=accountinfo-none
+
 # Active Abstract : No real extension. Plugin for dumpBackup.php
 
 Ad Manager
@@ -664,6 +668,11 @@
 
 Global Css Js
 
+Global Css Js - central wiki
+id = ext-globalcssjs-centralwiki
+file = GlobalCssJs/GlobalCssJs.central.i18n.php
+optional = global.css, global.js
+
 Global Preferences
 descmsg = globalprefs-desc
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie98639bb4876823b9ef186927297f33b9c0829a2
Gerrit-PatchSet: 1
Gerrit-Project: translatewiki
Gerrit-Branch: master
Gerrit-Owner: Raimond Spekking raimond.spekk...@gmail.com

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


[MediaWiki-commits] [Gerrit] Fix composer require versions - change (mediawiki...Wikibase)

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

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

Change subject: Fix composer require versions
..

Fix composer require versions

Change-Id: I7f55412f763be2e23a97c877834a797fa507bb9d
---
M composer.json
1 file changed, 10 insertions(+), 10 deletions(-)


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

diff --git a/composer.json b/composer.json
index 582790f..783cae2 100644
--- a/composer.json
+++ b/composer.json
@@ -24,16 +24,16 @@
},
require: {
php: =5.3.2,
-   data-values/data-values: ~0.1,
-   data-values/common: ~0.1,
-   data-values/geo: ~0.1,
-   data-values/number: ~0.2,
-   data-values/time: ~0.1,
-   data-values/validators: ~0.1,
-   data-values/data-types: ~0.1,
-   data-values/serialization: ~0.1,
-   data-values/javascript: ~0.3,
-   data-values/value-view: ~0.3,=0.3.3,
+   data-values/data-values: 0.1.*,
+   data-values/common: 0.1.*,
+   data-values/geo: 0.1.*,
+   data-values/number: 0.2.*,
+   data-values/time: 0.1.*,
+   data-values/validators: 0.1.*,
+   data-values/data-types: 0.1.*,
+   data-values/serialization: 0.1.*,
+   data-values/javascript: 0.3.*,
+   data-values/value-view: 0.3.*,=0.3.3,
wikibase/data-model: 0.6.*,
diff/diff: =0.9,
wikibase/easyrdf_lite: *

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7f55412f763be2e23a97c877834a797fa507bb9d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Addshore addshorew...@gmail.com

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


[MediaWiki-commits] [Gerrit] Revert [CentralCssJs] Register central wiki part of the ext... - change (translatewiki)

2014-02-25 Thread Raimond Spekking (Code Review)
Raimond Spekking has uploaded a new change for review.

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

Change subject: Revert [CentralCssJs] Register central wiki part of the 
extension
..

Revert [CentralCssJs] Register central wiki part of the extension

Key 8:global.js already belongs to ext-globalcssjs-centralwiki, conflict with 
ext-sharedcssjs

AccountInfo was not ready.

This reverts commit 8230c776d693802e87e4a20d54ebeead4e2b7e75.

Change-Id: I2747c114bc84fae1686a11a7182a9127a7e6263d
---
M groups/MediaWiki/mediawiki-defines.txt
1 file changed, 0 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/translatewiki 
refs/changes/63/115363/1

diff --git a/groups/MediaWiki/mediawiki-defines.txt 
b/groups/MediaWiki/mediawiki-defines.txt
index bd478ef..ed38da4 100644
--- a/groups/MediaWiki/mediawiki-defines.txt
+++ b/groups/MediaWiki/mediawiki-defines.txt
@@ -11,10 +11,6 @@
 
 Account Audit
 
-Account Info
-aliasfile = AccountInfo/AccountInfo.alias.php
-ignored=accountinfo-none
-
 # Active Abstract : No real extension. Plugin for dumpBackup.php
 
 Ad Manager
@@ -667,11 +663,6 @@
 descmsg = guc-desc
 
 Global Css Js
-
-Global Css Js - central wiki
-id = ext-globalcssjs-centralwiki
-file = GlobalCssJs/GlobalCssJs.central.i18n.php
-optional = global.css, global.js
 
 Global Preferences
 descmsg = globalprefs-desc

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2747c114bc84fae1686a11a7182a9127a7e6263d
Gerrit-PatchSet: 1
Gerrit-Project: translatewiki
Gerrit-Branch: master
Gerrit-Owner: Raimond Spekking raimond.spekk...@gmail.com

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


[MediaWiki-commits] [Gerrit] Revert [CentralCssJs] Register central wiki part of the ext... - change (translatewiki)

2014-02-25 Thread Raimond Spekking (Code Review)
Raimond Spekking has submitted this change and it was merged.

Change subject: Revert [CentralCssJs] Register central wiki part of the 
extension
..


Revert [CentralCssJs] Register central wiki part of the extension

Key 8:global.js already belongs to ext-globalcssjs-centralwiki, conflict with 
ext-sharedcssjs

AccountInfo was not ready.

This reverts commit 8230c776d693802e87e4a20d54ebeead4e2b7e75.

Change-Id: I2747c114bc84fae1686a11a7182a9127a7e6263d
---
M groups/MediaWiki/mediawiki-defines.txt
1 file changed, 0 insertions(+), 9 deletions(-)

Approvals:
  Raimond Spekking: Verified; Looks good to me, approved



diff --git a/groups/MediaWiki/mediawiki-defines.txt 
b/groups/MediaWiki/mediawiki-defines.txt
index bd478ef..ed38da4 100644
--- a/groups/MediaWiki/mediawiki-defines.txt
+++ b/groups/MediaWiki/mediawiki-defines.txt
@@ -11,10 +11,6 @@
 
 Account Audit
 
-Account Info
-aliasfile = AccountInfo/AccountInfo.alias.php
-ignored=accountinfo-none
-
 # Active Abstract : No real extension. Plugin for dumpBackup.php
 
 Ad Manager
@@ -667,11 +663,6 @@
 descmsg = guc-desc
 
 Global Css Js
-
-Global Css Js - central wiki
-id = ext-globalcssjs-centralwiki
-file = GlobalCssJs/GlobalCssJs.central.i18n.php
-optional = global.css, global.js
 
 Global Preferences
 descmsg = globalprefs-desc

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I2747c114bc84fae1686a11a7182a9127a7e6263d
Gerrit-PatchSet: 1
Gerrit-Project: translatewiki
Gerrit-Branch: master
Gerrit-Owner: Raimond Spekking raimond.spekk...@gmail.com
Gerrit-Reviewer: Raimond Spekking raimond.spekk...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] CirrusSearch dependencies for tests - change (integration/jenkins-job-builder-config)

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

Change subject: CirrusSearch dependencies for tests
..


CirrusSearch dependencies for tests

Updates job mwext-CirrusSearch-testextensions-master

Change-Id: I633620574b9683b6bb983719ff0ac8ec4b338fe1
---
M mediawiki-extensions.yaml
1 file changed, 4 insertions(+), 0 deletions(-)

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



diff --git a/mediawiki-extensions.yaml b/mediawiki-extensions.yaml
index e95c1eb..d68db36 100644
--- a/mediawiki-extensions.yaml
+++ b/mediawiki-extensions.yaml
@@ -543,6 +543,10 @@
 dependencies: 'Scribunto'
  - '{name}-{ext-name}-testextensions-{mwbranch}':
 name: mwext
+ext-name: CirrusSearch
+dependencies: 'Elastica,MwEmbedSupport,TimedMediaHandler,PdfHandler'
+ - '{name}-{ext-name}-testextensions-{mwbranch}':
+name: mwext
 ext-name: DataTypes
 dependencies: 'DataValues'
  - '{name}-{ext-name}-testextensions-{mwbranch}':

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I633620574b9683b6bb983719ff0ac8ec4b338fe1
Gerrit-PatchSet: 3
Gerrit-Project: integration/jenkins-job-builder-config
Gerrit-Branch: master
Gerrit-Owner: Hashar has...@free.fr
Gerrit-Reviewer: Hashar has...@free.fr
Gerrit-Reviewer: Manybubbles never...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] +sidebar userscript - change (wikimedia...triagescripts)

2014-02-25 Thread Aklapper (Code Review)
Aklapper has submitted this change and it was merged.

Change subject: +sidebar userscript
..


+sidebar userscript

Change-Id: I5cc7b104d0b5bb50b9fe122fbb93776bbaa04f65
---
A wikimedia-bugzilla-sidebar.user.js
1 file changed, 36 insertions(+), 0 deletions(-)

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



diff --git a/wikimedia-bugzilla-sidebar.user.js 
b/wikimedia-bugzilla-sidebar.user.js
new file mode 100644
index 000..42fbe29
--- /dev/null
+++ b/wikimedia-bugzilla-sidebar.user.js
@@ -0,0 +1,36 @@
+// ==UserScript==
+// @name   WMF Bugzilla: add links to sidebar
+// @namespace  http://arctus.nl
+// @version0.1
+// @description  Adds direct bug creations urls  browse project link to the 
sidebar. Adapt this script to your needs!
+// @match  https://bugzilla.wikimedia.org/*
+// @copyright  2014, Merlijn van Deen; MIT licensed
+// @requirehttps://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js
+// ==/UserScript==
+
+/* Configuration follows, and takes the form of
+   extraLinks['project/component name'] = 'https://direct url to bug creation'
+
+   You can find the url by opening the 'Report Bug' screen, setting relevant
+   values, and clicking the 'Remember values as bookmarkable template' button.
+   On that page, right-click the Bug entry template link, select Copy link
+   address and use that URL below.
+
+*/
+
+var extraLinks = {};
+extraLinks['pywikibot'] = 
'https://bugzilla.wikimedia.org/enter_bug.cgi?assigned_to=Pywikipedia-bugs%40lists.wikimedia.orgattach_text=blocked=bug_file_loc=http%3A%2F%2Fbug_severity=normalbug_status=NEWcf_browser=---cf_platform=---comment=component=Generalcontenttypeentry=contenttypemethod=autodetectcontenttypeselection=text%2Fplaindata=dependson=description=form_name=enter_bugkeywords=maketemplate=Remember%20values%20as%20bookmarkable%20templateop_sys=Allproduct=Pywikibotrep_platform=Allshort_desc=target_milestone=---version=core%20%282.0%29';
+extraLinks['tsreports'] = 
'https://bugzilla.wikimedia.org/enter_bug.cgi?assigned_to=valhallasw%40arctus.nlattach_text=blocked=bug_file_loc=http%3A%2F%2Fbug_severity=normalbug_status=NEWcf_browser=---cf_platform=---comment=component=tsreportscontenttypeentry=contenttypemethod=autodetectcontenttypeselection=text%2Fplaindata=dependson=description=form_name=enter_bugkeywords=maketemplate=Remember%20values%20as%20bookmarkable%20templateop_sys=Allproduct=Tool%20Labs%20toolsrep_platform=Allshort_desc=target_milestone=---version=unspecified';
+extraLinks['DBQ'] = 
'https://bugzilla.wikimedia.org/enter_bug.cgi?assigned_to=wikibugs-l%40lists.wikimedia.orgattach_text=blocked=bug_file_loc=http%3A%2F%2Fbug_severity=normalbug_status=NEWcf_browser=---cf_platform=---comment=component=Database%20Queriescontenttypeentry=contenttypemethod=autodetectcontenttypeselection=text%2Fplaindata=dependson=description=form_name=enter_bugkeywords=maketemplate=Remember%20values%20as%20bookmarkable%20templateop_sys=Allproduct=Tool%20Labs%20toolsrep_platform=Allshort_desc=target_milestone=---version=unspecified';
+
+/* Code follows */
+document.jQuery = jQuery;
+
+/* Insert direct bug creation links */
+$('#panel a[href=enter_bug.cgi]').parent().append('ul 
id=specificBugCreationLinks/ul')
+
+for(var key in extraLinks) {
+   $(#specificBugCreationLinks).append(
+   liin  + document.jQuery('a', {href:extraLinks[key], 
text:key})[0].outerHTML + /li
+   );
+};

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I5cc7b104d0b5bb50b9fe122fbb93776bbaa04f65
Gerrit-PatchSet: 2
Gerrit-Project: wikimedia/bugzilla/triagescripts
Gerrit-Branch: master
Gerrit-Owner: Merlijn van Deen valhall...@arctus.nl
Gerrit-Reviewer: Aklapper aklap...@wikimedia.org
Gerrit-Reviewer: Merlijn van Deen valhall...@arctus.nl

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


[MediaWiki-commits] [Gerrit] Fix the usage of promise for page loader - change (mediawiki...ContentTranslation)

2014-02-25 Thread Santhosh (Code Review)
Santhosh has uploaded a new change for review.

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

Change subject: Fix the usage of promise for page loader
..

Fix the usage of promise for page loader

As per https://github.com/kriskowal/q/wiki/Coming-from-jQuery

Change-Id: I5037141bdedf0dc6aa7fdf9782608b4162cb6c60
---
M server/models/dataModelManager.js
1 file changed, 4 insertions(+), 1 deletion(-)


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

diff --git a/server/models/dataModelManager.js 
b/server/models/dataModelManager.js
index 501af26..b79668b 100644
--- a/server/models/dataModelManager.js
+++ b/server/models/dataModelManager.js
@@ -38,7 +38,7 @@
} else {
PageLoader = require( __dirname + 
'/../pageloader/PageLoader.js').PageLoader;
pageloader = new PageLoader( 
dataModelManager.context.sourcePage );
-   pageloader.load().done( function ( data ) {
+   pageloader.load().then( function ( data ) {
dataModelManager.context.sourceText = data;
segmenter = new CXSegmenter( 
dataModelManager.context.sourceText );
segmenter.segment();
@@ -54,6 +54,9 @@
dataModelManager.publish();
// TODO: Dispatch the context to a number of 
task runners
// Once each task runners finish, publish.
+   }, function ( /*jqXHR, textStatus, errorThrown*/ ) {
+   console.error( '[CX] Error in retrieving the 
page ' +
+   dataModelManager.context.sourcePage );
} );
}
} );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5037141bdedf0dc6aa7fdf9782608b4162cb6c60
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com

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


[MediaWiki-commits] [Gerrit] [MediaWiki] Enable export for languages with an own Wikipedia - change (translatewiki)

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

Change subject: [MediaWiki] Enable export for languages with an own Wikipedia
..


[MediaWiki] Enable export for languages with an own Wikipedia

Those languages already a Wikipedia for historical reasons: if their
translations are not exported they get confused and unhappy and just
keep translating locally on their own Wikipedias instead of benefiting
all MediaWiki reusers.

Can't find a way other than a separate export command, because threshold
is always evaluated and unsets a language wherever it comes from.

https://translatewiki.net/wiki/Thread:Support/Enable_export_for_all_supported_languages_with_an_open_Wikipedia

Change-Id: I0007fd00579971d4d5bce5e4545492f87ea52867
---
M bin/repoexport
1 file changed, 3 insertions(+), 1 deletion(-)

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



diff --git a/bin/repoexport b/bin/repoexport
index fe78ebe..f7c64f3 100755
--- a/bin/repoexport
+++ b/bin/repoexport
@@ -16,8 +16,9 @@
 
 EXPORTER=$WIKI/extensions/Translate/scripts/export.php
 
SKIPLANGS=test,be-x-old,crh,dk,en,fiu-vro,gan,got,hif,kbd,kk,kk-cn,iu,kk-kz,kk-tr,ko-kp,ku,ku-arab,no,ruq,simple,sr,tg,tp,tt,ug,zh,zh-classical,zh-cn,zh-sg,zh-hk,zh-min-nan,zh-mo,zh-my,zh-tw,zh-yue,bbc,ady
+FORCELANGS=chy,cr,ki,nrm,rn,roa-rup,rw,tum,tw # Must not contain any of 
those above
 THRESHOLD=--threshold 35
-HOURS=--hours 200 # Somewhat over week
+HOURS=--hours 200 # Somewhat over a week
 
 if [ $PROJECT = commons-android ]
 then
@@ -85,6 +86,7 @@
 elif [ $PROJECT = mediawiki ]
 then
php $EXPORTER --target mediawiki/master/languages/messages --group 
'core' --lang '*' --skip $SKIPLANGS --threshold 18 $HOURS 
+   php $EXPORTER --target mediawiki/master/languages/messages --group 
'core' --lang $FORCELANGS $HOURS 
php $EXPORTER --target . --group 'ext-installer' --lang '*' --skip 
$SKIPLANGS $HOURS 
 
if [ -d mediawiki/REL1_22/ ]

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I0007fd00579971d4d5bce5e4545492f87ea52867
Gerrit-PatchSet: 3
Gerrit-Project: translatewiki
Gerrit-Branch: master
Gerrit-Owner: Nemo bis federicol...@tiscali.it
Gerrit-Reviewer: MF-Warburg mfwarb...@googlemail.com
Gerrit-Reviewer: Nemo bis federicol...@tiscali.it
Gerrit-Reviewer: Raimond Spekking raimond.spekk...@gmail.com
Gerrit-Reviewer: SPQRobin robinp.1...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Include section titles also in segmentation - change (mediawiki...ContentTranslation)

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

Change subject: Include section titles also in segmentation
..


Include section titles also in segmentation

Change-Id: I77e1d228c2b5f823d664b60ea87be444361bb7eb
---
M server/segmentation/paragraphSegmenter.js
M server/segmentation/sentenceSegmenter.js
2 files changed, 13 insertions(+), 15 deletions(-)

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



diff --git a/server/segmentation/paragraphSegmenter.js 
b/server/segmentation/paragraphSegmenter.js
index dcae4f5..149eb63 100644
--- a/server/segmentation/paragraphSegmenter.js
+++ b/server/segmentation/paragraphSegmenter.js
@@ -17,7 +17,6 @@
 
 function ParagraphSegmenter( content ) {
Segmenter.call( this, content );
-   this.paragraphs = [];
this.links = {};
 }
 
@@ -28,17 +27,22 @@
var segmenter = this,
$container = $( 'div' ).html( this.content );
 
-   $container.find( 'p' ).each( function ( index, paragraph ) {
-   var $paragraph = $( paragraph ),
-   sentenceSegments,
-   sentenceSegmenter = new SentenceSegmenter( 
$paragraph.html() );
+   segmenter.segmentedContent = '';
+   // TODO: Following line effectively filters the page content.
+   // We take only paragraphs and section titles. Will require a better
+   // strategy for preprocessing article content.
+   $container.find( 'p, h1, h2, h3, h4, h5, h6' ).each( function ( index, 
section ) {
+   var $section = $( section ), sentenceSegments, 
sentenceSegmenter;
 
+   sentenceSegmenter = new SentenceSegmenter( $section.html() );
sentenceSegmenter.segment();
sentenceSegments = sentenceSegmenter.getSegments();
segmenter.segments = $.extend( segmenter.segments, 
sentenceSegments );
+   // TODO: do we need segmentCount?
segmenter.segmentCount += sentenceSegmenter.getSegmentCount();
segmenter.links = $.extend( segmenter.links, 
sentenceSegmenter.getLinks() );
-   segmenter.paragraphs.push( sentenceSegmenter.toHTML() );
+   $section.html( sentenceSegmenter.toHTML() );
+   segmenter.segmentedContent +=  $section[0].outerHTML;
} );
 };
 
@@ -47,14 +51,7 @@
 };
 
 ParagraphSegmenter.prototype.toHTML = function () {
-   var i, paragraph, paragraphs = '';
-
-   for ( i = 0; i this.paragraphs.length; i++ ) {
-   paragraph = $( this.paragraphs[i] );
-   paragraphs += $( 'p' ).append( paragraph ).prop( 'outerHTML' 
);
-   }
-
-   return paragraphs;
+   return this.segmentedContent;
 };
 
 module.exports.ParagraphSegmenter = ParagraphSegmenter;
diff --git a/server/segmentation/sentenceSegmenter.js 
b/server/segmentation/sentenceSegmenter.js
index 77955a3..96f3785 100644
--- a/server/segmentation/sentenceSegmenter.js
+++ b/server/segmentation/sentenceSegmenter.js
@@ -37,7 +37,8 @@
linkSegmenter.segment();
this.links = $.extend( this.links, linkSegmenter.getSegments() 
);
this.segments[segmentId] = {
-   source: linkSegmenter.toHTML() + '. '
+   source: linkSegmenter.toHTML() +
+   ( ( i+1 !== this.segmentCount )? '. ': '' ) // 
XXX
};
// We need this lookup to keep the order of segments
// while constructing the segmented content using

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I77e1d228c2b5f823d664b60ea87be444361bb7eb
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Connect to server and use the data model to render the artic... - change (mediawiki...ContentTranslation)

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

Change subject: Connect to server and use the data model to render the article 
content
..


Connect to server and use the data model to render the article content

Change-Id: If5d340c979802784e42b9f62dcc603415b832202
---
M ContentTranslation.hooks.php
M Resources.php
M modules/source/ext.cx.source.js
M modules/translation/ext.cx.translation.js
4 files changed, 15 insertions(+), 28 deletions(-)

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



diff --git a/ContentTranslation.hooks.php b/ContentTranslation.hooks.php
index 64e97b7..d86303f 100644
--- a/ContentTranslation.hooks.php
+++ b/ContentTranslation.hooks.php
@@ -16,7 +16,7 @@
 * Hook: BeforePageDisplay
 */
public static function addModules( $out, $skin ) {
-   global $wgContentTranslationEventLogging;
+   global $wgContentTranslationEventLogging, 
$wgContentTranslationServerURL;
 
// If EventLogging integration is enabled, load the schema 
module
// and the event logging functions module
@@ -26,6 +26,9 @@
'ext.cx.eventlogging',
) );
}
+   $out-addScript(
+   script 
src='$wgContentTranslationServerURL/socket.io/socket.io.js'/script
+   );
 
return true;
}
@@ -42,4 +45,5 @@
 
return true;
}
+
 }
diff --git a/Resources.php b/Resources.php
index 82e4382..6ad38d5 100644
--- a/Resources.php
+++ b/Resources.php
@@ -15,7 +15,10 @@
 );
 
 $wgResourceModules['ext.cx.model'] = array(
-   'scripts' = 'base/ext.cx.model.js',
+   'scripts' = array(
+   'base/ext.cx.model.js',
+   'base/ext.cx.datamanager.js',
+   ),
 ) + $resourcePaths;
 
 $wgResourceModules['ext.cx.base'] = array(
diff --git a/modules/source/ext.cx.source.js b/modules/source/ext.cx.source.js
index 9bf7088..ad62040 100644
--- a/modules/source/ext.cx.source.js
+++ b/modules/source/ext.cx.source.js
@@ -26,8 +26,9 @@
 
ContentTranslationSource.prototype.init = function () {
mw.cx.sourceTitle = new mw.Uri().query.page;
+   mw.cx.targetLanguage = new mw.Uri().query.lang || '';
this.render();
-   this.load();
+   mw.cx.connect();
this.listen();
};
 
@@ -73,21 +74,11 @@
};
 
ContentTranslationSource.prototype.load = function () {
-   var api = new mw.Api(),
-   cxSource = this;
-
-   api.get( {
-   action: 'parse',
-   page: mw.cx.sourceTitle,
-   disablepp: true
-   } ).done( function ( result ) {
-   cxSource.$title.html( result.parse.title );
-   cxSource.$content.html( result.parse.text['*'] );
-   } );
+   this.$content.html( mw.cx.data.segmentedContent );
};
 
ContentTranslationSource.prototype.listen = function () {
-   // Empty for now
+   mw.hook( 'mw.cx.source.ready' ).add( $.proxy( this.load, this ) 
);
};
 
$.fn.cxSource = function ( options ) {
diff --git a/modules/translation/ext.cx.translation.js 
b/modules/translation/ext.cx.translation.js
index d79d5b1..1c1e58f 100644
--- a/modules/translation/ext.cx.translation.js
+++ b/modules/translation/ext.cx.translation.js
@@ -25,7 +25,6 @@
}
 
ContentTranslationEditor.prototype.init = function () {
-   mw.cx.targetLanguage = new mw.Uri().query.lang || '';
this.render();
this.listen();
};
@@ -89,18 +88,8 @@
} );
};
 
-   ContentTranslationEditor.prototype.update = function ( data ) {
-   var contentTranslationEditor = this;
-
-   $.post( mw.config.get( 'wgContentTranslationServerURL' ), {
-   sourcelang: mw.cx.sourceLanguage,
-   targetlang: mw.cx.targetLanguage,
-   sourcetext: data
-   } ).done( function ( response ) {
-   contentTranslationEditor.$content.html( response );
-   } ).fail( function () {
-   mw.log( 'API call to get machine translation failed.' );
-   } );
+   ContentTranslationEditor.prototype.update = function ( ) {
+   this.$content.html( mw.cx.data.segmentedContent );
 
mw.hook( 'mw.cx.progress' ).fire( 100 );
mw.hook( 'mw.cx.translation.change' ).fire();

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

Gerrit-MessageType: merged
Gerrit-Change-Id: 

[MediaWiki-commits] [Gerrit] Redis data store for the CX data model - change (mediawiki...ContentTranslation)

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

Change subject: Redis data store for the CX data model
..


Redis data store for the CX data model

A very simple redis strore that stores the data model in json string
with key as the source page.

Change-Id: Idca80f88e42ccc2e385bd24ced0b61013ef84033
---
M server/ContentTranslationService.js
M server/models/dataModelManager.js
M server/package.json
3 files changed, 73 insertions(+), 35 deletions(-)

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



diff --git a/server/ContentTranslationService.js 
b/server/ContentTranslationService.js
index ea87685..9269c41 100644
--- a/server/ContentTranslationService.js
+++ b/server/ContentTranslationService.js
@@ -14,40 +14,51 @@
 
 'use strict';
 
-var app, instanceName, server, io, port, context,
+var instanceName, context,
express = require( 'express' );
 
-port = process.argv[2] || 8000;
+var port = process.argv[2] || 8000;
 
-app = express();
-server = require( 'http' ).createServer( app );
-io = require( 'socket.io' ).listen( server );
+var app = express();
+var server = require( 'http' ).createServer( app );
+var io = require( 'socket.io' ).listen( server );
 
+var redis = require( 'redis' );
+
+instanceName = 'worker(' + process.pid + ')';
 // socket.io connection establishment
 io.sockets.on( 'connection', function ( socket ) {
var datamodelManager,
-   PageLoader,
-   CXDataModelManager;
-   console.log( '[CX] Client connected to worker(' + process.pid + '). 
Socket: ' + socket.id );
+   CXDataModelManager,
+   redisSub = redis.createClient();
+
+   console.log( '[CX] Client connected to ' + instanceName + '). Socket: ' 
+ socket.id );
+   redisSub.subscribe( 'cx' );
+   redisSub.on( 'message', function( channel, message ) {
+   socket.emit( 'cx.data.update', JSON.parse( message ) );
+   console.log('[CX] Received from channel #' + channel + ':' + 
message );
+   } );
+
socket.on( 'cx.init', function ( data ) {
-   var pageloader;
CXDataModelManager = require(  __dirname + 
'/models/dataModelManager.js').CXDataModelManager;
context = {
sourceLanguage: data.sourceLanguage,
targetLanguage: data.targetLanguage,
sourcePage: data.sourcePage,
-   socket: socket
+   pub: redis.createClient(),
+   store: redis.createClient()
};
-   PageLoader  = require(  __dirname + 
'/pageloader/PageLoader.js').PageLoader;
-   pageloader = new PageLoader( context.sourcePage );
-   pageloader.load().done( function ( data ) {
-   context.sourceText = data;
-   // Inject the session context to dataModelManager
-   // It should take care of managing the data model and 
pushing
-   // it to the client through socket.
-   datamodelManager = new CXDataModelManager( context );
-   } );
+   // Inject the session context to dataModelManager
+   // It should take care of managing the data model and pushing
+   // it to the client through socket.
+   datamodelManager = new CXDataModelManager( context );
} );
+
+   socket.on( 'disconnect', function () {
+   console.warn( '[CX] Dsconnecting from redis' );
+   redisSub.quit();
+   } );
+
 } );
 
 // Everything else goes through this.
diff --git a/server/models/dataModelManager.js 
b/server/models/dataModelManager.js
index 346bd62..501af26 100644
--- a/server/models/dataModelManager.js
+++ b/server/models/dataModelManager.js
@@ -25,27 +25,53 @@
  * Initialize
  */
 CXDataModelManager.prototype.init = function () {
-   var dataModelManager = this, segmenter;
+   var dataModelManager = this,
+   segmenter,
+   PageLoader, pageloader;
 
-   segmenter = new CXSegmenter( this.context.sourceText );
-   segmenter.segment();
-   this.dataModel = {
-   version: 0,
-   sourceLanguage: this.context.sourceLanguage,
-   targetLanguage: this.context.targetLanguage,
-   sourceLocation: this.context.sourceTitle,
-   segments: segmenter.getSegments(),
-   segmentedContent: segmenter.getSegmentedContent(),
-   links: segmenter.getLinks()
-   };
-   dataModelManager.refresh();
+   // TODO: refactor this
+   this.context.store.get( this.context.sourcePage, function ( err, data ) 
{
+   dataModelManager.dataModel = JSON.parse( data );
+   if ( dataModelManager.dataModel ) {
+   // data model 

[MediaWiki-commits] [Gerrit] Add ext.cx.datamanager.js - change (mediawiki...ContentTranslation)

2014-02-25 Thread Santhosh (Code Review)
Santhosh has uploaded a new change for review.

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

Change subject: Add ext.cx.datamanager.js
..

Add ext.cx.datamanager.js

Missed in  If5d340c979802784e42b9f62dcc603415b832202

Change-Id: If80a54501f417eaf655bef4b53350db8b35820fb
---
A modules/base/ext.cx.datamanager.js
1 file changed, 43 insertions(+), 0 deletions(-)


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

diff --git a/modules/base/ext.cx.datamanager.js 
b/modules/base/ext.cx.datamanager.js
new file mode 100644
index 000..890ad71
--- /dev/null
+++ b/modules/base/ext.cx.datamanager.js
@@ -0,0 +1,43 @@
+/**
+ * ContentTranslation extension
+ * A tool that allows editors to translate pages from one language
+ * to another with the help of machine translation and other translation aids
+ *
+ * @file
+ * @ingroup Extensions
+ * @copyright See AUTHORS.txt
+ * @license GPL-2.0+
+ */
+( function ( $, mw ) {
+   'use strict';
+
+   var socket;
+
+   /* global io */
+   function initConnection() {
+   socket = io.connect( mw.config.get( 
'wgContentTranslationServerURL' ) );
+   mw.log( '[CX] Connected to server' );
+   }
+
+   function updateModel( data) {
+   mw.log( '[CX] Recieved data from server' );
+   mw.cx.data = data;
+   mw.hook( 'mw.cx.source.ready' ).fire();
+   }
+
+   mw.cx.connect = function () {
+   if ( !socket ) {
+   initConnection();
+   }
+   socket.emit( 'cx.init', {
+   // FIXME
+   sourcePage: 'http://en.wikipedia.org/wiki/' + 
mw.cx.sourceTitle,
+   sourceLanguage: mw.cx.sourceLanguage,
+   targetLanguage: mw.cx.targetLanguage,
+   channel: 'cx'
+   } );
+   mw.log( '[CX] Sending context information to server' );
+   socket.on( 'cx.data.update', updateModel );
+   };
+
+}( jQuery, mediaWiki ) );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: If80a54501f417eaf655bef4b53350db8b35820fb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com

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


[MediaWiki-commits] [Gerrit] Add ext.cx.datamanager.js - change (mediawiki...ContentTranslation)

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

Change subject: Add ext.cx.datamanager.js
..


Add ext.cx.datamanager.js

Missed in  If5d340c979802784e42b9f62dcc603415b832202

Change-Id: If80a54501f417eaf655bef4b53350db8b35820fb
---
A modules/base/ext.cx.datamanager.js
1 file changed, 43 insertions(+), 0 deletions(-)

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



diff --git a/modules/base/ext.cx.datamanager.js 
b/modules/base/ext.cx.datamanager.js
new file mode 100644
index 000..890ad71
--- /dev/null
+++ b/modules/base/ext.cx.datamanager.js
@@ -0,0 +1,43 @@
+/**
+ * ContentTranslation extension
+ * A tool that allows editors to translate pages from one language
+ * to another with the help of machine translation and other translation aids
+ *
+ * @file
+ * @ingroup Extensions
+ * @copyright See AUTHORS.txt
+ * @license GPL-2.0+
+ */
+( function ( $, mw ) {
+   'use strict';
+
+   var socket;
+
+   /* global io */
+   function initConnection() {
+   socket = io.connect( mw.config.get( 
'wgContentTranslationServerURL' ) );
+   mw.log( '[CX] Connected to server' );
+   }
+
+   function updateModel( data) {
+   mw.log( '[CX] Recieved data from server' );
+   mw.cx.data = data;
+   mw.hook( 'mw.cx.source.ready' ).fire();
+   }
+
+   mw.cx.connect = function () {
+   if ( !socket ) {
+   initConnection();
+   }
+   socket.emit( 'cx.init', {
+   // FIXME
+   sourcePage: 'http://en.wikipedia.org/wiki/' + 
mw.cx.sourceTitle,
+   sourceLanguage: mw.cx.sourceLanguage,
+   targetLanguage: mw.cx.targetLanguage,
+   channel: 'cx'
+   } );
+   mw.log( '[CX] Sending context information to server' );
+   socket.on( 'cx.data.update', updateModel );
+   };
+
+}( jQuery, mediaWiki ) );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If80a54501f417eaf655bef4b53350db8b35820fb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: KartikMistry kartik.mis...@gmail.com
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 Redis as storage for socket.io - change (mediawiki...ContentTranslation)

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

Change subject: Use Redis as storage for socket.io
..


Use Redis as storage for socket.io

So that the instances can share the socket information

Change-Id: I28ceacb472d168140ef044ca8aad1926b24fb999
---
M server/ContentTranslationService.js
1 file changed, 13 insertions(+), 4 deletions(-)

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



diff --git a/server/ContentTranslationService.js 
b/server/ContentTranslationService.js
index 9269c41..be067bc 100644
--- a/server/ContentTranslationService.js
+++ b/server/ContentTranslationService.js
@@ -1,5 +1,5 @@
 /**
- *  ContentTranslation server
+ * ContentTranslation server
  *
  * @file
  * @copyright See AUTHORS.txt
@@ -22,8 +22,17 @@
 var app = express();
 var server = require( 'http' ).createServer( app );
 var io = require( 'socket.io' ).listen( server );
-
 var redis = require( 'redis' );
+
+// Use Redis as the store for socket.io
+var RedisStore = require( 'socket.io/lib/stores/redis' );
+io.set( 'store',
+   new RedisStore( {
+   redisPub: redis.createClient(),
+   redisSub: redis.createClient(),
+   redisClient: redis.createClient()
+   } )
+);
 
 instanceName = 'worker(' + process.pid + ')';
 // socket.io connection establishment
@@ -34,13 +43,13 @@
 
console.log( '[CX] Client connected to ' + instanceName + '). Socket: ' 
+ socket.id );
redisSub.subscribe( 'cx' );
-   redisSub.on( 'message', function( channel, message ) {
+   redisSub.on( 'message', function ( channel, message ) {
socket.emit( 'cx.data.update', JSON.parse( message ) );
console.log('[CX] Received from channel #' + channel + ':' + 
message );
} );
 
socket.on( 'cx.init', function ( data ) {
-   CXDataModelManager = require(  __dirname + 
'/models/dataModelManager.js').CXDataModelManager;
+   CXDataModelManager = require( __dirname + 
'/models/dataModelManager.js').CXDataModelManager;
context = {
sourceLanguage: data.sourceLanguage,
targetLanguage: data.targetLanguage,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I28ceacb472d168140ef044ca8aad1926b24fb999
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] More control in compoer require versions - change (mediawiki...Wikibase)

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

Change subject: More control in compoer require versions
..


More control in compoer require versions

Change-Id: I7f55412f763be2e23a97c877834a797fa507bb9d
---
M composer.json
1 file changed, 11 insertions(+), 11 deletions(-)

Approvals:
  Tobias Gritschacher: Looks good to me, approved
  WikidataJenkins: Verified
  jenkins-bot: Verified



diff --git a/composer.json b/composer.json
index 582790f..042405e 100644
--- a/composer.json
+++ b/composer.json
@@ -24,17 +24,17 @@
},
require: {
php: =5.3.2,
-   data-values/data-values: ~0.1,
-   data-values/common: ~0.1,
-   data-values/geo: ~0.1,
-   data-values/number: ~0.2,
-   data-values/time: ~0.1,
-   data-values/validators: ~0.1,
-   data-values/data-types: ~0.1,
-   data-values/serialization: ~0.1,
-   data-values/javascript: ~0.3,
-   data-values/value-view: ~0.3,=0.3.3,
-   wikibase/data-model: 0.6.*,
+   data-values/data-values: ~0.1.0,
+   data-values/common: ~0.2.0,
+   data-values/geo: ~0.1.0,
+   data-values/number: ~0.2.0,
+   data-values/time: ~0.2.0,
+   data-values/validators: ~0.1.0,
+   data-values/data-types: ~0.1.0,
+   data-values/serialization: ~0.1.0,
+   data-values/javascript: ~0.3.0,
+   data-values/value-view: ~0.3.3,
+   wikibase/data-model: ~0.6.0,
diff/diff: =0.9,
wikibase/easyrdf_lite: *
},

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7f55412f763be2e23a97c877834a797fa507bb9d
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Addshore addshorew...@gmail.com
Gerrit-Reviewer: Tobias Gritschacher tobias.gritschac...@wikimedia.de
Gerrit-Reviewer: WikidataJenkins wikidata-servi...@wikimedia.de
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Add license information - change (mediawiki...wikihiero)

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

Change subject: Add license information
..


Add license information

Change-Id: I5e44da15dadff1d47bbe92fb6eb50c448ccbf96d
---
A COPYING
M wikihiero.php
2 files changed, 340 insertions(+), 0 deletions(-)

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



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

[MediaWiki-commits] [Gerrit] Client: Subscribe for cx.data.update only once - change (mediawiki...ContentTranslation)

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

Change subject: Client: Subscribe for cx.data.update only once
..


Client: Subscribe for cx.data.update only once

Change-Id: Iab0940c9b0a880cb505c932c91bc62e332cdc17b
---
M server/public/js/main.js
1 file changed, 7 insertions(+), 7 deletions(-)

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



diff --git a/server/public/js/main.js b/server/public/js/main.js
index 08ac1a5..444b0e2 100644
--- a/server/public/js/main.js
+++ b/server/public/js/main.js
@@ -15,6 +15,13 @@
$( document ).ready( function () {
var socket = io.connect( '/', { port: 8000 } );
$( 'progress' ).hide();
+   socket.on( 'cx.data.update', function ( data ) {
+   cxdata = data;
+   $( 'progress' ).hide();
+   $( '.status' ).text( 'Recieved version '+ 
cxdata.version + '. Click on the content segments to inspect.');
+   $( '.article' ).html( cxdata.segmentedContent );
+   console.log( cxdata );
+   } );
$( 'button' ).click( function () {
$( 'progress' ).show();
$( '.status' ).text( 'Connecting to server...' );
@@ -22,13 +29,6 @@
sourcePage:  $('input[name=sourcePage').val(),
sourceLanguage: 
$('input[name=sourceLanguage').val(),
targetLanguage: 
$('input[name=targetLanguage').val()
-   } );
-   socket.on( 'cx.data.update', function ( data ) {
-   cxdata = data;
-   $( 'progress' ).hide();
-   $( '.status' ).text( 'Recieved version ' + 
cxdata.version + '. Click on the content segments to inspect.' );
-   $( '.article' ).html( cxdata.segmentedContent );
-   console.log( cxdata );
} );
} );
} );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iab0940c9b0a880cb505c932c91bc62e332cdc17b
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Setup test.wikidata as repo for test2 and test.wikipedia - change (operations/mediawiki-config)

2014-02-25 Thread Aude (Code Review)
Aude has uploaded a new change for review.

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

Change subject: Setup test.wikidata as repo for test2 and test.wikipedia
..

Setup test.wikidata as repo for test2 and test.wikipedia

test2 allows running qunit tests, which has unintended
side-effects (creating ghost items on wikidata).

making test2 the primary test client for testing page moves.

removing test2 from the wikidataclient.dblist. test2wiki has
wikibase client enabled via $wmgUseWikibaseClient = true in
InitialiseSettings.php

these changes result in test2 not getting change propagations,
which can be fixed by adding another cronjob and/or
making the ChangeNotification jobs work via jobqueue / redis.

Bug: 61893
Change-Id: I6f4c512e0b37f49e0446c9b92ce3bcf0dc33a9de
---
M wikidataclient.dblist
M wmf-config/InitialiseSettings.php
M wmf-config/Wikibase.php
3 files changed, 11 insertions(+), 7 deletions(-)


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

diff --git a/wikidataclient.dblist b/wikidataclient.dblist
index ea82660..fd9d610 100644
--- a/wikidataclient.dblist
+++ b/wikidataclient.dblist
@@ -310,7 +310,6 @@
 szlwiki
 tawiki
 tawikisource
-test2wiki
 tetwiki
 tewiki
 tewikisource
diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index 399aa75..b4f72bb 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -12762,8 +12762,7 @@
'propagateChangesToRepo' = false,
),
'test2wiki' = array(
-   'siteGlobalID' = 'enwiki',
-   'propagateChangesToRepo' = false,
+   'siteGlobalID' = 'enwiki'
),
'be_x_oldwiki' = array(
'sort' = 'alphabetic',
diff --git a/wmf-config/Wikibase.php b/wmf-config/Wikibase.php
index 7bfb862..91c08a5 100644
--- a/wmf-config/Wikibase.php
+++ b/wmf-config/Wikibase.php
@@ -88,12 +88,18 @@
require_once( 
$IP/extensions/Wikibase/client/WikibaseClient.php );
}
 
-   $wgWBClientSettings['changesDatabase'] = 'wikidatawiki';
-   $wgWBClientSettings['repoDatabase'] = 'wikidatawiki';
-
// to be safe, keeping this here although $wgDBname is default setting
$wgWBClientSettings['siteGlobalID'] = $wgDBname;
-   $wgWBClientSettings['repoUrl'] = //{$wmfHostnames['wikidata']};
+
+   if ( in_array( $wgDBname, array( 'test2wiki', 'testwiki' ) ) ) {
+   $wgWBClientSettings['changesDatabase'] = 'testwikidatawiki';
+   $wgWBClientSettings['repoDatabase'] = 'testwikidatawiki';
+   $wgWBClientSettings['repoUrl'] = //test.wikidata.org;
+   } else {
+   $wgWBClientSettings['changesDatabase'] = 'wikidatawiki';
+   $wgWBClientSettings['repoDatabase'] = 'wikidatawiki';
+   $wgWBClientSettings['repoUrl'] = 
//{$wmfHostnames['wikidata']};
+   }
 
$wgWBClientSettings['repoNamespaces'] = array(
'wikibase-item' = '',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6f4c512e0b37f49e0446c9b92ce3bcf0dc33a9de
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Aude aude.w...@gmail.com

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


[MediaWiki-commits] [Gerrit] Client: For connecting to socket, port is optional, remove it - change (mediawiki...ContentTranslation)

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

Change subject: Client: For connecting to socket, port is optional, remove it
..


Client: For connecting to socket, port is optional, remove it

Change-Id: I914a32def6de39e04c7212dfd699dfc65998a77a
---
M server/public/js/main.js
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/server/public/js/main.js b/server/public/js/main.js
index 444b0e2..5a29213 100644
--- a/server/public/js/main.js
+++ b/server/public/js/main.js
@@ -13,7 +13,7 @@
 
/* global io */
$( document ).ready( function () {
-   var socket = io.connect( '/', { port: 8000 } );
+   var socket = io.connect( '/' );
$( 'progress' ).hide();
socket.on( 'cx.data.update', function ( data ) {
cxdata = data;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I914a32def6de39e04c7212dfd699dfc65998a77a
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Remove doc about a file that doesnt exist - change (mediawiki/core)

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

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

Change subject: Remove doc about a file that doesnt exist
..

Remove doc about a file that doesnt exist

Change-Id: I1bcf0a8a9a10906b6078c3f45f864359f6d32eda
---
M languages/Language.php
1 file changed, 1 insertion(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/67/115367/1

diff --git a/languages/Language.php b/languages/Language.php
index 320688a..fcb0f09 100644
--- a/languages/Language.php
+++ b/languages/Language.php
@@ -3075,8 +3075,7 @@
 * wfMessage( 'message' )-numParams( $num )-text()
 * /code
 *
-* See LanguageGu.php for the Gujarati implementation and
-* $separatorTransformTable on MessageIs.php for
+* See $separatorTransformTable on MessageIs.php for
 * the , = . and . = , implementation.
 *
 * @todo check if it's viable to use localeconv() for the decimal

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1bcf0a8a9a10906b6078c3f45f864359f6d32eda
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Addshore addshorew...@gmail.com

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


[MediaWiki-commits] [Gerrit] Fix the usage of promise for page loader - change (mediawiki...ContentTranslation)

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

Change subject: Fix the usage of promise for page loader
..


Fix the usage of promise for page loader

As per https://github.com/kriskowal/q/wiki/Coming-from-jQuery

Change-Id: I5037141bdedf0dc6aa7fdf9782608b4162cb6c60
---
M server/models/dataModelManager.js
1 file changed, 4 insertions(+), 1 deletion(-)

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



diff --git a/server/models/dataModelManager.js 
b/server/models/dataModelManager.js
index 501af26..b79668b 100644
--- a/server/models/dataModelManager.js
+++ b/server/models/dataModelManager.js
@@ -38,7 +38,7 @@
} else {
PageLoader = require( __dirname + 
'/../pageloader/PageLoader.js').PageLoader;
pageloader = new PageLoader( 
dataModelManager.context.sourcePage );
-   pageloader.load().done( function ( data ) {
+   pageloader.load().then( function ( data ) {
dataModelManager.context.sourceText = data;
segmenter = new CXSegmenter( 
dataModelManager.context.sourceText );
segmenter.segment();
@@ -54,6 +54,9 @@
dataModelManager.publish();
// TODO: Dispatch the context to a number of 
task runners
// Once each task runners finish, publish.
+   }, function ( /*jqXHR, textStatus, errorThrown*/ ) {
+   console.error( '[CX] Error in retrieving the 
page ' +
+   dataModelManager.context.sourcePage );
} );
}
} );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I5037141bdedf0dc6aa7fdf9782608b4162cb6c60
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Remove doc about a file that doesnt exist - change (mediawiki/core)

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

Change subject: Remove doc about a file that doesnt exist
..


Remove doc about a file that doesnt exist

Change-Id: I1bcf0a8a9a10906b6078c3f45f864359f6d32eda
---
M languages/Language.php
1 file changed, 1 insertion(+), 2 deletions(-)

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



diff --git a/languages/Language.php b/languages/Language.php
index 320688a..fcb0f09 100644
--- a/languages/Language.php
+++ b/languages/Language.php
@@ -3075,8 +3075,7 @@
 * wfMessage( 'message' )-numParams( $num )-text()
 * /code
 *
-* See LanguageGu.php for the Gujarati implementation and
-* $separatorTransformTable on MessageIs.php for
+* See $separatorTransformTable on MessageIs.php for
 * the , = . and . = , implementation.
 *
 * @todo check if it's viable to use localeconv() for the decimal

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1bcf0a8a9a10906b6078c3f45f864359f6d32eda
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Addshore addshorew...@gmail.com
Gerrit-Reviewer: Aude aude.w...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Experiment to illustrate the opening animation - change (mediawiki...MultimediaViewer)

2014-02-25 Thread Pginer (Code Review)
Pginer has uploaded a new change for review.

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

Change subject: Experiment to illustrate the opening animation
..

Experiment to illustrate the opening animation

This is just an experiment to illustrate the how to make a more subtle
version of the panel animation. Do not merge this code without serious
refactoring first.

Change-Id: Id6705b63b26d8be341e77352924cad6ac4b73da1
---
M resources/mmv/mmv.js
M resources/mmv/mmv.less
2 files changed, 43 insertions(+), 2 deletions(-)


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

diff --git a/resources/mmv/mmv.js b/resources/mmv/mmv.js
index 3878625..24ed212 100755
--- a/resources/mmv/mmv.js
+++ b/resources/mmv/mmv.js
@@ -416,9 +416,11 @@
MMVP.animateMetadataDivOnce = function () {
if ( !this.hasAnimatedMetadata ) {
this.hasAnimatedMetadata = true;
-   $.scrollTo( 20, 300 )
-   .scrollTo( 0, 300 );
+   $(.mlb-post-image).addClass(invite);
+   /*$.scrollTo( 10, 400 )
+   .scrollTo( 0, 400 );*/
}
+   $(.mlb-post-image).css(opacity,1);
return $.scrollTo.window().promise();
};
 
diff --git a/resources/mmv/mmv.less b/resources/mmv/mmv.less
index 173565c..6dbd833 100644
--- a/resources/mmv/mmv.less
+++ b/resources/mmv/mmv.less
@@ -81,8 +81,47 @@
background-color: @metadata-background;
position: absolute;
min-height: (@bottom-height + 1);
+   opacity:0;
+   .invite {
+   -webkit-animation-name: invite-animation;
+   -webkit-animation-duration: 0.5s;
+   animation-name: invite-animation;
+   animation-duration: 0.5s;
+   }
 }
 
+@-webkit-keyframes invite-animation {
+   0% {
+   opacity:0.6;
+   margin-top: 5px;
+   }
+   50% {
+   opacity: 0.9;
+   margin-top: -3px;
+   }
+   100% {
+   opacity:1;
+   margin-top: 0;
+   }
+}
+
+@keyframes invite-animation {
+   0% {
+   opacity:0.6;
+   margin-top: 5px;
+   }
+   50% {
+   opacity: 0.9;
+   margin-top: -3px;
+   }
+   100% {
+   opacity:1;
+   margin-top: 0;
+   }
+}
+
+
+
 .mlb-controls {
height: auto;
border-bottom: 1px solid #cc;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id6705b63b26d8be341e77352924cad6ac4b73da1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: master
Gerrit-Owner: Pginer pgi...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Add missing jquery module - change (mediawiki...ContentTranslation)

2014-02-25 Thread KartikMistry (Code Review)
KartikMistry has uploaded a new change for review.

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

Change subject: Add missing jquery module
..

Add missing jquery module

 * Add jquery node module to package.json
 * Sorted alphabetically

Change-Id: I4e8c0e7d597e31532b9a30490a12ed685999b6a8
---
M server/package.json
1 file changed, 3 insertions(+), 2 deletions(-)


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

diff --git a/server/package.json b/server/package.json
index 856fe19..b3d325d 100644
--- a/server/package.json
+++ b/server/package.json
@@ -4,10 +4,11 @@
version: 0.1.0,
dependencies: {
express: 3.x,
-   socket.io: 0.9.x,
+   jquery: *,
q: *,
redis: 0.10,
-   request: *
+   request: *,
+   socket.io: 0.9.x
},
devDependencies: {
colors: ~0.6.2,

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4e8c0e7d597e31532b9a30490a12ed685999b6a8
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: KartikMistry kartik.mis...@gmail.com

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


[MediaWiki-commits] [Gerrit] Correct the selectors in server playground javascript - change (mediawiki...ContentTranslation)

2014-02-25 Thread Santhosh (Code Review)
Santhosh has uploaded a new change for review.

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

Change subject: Correct the selectors in server playground javascript
..

Correct the selectors in server playground javascript

Chrome is happy with wrong selector. FF complains.

Change-Id: Idcbdbd93973a9f934a0a63a7bc5666ac9c5e24a4
---
M server/public/js/main.js
1 file changed, 3 insertions(+), 3 deletions(-)


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

diff --git a/server/public/js/main.js b/server/public/js/main.js
index 5a29213..0197f65 100644
--- a/server/public/js/main.js
+++ b/server/public/js/main.js
@@ -26,9 +26,9 @@
$( 'progress' ).show();
$( '.status' ).text( 'Connecting to server...' );
socket.emit( 'cx.init', {
-   sourcePage:  $('input[name=sourcePage').val(),
-   sourceLanguage: 
$('input[name=sourceLanguage').val(),
-   targetLanguage: 
$('input[name=targetLanguage').val()
+   sourcePage:  $( 'input[name=sourcePage]' 
).val(),
+   sourceLanguage: $( 'input[name=sourceLanguage]' 
).val(),
+   targetLanguage: $( 'input[name=targetLanguage]' 
).val()
} );
} );
} );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idcbdbd93973a9f934a0a63a7bc5666ac9c5e24a4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com

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


[MediaWiki-commits] [Gerrit] Correct the selectors in server playground javascript - change (mediawiki...ContentTranslation)

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

Change subject: Correct the selectors in server playground javascript
..


Correct the selectors in server playground javascript

Chrome is happy with wrong selector. FF complains.

Change-Id: Idcbdbd93973a9f934a0a63a7bc5666ac9c5e24a4
---
M server/public/js/main.js
1 file changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/server/public/js/main.js b/server/public/js/main.js
index 5a29213..0197f65 100644
--- a/server/public/js/main.js
+++ b/server/public/js/main.js
@@ -26,9 +26,9 @@
$( 'progress' ).show();
$( '.status' ).text( 'Connecting to server...' );
socket.emit( 'cx.init', {
-   sourcePage:  $('input[name=sourcePage').val(),
-   sourceLanguage: 
$('input[name=sourceLanguage').val(),
-   targetLanguage: 
$('input[name=targetLanguage').val()
+   sourcePage:  $( 'input[name=sourcePage]' 
).val(),
+   sourceLanguage: $( 'input[name=sourceLanguage]' 
).val(),
+   targetLanguage: $( 'input[name=targetLanguage]' 
).val()
} );
} );
} );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Idcbdbd93973a9f934a0a63a7bc5666ac9c5e24a4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Add missing jquery module - change (mediawiki...ContentTranslation)

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

Change subject: Add missing jquery module
..


Add missing jquery module

* Add jquery node module to package.json
* Sorted alphabetically

Change-Id: I4e8c0e7d597e31532b9a30490a12ed685999b6a8
---
M server/package.json
1 file changed, 3 insertions(+), 2 deletions(-)

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



diff --git a/server/package.json b/server/package.json
index 856fe19..b3d325d 100644
--- a/server/package.json
+++ b/server/package.json
@@ -4,10 +4,11 @@
version: 0.1.0,
dependencies: {
express: 3.x,
-   socket.io: 0.9.x,
+   jquery: *,
q: *,
redis: 0.10,
-   request: *
+   request: *,
+   socket.io: 0.9.x
},
devDependencies: {
colors: ~0.6.2,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I4e8c0e7d597e31532b9a30490a12ed685999b6a8
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: KartikMistry kartik.mis...@gmail.com
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: Santhosh santhosh.thottin...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Remove dependence upon $wgPasswordSenderName - change (mediawiki...Echo)

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

Change subject: Remove dependence upon $wgPasswordSenderName
..


Remove dependence upon $wgPasswordSenderName

Fallback to 'emailsender' message if not set

Change-Id: Id136692b80b7582a515501672259394e8db74112
Follows-Up: Id20e4ec1cdae94fadb278146cd72d5a9b247dccf
---
M Echo.php
M Hooks.php
2 files changed, 9 insertions(+), 2 deletions(-)

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



diff --git a/Echo.php b/Echo.php
index 721c84a..910aaed 100644
--- a/Echo.php
+++ b/Echo.php
@@ -273,7 +273,8 @@
 // Should be defined in LocalSettings.php
 $wgNotificationSender = $wgPasswordSender;
 // Name for from on email notifications. Should be defined in 
LocalSettings.php
-$wgNotificationSenderName = $wgPasswordSenderName;
+// if null, uses 'emailsender' message
+$wgNotificationSenderName = null;
 // Name for reply to on email notifications. Should be defined in 
LocalSettings.php
 $wgNotificationReplyName = 'No Reply';
 
diff --git a/Hooks.php b/Hooks.php
index 6ef847e..689bf74 100644
--- a/Hooks.php
+++ b/Hooks.php
@@ -14,7 +14,8 @@
 */
public static function initEchoExtension() {
global $wgEchoBackend, $wgEchoBackendName, $wgEchoNotifications,
-   $wgEchoNotificationCategories, 
$wgEchoNotificationIcons, $wgEchoConfig;
+   $wgEchoNotificationCategories, 
$wgEchoNotificationIcons, $wgEchoConfig,
+   $wgNotificationSenderName;
 
// allow extensions to define their own event
wfRunHooks( 'BeforeCreateEchoEvent', array( 
$wgEchoNotifications, $wgEchoNotificationCategories, 
$wgEchoNotificationIcons ) );
@@ -29,6 +30,11 @@
}
}
}
+
+   if ( $wgNotificationSenderName === null ) {
+   $wgNotificationSenderName = wfMessage( 'emailsender' 
)-inContentLanguage()-text();
+   }
+
}
 
/**

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id136692b80b7582a515501672259394e8db74112
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Echo
Gerrit-Branch: master
Gerrit-Owner: Legoktm legoktm.wikipe...@gmail.com
Gerrit-Reviewer: Bartosz Dziewoński matma@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Namespacing MMV properly - change (mediawiki...MultimediaViewer)

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

Change subject: Namespacing MMV properly
..


Namespacing MMV properly

Everything is under mw.mmv now.
(Also, I cut down on the number of direct global instance references a bit.)

Change-Id: I88bb3b62b82ce54126dd069b0aab4412d9404719
---
M MultimediaViewer.php
M resources/mmv/mmv.bootstrap.js
M resources/mmv/mmv.js
M resources/mmv/mmv.lightboximage.js
M resources/mmv/mmv.lightboxinterface.js
M resources/mmv/mmv.multilightbox.js
M resources/mmv/ui/mmv.ui.metadataPanel.js
M tests/qunit/mmv/mmv.bootstrap.test.js
M tests/qunit/mmv/mmv.lightboximage.test.js
M tests/qunit/mmv/mmv.lightboxinterface.test.js
M tests/qunit/mmv/mmv.multilightbox.test.js
M tests/qunit/mmv/mmv.test.js
M tests/qunit/mmv/mmv.testhelpers.js
13 files changed, 119 insertions(+), 107 deletions(-)

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



diff --git a/MultimediaViewer.php b/MultimediaViewer.php
index 1319a59..0f8b7aa 100644
--- a/MultimediaViewer.php
+++ b/MultimediaViewer.php
@@ -39,13 +39,16 @@
return array(
'localBasePath' = __DIR__ . /resources/$path,
'remoteExtPath' = MultimediaViewer/resources/$path,
-
);
};
 
$wgResourceModules['mmv.lightboximage'] = array_merge( array(
'scripts' = array(
'mmv.lightboximage.js',
+   ),
+
+   'dependencies' = array(
+   'mmv.base',
),
), $moduleInfo( 'mmv' ) );
 
@@ -55,6 +58,7 @@
),
 
'dependencies' = array(
+   'mmv.base',
'mmv.ui.buttons',
'mmv.ui.categories',
'mmv.ui.description',
@@ -99,6 +103,7 @@
),
 
'dependencies' = array(
+   'mmv.base',
'mmv.lightboxinterface',
),
), $moduleInfo( 'mmv' ) );
@@ -405,6 +410,7 @@
),
 
'dependencies' = array(
+   'mmv.base',
'jquery.scrollTo',
'mmv.lightboximage',
'jquery.fullscreen',
diff --git a/resources/mmv/mmv.bootstrap.js b/resources/mmv/mmv.bootstrap.js
index bc45b10..dfe7a8d 100755
--- a/resources/mmv/mmv.bootstrap.js
+++ b/resources/mmv/mmv.bootstrap.js
@@ -70,10 +70,10 @@
deferred.reject( error.message );
} );
 
-   return $.when( deferred ).then( function () {
+   return deferred.done( function ( viewer ) {
if ( !bs.viewerInitialized ) {
if ( bs.thumbs.length ) {
-   mw.mediaViewer.initWithThumbs( 
bs.thumbs );
+   viewer.initWithThumbs( bs.thumbs );
}
 
bs.viewerInitialized = true;
@@ -84,7 +84,7 @@
/**
 * Checks if the mmv CSS has been correctly added to the page
 * This is a workaround for core bug 61852
-* @param {jQuery.Promise} deferred
+* @param {jQuery.Promise.mw.mmv.MultimediaViewer} deferred
 */
MMVB.isCSSReady = function ( deferred ) {
var $dummy = $( 'div class=' + this.readinessCSSClass + '' )
@@ -94,7 +94,7 @@
if ( $dummy.css( 'display' ) === 'inline' ) {
// Let's be clean and remove the test item before 
resolving the deferred
$dummy.remove();
-   deferred.resolve();
+   deferred.resolve( mw.mmv.mediaViewer );
} else {
$dummy.remove();
setTimeout( function () { bs.isCSSReady( deferred ); }, 
this.readinessWaitDuration );
@@ -179,8 +179,8 @@
mw.mmv.logger.log( 'enlarge-link-click' );
}
 
-   this.loadViewer().then( function () {
-   mw.mediaViewer.loadImageByTitle( 
title.getPrefixedText(), true );
+   this.loadViewer().then( function ( viewer ) {
+   viewer.loadImageByTitle( title.getPrefixedText(), true 
);
} );
 
e.preventDefault();
@@ -203,8 +203,8 @@
return;
}
 
-   this.loadViewer().then( function () {
-   mw.mediaViewer.hash();
+   this.loadViewer().then( function ( viewer ) {
+   viewer.hash();
} );
};
 
diff --git a/resources/mmv/mmv.js b/resources/mmv/mmv.js
index 880a2a8..5dc9cff 100755
--- a/resources/mmv/mmv.js
+++ b/resources/mmv/mmv.js
@@ -22,13 +22,13 @@
/**
 * 

[MediaWiki-commits] [Gerrit] Fix ForeignDBViaLBRepo favicon - change (mediawiki/core)

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

Change subject: Fix ForeignDBViaLBRepo favicon
..


Fix ForeignDBViaLBRepo favicon

Due to the weird inheritance structure of the FileRepo tree,
ForeignDBViaLBRepo inherited the wrong getInfo behavior and
returned the favicon of the local wiki.

Change-Id: I4892247c0e4a2e05c9148efe089f0ff52459bbd0
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/253
---
M includes/filerepo/ForeignDBViaLBRepo.php
1 file changed, 4 insertions(+), 0 deletions(-)

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



diff --git a/includes/filerepo/ForeignDBViaLBRepo.php 
b/includes/filerepo/ForeignDBViaLBRepo.php
index 18f8d5d..8153ffb 100644
--- a/includes/filerepo/ForeignDBViaLBRepo.php
+++ b/includes/filerepo/ForeignDBViaLBRepo.php
@@ -90,4 +90,8 @@
protected function assertWritableRepo() {
throw new MWException( get_class( $this ) . ': write operations 
are not supported.' );
}
+
+   public function getInfo() {
+   return FileRepo::getInfo();
+   }
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I4892247c0e4a2e05c9148efe089f0ff52459bbd0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza gti...@wikimedia.org
Gerrit-Reviewer: Aarcos aarcos.w...@gmail.com
Gerrit-Reviewer: Gilles gdu...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Flow: use the default link and redlink colors for usernames ... - change (mediawiki...Flow)

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

Change subject: Flow: use the default link and redlink colors for usernames 
above posts
..


Flow: use the default link and redlink colors for usernames above posts

Bug: 61890
Change-Id: I5fdf7543a48e478ee36e4b1cc774d6f70d80306b
---
M modules/base/styles/various.less
M modules/discussion/styles/post.less
M modules/discussion/styles/settings/colors.less
3 files changed, 4 insertions(+), 24 deletions(-)

Approvals:
  Bartosz Dziewoński: Looks good to me, approved
  Matthias Mullie: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/modules/base/styles/various.less b/modules/base/styles/various.less
index aeab8af..ea8522d 100644
--- a/modules/base/styles/various.less
+++ b/modules/base/styles/various.less
@@ -76,25 +76,9 @@
opacity: 0.6;
 }
 
-// Overwrite user link color
-.flow-container {
-   a {
-   .mw-userlink {
-   color: @username-color;
-   .new {
-   color: @username-redlink-color;
-   }
-   }
-   }
-   .mw-usertoollinks {
-   font-weight: normal;
-   a {
-   color: @username-color;
-   .new {
-   color: @username-redlink-color;
-   }
-   }
-   }
+// additional user links should never be bolded
+.flow-container .mw-usertoollinks {
+   font-weight: normal;
 }
 
 // For some reason, when overflow:(auto|scroll) is applied to the element where
diff --git a/modules/discussion/styles/post.less 
b/modules/discussion/styles/post.less
index 8995613..165c7d9 100644
--- a/modules/discussion/styles/post.less
+++ b/modules/discussion/styles/post.less
@@ -62,7 +62,7 @@
 
.flow-post-own {
.flow-creator  a {
-   // @username-color at 20% transparency
+   // username color at 20% transparency
background-color: rgba(60, 104, 177, 0.2);
}
}
diff --git a/modules/discussion/styles/settings/colors.less 
b/modules/discussion/styles/settings/colors.less
index 40dfef1..0b6f843 100644
--- a/modules/discussion/styles/settings/colors.less
+++ b/modules/discussion/styles/settings/colors.less
@@ -4,7 +4,3 @@
 
 @post-title-color: #3c68b1;
 @post-content-color: #333;
-
-@username-color: #3C68B1;
-// Normal redlink colour
-@username-redlink-color: #a55858;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I5fdf7543a48e478ee36e4b1cc774d6f70d80306b
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: MZMcBride w...@mzmcbride.com
Gerrit-Reviewer: Bartosz Dziewoński matma@gmail.com
Gerrit-Reviewer: Matthias Mullie mmul...@wikimedia.org
Gerrit-Reviewer: Spage sp...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Whitespace cleanups + misc - change (mediawiki...ContentTranslation)

2014-02-25 Thread Nikerabbit (Code Review)
Nikerabbit has uploaded a new change for review.

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

Change subject: Whitespace cleanups + misc
..

Whitespace cleanups + misc

Change-Id: I8fc39814abb95a4213aaf7bb89dd156908439c7d
---
M server/ContentTranslationService.js
M server/models/dataModelManager.js
M server/pageloader/PageLoader.js
M server/public/js/main.js
M server/segmentation/paragraphSegmenter.js
M server/segmentation/sentenceSegmenter.js
M server/server.js
7 files changed, 12 insertions(+), 13 deletions(-)


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

diff --git a/server/ContentTranslationService.js 
b/server/ContentTranslationService.js
index be067bc..2e7361d 100644
--- a/server/ContentTranslationService.js
+++ b/server/ContentTranslationService.js
@@ -37,7 +37,7 @@
 instanceName = 'worker(' + process.pid + ')';
 // socket.io connection establishment
 io.sockets.on( 'connection', function ( socket ) {
-   var datamodelManager,
+   var dataModelManager,
CXDataModelManager,
redisSub = redis.createClient();
 
@@ -45,11 +45,11 @@
redisSub.subscribe( 'cx' );
redisSub.on( 'message', function ( channel, message ) {
socket.emit( 'cx.data.update', JSON.parse( message ) );
-   console.log('[CX] Received from channel #' + channel + ':' + 
message );
+   console.log( '[CX] Received from channel #' + channel + ':' + 
message );
} );
 
socket.on( 'cx.init', function ( data ) {
-   CXDataModelManager = require( __dirname + 
'/models/dataModelManager.js').CXDataModelManager;
+   CXDataModelManager = require( __dirname + 
'/models/dataModelManager.js' ).CXDataModelManager;
context = {
sourceLanguage: data.sourceLanguage,
targetLanguage: data.targetLanguage,
@@ -60,7 +60,7 @@
// Inject the session context to dataModelManager
// It should take care of managing the data model and pushing
// it to the client through socket.
-   datamodelManager = new CXDataModelManager( context );
+   dataModelManager = new CXDataModelManager( context );
} );
 
socket.on( 'disconnect', function () {
@@ -71,7 +71,7 @@
 } );
 
 // Everything else goes through this.
-app.use( express.static( __dirname + '/public') );
+app.use( express.static( __dirname + '/public' ) );
 console.log( '[CX] ' + instanceName + ' ready. Listening on port: ' + port );
 server.listen( port );
 
diff --git a/server/models/dataModelManager.js 
b/server/models/dataModelManager.js
index b79668b..44e5503 100644
--- a/server/models/dataModelManager.js
+++ b/server/models/dataModelManager.js
@@ -36,7 +36,7 @@
// data model present in redis store
dataModelManager.publish();
} else {
-   PageLoader = require( __dirname + 
'/../pageloader/PageLoader.js').PageLoader;
+   PageLoader = require( __dirname + 
'/../pageloader/PageLoader.js' ).PageLoader;
pageloader = new PageLoader( 
dataModelManager.context.sourcePage );
pageloader.load().then( function ( data ) {
dataModelManager.context.sourceText = data;
diff --git a/server/pageloader/PageLoader.js b/server/pageloader/PageLoader.js
index fe53526..1803e41 100644
--- a/server/pageloader/PageLoader.js
+++ b/server/pageloader/PageLoader.js
@@ -40,7 +40,7 @@
title = this.page.split( '/' ).pop();
if ( config.pageloaderservice === 'parsoid' ) {
ParsoidPageLoader = require( __dirname + 
'/ParsoidPageLoader.js' ).ParsoidPageLoader;
-   loader = new ParsoidPageLoader( config.parsoid.api, 'enwiki' ); 
//FIXME
+   loader = new ParsoidPageLoader( config.parsoid.api, 'enwiki' ); 
// FIXME
promise = loader.load( title );
}
if ( config.pageloaderservice === 'mediawiki' ) {
diff --git a/server/public/js/main.js b/server/public/js/main.js
index 0197f65..9c25b74 100644
--- a/server/public/js/main.js
+++ b/server/public/js/main.js
@@ -1,5 +1,6 @@
 ( function ( $ ) {
'use strict';
+
var cxdata;
$( '.article' ).on( 'click', '.cx-segment', function () {
var segment = cxdata.segments[$( this ).data( 'segment' )];
diff --git a/server/segmentation/paragraphSegmenter.js 
b/server/segmentation/paragraphSegmenter.js
index 149eb63..c24ec75 100644
--- a/server/segmentation/paragraphSegmenter.js
+++ b/server/segmentation/paragraphSegmenter.js
@@ -7,7 +7,6 @@
  * @license GPL-2.0+
  */
 
-
 'use strict';
 
 var util = require( 'util' ),
diff --git a/server/segmentation/sentenceSegmenter.js 
b/server/segmentation/sentenceSegmenter.js

[MediaWiki-commits] [Gerrit] Use Html::linkedScript - change (mediawiki...ContentTranslation)

2014-02-25 Thread Nikerabbit (Code Review)
Nikerabbit has uploaded a new change for review.

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

Change subject: Use Html::linkedScript
..

Use Html::linkedScript

Proper escaping etc.

Change-Id: Ifa9590f733f85caf91ac20fbab51325dcba9e8ea
---
M ContentTranslation.hooks.php
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/ContentTranslation.hooks.php b/ContentTranslation.hooks.php
index d86303f..d570bb5 100644
--- a/ContentTranslation.hooks.php
+++ b/ContentTranslation.hooks.php
@@ -27,7 +27,7 @@
) );
}
$out-addScript(
-   script 
src='$wgContentTranslationServerURL/socket.io/socket.io.js'/script
+   Html::linkedScript( 
$wgContentTranslationServerURL/socket.io/socket.io.js )
);
 
return true;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifa9590f733f85caf91ac20fbab51325dcba9e8ea
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Nikerabbit niklas.laxst...@gmail.com

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


[MediaWiki-commits] [Gerrit] Whitespace cleanups + misc - change (mediawiki...ContentTranslation)

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

Change subject: Whitespace cleanups + misc
..


Whitespace cleanups + misc

Change-Id: I8fc39814abb95a4213aaf7bb89dd156908439c7d
---
M server/ContentTranslationService.js
M server/models/dataModelManager.js
M server/pageloader/PageLoader.js
M server/public/js/main.js
M server/segmentation/paragraphSegmenter.js
M server/segmentation/sentenceSegmenter.js
M server/server.js
7 files changed, 16 insertions(+), 17 deletions(-)

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



diff --git a/server/ContentTranslationService.js 
b/server/ContentTranslationService.js
index be067bc..2e7361d 100644
--- a/server/ContentTranslationService.js
+++ b/server/ContentTranslationService.js
@@ -37,7 +37,7 @@
 instanceName = 'worker(' + process.pid + ')';
 // socket.io connection establishment
 io.sockets.on( 'connection', function ( socket ) {
-   var datamodelManager,
+   var dataModelManager,
CXDataModelManager,
redisSub = redis.createClient();
 
@@ -45,11 +45,11 @@
redisSub.subscribe( 'cx' );
redisSub.on( 'message', function ( channel, message ) {
socket.emit( 'cx.data.update', JSON.parse( message ) );
-   console.log('[CX] Received from channel #' + channel + ':' + 
message );
+   console.log( '[CX] Received from channel #' + channel + ':' + 
message );
} );
 
socket.on( 'cx.init', function ( data ) {
-   CXDataModelManager = require( __dirname + 
'/models/dataModelManager.js').CXDataModelManager;
+   CXDataModelManager = require( __dirname + 
'/models/dataModelManager.js' ).CXDataModelManager;
context = {
sourceLanguage: data.sourceLanguage,
targetLanguage: data.targetLanguage,
@@ -60,7 +60,7 @@
// Inject the session context to dataModelManager
// It should take care of managing the data model and pushing
// it to the client through socket.
-   datamodelManager = new CXDataModelManager( context );
+   dataModelManager = new CXDataModelManager( context );
} );
 
socket.on( 'disconnect', function () {
@@ -71,7 +71,7 @@
 } );
 
 // Everything else goes through this.
-app.use( express.static( __dirname + '/public') );
+app.use( express.static( __dirname + '/public' ) );
 console.log( '[CX] ' + instanceName + ' ready. Listening on port: ' + port );
 server.listen( port );
 
diff --git a/server/models/dataModelManager.js 
b/server/models/dataModelManager.js
index b79668b..da64a85 100644
--- a/server/models/dataModelManager.js
+++ b/server/models/dataModelManager.js
@@ -36,7 +36,7 @@
// data model present in redis store
dataModelManager.publish();
} else {
-   PageLoader = require( __dirname + 
'/../pageloader/PageLoader.js').PageLoader;
+   PageLoader = require( __dirname + 
'/../pageloader/PageLoader.js' ).PageLoader;
pageloader = new PageLoader( 
dataModelManager.context.sourcePage );
pageloader.load().then( function ( data ) {
dataModelManager.context.sourceText = data;
@@ -87,7 +87,7 @@
 };
 
 /**
- *  Get the data model
+ * Get the data model
  */
 CXDataModelManager.prototype.getDataModel = function () {
return this.dataModel;
diff --git a/server/pageloader/PageLoader.js b/server/pageloader/PageLoader.js
index fe53526..1803e41 100644
--- a/server/pageloader/PageLoader.js
+++ b/server/pageloader/PageLoader.js
@@ -40,7 +40,7 @@
title = this.page.split( '/' ).pop();
if ( config.pageloaderservice === 'parsoid' ) {
ParsoidPageLoader = require( __dirname + 
'/ParsoidPageLoader.js' ).ParsoidPageLoader;
-   loader = new ParsoidPageLoader( config.parsoid.api, 'enwiki' ); 
//FIXME
+   loader = new ParsoidPageLoader( config.parsoid.api, 'enwiki' ); 
// FIXME
promise = loader.load( title );
}
if ( config.pageloaderservice === 'mediawiki' ) {
diff --git a/server/public/js/main.js b/server/public/js/main.js
index 0197f65..9a01288 100644
--- a/server/public/js/main.js
+++ b/server/public/js/main.js
@@ -1,5 +1,6 @@
 ( function ( $ ) {
'use strict';
+
var cxdata;
$( '.article' ).on( 'click', '.cx-segment', function () {
var segment = cxdata.segments[$( this ).data( 'segment' )];
@@ -26,7 +27,7 @@
$( 'progress' ).show();
$( '.status' ).text( 'Connecting to server...' );
socket.emit( 'cx.init', {
-   sourcePage:  $( 'input[name=sourcePage]' 
).val(),
+   

[MediaWiki-commits] [Gerrit] Improved way to tick all namespaces when Select all is ticked - change (mediawiki/core)

2014-02-25 Thread 01tonythomas (Code Review)
01tonythomas has uploaded a new change for review.

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

Change subject: Improved way to tick all namespaces when Select all is ticked
..

Improved way to tick all namespaces when Select all is ticked

Follow up from Ie62b9186e98dd770de4282ea57d7248158a6e782
Co Author : Helder.Wiki

Change-Id: Iea336d40ac7d1271d4934797f74dabadea0cdafe
---
M resources/mediawiki.special/mediawiki.special.preferences.js
1 file changed, 1 insertion(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/73/115373/1

diff --git a/resources/mediawiki.special/mediawiki.special.preferences.js 
b/resources/mediawiki.special/mediawiki.special.preferences.js
index 7f1fd43..23d7837 100644
--- a/resources/mediawiki.special/mediawiki.special.preferences.js
+++ b/resources/mediawiki.special/mediawiki.special.preferences.js
@@ -262,10 +262,6 @@
$checkBoxes.prop( 'disabled', true );
}
$( '#mw-input-wpsearcheverything' ).change( function () {
-   if ( $( this ).prop( 'checked' ) ) {
-   $checkBoxes.prop( 'disabled', true );
-   } else {
-   $checkBoxes.prop( 'disabled', false );
-   }
+   $checkBoxes.prop( 'disabled', $( this ).prop( 'checked' ) );
} );
 } );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iea336d40ac7d1271d4934797f74dabadea0cdafe
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: 01tonythomas 01tonytho...@gmail.com

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


[MediaWiki-commits] [Gerrit] Namespace translation for Urdu - change (mediawiki...Scribunto)

2014-02-25 Thread Odder (Code Review)
Odder has uploaded a new change for review.

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

Change subject: Namespace translation for Urdu
..

Namespace translation for Urdu

Bug: 61905
Change-Id: Ibb25af7137d32682bf2a253694c82d6010683ddb
---
M Scribunto.namespaces.php
1 file changed, 5 insertions(+), 0 deletions(-)


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

diff --git a/Scribunto.namespaces.php b/Scribunto.namespaces.php
index 2a4bb65..2d607bb 100644
--- a/Scribunto.namespaces.php
+++ b/Scribunto.namespaces.php
@@ -291,6 +291,11 @@
829 = 'Обговорення_модуля',
 );
 
+$namespaceNames['ur'] = array(
+   828 = 'ماڈیول',
+   829 = 'تبادلۂ_خیال_ماڈیول',
+);
+
 $namespaceNames['vi'] = array(
828 = 'Mô_đun',
829 = 'Thảo_luận_Mô_đun',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ibb25af7137d32682bf2a253694c82d6010683ddb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Scribunto
Gerrit-Branch: master
Gerrit-Owner: Odder tom...@twkozlowski.net

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


[MediaWiki-commits] [Gerrit] redirect ukwikimedia to wikimedia.org.uk - change (operations/apache-config)

2014-02-25 Thread Faidon Liambotis (Code Review)
Faidon Liambotis has submitted this change and it was merged.

Change subject: redirect ukwikimedia to wikimedia.org.uk
..


redirect ukwikimedia to wikimedia.org.uk

Bug: 56938
RT: 6853
Change-Id: I0420d51deb7ccd61e62cc22297bf5814148eafc4
---
M redirects.conf
M redirects.dat
M wikimedia.conf
3 files changed, 7 insertions(+), 1 deletion(-)

Approvals:
  Faidon Liambotis: Verified; Looks good to me, approved



diff --git a/redirects.conf b/redirects.conf
index 018c313..63367a9 100644
--- a/redirects.conf
+++ b/redirects.conf
@@ -348,6 +348,7 @@
kr.wikimedia.org \
pk.wikimedia.org \
pt.wikimedia.org \
+   uk.wikimedia.org \
ve.wikimedia.org \
wikimania.wikimedia.org \
labs.wikimedia.org \
@@ -883,6 +884,9 @@
# funnelpt.wikimedia.orghttp://wikimedia.pt/
RewriteCond %{HTTP_HOST} =pt.wikimedia.org
RewriteRule . http://wikimedia.pt/ [R=301,L,NE]
+   # rewrite   uk.wikimedia.orghttps://wikimedia.org.uk/
+   RewriteCond %{HTTP_HOST} =uk.wikimedia.org
+   RewriteRule .* https://wikimedia.org.uk$0 [R=301,L,NE]
# rewrite   ve.wikimedia.orghttp://wikimedia.org.ve
RewriteCond %{HTTP_HOST} =ve.wikimedia.org
RewriteRule .* http://wikimedia.org.ve$0 [R=301,L,NE]
diff --git a/redirects.dat b/redirects.dat
index b0be8a0..1a67e7e 100644
--- a/redirects.dat
+++ b/redirects.dat
@@ -422,6 +422,8 @@
 # pt.wikimedia.org was migrated to wikimedia.pt
 funnel pt.wikimedia.orghttp://wikimedia.pt/
 
+rewriteuk.wikimedia.orghttps://wikimedia.org.uk/
+
 rewriteve.wikimedia.orghttp://wikimedia.org.ve
 
 
diff --git a/wikimedia.conf b/wikimedia.conf
index 661a5c8..2cc33c1 100644
--- a/wikimedia.conf
+++ b/wikimedia.conf
@@ -1,7 +1,7 @@
 # Chapter wikis
 VirtualHost *
 ServerName wikimedia-chapter
-ServerAlias no.wikimedia.org nl.wikimedia.org www.nl.wikimedia.org 
pl.wikimedia.org nz.wikimedia.org il.wikimedia.org rs.wikimedia.org 
pa-us.wikimedia.org uk.wikimedia.org us.wikimedia.org se.wikimedia.org 
ru.wikimedia.org ua.wikimedia.org co.wikimedia.org fi.wikimedia.org 
ve.wikimedia.org br.wikimedia.org dk.wikimedia.org tr.wikimedia.org 
noboard.chapters.wikimedia.org mk.wikimedia.org et.wikimedia.org 
nyc.wikimedia.org mx.wikimedia.org ar.wikimedia.org bd.wikimedia.org 
be.wikimedia.org
+ServerAlias no.wikimedia.org nl.wikimedia.org www.nl.wikimedia.org 
pl.wikimedia.org nz.wikimedia.org il.wikimedia.org rs.wikimedia.org 
pa-us.wikimedia.org us.wikimedia.org se.wikimedia.org ru.wikimedia.org 
ua.wikimedia.org co.wikimedia.org fi.wikimedia.org ve.wikimedia.org 
br.wikimedia.org dk.wikimedia.org tr.wikimedia.org 
noboard.chapters.wikimedia.org mk.wikimedia.org et.wikimedia.org 
nyc.wikimedia.org mx.wikimedia.org ar.wikimedia.org bd.wikimedia.org 
be.wikimedia.org
 UseCanonicalName off
 DocumentRoot /usr/local/apache/common/docroot/wikimedia.org
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I0420d51deb7ccd61e62cc22297bf5814148eafc4
Gerrit-PatchSet: 3
Gerrit-Project: operations/apache-config
Gerrit-Branch: master
Gerrit-Owner: Jeremyb jer...@tuxmachine.com
Gerrit-Reviewer: Faidon Liambotis fai...@wikimedia.org
Gerrit-Reviewer: Jeremyb jer...@tuxmachine.com
Gerrit-Reviewer: Kelson kel...@kiwix.org
Gerrit-Reviewer: Reedy re...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Revert redirect ukwikimedia to wikimedia.org.uk - change (operations/apache-config)

2014-02-25 Thread Steinsplitter (Code Review)
Steinsplitter has uploaded a new change for review.

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

Change subject: Revert redirect ukwikimedia to wikimedia.org.uk
..

Revert redirect ukwikimedia to wikimedia.org.uk

This reverts commit 97f49a76b4ffdeaaeae5dff1a7e99d4ce8cf3086.

redirect from a wikimedia url to a local chapter privat hosted page, possible 
privacy problems

Change-Id: I1bdf0c03f96d6551aec2f5a80e31f37225d160e3
---
M redirects.conf
M redirects.dat
M wikimedia.conf
3 files changed, 1 insertion(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/apache-config 
refs/changes/75/115375/1

diff --git a/redirects.conf b/redirects.conf
index 63367a9..018c313 100644
--- a/redirects.conf
+++ b/redirects.conf
@@ -348,7 +348,6 @@
kr.wikimedia.org \
pk.wikimedia.org \
pt.wikimedia.org \
-   uk.wikimedia.org \
ve.wikimedia.org \
wikimania.wikimedia.org \
labs.wikimedia.org \
@@ -884,9 +883,6 @@
# funnelpt.wikimedia.orghttp://wikimedia.pt/
RewriteCond %{HTTP_HOST} =pt.wikimedia.org
RewriteRule . http://wikimedia.pt/ [R=301,L,NE]
-   # rewrite   uk.wikimedia.orghttps://wikimedia.org.uk/
-   RewriteCond %{HTTP_HOST} =uk.wikimedia.org
-   RewriteRule .* https://wikimedia.org.uk$0 [R=301,L,NE]
# rewrite   ve.wikimedia.orghttp://wikimedia.org.ve
RewriteCond %{HTTP_HOST} =ve.wikimedia.org
RewriteRule .* http://wikimedia.org.ve$0 [R=301,L,NE]
diff --git a/redirects.dat b/redirects.dat
index 1a67e7e..b0be8a0 100644
--- a/redirects.dat
+++ b/redirects.dat
@@ -422,8 +422,6 @@
 # pt.wikimedia.org was migrated to wikimedia.pt
 funnel pt.wikimedia.orghttp://wikimedia.pt/
 
-rewriteuk.wikimedia.orghttps://wikimedia.org.uk/
-
 rewriteve.wikimedia.orghttp://wikimedia.org.ve
 
 
diff --git a/wikimedia.conf b/wikimedia.conf
index 2cc33c1..661a5c8 100644
--- a/wikimedia.conf
+++ b/wikimedia.conf
@@ -1,7 +1,7 @@
 # Chapter wikis
 VirtualHost *
 ServerName wikimedia-chapter
-ServerAlias no.wikimedia.org nl.wikimedia.org www.nl.wikimedia.org 
pl.wikimedia.org nz.wikimedia.org il.wikimedia.org rs.wikimedia.org 
pa-us.wikimedia.org us.wikimedia.org se.wikimedia.org ru.wikimedia.org 
ua.wikimedia.org co.wikimedia.org fi.wikimedia.org ve.wikimedia.org 
br.wikimedia.org dk.wikimedia.org tr.wikimedia.org 
noboard.chapters.wikimedia.org mk.wikimedia.org et.wikimedia.org 
nyc.wikimedia.org mx.wikimedia.org ar.wikimedia.org bd.wikimedia.org 
be.wikimedia.org
+ServerAlias no.wikimedia.org nl.wikimedia.org www.nl.wikimedia.org 
pl.wikimedia.org nz.wikimedia.org il.wikimedia.org rs.wikimedia.org 
pa-us.wikimedia.org uk.wikimedia.org us.wikimedia.org se.wikimedia.org 
ru.wikimedia.org ua.wikimedia.org co.wikimedia.org fi.wikimedia.org 
ve.wikimedia.org br.wikimedia.org dk.wikimedia.org tr.wikimedia.org 
noboard.chapters.wikimedia.org mk.wikimedia.org et.wikimedia.org 
nyc.wikimedia.org mx.wikimedia.org ar.wikimedia.org bd.wikimedia.org 
be.wikimedia.org
 UseCanonicalName off
 DocumentRoot /usr/local/apache/common/docroot/wikimedia.org
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1bdf0c03f96d6551aec2f5a80e31f37225d160e3
Gerrit-PatchSet: 1
Gerrit-Project: operations/apache-config
Gerrit-Branch: master
Gerrit-Owner: Steinsplitter steinsplitter-w...@live.com

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


[MediaWiki-commits] [Gerrit] Workaround for a scrolling bug in IE8 - change (mediawiki...WikiEditor)

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

Change subject: Workaround for a scrolling bug in IE8
..


Workaround for a scrolling bug in IE8

Bug: 61908
Change-Id: I69dbfa267b26916628181553b213f05add909c99
---
M modules/jquery.wikiEditor.js
1 file changed, 7 insertions(+), 0 deletions(-)

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



diff --git a/modules/jquery.wikiEditor.js b/modules/jquery.wikiEditor.js
index 8c0afcd..85030b6 100644
--- a/modules/jquery.wikiEditor.js
+++ b/modules/jquery.wikiEditor.js
@@ -481,6 +481,13 @@
};
 
/**
+* Workaround for a scrolling bug in IE8 (bug 61908)
+*/
+   if ( $.client.profile().name === 'msie' ) {
+   context.$textarea.css( 'height', context.$textarea.height() );
+   }
+
+   /**
 * Base UI Construction
 *
 * The UI is built from several containers, the outer-most being a div 
classed as wikiEditor-ui. These containers

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I69dbfa267b26916628181553b213f05add909c99
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/WikiEditor
Gerrit-Branch: master
Gerrit-Owner: Gerrit Patch Uploader gerritpatchuploa...@gmail.com
Gerrit-Reviewer: Bartosz Dziewoński matma@gmail.com
Gerrit-Reviewer: Gerrit Patch Uploader gerritpatchuploa...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] close ukwikimedia - change (operations/mediawiki-config)

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

Change subject: close ukwikimedia
..


close ukwikimedia

Bug: 56938
RT: 6853
Change-Id: Ib45270536bdf207a7edeec24082f08df3af2a60f
---
M closed.dblist
M wmf-config/InitialiseSettings.php
2 files changed, 1 insertion(+), 32 deletions(-)

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



diff --git a/closed.dblist b/closed.dblist
index e42e30d..307c53a 100644
--- a/closed.dblist
+++ b/closed.dblist
@@ -100,6 +100,7 @@
 twwiktionary
 ugwikibooks
 ugwikiquote
+ukwikimedia
 usabilitywiki
 uzwikibooks
 vewikimedia
diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index 399aa75..136f3a6 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -7519,38 +7519,6 @@
'ukwiktionary' = array(
'autoeditor' = array( 'autoreview' = true ),
),
-   'ukwikimedia' = array(
-   '*' = array(
-   'upload' = false,
-   'edit' = false,
-   'editallpages' = false,
-   'move' = false,
-   'createpage' = false,
-   ),
-   'user' = array(
-   'upload' = false,
-   'edit' = true,
-   'editallpages' = false,
-   'move' = false,
-   'createpage' = false,
-   ),
-   'sysop' = array(
-   'upload' = false,
-   'edit' = true,
-   'editallpages' = false,
-   'move' = false,
-   'importupload' = false,
-   'createpage' = false,
-   ),
-   'bureaucrat' = array(
-   'upload' = false,
-   'edit' = true,
-   'editallpages' = true,
-   'move' = true,
-   'importupload' = false,
-   'createpage' = true,
-   ),
-   ),
'urwiki' = array(
'rollbacker' = array( 'rollback' = true ), // bug 45642
),

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ib45270536bdf207a7edeec24082f08df3af2a60f
Gerrit-PatchSet: 3
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Jeremyb jer...@tuxmachine.com
Gerrit-Reviewer: Jeremyb jer...@tuxmachine.com
Gerrit-Reviewer: Kelson kel...@kiwix.org
Gerrit-Reviewer: Reedy re...@wikimedia.org
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 Html::linkedScript - change (mediawiki...ContentTranslation)

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

Change subject: Use Html::linkedScript
..


Use Html::linkedScript

Proper escaping etc.

Change-Id: Ifa9590f733f85caf91ac20fbab51325dcba9e8ea
---
M ContentTranslation.hooks.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/ContentTranslation.hooks.php b/ContentTranslation.hooks.php
index d86303f..d570bb5 100644
--- a/ContentTranslation.hooks.php
+++ b/ContentTranslation.hooks.php
@@ -27,7 +27,7 @@
) );
}
$out-addScript(
-   script 
src='$wgContentTranslationServerURL/socket.io/socket.io.js'/script
+   Html::linkedScript( 
$wgContentTranslationServerURL/socket.io/socket.io.js )
);
 
return true;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ifa9590f733f85caf91ac20fbab51325dcba9e8ea
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: Amire80 amir.ahar...@mail.huji.ac.il
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 animation mixin cleaner - change (mediawiki...Popups)

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

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

Change subject: Make animation mixin cleaner
..

Make animation mixin cleaner

Change-Id: I5103daf43112d5a412c030dd90fda67a08469885
---
M resources/ext.popups.animation.less
1 file changed, 5 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Popups 
refs/changes/76/115376/1

diff --git a/resources/ext.popups.animation.less 
b/resources/ext.popups.animation.less
index 2dd335f..f12d15c 100644
--- a/resources/ext.popups.animation.less
+++ b/resources/ext.popups.animation.less
@@ -6,12 +6,11 @@
transform: translate(@x, @y);
 }
 
-.mwe-popups-animation ( @name, @duration ) {
-   -webkit-animation: @name @duration;
-   -moz-animation: @name @duration;
-   -ms-animation: @name @duration;
-   -o-animation: @name @duration;
-   animation: @name @duration;
+.mwe-popups-animation ( ... ) {
+   -webkit-animation: @arguments;
+   -moz-animation: @arguments;
+   -o-animation: @arguments;
+   animation: @arguments;
 }
 
 @-webkit-keyframes mwe-popups-fade-in {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5103daf43112d5a412c030dd90fda67a08469885
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Popups
Gerrit-Branch: master
Gerrit-Owner: Prtksxna psax...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Improved way to tick all namespaces when Select all is ticked - change (mediawiki/core)

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

Change subject: Improved way to tick all namespaces when Select all is ticked
..


Improved way to tick all namespaces when Select all is ticked

Follow up from Ie62b9186e98dd770de4282ea57d7248158a6e782
Co Author : Helder.Wiki

Change-Id: Iea336d40ac7d1271d4934797f74dabadea0cdafe
---
M resources/mediawiki.special/mediawiki.special.preferences.js
1 file changed, 1 insertion(+), 5 deletions(-)

Approvals:
  Bartosz Dziewoński: Looks good to me, approved
  Helder.wiki: Looks good to me, but someone else must approve
  Technical 13: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/resources/mediawiki.special/mediawiki.special.preferences.js 
b/resources/mediawiki.special/mediawiki.special.preferences.js
index 7f1fd43..23d7837 100644
--- a/resources/mediawiki.special/mediawiki.special.preferences.js
+++ b/resources/mediawiki.special/mediawiki.special.preferences.js
@@ -262,10 +262,6 @@
$checkBoxes.prop( 'disabled', true );
}
$( '#mw-input-wpsearcheverything' ).change( function () {
-   if ( $( this ).prop( 'checked' ) ) {
-   $checkBoxes.prop( 'disabled', true );
-   } else {
-   $checkBoxes.prop( 'disabled', false );
-   }
+   $checkBoxes.prop( 'disabled', $( this ).prop( 'checked' ) );
} );
 } );

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iea336d40ac7d1271d4934797f74dabadea0cdafe
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: 01tonythomas 01tonytho...@gmail.com
Gerrit-Reviewer: Bartosz Dziewoński matma@gmail.com
Gerrit-Reviewer: Brian Wolff bawolff...@gmail.com
Gerrit-Reviewer: Helder.wiki helder.w...@gmail.com
Gerrit-Reviewer: MarkTraceur mtrac...@member.fsf.org
Gerrit-Reviewer: Technical 13 technical...@yahoo.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] mediawiki.less: Use less mixin to reduce code repetition in ... - change (mediawiki/core)

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

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

Change subject: mediawiki.less: Use less mixin to reduce code repetition in 
animation
..

mediawiki.less: Use less mixin to reduce code repetition in animation

Adds an `animation` and `transform-rotate` mixin to help with the animation.
Also creates a mixin for the keyframes and uses them for webkit, moz and
opera specific declerations.

Change-Id: I167dc5e5a2f43f64c5029864e76d42fcc82af622
---
M resources/mediawiki.less/mediawiki.mixins.less
M resources/mediawiki.less/mediawiki.mixins.rotation.less
2 files changed, 32 insertions(+), 18 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/77/115377/1

diff --git a/resources/mediawiki.less/mediawiki.mixins.less 
b/resources/mediawiki.less/mediawiki.mixins.less
index 80b68cc..86a7750 100644
--- a/resources/mediawiki.less/mediawiki.mixins.less
+++ b/resources/mediawiki.less/mediawiki.mixins.less
@@ -51,3 +51,17 @@
-webkit-transition: @string;
transition: @string;
 }
+
+/* Being used by the rotation animation */
+.animation (...) {
+   -webkit-animation: @arguments;
+   -moz-animation: @arguments;
+   -o-animation: @arguments;
+   animation: @arguments;
+}
+
+.transform-rotate (@deg) {
+   -webkit-transform: rotate(@deg);
+   -moz-transform: rotate(@deg);
+   transform: rotate(@deg);
+}
diff --git a/resources/mediawiki.less/mediawiki.mixins.rotation.less 
b/resources/mediawiki.less/mediawiki.mixins.rotation.less
index 82de5de..70f278b 100644
--- a/resources/mediawiki.less/mediawiki.mixins.rotation.less
+++ b/resources/mediawiki.less/mediawiki.mixins.rotation.less
@@ -1,31 +1,31 @@
 // This is a separate file because importing the mixin causes
 // the keyframes blocks to be included in the output, regardless
 // of whether .rotation is used.
-@-webkit-keyframes rotate {
+.rotate-frames () {
from {
-   -webkit-transform:rotate(0deg);
+   .transform-rotate(0deg);
}
to {
-   -webkit-transform:rotate(360deg);
+   .transform-rotate(360deg);
}
+}
+
+@-webkit-keyframes rotate {
+   .rotate-frames;
+}
+
+@-moz-keyframes rotate {
+   .rotate-frames;
+}
+
+@-o-keyframes rotate {
+   .rotate-frames;
 }
 
 @keyframes rotate {
-   from {
-   transform: rotate(0deg);
-   }
-   to {
-   transform: rotate(360deg);
-   }
+   .rotate-frames;
 }
 
-.rotation(@time) {
-   -webkit-animation-name: rotate;
-   -webkit-animation-duration: @time;
-   -webkit-animation-iteration-count: infinite;
-   -webkit-animation-timing-function: linear;
-   animation-name: rotate;
-   animation-duration: @time;
-   animation-iteration-count: infinite;
-   animation-timing-function: linear;
+.rotation( @time ) {
+   .animation(rotate, @time, infinite, linear);
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I167dc5e5a2f43f64c5029864e76d42fcc82af622
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Prtksxna psax...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Workaround for a scrolling bug in IE8 on resize - change (mediawiki...WikiEditor)

2014-02-25 Thread Gerrit Patch Uploader (Code Review)
Gerrit Patch Uploader has uploaded a new change for review.

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

Change subject: Workaround for a scrolling bug in IE8 on resize
..

Workaround for a scrolling bug in IE8 on resize

Bug: 61910
Change-Id: I6dacc1ed2f2fdf4ea615a477b711dc78667bae68
---
M modules/jquery.wikiEditor.js
1 file changed, 6 insertions(+), 0 deletions(-)


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

diff --git a/modules/jquery.wikiEditor.js b/modules/jquery.wikiEditor.js
index 85030b6..4c04366 100644
--- a/modules/jquery.wikiEditor.js
+++ b/modules/jquery.wikiEditor.js
@@ -327,6 +327,11 @@
 * Executes core event filters as well as event handlers 
provided by modules.
 */
trigger: function ( name, event ) {
+   // Workaround for a scrolling bug in IE8 (bug 61908)
+   if ( $.client.profile().name === 'msie' ) {
+   context.$textarea.css( 'width', 
context.$textarea.parent().width() );
+   }
+
// Event is an optional argument, but from here on out, 
at least the type field should be dependable
if ( typeof event === 'undefined' ) {
event = { 'type': 'custom' };
@@ -485,6 +490,7 @@
 */
if ( $.client.profile().name === 'msie' ) {
context.$textarea.css( 'height', context.$textarea.height() );
+   context.$textarea.css( 'width', 
context.$textarea.parent().width() );
}
 
/**

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6dacc1ed2f2fdf4ea615a477b711dc78667bae68
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikiEditor
Gerrit-Branch: master
Gerrit-Owner: Gerrit Patch Uploader gerritpatchuploa...@gmail.com
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Reduce Wikidata author vcard to creator part - change (mediawiki...CommonsMetadata)

2014-02-25 Thread Gilles (Code Review)
Gilles has uploaded a new change for review.

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

Change subject: Reduce Wikidata author vcard to creator part
..

Reduce Wikidata author vcard to creator part

Wikidata templates dump a vcard with too much data
in the artist field. When that format is found, TemplateParser
reduces it to meaningful information.

Change-Id: Id646261cf7b7516512a722af44f7f53da1e52005
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/202
---
M TemplateParser.php
M tests/phpunit/TemplateParserTest.php
2 files changed, 22 insertions(+), 4 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CommonsMetadata 
refs/changes/79/115379/1

diff --git a/TemplateParser.php b/TemplateParser.php
index c987c0d..36df00f 100755
--- a/TemplateParser.php
+++ b/TemplateParser.php
@@ -154,13 +154,31 @@
$table = $domNavigator-closest( $labelField, 'table' );
$groupName = $table ? $table-getNodePath() : '-';
 
-   $data[$groupName][$fieldName] = $this-parseText( 
$domNavigator, $informationField );
+   $method = 'parse' . $fieldName;
+
+   if ( !method_exists( $this, $method ) ) {
+   $method = 'parseText';
+   }
+
+   $data[$groupName][$fieldName] = $this-{$method}( 
$domNavigator, $informationField );
}
//return $this-arrayTranspose( $data );
// FIXME bug 57259 - for now select the first information 
template if there are more than one
return $data ? reset($data) : array();
}
 
+   protected function parseArtist( DomNavigator $domNavigator, DOMNode 
$node ) {
+   foreach ( $domNavigator-findElementsWithId( 'span', 'creator', 
$node ) as $creator ) {
+   foreach ( $domNavigator-findElementsWithClass( 'a', 
'extiw', $creator) as $creatorLink )  {
+   return $this-toHtml( $creatorLink );
+   }
+
+   return $creator-textContent;
+   }
+
+   return $this-parseText( $domNavigator, $node );
+   }
+
protected function parseLicenses( DomNavigator $domNavigator ) {
$data = array();
foreach ( $domNavigator-findElementsWithClass( '*', 
'licensetpl' ) as $licenseNode ) {
diff --git a/tests/phpunit/TemplateParserTest.php 
b/tests/phpunit/TemplateParserTest.php
index 8283fa7..c3096a8 100644
--- a/tests/phpunit/TemplateParserTest.php
+++ b/tests/phpunit/TemplateParserTest.php
@@ -214,10 +214,10 @@
 * The template markup should not be present in the metadata.
 */
public function testHCard() {
-   $this-markTestSkipped( 'bug 57383' );
-
$data = $this-parseTestHTML( 'creator_template' );
-   $this-assertFieldEquals( 'Artist', 'George Gower', $data );
+   $this-assertFieldEquals( 'Artist',
+   'a href=//en.wikipedia.org/wiki/George_Gower 
class=extiw title=en:George GowerGeorge Gower/a',
+   $data );
}
 
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id646261cf7b7516512a722af44f7f53da1e52005
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/CommonsMetadata
Gerrit-Branch: master
Gerrit-Owner: Gilles gdu...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Disable headings test while Bug 61856 is under investigation - change (mediawiki...VisualEditor)

2014-02-25 Thread Cmcmahon (Code Review)
Cmcmahon has uploaded a new change for review.

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

Change subject: Disable headings test while Bug 61856 is under investigation
..

Disable headings test while Bug 61856 is under investigation

This is an expensive test and I'd rather not run it than
have it always failing.

Change-Id: I8ee30bf3e6eb0841f51a4ab02610dd2b3ce8349e
---
M modules/ve-mw/test/browser/features/headings.feature
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/modules/ve-mw/test/browser/features/headings.feature 
b/modules/ve-mw/test/browser/features/headings.feature
index 4bbded0..8d3a4af 100644
--- a/modules/ve-mw/test/browser/features/headings.feature
+++ b/modules/ve-mw/test/browser/features/headings.feature
@@ -1,4 +1,4 @@
-@ie6-bug  @ie7-bug  @ie8-bug  @ie9-bug @ie10-bug 
@en.wikipedia.beta.wmflabs.org @test2.wikipedia.org @login
+@ie6-bug  @ie7-bug  @ie8-bug  @ie9-bug @ie10-bug @login
 Feature: VisualEditor Headings
 
   @edit_user_page

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8ee30bf3e6eb0841f51a4ab02610dd2b3ce8349e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Cmcmahon cmcma...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Remove STRAIGHT_JOIN from ApiQueryLogEvents - change (mediawiki/core)

2014-02-25 Thread Anomie (Code Review)
Anomie has uploaded a new change for review.

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

Change subject: Remove STRAIGHT_JOIN from ApiQueryLogEvents
..

Remove STRAIGHT_JOIN from ApiQueryLogEvents

Per Sean Pringle:
 In all cases the STRAIGHT_JOIN forces an index scan on logging.times
 index, or more rarely a range access on logging.type_time index. Both
 query plans hit tens of millions of rows and take many minutes.

 Removing the STRAIGHT_JOIN allows the MariaDB query optimizer to
 choose a plan that takes seconds. Often it includes a filesort step,
 but more importantly it allows index condition pushdown which makes
 the filesort cheap.

Bug: 61889
Change-Id: Iad3905f29a2bdee1e3ebbfb2e1909b330faa8e81
---
M includes/api/ApiQueryLogEvents.php
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/81/115381/1

diff --git a/includes/api/ApiQueryLogEvents.php 
b/includes/api/ApiQueryLogEvents.php
index 1578775..848c6ce 100644
--- a/includes/api/ApiQueryLogEvents.php
+++ b/includes/api/ApiQueryLogEvents.php
@@ -65,7 +65,6 @@
 
// Order is significant here
$this-addTables( array( 'logging', 'user', 'page' ) );
-   $this-addOption( 'STRAIGHT_JOIN' );
$this-addJoinConds( array(
'user' = array( 'LEFT JOIN',
'user_id=log_user' ),

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iad3905f29a2bdee1e3ebbfb2e1909b330faa8e81
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Anomie bjor...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] bugfix; '\number' from e.g. date cause 'sre_constants.error:... - change (pywikibot/compat)

2014-02-25 Thread DrTrigon (Code Review)
DrTrigon has uploaded a new change for review.

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

Change subject: bugfix; '\number' from e.g. date cause 'sre_constants.error: 
invalid group reference'
..

bugfix; '\number' from e.g. date cause 'sre_constants.error: invalid group 
reference'

Change-Id: I35633d22f9f96f776198344cb7c1f89f1e8e9e12
---
M catimages.py
1 file changed, 4 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/compat 
refs/changes/82/115382/1

diff --git a/catimages.py b/catimages.py
index f44de4d..bdfa7bd 100644
--- a/catimages.py
+++ b/catimages.py
@@ -4054,13 +4054,15 @@
 def _append_to_template(self, text, name, append):
 # mask/search template to append to
 pattern = re.compile(u(\{\{%s.*?\n)(\s*\}\}\n{2}) % name, flags=re.S)
-template = pattern.search(text).groups()
+match = pattern.search(text)
+template = match.groups()
 
 # append to template
 template = u.join([template[0], append, u\n, template[1]])
 
 # apply changes
-text = pattern.sub(template, text)
+#text = pattern.sub(template, text)  # '\number' from e.g. date cause 
'sre_constants.error: invalid group reference'
+text = text.replace(match.group(0), template)
 return text
 
 # gather data from all information interfaces

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I35633d22f9f96f776198344cb7c1f89f1e8e9e12
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/compat
Gerrit-Branch: master
Gerrit-Owner: DrTrigon dr.tri...@surfeu.ch

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


[MediaWiki-commits] [Gerrit] Update specs example to use new types (without string/ pre... - change (mediawiki...TemplateData)

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

Change subject: Update specs example to use new types (without string/ prefix)
..


Update specs example to use new types (without string/ prefix)

Follows-up 6cdb47d097543d88d58e0 which dropped the prefixes. The example
was still using 'string/wiki-user-name' instead of 'wiki-user-name'.

Change-Id: Ia6f353600cea6e3da53ea0cabc45a77d35642e40
---
M spec.templatedata.json
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/spec.templatedata.json b/spec.templatedata.json
index abfdb85..960753a 100644
--- a/spec.templatedata.json
+++ b/spec.templatedata.json
@@ -83,7 +83,7 @@
params: {
user: {
label: User's name,
-   type: string/wiki-user-name,
+   type: wiki-user-name,
required: true,
description: User name of person who forgot to sign 
their comment.,
aliases: [1]

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia6f353600cea6e3da53ea0cabc45a77d35642e40
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/TemplateData
Gerrit-Branch: master
Gerrit-Owner: Ltrlg ltrlg...@gmail.com
Gerrit-Reviewer: Krinkle krinklem...@gmail.com
Gerrit-Reviewer: MarkTraceur mtrac...@member.fsf.org
Gerrit-Reviewer: Nemo bis federicol...@tiscali.it
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 use @include as that supresses useful error output - change (mediawiki...Wikibase)

2014-02-25 Thread Aude (Code Review)
Aude has uploaded a new change for review.

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

Change subject: Don't use @include as that supresses useful error output
..

Don't use @include as that supresses useful error output

Change-Id: Iafcc7c188841d2710f0eea925a901dd59aac813a
---
M client/WikibaseClient.php
M repo/Wikibase.php
2 files changed, 2 insertions(+), 2 deletions(-)


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

diff --git a/client/WikibaseClient.php b/client/WikibaseClient.php
index b009543..a898993 100644
--- a/client/WikibaseClient.php
+++ b/client/WikibaseClient.php
@@ -35,7 +35,7 @@
 
 // Include the WikibaseLib extension if that hasn't been done yet, since it's 
required for WikibaseClient to work.
 if ( !defined( 'WBL_VERSION' ) ) {
-   @include_once( __DIR__ . '/../lib/WikibaseLib.php' );
+   include_once( __DIR__ . '/../lib/WikibaseLib.php' );
 }
 
 if ( !defined( 'WBL_VERSION' ) ) {
diff --git a/repo/Wikibase.php b/repo/Wikibase.php
index ad7028f..1262202 100644
--- a/repo/Wikibase.php
+++ b/repo/Wikibase.php
@@ -27,7 +27,7 @@
 
 // Include the WikibaseLib extension if that hasn't been done yet, since it's 
required for Wikibase to work.
 if ( !defined( 'WBL_VERSION' ) ) {
-   @include_once( __DIR__ . '/../lib/WikibaseLib.php' );
+   include_once( __DIR__ . '/../lib/WikibaseLib.php' );
 }
 
 if ( !defined( 'WBL_VERSION' ) ) {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iafcc7c188841d2710f0eea925a901dd59aac813a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: mw1.23-wmf15
Gerrit-Owner: Aude aude.w...@gmail.com
Gerrit-Reviewer: Hoo man h...@online.de

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


[MediaWiki-commits] [Gerrit] Namespace translation for Urdu - change (mediawiki...Scribunto)

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

Change subject: Namespace translation for Urdu
..


Namespace translation for Urdu

Bug: 61905
Change-Id: Ibb25af7137d32682bf2a253694c82d6010683ddb
---
M Scribunto.namespaces.php
1 file changed, 5 insertions(+), 0 deletions(-)

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



diff --git a/Scribunto.namespaces.php b/Scribunto.namespaces.php
index 2a4bb65..2d607bb 100644
--- a/Scribunto.namespaces.php
+++ b/Scribunto.namespaces.php
@@ -291,6 +291,11 @@
829 = 'Обговорення_модуля',
 );
 
+$namespaceNames['ur'] = array(
+   828 = 'ماڈیول',
+   829 = 'تبادلۂ_خیال_ماڈیول',
+);
+
 $namespaceNames['vi'] = array(
828 = 'Mô_đun',
829 = 'Thảo_luận_Mô_đun',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibb25af7137d32682bf2a253694c82d6010683ddb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Scribunto
Gerrit-Branch: master
Gerrit-Owner: Odder tom...@twkozlowski.net
Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com
Gerrit-Reviewer: Siebrand siebr...@wikimedia.org
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 use @include as that supresses useful error output - change (mediawiki...Wikibase)

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

Change subject: Don't use @include as that supresses useful error output
..


Don't use @include as that supresses useful error output

Change-Id: Iafcc7c188841d2710f0eea925a901dd59aac813a
---
M client/WikibaseClient.php
M repo/Wikibase.php
2 files changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Hoo man: Looks good to me, approved
  WikidataJenkins: Verified
  jenkins-bot: Verified



diff --git a/client/WikibaseClient.php b/client/WikibaseClient.php
index b009543..a898993 100644
--- a/client/WikibaseClient.php
+++ b/client/WikibaseClient.php
@@ -35,7 +35,7 @@
 
 // Include the WikibaseLib extension if that hasn't been done yet, since it's 
required for WikibaseClient to work.
 if ( !defined( 'WBL_VERSION' ) ) {
-   @include_once( __DIR__ . '/../lib/WikibaseLib.php' );
+   include_once( __DIR__ . '/../lib/WikibaseLib.php' );
 }
 
 if ( !defined( 'WBL_VERSION' ) ) {
diff --git a/repo/Wikibase.php b/repo/Wikibase.php
index ad7028f..1262202 100644
--- a/repo/Wikibase.php
+++ b/repo/Wikibase.php
@@ -27,7 +27,7 @@
 
 // Include the WikibaseLib extension if that hasn't been done yet, since it's 
required for Wikibase to work.
 if ( !defined( 'WBL_VERSION' ) ) {
-   @include_once( __DIR__ . '/../lib/WikibaseLib.php' );
+   include_once( __DIR__ . '/../lib/WikibaseLib.php' );
 }
 
 if ( !defined( 'WBL_VERSION' ) ) {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iafcc7c188841d2710f0eea925a901dd59aac813a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: mw1.23-wmf15
Gerrit-Owner: Aude aude.w...@gmail.com
Gerrit-Reviewer: Hoo man h...@online.de
Gerrit-Reviewer: WikidataJenkins wikidata-servi...@wikimedia.de
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] sort by dbname before outputting - change (operations/mediawiki-config)

2014-02-25 Thread Reedy (Code Review)
Reedy has uploaded a new change for review.

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

Change subject: sort by dbname before outputting
..

sort by dbname before outputting

Change-Id: I57b69c9d577cf84934eb37667be33fb50564bed0
---
M multiversion/updateWikiversions.php
1 file changed, 1 insertion(+), 0 deletions(-)


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

diff --git a/multiversion/updateWikiversions.php 
b/multiversion/updateWikiversions.php
index 0aa3911..9fac56e 100644
--- a/multiversion/updateWikiversions.php
+++ b/multiversion/updateWikiversions.php
@@ -62,6 +62,7 @@
}
 
$total = count( $versionRows );
+   ksort( $versionRows );
 
MWWikiversions::writeWikiVersionsFile( $jsonPath, $versionRows );
echo Updated $jsonPath: $inserted inserted, $migrated migrated.\n;

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I57b69c9d577cf84934eb37667be33fb50564bed0
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Reedy re...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] sort by dbname before outputting - change (operations/mediawiki-config)

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

Change subject: sort by dbname before outputting
..


sort by dbname before outputting

Change-Id: I57b69c9d577cf84934eb37667be33fb50564bed0
---
M multiversion/updateWikiversions.php
1 file changed, 1 insertion(+), 0 deletions(-)

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



diff --git a/multiversion/updateWikiversions.php 
b/multiversion/updateWikiversions.php
index 0aa3911..9fac56e 100644
--- a/multiversion/updateWikiversions.php
+++ b/multiversion/updateWikiversions.php
@@ -62,6 +62,7 @@
}
 
$total = count( $versionRows );
+   ksort( $versionRows );
 
MWWikiversions::writeWikiVersionsFile( $jsonPath, $versionRows );
echo Updated $jsonPath: $inserted inserted, $migrated migrated.\n;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I57b69c9d577cf84934eb37667be33fb50564bed0
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Reedy re...@wikimedia.org
Gerrit-Reviewer: Reedy re...@wikimedia.org
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 indentation was successful before trying again - change (VisualEditor/VisualEditor)

2014-02-25 Thread Esanders (Code Review)
Esanders has uploaded a new change for review.

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

Change subject: Check indentation was successful before trying again
..

Check indentation was successful before trying again

If for some reason the indentation fails (although it really
shouldn't), we don't want to get stuck in an infinite loop.

Bug: 58060
Change-Id: Icf74c42a224d949e51727fd93a84c0b3bfa3e8d5
---
M modules/ve/ui/actions/ve.ui.ListAction.js
1 file changed, 2 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/85/115385/1

diff --git a/modules/ve/ui/actions/ve.ui.ListAction.js 
b/modules/ve/ui/actions/ve.ui.ListAction.js
index 5db0b2e..ad683ea 100644
--- a/modules/ve/ui/actions/ve.ui.ListAction.js
+++ b/modules/ve/ui/actions/ve.ui.ListAction.js
@@ -134,11 +134,9 @@
 
surfaceModel.breakpoint();
 
-   node = documentModel.getNodeFromOffset( 
surfaceModel.getSelection().start );
-   while ( node.hasMatchingAncestor( 'list' ) ) {
-   this.surface.execute( 'indentation', 'decrease' );
+   do {
node = documentModel.getNodeFromOffset( 
surfaceModel.getSelection().start );
-   }
+   } while ( node.hasMatchingAncestor( 'list' )  this.surface.execute( 
'indentation', 'decrease' ) );
 
surfaceModel.breakpoint();
 };

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Icf74c42a224d949e51727fd93a84c0b3bfa3e8d5
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders esand...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Tweak browsertests URLs - change (integration/jenkins-job-builder-config)

2014-02-25 Thread Hashar (Code Review)
Hashar has uploaded a new change for review.

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

Change subject: Tweak browsertests URLs
..

Tweak browsertests URLs

We need browsertests to mimic MediaWiki paths in production. Ie
something like:

 http://localhost:9413/CirrusSearch/wiki/Main_Page
 http://localhost:9413/CirrusSearch/w/api.php

Made possible by adding a symlink of w - .

Depends on some Apache rewriting.

Change-Id: I0855e60fb53f68b98beec55e445298a2af22f0fa
---
M macro.yaml
1 file changed, 7 insertions(+), 3 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/integration/jenkins-job-builder-config 
refs/changes/87/115387/1

diff --git a/macro.yaml b/macro.yaml
index 5d64010..f6c982c 100644
--- a/macro.yaml
+++ b/macro.yaml
@@ -88,13 +88,17 @@
 # Same for log dir
 chmod a+w log/
 
+# Crazy hack to match production expectations
+ln -s . w
+
 TEST_ID=`echo $ZUUL_PROJECT/$ZUUL_COMMIT/$BUILD_NUMBER | tr '/' '-'`
 
 # Post configure MediaWiki
 echo -n ?php
-  # Injected by Jenkins
-  \$wgServer = 'http://localhost:9413/';
-  \$wgScriptPath = '/$TEST_ID';
+  # Injected by Jenkins Job Builder macro 'browsertests'
+  \$wgServer = 'http://localhost:9413';
+  \$wgScriptPath = '/$TEST_ID/w';
+  \$wgArticlePath = '/$TEST_ID/wiki/$1';
   \$wgScript = \$wgStylePath = \$wgLogo = false;
   \$wgUsePathInfo = false;
 $WORKSPACE/LocalSettings.php

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0855e60fb53f68b98beec55e445298a2af22f0fa
Gerrit-PatchSet: 1
Gerrit-Project: integration/jenkins-job-builder-config
Gerrit-Branch: master
Gerrit-Owner: Hashar has...@free.fr

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


[MediaWiki-commits] [Gerrit] contint: tweak browsertests URLs - change (operations/puppet)

2014-02-25 Thread Hashar (Code Review)
Hashar has uploaded a new change for review.

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

Change subject: contint: tweak browsertests URLs
..

contint: tweak browsertests URLs

We need browsertests to mimic MediaWiki paths in production. Ie
something like:

http://localhost:9413/CirrusSearch/wiki/Main_Page
http://localhost:9413/CirrusSearch/w/api.php

Made possible by having the job create a symlink of w - .

Jenkins jobs change is: https://gerrit.wikimedia.org/r/115387

Change-Id: I0855e60fb53f68b98beec55e445298a2af22f0fa
---
M modules/contint/manifests/browsertests.pp
M modules/contint/templates/apache/localvhost.erb
2 files changed, 11 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/88/115388/1

diff --git a/modules/contint/manifests/browsertests.pp 
b/modules/contint/manifests/browsertests.pp
index a22d250..0c78f99 100644
--- a/modules/contint/manifests/browsertests.pp
+++ b/modules/contint/manifests/browsertests.pp
@@ -30,6 +30,8 @@
 ]: ensure = present
 }
 
+apache_module { 'browser_test_apache_mod_rewrite': name = 'rewrite' }
+
 # And we need a vhost :-)
 contint::localvhost { 'browsertests':
 port   = 9413,
diff --git a/modules/contint/templates/apache/localvhost.erb 
b/modules/contint/templates/apache/localvhost.erb
index bc9510b..53efa1d 100644
--- a/modules/contint/templates/apache/localvhost.erb
+++ b/modules/contint/templates/apache/localvhost.erb
@@ -7,6 +7,15 @@
ServerName localhost
DocumentRoot %= @docroot %
 
+   # Lame examples::
+   # http://localhost:9413/CirrusSearch/
+   # http://localhost:9413/CirrusSearch/Main_Page
+   # http://localhost:9413/CirrusSearch/api.php
+   RewriteEngine on
+   RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-f
+   RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-d
+   RewriteRule ^/([\w-]+)/(.*)?$ /$1/index.php [L]
+
Directory /
Order deny,allow
Deny from all

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0855e60fb53f68b98beec55e445298a2af22f0fa
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Hashar has...@free.fr

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


[MediaWiki-commits] [Gerrit] Add support for new private legalteamwiki - change (mediawiki...deploy)

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

Change subject: Add support for new private legalteamwiki
..


Add support for new private legalteamwiki

Depends on I495e024494d0a978 (the wiki being set up) to actually work,
but shouldn't be an issue to have this go live in advance, I think?

Bug: 61222
Change-Id: I31b4d6f955b236eb72123e918fa3ca7d59ca7211
---
M conf/wmf/localsettings.js
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Subramanya Sastry: Looks good to me, but someone else must approve
  GWicke: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/conf/wmf/localsettings.js b/conf/wmf/localsettings.js
index 3d66bcb..31ef992 100644
--- a/conf/wmf/localsettings.js
+++ b/conf/wmf/localsettings.js
@@ -11,6 +11,7 @@
 privateInterwikiMap = {
 'boardwiki': 'https://board.wikimedia.org/w/api.php',
 'collabwiki': 'https://collab.wikimedia.org/w/api.php',
+'legalteamwiki': 
'https://legalteam.wikimedia.org/w/api.php',
 'officewiki': 'https://office.wikimedia.org/w/api.php',
 'wikimaniateamwiki': 
'https://wikimaniateam.wikimedia.org/w/api.php',
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I31b4d6f955b236eb72123e918fa3ca7d59ca7211
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/services/parsoid/deploy
Gerrit-Branch: master
Gerrit-Owner: Jforrester jforres...@wikimedia.org
Gerrit-Reviewer: GWicke gwi...@wikimedia.org
Gerrit-Reviewer: Subramanya Sastry ssas...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] More control in composer require versions - change (mediawiki...Wikibase)

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

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

Change subject: More control in composer require versions
..

More control in composer require versions

Change-Id: I7f55412f763be2e23a97c877834a797fa507bb9d
(cherry picked from commit 629a5e604efe91c3b6271b156f4a76d9d00a913e)
---
M composer.json
1 file changed, 11 insertions(+), 11 deletions(-)


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

diff --git a/composer.json b/composer.json
index 582790f..042405e 100644
--- a/composer.json
+++ b/composer.json
@@ -24,17 +24,17 @@
},
require: {
php: =5.3.2,
-   data-values/data-values: ~0.1,
-   data-values/common: ~0.1,
-   data-values/geo: ~0.1,
-   data-values/number: ~0.2,
-   data-values/time: ~0.1,
-   data-values/validators: ~0.1,
-   data-values/data-types: ~0.1,
-   data-values/serialization: ~0.1,
-   data-values/javascript: ~0.3,
-   data-values/value-view: ~0.3,=0.3.3,
-   wikibase/data-model: 0.6.*,
+   data-values/data-values: ~0.1.0,
+   data-values/common: ~0.2.0,
+   data-values/geo: ~0.1.0,
+   data-values/number: ~0.2.0,
+   data-values/time: ~0.2.0,
+   data-values/validators: ~0.1.0,
+   data-values/data-types: ~0.1.0,
+   data-values/serialization: ~0.1.0,
+   data-values/javascript: ~0.3.0,
+   data-values/value-view: ~0.3.3,
+   wikibase/data-model: ~0.6.0,
diff/diff: =0.9,
wikibase/easyrdf_lite: *
},

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7f55412f763be2e23a97c877834a797fa507bb9d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: mw1.23-wmf15
Gerrit-Owner: Addshore addshorew...@gmail.com

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


[MediaWiki-commits] [Gerrit] bugfix; '\number' from e.g. date cause 'sre_constants.error:... - change (pywikibot/compat)

2014-02-25 Thread DrTrigon (Code Review)
DrTrigon has submitted this change and it was merged.

Change subject: bugfix; '\number' from e.g. date cause 'sre_constants.error: 
invalid group reference'
..


bugfix; '\number' from e.g. date cause 'sre_constants.error: invalid group 
reference'

Change-Id: I35633d22f9f96f776198344cb7c1f89f1e8e9e12
---
M catimages.py
1 file changed, 4 insertions(+), 2 deletions(-)

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



diff --git a/catimages.py b/catimages.py
index f44de4d..bdfa7bd 100644
--- a/catimages.py
+++ b/catimages.py
@@ -4054,13 +4054,15 @@
 def _append_to_template(self, text, name, append):
 # mask/search template to append to
 pattern = re.compile(u(\{\{%s.*?\n)(\s*\}\}\n{2}) % name, flags=re.S)
-template = pattern.search(text).groups()
+match = pattern.search(text)
+template = match.groups()
 
 # append to template
 template = u.join([template[0], append, u\n, template[1]])
 
 # apply changes
-text = pattern.sub(template, text)
+#text = pattern.sub(template, text)  # '\number' from e.g. date cause 
'sre_constants.error: invalid group reference'
+text = text.replace(match.group(0), template)
 return text
 
 # gather data from all information interfaces

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I35633d22f9f96f776198344cb7c1f89f1e8e9e12
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/compat
Gerrit-Branch: master
Gerrit-Owner: DrTrigon dr.tri...@surfeu.ch
Gerrit-Reviewer: DrTrigon dr.tri...@surfeu.ch
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] mediawiki.notification: Hide #mw-notification-area when it's... - change (mediawiki/core)

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

Change subject: mediawiki.notification: Hide #mw-notification-area when it's 
empty
..


mediawiki.notification: Hide #mw-notification-area when it's empty

We need to hide the area manually, since it has padding, causing it to
obscure whatever is behind it in spite of being invisible.

Bug: 52659
Change-Id: I54e51b392673bc361af4e7bf703df75b83d783d4
---
M RELEASE-NOTES-1.23
M resources/mediawiki/mediawiki.notification.js
2 files changed, 14 insertions(+), 0 deletions(-)

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



diff --git a/RELEASE-NOTES-1.23 b/RELEASE-NOTES-1.23
index be53faf..3f09b81 100644
--- a/RELEASE-NOTES-1.23
+++ b/RELEASE-NOTES-1.23
@@ -142,6 +142,8 @@
 * (bug 60543) Special:PrefixIndex forgot stripprefix=1 for Next page link
 * (bug 29762) Undoing an already-undone edit will now display an appropriate
   message instead of leading the user to make a null edit.
+* (bug 52659) mediawiki.notification: Notification area remained visible when
+  empty and thus was stealing pointer events from links on the page.
 
 === Web API changes in 1.23 ===
 * (bug 54884) action=parseprop=categories now indicates hidden and missing
diff --git a/resources/mediawiki/mediawiki.notification.js 
b/resources/mediawiki/mediawiki.notification.js
index f142fa4..b5fd69c 100644
--- a/resources/mediawiki/mediawiki.notification.js
+++ b/resources/mediawiki/mediawiki.notification.js
@@ -4,6 +4,8 @@
var notification,
// The #mw-notification-area div that all notifications are 
contained inside.
$area,
+   // Number of open notification boxes at any time
+   openNotificationCount = 0,
isPageReady = false,
preReadyNotifQueue = [];
 
@@ -96,11 +98,14 @@
autohideCount,
notif;
 
+   $area.show();
+
if ( this.isOpen ) {
return;
}
 
this.isOpen = true;
+   openNotificationCount++;
 
options = this.options;
$notification = this.$notification;
@@ -268,6 +273,7 @@
return;
}
this.isOpen = false;
+   openNotificationCount--;
// Clear any remaining timeout on close
this.pause();
 
@@ -319,6 +325,12 @@
complete: function () {
// Remove the notification
$( this ).remove();
+   // Hide the area manually after closing 
the last notification, since it has padding,
+   // causing it to obscure whatever is 
behind it in spite of being invisible (bug 52659).
+   // It's okay to do this before getting 
rid of the placeholder, as it's invisible as well.
+   if ( openNotificationCount === 0 ) {
+   $area.hide();
+   }
if ( options.placeholder ) {
// Use a fast slide up 
animation after closing to make it look like the notifications
// below slide up into place 
when the notification disappears

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I54e51b392673bc361af4e7bf703df75b83d783d4
Gerrit-PatchSet: 6
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński matma@gmail.com
Gerrit-Reviewer: Bartosz Dziewoński matma@gmail.com
Gerrit-Reviewer: Catrope roan.katt...@gmail.com
Gerrit-Reviewer: Daniel Friesen dan...@nadir-seen-fire.com
Gerrit-Reviewer: Jack Phoenix j...@countervandalism.net
Gerrit-Reviewer: Jforrester jforres...@wikimedia.org
Gerrit-Reviewer: Krinkle krinklem...@gmail.com
Gerrit-Reviewer: Ori.livneh o...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Initial commit of code - change (mediawiki...CommonMessages)

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

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

Change subject: Initial commit of code
..

Initial commit of code

Change-Id: I1dcafde55b9d84ddd0acd88c824433c569d58a66
---
A CommonMessages.body.php
A CommonMessages.i18n.php
A CommonMessages.php
A export/.gitignore
A export/README
A exportMessages.php
6 files changed, 158 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CommonMessages 
refs/changes/90/115390/1

diff --git a/CommonMessages.body.php b/CommonMessages.body.php
new file mode 100644
index 000..06d5ca6
--- /dev/null
+++ b/CommonMessages.body.php
@@ -0,0 +1,44 @@
+?php
+
+class CommonMessages {
+
+   /** @var array $keys */
+   protected $keys;
+
+   public static function singleton() {
+   static $self = null;
+   if ( !$self ) {
+   $self = new self;
+   }
+   return $self;
+   }
+
+   public function transformKey( $key ) {
+   global $wgCommonMessagesPrefix;
+   return $wgCommonMessagesPrefix . '-' . $key;
+   }
+
+   /**
+* @param string $key non-transformed key
+* @return bool
+*/
+   public function isKeyRegistered( $key ) {
+   if ( $this-keys === null ) {
+   // Load the JSON file.
+   wfSuppressWarnings();
+   $file = file_get_contents( __DIR__ . '/export/en.json' 
);
+   wfRestoreWarnings();
+   if ( !$file ) {
+   $this-keys = array();
+   return false;
+   }
+   $json = FormatJson::decode( $file, true );
+   if ( !$json ) {
+   $this-keys = array();
+   return false;
+   }
+   $this-keys = array_keys( $json );
+   }
+   return in_array( $this-transformKey( $key ), $this-keys );
+   }
+}
\ No newline at end of file
diff --git a/CommonMessages.i18n.php b/CommonMessages.i18n.php
new file mode 100644
index 000..9733a41
--- /dev/null
+++ b/CommonMessages.i18n.php
@@ -0,0 +1,18 @@
+?php
+
+$messages = array();
+
+/**
+ * English
+ * @author Kunal Mehta
+ */
+$messages['en'] = array(
+   'commonmessages-desc' = 'Allows a wikifarm to override messages from 
another wiki',
+);
+
+/** Message documentation (Message documentation)
+ * @author Kunal Mehta
+ */
+$messages['qqq'] = array(
+   'commonmessages-desc' = 
'{{desc|name=CommonMessages|url=https://www.mediawiki.org/wiki/Extension:CommonMessages}}',
+);
diff --git a/CommonMessages.php b/CommonMessages.php
new file mode 100644
index 000..3439423
--- /dev/null
+++ b/CommonMessages.php
@@ -0,0 +1,49 @@
+?php
+
+/**
+ * CommonMessages extension
+ *
+ * Allows a wikifarm to have custom
+ * message overrides easilly
+ * Mainly designed for ShoutWiki's setup,
+ * but can be used for any farm.
+ *
+ * @requires MediaWiki 1.23
+ * @license WTFPL
+ * @author Kunal Mehta lego...@gmail.com
+ */
+
+if ( !defined( 'MEDIAWIKI' ) ) {
+   exit;
+}
+
+$wgExtensionCredits['other'][] = array(
+   'path' = __FILE__,
+   'name' = 'CommonMessages',
+   'author' = 'Kunal Mehta',
+   'descriptionmsg' = 'commonmessages-desc',
+   'version' = '0.0.1',
+);
+
+/**
+ * Prefix of messages when exporting.
+ * Must be configured.
+ */
+$wgCommonMessagesPrefix = '';
+
+if ( file_exists( __DIR__ . '/export/en.json' ) ) {
+   // If an export has happened, load it
+   $wgMessagesDirs['MessageCommons'] = __DIR__ . '/export';
+}
+
+$wgExtensionMessagesFiles['CommonMessages'] =  __DIR__ . 
'/CommonMessages.i18n.php';
+$wgAutoloadClasses['CommonMessages'] = __DIR__ . '/CommonMessages.body.php';
+
+$wgHooks['MessageCache::get'][] = function( $key ) {
+   $commons = CommonMessages::singleton();
+   if ( $commons-isKeyRegistered( $key ) ) {
+   $key = $commons-transformKey( $key );
+   }
+
+   return true;
+};
diff --git a/export/.gitignore b/export/.gitignore
new file mode 100644
index 000..a6c57f5
--- /dev/null
+++ b/export/.gitignore
@@ -0,0 +1 @@
+*.json
diff --git a/export/README b/export/README
new file mode 100644
index 000..f60e76e
--- /dev/null
+++ b/export/README
@@ -0,0 +1 @@
+This directory will be filled after using the exportMessages.php script.
diff --git a/exportMessages.php b/exportMessages.php
new file mode 100644
index 000..8b8c233
--- /dev/null
+++ b/exportMessages.php
@@ -0,0 +1,45 @@
+?php
+
+$IP = getenv( 'MW_INSTALL_PATH' );
+if ( $IP === false ) {
+   $IP = __DIR__ . '/../..';
+}
+
+// Require base maintenance class
+require_once( $IP/maintenance/Maintenance.php );
+
+class ExportMessages extends Maintenance {
+
+   

[MediaWiki-commits] [Gerrit] Disable headings test while Bug 61856 is under investigation - change (mediawiki...VisualEditor)

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

Change subject: Disable headings test while Bug 61856 is under investigation
..


Disable headings test while Bug 61856 is under investigation

This is an expensive test and I'd rather not run it than
have it always failing.

Change-Id: I8ee30bf3e6eb0841f51a4ab02610dd2b3ce8349e
---
M modules/ve-mw/test/browser/features/headings.feature
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/modules/ve-mw/test/browser/features/headings.feature 
b/modules/ve-mw/test/browser/features/headings.feature
index 4bbded0..8d3a4af 100644
--- a/modules/ve-mw/test/browser/features/headings.feature
+++ b/modules/ve-mw/test/browser/features/headings.feature
@@ -1,4 +1,4 @@
-@ie6-bug  @ie7-bug  @ie8-bug  @ie9-bug @ie10-bug 
@en.wikipedia.beta.wmflabs.org @test2.wikipedia.org @login
+@ie6-bug  @ie7-bug  @ie8-bug  @ie9-bug @ie10-bug @login
 Feature: VisualEditor Headings
 
   @edit_user_page

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8ee30bf3e6eb0841f51a4ab02610dd2b3ce8349e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Cmcmahon cmcma...@wikimedia.org
Gerrit-Reviewer: Cmcmahon cmcma...@wikimedia.org
Gerrit-Reviewer: Jhall jh...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 5b395c7..c6a1bbd - change (mediawiki/extensions)

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

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

Change subject: Syncronize VisualEditor: 5b395c7..c6a1bbd
..

Syncronize VisualEditor: 5b395c7..c6a1bbd

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


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

diff --git a/VisualEditor b/VisualEditor
index 5b395c7..c6a1bbd 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 5b395c71d584a656e3297ddd232331d517dad764
+Subproject commit c6a1bbdacff28f47c894901fde2d5a5b3575ca65

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I13e985ad06067edba48c4589005ed9eeeb04bec5
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync jenkins-...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 5b395c7..c6a1bbd - change (mediawiki/extensions)

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

Change subject: Syncronize VisualEditor: 5b395c7..c6a1bbd
..


Syncronize VisualEditor: 5b395c7..c6a1bbd

Change-Id: I13e985ad06067edba48c4589005ed9eeeb04bec5
---
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 5b395c7..c6a1bbd 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 5b395c71d584a656e3297ddd232331d517dad764
+Subproject commit c6a1bbdacff28f47c894901fde2d5a5b3575ca65

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I13e985ad06067edba48c4589005ed9eeeb04bec5
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync jenkins-...@wikimedia.org
Gerrit-Reviewer: Jenkins-mwext-sync jenkins-...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] backport Iafcc7c, remove @ from @include_once for WikibaseLib - change (mediawiki...Wikidata)

2014-02-25 Thread Aude (Code Review)
Aude has uploaded a new change for review.

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

Change subject: backport Iafcc7c, remove @ from @include_once for WikibaseLib
..

backport Iafcc7c, remove @ from @include_once for WikibaseLib

might be related to bug: 61914 or at least be issue in certain cases

Change-Id: I42d868c006784fcc8f87b66644d73fd3a487b17d
---
M composer.lock
M extensions/Wikibase/client/WikibaseClient.php
M extensions/Wikibase/repo/Wikibase.php
M vendor/autoload.php
M vendor/composer/autoload_real.php
M vendor/composer/installed.json
6 files changed, 16 insertions(+), 16 deletions(-)


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

diff --git a/composer.lock b/composer.lock
index dcd86e5..8233d3d 100644
--- a/composer.lock
+++ b/composer.lock
@@ -851,12 +851,12 @@
 source: {
 type: git,
 url: 
https://github.com/wikimedia/mediawiki-extensions-Wikibase.git;,
-reference: 3c23a9f105504788d557027e6981e411238a10d2
+reference: b98b27579a0d7b3d050f39a98497b348b51b043e
 },
 dist: {
 type: zip,
-url: 
https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/3c23a9f105504788d557027e6981e411238a10d2;,
-reference: 3c23a9f105504788d557027e6981e411238a10d2,
+url: 
https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/b98b27579a0d7b3d050f39a98497b348b51b043e;,
+reference: b98b27579a0d7b3d050f39a98497b348b51b043e,
 shasum: 
 },
 require: {
@@ -915,7 +915,7 @@
 wikibaserepo,
 wikidata
 ],
-time: 2014-02-24 16:46:27
+time: 2014-02-25 15:34:42
 }
 ],
 packages-dev: [
diff --git a/extensions/Wikibase/client/WikibaseClient.php 
b/extensions/Wikibase/client/WikibaseClient.php
index b009543..a898993 100644
--- a/extensions/Wikibase/client/WikibaseClient.php
+++ b/extensions/Wikibase/client/WikibaseClient.php
@@ -35,7 +35,7 @@
 
 // Include the WikibaseLib extension if that hasn't been done yet, since it's 
required for WikibaseClient to work.
 if ( !defined( 'WBL_VERSION' ) ) {
-   @include_once( __DIR__ . '/../lib/WikibaseLib.php' );
+   include_once( __DIR__ . '/../lib/WikibaseLib.php' );
 }
 
 if ( !defined( 'WBL_VERSION' ) ) {
diff --git a/extensions/Wikibase/repo/Wikibase.php 
b/extensions/Wikibase/repo/Wikibase.php
index ad7028f..1262202 100644
--- a/extensions/Wikibase/repo/Wikibase.php
+++ b/extensions/Wikibase/repo/Wikibase.php
@@ -27,7 +27,7 @@
 
 // Include the WikibaseLib extension if that hasn't been done yet, since it's 
required for Wikibase to work.
 if ( !defined( 'WBL_VERSION' ) ) {
-   @include_once( __DIR__ . '/../lib/WikibaseLib.php' );
+   include_once( __DIR__ . '/../lib/WikibaseLib.php' );
 }
 
 if ( !defined( 'WBL_VERSION' ) ) {
diff --git a/vendor/autoload.php b/vendor/autoload.php
index cee471b..318b769 100644
--- a/vendor/autoload.php
+++ b/vendor/autoload.php
@@ -4,4 +4,4 @@
 
 require_once __DIR__ . '/composer' . '/autoload_real.php';
 
-return ComposerAutoloaderInit3f9eec0889d9e95b2895f59917d9d237::getLoader();
+return ComposerAutoloaderInit27a38ee0df0c71f65303a5f6ca78197d::getLoader();
diff --git a/vendor/composer/autoload_real.php 
b/vendor/composer/autoload_real.php
index 8d2ebf4..4f92a7a 100644
--- a/vendor/composer/autoload_real.php
+++ b/vendor/composer/autoload_real.php
@@ -2,7 +2,7 @@
 
 // autoload_real.php @generated by Composer
 
-class ComposerAutoloaderInit3f9eec0889d9e95b2895f59917d9d237
+class ComposerAutoloaderInit27a38ee0df0c71f65303a5f6ca78197d
 {
 private static $loader;
 
@@ -19,9 +19,9 @@
 return self::$loader;
 }
 
-
spl_autoload_register(array('ComposerAutoloaderInit3f9eec0889d9e95b2895f59917d9d237',
 'loadClassLoader'), true, true);
+
spl_autoload_register(array('ComposerAutoloaderInit27a38ee0df0c71f65303a5f6ca78197d',
 'loadClassLoader'), true, true);
 self::$loader = $loader = new \Composer\Autoload\ClassLoader();
-
spl_autoload_unregister(array('ComposerAutoloaderInit3f9eec0889d9e95b2895f59917d9d237',
 'loadClassLoader'));
+
spl_autoload_unregister(array('ComposerAutoloaderInit27a38ee0df0c71f65303a5f6ca78197d',
 'loadClassLoader'));
 
 $vendorDir = dirname(__DIR__);
 $baseDir = dirname($vendorDir);
@@ -45,14 +45,14 @@
 
 $includeFiles = require __DIR__ . '/autoload_files.php';
 foreach ($includeFiles as $file) {
-composerRequire3f9eec0889d9e95b2895f59917d9d237($file);
+composerRequire27a38ee0df0c71f65303a5f6ca78197d($file);
 }
 
 return $loader;
 }
 }
 
-function composerRequire3f9eec0889d9e95b2895f59917d9d237($file)
+function 

[MediaWiki-commits] [Gerrit] Enable data transclusion for wikisource - change (operations/mediawiki-config)

2014-02-25 Thread Aude (Code Review)
Aude has uploaded a new change for review.

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

Change subject: Enable data transclusion for wikisource
..

Enable data transclusion for wikisource

Change-Id: I5a2b7b360be808e4780f14dda375af17930dec97
---
M wmf-config/InitialiseSettings.php
1 file changed, 1 insertion(+), 2 deletions(-)


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

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index 136f3a6..4419bc0 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -12697,8 +12697,7 @@
 
 'wmgWikibaseEnableData' = array(
'default' = true,
-   'commonswiki' = false,
-   'wikisource' = false
+   'commonswiki' = false
 ),
 
 'wmgUseWikibaseRepo' = array(

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5a2b7b360be808e4780f14dda375af17930dec97
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Aude aude.w...@gmail.com

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


[MediaWiki-commits] [Gerrit] backport Iafcc7c, remove @ from @include_once for WikibaseLib - change (mediawiki...Wikidata)

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

Change subject: backport Iafcc7c, remove @ from @include_once for WikibaseLib
..


backport Iafcc7c, remove @ from @include_once for WikibaseLib

might be related to bug: 61914 or at least be issue in certain cases

Change-Id: I42d868c006784fcc8f87b66644d73fd3a487b17d
---
M composer.lock
M extensions/Wikibase/client/WikibaseClient.php
M extensions/Wikibase/repo/Wikibase.php
M vendor/autoload.php
M vendor/composer/autoload_real.php
M vendor/composer/installed.json
6 files changed, 16 insertions(+), 16 deletions(-)

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



diff --git a/composer.lock b/composer.lock
index dcd86e5..8233d3d 100644
--- a/composer.lock
+++ b/composer.lock
@@ -851,12 +851,12 @@
 source: {
 type: git,
 url: 
https://github.com/wikimedia/mediawiki-extensions-Wikibase.git;,
-reference: 3c23a9f105504788d557027e6981e411238a10d2
+reference: b98b27579a0d7b3d050f39a98497b348b51b043e
 },
 dist: {
 type: zip,
-url: 
https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/3c23a9f105504788d557027e6981e411238a10d2;,
-reference: 3c23a9f105504788d557027e6981e411238a10d2,
+url: 
https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/b98b27579a0d7b3d050f39a98497b348b51b043e;,
+reference: b98b27579a0d7b3d050f39a98497b348b51b043e,
 shasum: 
 },
 require: {
@@ -915,7 +915,7 @@
 wikibaserepo,
 wikidata
 ],
-time: 2014-02-24 16:46:27
+time: 2014-02-25 15:34:42
 }
 ],
 packages-dev: [
diff --git a/extensions/Wikibase/client/WikibaseClient.php 
b/extensions/Wikibase/client/WikibaseClient.php
index b009543..a898993 100644
--- a/extensions/Wikibase/client/WikibaseClient.php
+++ b/extensions/Wikibase/client/WikibaseClient.php
@@ -35,7 +35,7 @@
 
 // Include the WikibaseLib extension if that hasn't been done yet, since it's 
required for WikibaseClient to work.
 if ( !defined( 'WBL_VERSION' ) ) {
-   @include_once( __DIR__ . '/../lib/WikibaseLib.php' );
+   include_once( __DIR__ . '/../lib/WikibaseLib.php' );
 }
 
 if ( !defined( 'WBL_VERSION' ) ) {
diff --git a/extensions/Wikibase/repo/Wikibase.php 
b/extensions/Wikibase/repo/Wikibase.php
index ad7028f..1262202 100644
--- a/extensions/Wikibase/repo/Wikibase.php
+++ b/extensions/Wikibase/repo/Wikibase.php
@@ -27,7 +27,7 @@
 
 // Include the WikibaseLib extension if that hasn't been done yet, since it's 
required for Wikibase to work.
 if ( !defined( 'WBL_VERSION' ) ) {
-   @include_once( __DIR__ . '/../lib/WikibaseLib.php' );
+   include_once( __DIR__ . '/../lib/WikibaseLib.php' );
 }
 
 if ( !defined( 'WBL_VERSION' ) ) {
diff --git a/vendor/autoload.php b/vendor/autoload.php
index cee471b..318b769 100644
--- a/vendor/autoload.php
+++ b/vendor/autoload.php
@@ -4,4 +4,4 @@
 
 require_once __DIR__ . '/composer' . '/autoload_real.php';
 
-return ComposerAutoloaderInit3f9eec0889d9e95b2895f59917d9d237::getLoader();
+return ComposerAutoloaderInit27a38ee0df0c71f65303a5f6ca78197d::getLoader();
diff --git a/vendor/composer/autoload_real.php 
b/vendor/composer/autoload_real.php
index 8d2ebf4..4f92a7a 100644
--- a/vendor/composer/autoload_real.php
+++ b/vendor/composer/autoload_real.php
@@ -2,7 +2,7 @@
 
 // autoload_real.php @generated by Composer
 
-class ComposerAutoloaderInit3f9eec0889d9e95b2895f59917d9d237
+class ComposerAutoloaderInit27a38ee0df0c71f65303a5f6ca78197d
 {
 private static $loader;
 
@@ -19,9 +19,9 @@
 return self::$loader;
 }
 
-
spl_autoload_register(array('ComposerAutoloaderInit3f9eec0889d9e95b2895f59917d9d237',
 'loadClassLoader'), true, true);
+
spl_autoload_register(array('ComposerAutoloaderInit27a38ee0df0c71f65303a5f6ca78197d',
 'loadClassLoader'), true, true);
 self::$loader = $loader = new \Composer\Autoload\ClassLoader();
-
spl_autoload_unregister(array('ComposerAutoloaderInit3f9eec0889d9e95b2895f59917d9d237',
 'loadClassLoader'));
+
spl_autoload_unregister(array('ComposerAutoloaderInit27a38ee0df0c71f65303a5f6ca78197d',
 'loadClassLoader'));
 
 $vendorDir = dirname(__DIR__);
 $baseDir = dirname($vendorDir);
@@ -45,14 +45,14 @@
 
 $includeFiles = require __DIR__ . '/autoload_files.php';
 foreach ($includeFiles as $file) {
-composerRequire3f9eec0889d9e95b2895f59917d9d237($file);
+composerRequire27a38ee0df0c71f65303a5f6ca78197d($file);
 }
 
 return $loader;
 }
 }
 
-function composerRequire3f9eec0889d9e95b2895f59917d9d237($file)
+function 

[MediaWiki-commits] [Gerrit] Needs latest mediawiki_selenium to talk to SauceLab - change (mediawiki...UploadWizard)

2014-02-25 Thread Cmcmahon (Code Review)
Cmcmahon has uploaded a new change for review.

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

Change subject: Needs latest mediawiki_selenium to talk to SauceLab
..

Needs latest mediawiki_selenium to talk to SauceLab

Change-Id: Ic44662c33663a673b158e82b6109b896282aeb00
---
M tests/browser/Gemfile.lock
1 file changed, 4 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/UploadWizard 
refs/changes/94/115394/1

diff --git a/tests/browser/Gemfile.lock b/tests/browser/Gemfile.lock
index 1ddc40b..748e428 100644
--- a/tests/browser/Gemfile.lock
+++ b/tests/browser/Gemfile.lock
@@ -2,7 +2,7 @@
   remote: https://rubygems.org/
   specs:
 builder (3.2.2)
-childprocess (0.4.0)
+childprocess (0.5.1)
   ffi (~ 1.0, = 1.0.11)
 chunky_png (1.3.0)
 cucumber (1.3.10)
@@ -23,7 +23,7 @@
 headless (1.0.1)
 i18n (0.6.9)
 json (1.8.1)
-mediawiki_selenium (0.2.2)
+mediawiki_selenium (0.2.7)
   cucumber (~ 1.3, = 1.3.10)
   headless (~ 1.0, = 1.0.1)
   json (~ 1.8, = 1.8.1)
@@ -48,12 +48,12 @@
   diff-lcs (= 1.1.3,  2.0)
 rubyzip (1.1.0)
 selenium-webdriver (2.39.0)
-  childprocess (= 0.2.5)
+  childprocess (= 0.5.0)
   multi_json (~ 1.0)
   rubyzip (~ 1.0)
   websocket (~ 1.0.4)
 syntax (1.2.0)
-watir-webdriver (0.6.7)
+watir-webdriver (0.6.8)
   selenium-webdriver (= 2.18.0)
 websocket (1.0.7)
 yml_reader (0.2)

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic44662c33663a673b158e82b6109b896282aeb00
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/UploadWizard
Gerrit-Branch: master
Gerrit-Owner: Cmcmahon cmcma...@wikimedia.org

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


[MediaWiki-commits] [Gerrit] Needs latest mediawiki_selenium to talk to SauceLab - change (mediawiki...UploadWizard)

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

Change subject: Needs latest mediawiki_selenium to talk to SauceLab
..


Needs latest mediawiki_selenium to talk to SauceLab

Change-Id: Ic44662c33663a673b158e82b6109b896282aeb00
---
M tests/browser/Gemfile.lock
1 file changed, 4 insertions(+), 4 deletions(-)

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



diff --git a/tests/browser/Gemfile.lock b/tests/browser/Gemfile.lock
index 1ddc40b..748e428 100644
--- a/tests/browser/Gemfile.lock
+++ b/tests/browser/Gemfile.lock
@@ -2,7 +2,7 @@
   remote: https://rubygems.org/
   specs:
 builder (3.2.2)
-childprocess (0.4.0)
+childprocess (0.5.1)
   ffi (~ 1.0, = 1.0.11)
 chunky_png (1.3.0)
 cucumber (1.3.10)
@@ -23,7 +23,7 @@
 headless (1.0.1)
 i18n (0.6.9)
 json (1.8.1)
-mediawiki_selenium (0.2.2)
+mediawiki_selenium (0.2.7)
   cucumber (~ 1.3, = 1.3.10)
   headless (~ 1.0, = 1.0.1)
   json (~ 1.8, = 1.8.1)
@@ -48,12 +48,12 @@
   diff-lcs (= 1.1.3,  2.0)
 rubyzip (1.1.0)
 selenium-webdriver (2.39.0)
-  childprocess (= 0.2.5)
+  childprocess (= 0.5.0)
   multi_json (~ 1.0)
   rubyzip (~ 1.0)
   websocket (~ 1.0.4)
 syntax (1.2.0)
-watir-webdriver (0.6.7)
+watir-webdriver (0.6.8)
   selenium-webdriver (= 2.18.0)
 websocket (1.0.7)
 yml_reader (0.2)

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic44662c33663a673b158e82b6109b896282aeb00
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/UploadWizard
Gerrit-Branch: master
Gerrit-Owner: Cmcmahon cmcma...@wikimedia.org
Gerrit-Reviewer: Cmcmahon cmcma...@wikimedia.org
Gerrit-Reviewer: jenkins-bot 

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


[MediaWiki-commits] [Gerrit] Add sequence support for upsert in DatabaseOracle - change (mediawiki/core)

2014-02-25 Thread MarkAHershberger (Code Review)
MarkAHershberger has uploaded a new change for review.

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

Change subject: Add sequence support for upsert in DatabaseOracle
..

Add sequence support for upsert in DatabaseOracle

In the same way as in selectInsert

Bug: 53710
Change-Id: I26f891da808ecdc932e29eebda71df4c17a29617
(cherry picked from commit 3d0f393ced80206053e18f893a17fbb81be14c8d)
---
M includes/db/DatabaseOracle.php
1 file changed, 30 insertions(+), 2 deletions(-)


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

diff --git a/includes/db/DatabaseOracle.php b/includes/db/DatabaseOracle.php
index 32d4d98..fb2d435 100644
--- a/includes/db/DatabaseOracle.php
+++ b/includes/db/DatabaseOracle.php
@@ -551,8 +551,12 @@
} else {
$first = false;
}
-
-   $sql .= $this-fieldBindStatement( $table, $col, $val );
+   if ( $this-isQuotedIdentifier( $val ) ) {
+   $sql .= $this-removeIdentifierQuotes( $val );
+   unset( $row[$col] );
+   } else {
+   $sql .= $this-fieldBindStatement( $table, 
$col, $val );
+   }
}
$sql .= ')';
 
@@ -679,6 +683,30 @@
return $retval;
}
 
+   public function upsert( $table, array $rows, array $uniqueIndexes, 
array $set,
+   $fname = __METHOD__
+   ) {
+   if ( !count( $rows ) ) {
+   return true; // nothing to do
+   }
+
+   if ( !is_array( reset( $rows ) ) ) {
+   $rows = array( $rows );
+   }
+
+   $sequenceData = $this-getSequenceData( $table );
+   if ( $sequenceData !== false ) {
+   // add sequence column to each list of columns, when 
not set
+   foreach ( $rows as $row ) {
+   if ( !isset( $row[$sequenceData['column']] ) ) {
+   $row[$sequenceData['column']] = 
$this-addIdentifierQuotes('GET_SEQUENCE_VALUE(\'' . $sequenceData['sequence'] 
. '\')');
+   }
+   }
+   }
+
+   return parent::upsert( $table, $rows, $uniqueIndexes, $set, 
$fname );
+   }
+
function tableName( $name, $format = 'quoted' ) {
/*
Replace reserved words with better ones

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I26f891da808ecdc932e29eebda71df4c17a29617
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: REL1_22
Gerrit-Owner: MarkAHershberger mhershber...@wikimedia.org
Gerrit-Reviewer: Umherirrender umherirrender_de...@web.de

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


[MediaWiki-commits] [Gerrit] Renamed function name reorder args for clarity + added docs. - change (mediawiki...parsoid)

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

Change subject: Renamed function name  reorder args for clarity + added docs.
..


Renamed function name  reorder args for clarity + added docs.

* Renamed buildDOMFragmentForTokenStream -- buildDOMFragmentTokens
  and made env. the first arg.

* Added documentation to buildDOMFragmentTokens and encapsulateHTML

Change-Id: I7eccfd3f4dc5b4b91d20d1d24d98ec514df6dfbc
---
M lib/ext.Cite.js
M lib/ext.core.DOMFragmentBuilder.js
M lib/ext.core.TemplateHandler.js
M lib/mediawiki.DOMUtils.js
4 files changed, 65 insertions(+), 6 deletions(-)

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



diff --git a/lib/ext.Cite.js b/lib/ext.Cite.js
index 2b7c560..6c5f004 100644
--- a/lib/ext.Cite.js
+++ b/lib/ext.Cite.js
@@ -304,10 +304,10 @@
 
cb({
async: false,
-   tokens: DU.buildDOMFragmentForTokenStream(
+   tokens: DU.buildDOMFragmentTokens(
+   manager.env,
refsTok,
olHTML,
-   manager.env,
olProcessor,
// The ol HTML above is just skeleton HTML 
from a string.
// So, it doesn't have any DSR on it. We want 
DSR added to it.
diff --git a/lib/ext.core.DOMFragmentBuilder.js 
b/lib/ext.core.DOMFragmentBuilder.js
index a1f13d1..6db5fab 100644
--- a/lib/ext.core.DOMFragmentBuilder.js
+++ b/lib/ext.core.DOMFragmentBuilder.js
@@ -93,7 +93,7 @@
 };
 
 DOMFragmentBuilder.prototype.wrapDOMFragment = function(cb, scopeToken, dom) {
-   var toks = DU.buildDOMFragmentForTokenStream(scopeToken, dom, 
this.manager.env);
+   var toks = DU.buildDOMFragmentTokens(this.manager.env, scopeToken, dom);
 
// Nothing more to send cb after this
cb({tokens: toks, async:false});
diff --git a/lib/ext.core.TemplateHandler.js b/lib/ext.core.TemplateHandler.js
index da9b2c8..0b37bda 100644
--- a/lib/ext.core.TemplateHandler.js
+++ b/lib/ext.core.TemplateHandler.js
@@ -727,10 +727,10 @@
));
};
 
-   var toks = DU.buildDOMFragmentForTokenStream(
+   var toks = DU.buildDOMFragmentTokens(
+   this.manager.env,
state.token,
doc,
-   this.manager.env,
addWrapperAttrs,
{ isForeignContent: true }
);
diff --git a/lib/mediawiki.DOMUtils.js b/lib/mediawiki.DOMUtils.js
index 183362d..94f3866 100644
--- a/lib/mediawiki.DOMUtils.js
+++ b/lib/mediawiki.DOMUtils.js
@@ -1441,6 +1441,49 @@
 
},
 
+   /**
+* Generates wrapper tokens for a HTML expansion -- the wrapper
+* tokens are placeholders that adequately represent semantics
+* of the HTML DOM for the purposes of additional token transformations
+* that will be applied to them.
+*
+* @param {Object} env
+*The active environment/context.
+*
+* @param {Object} token
+*The token that generated the DOM.
+*
+* @param {Object} expansion
+*expansion.html  -- HTML of the expansion
+*expansion.nodes -- outermost nodes of the HTML
+*
+* @param {Object} addAttrsCB
+*Callback that adds additional attributes to the generated tokens.
+*
+* @param {Object} opts
+*aboutId   : The about-id to set on the generated tokens.
+*
+*noAboutId : If true, an about-id will not be added to the tokens
+*if an aboutId is not provided.
+*Ex: figure
+*
+*tsr   : The TSR to set on the generated tokens. This TSR is
+*used to compute DSR on the placeholder tokens.
+*The computed DSR is transferred over to the unpacked 
DOM
+*if setDSR is true (see below).
+*
+*setDSR: When the DOM-fragment is unpacked, this option governs
+*whether the DSR from the placeholder node is 
transferred
+*over to the unpacked DOM or not.
+*Ex: Cite, reused transclusions
+*
+*isForeignContent :
+*Does the DOM come from outside the main page? This 
governs
+*how the encapsulation ids are assigned to the 
unpacked DOM.
+*Ex: transclusions, extensions -- all siblings get the 
same
+*about id. This is not true for figure HTML.
+*
+*/
encapsulateExpansionHTML: function(env, token, expansion, opts) {
opts = opts || {};
 
@@ -1501,8 +1544,24 @@
 *
 * The DOMPostProcessor will 

  1   2   3   >