[MediaWiki-commits] [Gerrit] Add WRITE_ALL flag to BagOStuff::merge() - change (mediawiki/core)

2015-10-18 Thread Aaron Schulz (Code Review)
Aaron Schulz has uploaded a new change for review.

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

Change subject: Add WRITE_ALL flag to BagOStuff::merge()
..

Add WRITE_ALL flag to BagOStuff::merge()

* This blocks on writing to all replicas
  and returns false if any failed.
* Redundant doc comments were also removed.

Change-Id: I9ed098d563c64dba605e7809bc96731da3b3e79d
---
M includes/libs/objectcache/BagOStuff.php
M includes/objectcache/MultiWriteBagOStuff.php
2 files changed, 25 insertions(+), 60 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/82/247182/1

diff --git a/includes/libs/objectcache/BagOStuff.php 
b/includes/libs/objectcache/BagOStuff.php
index fc74985..a07c570 100644
--- a/includes/libs/objectcache/BagOStuff.php
+++ b/includes/libs/objectcache/BagOStuff.php
@@ -67,6 +67,8 @@
/** Bitfield constants for get()/getMulti() */
const READ_LATEST = 1; // use latest data for replicated stores
const READ_VERIFIED = 2; // promise that caller can tell when keys are 
stale
+   /** Bitfield constants for merge() */
+   const WRITE_ALL = 1; // synchronously write to all locations for 
replicated stores
 
public function __construct( array $params = array() ) {
if ( isset( $params['logger'] ) ) {
@@ -158,6 +160,7 @@
 * @param mixed $casToken
 * @param integer $flags Bitfield of BagOStuff::READ_* constants 
[optional]
 * @return mixed Returns false on failure and if the item does not exist
+* @throws Exception
 */
protected function getWithToken( $key, &$casToken, $flags = 0 ) {
throw new Exception( __METHOD__ . ' not implemented.' );
@@ -191,10 +194,11 @@
 * @param callable $callback Callback method to be executed
 * @param int $exptime Either an interval in seconds or a unix 
timestamp for expiry
 * @param int $attempts The amount of times to attempt a merge in case 
of failure
+* @param int $flags Bitfield of BagOStuff::WRITE_* constants
 * @return bool Success
 * @throws InvalidArgumentException
 */
-   public function merge( $key, $callback, $exptime = 0, $attempts = 10 ) {
+   public function merge( $key, $callback, $exptime = 0, $attempts = 10, 
$flags = 0 ) {
if ( !is_callable( $callback ) ) {
throw new InvalidArgumentException( "Got invalid 
callback." );
}
diff --git a/includes/objectcache/MultiWriteBagOStuff.php 
b/includes/objectcache/MultiWriteBagOStuff.php
index c05ecb6..976d387 100644
--- a/includes/objectcache/MultiWriteBagOStuff.php
+++ b/includes/objectcache/MultiWriteBagOStuff.php
@@ -80,11 +80,10 @@
$this->asyncWrites = isset( $params['replication'] ) && 
$params['replication'] === 'async';
}
 
-   /**
-* @param bool $debug
-*/
public function setDebug( $debug ) {
-   $this->doWrite( self::ALL, 'setDebug', $debug );
+   foreach ( $this->caches as $cache ) {
+   $cache->setDebug( $debug );
+   }
}
 
protected function doGet( $key, $flags = 0 ) {
@@ -102,87 +101,48 @@
&& $misses > 0
&& ( $flags & self::READ_VERIFIED ) == 
self::READ_VERIFIED
) {
-   $this->doWrite( $misses, 'set', $key, $value, 
self::UPGRADE_TTL );
+   $this->doWrite( $misses, $this->asyncWrites, 'set', 
$key, $value, self::UPGRADE_TTL );
}
 
return $value;
}
 
-   /**
-* @param string $key
-* @param mixed $value
-* @param int $exptime
-* @return bool
-*/
public function set( $key, $value, $exptime = 0 ) {
-   return $this->doWrite( self::ALL, 'set', $key, $value, $exptime 
);
+   return $this->doWrite( self::ALL, $this->asyncWrites, 'set', 
$key, $value, $exptime );
}
 
-   /**
-* @param string $key
-* @return bool
-*/
public function delete( $key ) {
-   return $this->doWrite( self::ALL, 'delete', $key );
+   return $this->doWrite( self::ALL, $this->asyncWrites, 'delete', 
$key );
}
 
-   /**
-* @param string $key
-* @param mixed $value
-* @param int $exptime
-* @return bool
-*/
public function add( $key, $value, $exptime = 0 ) {
-   return $this->doWrite( self::ALL, 'add', $key, $value, $exptime 
);
+   return $this->doWrite( self::ALL, $this->asyncWrites, 'add', 
$key, $value, $exptime );
}
 
-   /**
-* @param string $key
-* @param int $value
-* @return bool|null
-*/
public function incr( $key, $value = 1 ) {
-   return 

[MediaWiki-commits] [Gerrit] User education popup for citations - change (mediawiki...Citoid)

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

Change subject: User education popup for citations
..


User education popup for citations

Bug: T108620
Change-Id: I68b077528b36c25b7ebf59bbdae21a8a8c1bc42a
---
M extension.json
A modules/ve.ui.CiteFromIdInspectorTool.css
M modules/ve.ui.CiteFromIdInspectorTool.js
3 files changed, 14 insertions(+), 0 deletions(-)

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



diff --git a/extension.json b/extension.json
index 86c6de7..f6789df 100644
--- a/extension.json
+++ b/extension.json
@@ -31,6 +31,7 @@
],
"styles": [
"modules/ve.ui.CiteSourceSelectWidget.css",
+   "modules/ve.ui.CiteFromIdInspectorTool.css",
"modules/ve.ui.CiteFromIdInspector.css"
],
"dependencies": [
diff --git a/modules/ve.ui.CiteFromIdInspectorTool.css 
b/modules/ve.ui.CiteFromIdInspectorTool.css
new file mode 100644
index 000..b7cc722
--- /dev/null
+++ b/modules/ve.ui.CiteFromIdInspectorTool.css
@@ -0,0 +1,8 @@
+/*!
+ * VisualEditor UserInterface CiteFromIdInspectorTool styles.
+ */
+
+.oo-ui-tool-name-citefromid .oo-ui-popupWidget-body 
.ve-ui-educationPopup-header {
+   background: 
url(../../VisualEditor/modules/ve-mw/ui/styles/tools/images/reference-ltr.png) 
no-repeat center/90%;
+   height: 150px;
+}
diff --git a/modules/ve.ui.CiteFromIdInspectorTool.js 
b/modules/ve.ui.CiteFromIdInspectorTool.js
index 10306f7..c9491e8 100644
--- a/modules/ve.ui.CiteFromIdInspectorTool.js
+++ b/modules/ve.ui.CiteFromIdInspectorTool.js
@@ -57,9 +57,14 @@
 */
ve.ui.CiteFromIdInspectorTool = function VeUiCiteFromIdInspectorTool() {
ve.ui.CiteFromIdInspectorTool.super.apply( this, arguments );
+   ve.ui.MWEducationPopupTool.call( this, {
+   title: ve.msg( 
'visualeditor-dialogbutton-citation-educationpopup-title' ),
+   text: ve.msg( 
'visualeditor-dialogbutton-citation-educationpopup-text' )
+   } );
};
 
OO.inheritClass( ve.ui.CiteFromIdInspectorTool, ve.ui.InspectorTool );
+   OO.mixinClass( ve.ui.CiteFromIdInspectorTool, 
ve.ui.MWEducationPopupTool );
 
ve.ui.CiteFromIdInspectorTool.static.name = 'citefromid';
ve.ui.CiteFromIdInspectorTool.static.autoAddToCatchall = false;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I68b077528b36c25b7ebf59bbdae21a8a8c1bc42a
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/Citoid
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: Esanders 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] WIP: Fix sol handling in separators - change (mediawiki...parsoid)

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

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

Change subject: WIP: Fix sol handling in separators
..

WIP: Fix sol handling in separators

Only /\n$/ puts serializer in SOL-state, not /\n\s*$/.
However, fixing this bug exposes another fairly serious one.
NL constraints for various HTML tags don't indicate whether
the wikitext for the HTML tags should force SOL state by stripping
an excess characters at the start of line.

[subbu@earth lib] echo "\na\n b" | node parse
--html2wt
* a
 * b

This is clearly a bug. The reason we didn't trip over it all this
while is because 'make-indent-pre' stripped the excess whitespace
to prevent indent-pre-ing the content. However, that is a scenario
of one bug papering over another bug.

To be investigated and cleaned up.

Change-Id: I7a5ccd33b31fa4222f016e33a9576f4127590b2d
---
M lib/wts.SerializerState.js
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/lib/wts.SerializerState.js b/lib/wts.SerializerState.js
index b88853d..0933d6d 100644
--- a/lib/wts.SerializerState.js
+++ b/lib/wts.SerializerState.js
@@ -218,7 +218,7 @@
 SSP.sepIntroducedSOL = function(sep) {
// Don't get tripped by newlines in comments!  Be wary of nowikis added
// by makeSepIndentPreSafe on the last line.
-   if (sep.replace(Util.COMMENT_REGEXP_G, '').search(/\n\s*$/) !== -1) {
+   if (sep.replace(Util.COMMENT_REGEXP_G, '').search(/\n$/) !== -1) {
this.onSOL = true;
}
 };

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

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

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


[MediaWiki-commits] [Gerrit] Decouple ChronologyProtector from user sessions - change (mediawiki/core)

2015-10-18 Thread Aaron Schulz (Code Review)
Aaron Schulz has uploaded a new change for review.

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

Change subject: Decouple ChronologyProtector from user sessions
..

Decouple ChronologyProtector from user sessions

* This now works for users without sessions and for
  requests across subdomains.
* Use merge() to avoid rolling back master positions
  if the user has multiple tabs open at once.
* The global state is now removed.
* toString() method is no longer missing from DBMasterPos.

Change-Id: Ib25d05994d62b25c2f89e67b7f51009c54f4bca8
---
M includes/db/ChronologyProtector.php
M includes/db/DatabaseUtility.php
M includes/db/loadbalancer/LBFactoryMulti.php
M includes/db/loadbalancer/LBFactorySimple.php
4 files changed, 111 insertions(+), 21 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/78/247178/1

diff --git a/includes/db/ChronologyProtector.php 
b/includes/db/ChronologyProtector.php
index 0c7b612..a44faa6 100644
--- a/includes/db/ChronologyProtector.php
+++ b/includes/db/ChronologyProtector.php
@@ -26,14 +26,44 @@
  * Kind of like Hawking's [[Chronology Protection Agency]].
  */
 class ChronologyProtector {
-   /** @var array (DB master name => position) */
-   protected $startupPositions = array();
+   /** @var BagOStuff */
+   protected $store;
 
-   /** @var array (DB master name => position) */
+   /** @var string Storage key name */
+   protected $key;
+   /** @var array Map of (ip: , agent: ) */
+   protected $client;
+   /** @var DBMasterPos[] Map of (DB master name => position) */
+   protected $startupPositions = array();
+   /** @var DBMasterPos[] Map of (DB master name => position) */
protected $shutdownPositions = array();
 
+   /** @var bool Whether to actually wait on and record positions */
+   protected $enabled = true;
/** @var bool Whether the session data was loaded */
protected $initialized = false;
+
+   /**
+* @param BagOStuff $store
+* @param array $client Map of (ip: , agent: )
+* @since 1.27
+*/
+   public function __construct( BagOStuff $store, array $client ) {
+   $this->store = $store;
+   $this->client = $client;
+   $this->key = $store->makeGlobalKey(
+   'ChronologyProtector',
+   md5( $client['ip'] . "\n" . $client['agent'] )
+   );
+   }
+
+   /**
+* @param bool $enabled
+* @since 1.27
+*/
+   public function setEnabled( $enabled ) {
+   $this->enabled = $enabled;
+   }
 
/**
 * Initialise a LoadBalancer to give it appropriate chronology 
protection.
@@ -47,15 +77,12 @@
 * @return void
 */
public function initLB( LoadBalancer $lb ) {
-   if ( $lb->getServerCount() <= 1 ) {
-   return; // non-replicated setup
+   if ( !$this->enabled || $lb->getServerCount() <= 1 ) {
+   return; // non-replicated setup or disabled
}
-   if ( !$this->initialized ) {
-   $this->initialized = true;
-   if ( isset( $_SESSION[__CLASS__] ) && is_array( 
$_SESSION[__CLASS__] ) ) {
-   $this->startupPositions = $_SESSION[__CLASS__];
-   }
-   }
+
+   $this->initialize();
+
$masterName = $lb->getServerName( 0 );
if ( !empty( $this->startupPositions[$masterName] ) ) {
$info = $lb->parentInfo();
@@ -73,21 +100,26 @@
 * @return void
 */
public function shutdownLB( LoadBalancer $lb ) {
-   if ( session_id() == '' || $lb->getServerCount() <= 1 ) {
-   return; // don't start a session; don't bother with 
non-replicated setups
+   if ( !$this->enabled || $lb->getServerCount() <= 1 ) {
+   return; // non-replicated setup or disabled
}
+
+   $info = $lb->parentInfo();
$masterName = $lb->getServerName( 0 );
if ( isset( $this->shutdownPositions[$masterName] ) ) {
+   wfDebug( __METHOD__ . ": LB {$info['id']} already shut 
down\n" );
+
return; // already done
}
+
// Only save the position if writes have been done on the 
connection
$db = $lb->getAnyOpenConnection( 0 );
-   $info = $lb->parentInfo();
if ( !$db || !$db->doneWrites() ) {
wfDebug( __METHOD__ . ": LB {$info['id']}, no writes 
done\n" );
 
-   return;
+   return; // nothing to do
}
+
$pos = $db->getMasterPos();
wfDebug( 

[MediaWiki-commits] [Gerrit] v2.10.3.1 - change (xowa)

2015-10-18 Thread Gnosygnu (Code Review)
Gnosygnu has uploaded a new change for review.

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

Change subject: v2.10.3.1
..

v2.10.3.1

Change-Id: Ieb1d657011f49125cf0bd3a43ddc854a92d41451
---
M 100_core/src/gplx/core/btries/Btrie_slim_mgr.java
M 100_core/src_100_types_primitive/gplx/Byte_ascii.java
M 100_core/src_130_brys/gplx/Bry_bfr_mkr.java
M 150_gfui/src_200_ipt/gplx/gfui/IptEvtDataKey.java
M 150_gfui/src_300_gxw/gplx/gfui/GxwCbkHost_.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_clipboard.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_clipboard_.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_dlg_file.java
A 150_gfui/src_700_env/gplx/gfui/Gfui_dlg_file_.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_dlg_msg.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_dlg_msg_.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_kit_base.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_mnu_grp.java
A 150_gfui/src_700_env/gplx/gfui/Gfui_mnu_grp_.java
M 150_gfui/xtn/gplx/gfui/Swt_html.java
A 150_gfui/xtn/gplx/gfui/Swt_html_eval_rslt.java
A 400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_itm.java
A 400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr.java
A 400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_tst.java
D 400_xowa/src/gplx/langs/htmls/parsers/Gfo_html_node.java
D 400_xowa/src/gplx/langs/htmls/parsers/Gfo_html_parser.java
D 400_xowa/src/gplx/langs/htmls/parsers/Gfo_html_wkr.java
D 400_xowa/src/gplx/langs/htmls/parsers/Xob_html_tkn.java
M 400_xowa/src/gplx/xowa/Xoa_app.java
M 400_xowa/src/gplx/xowa/Xoa_app_.java
M 400_xowa/src/gplx/xowa/Xoa_app_fxt.java
M 400_xowa/src/gplx/xowa/Xoa_page.java
M 400_xowa/src/gplx/xowa/Xoa_ttl.java
M 400_xowa/src/gplx/xowa/Xoa_url.java
M 400_xowa/src/gplx/xowa/Xoae_app.java
M 400_xowa/src/gplx/xowa/Xoae_page.java
M 400_xowa/src/gplx/xowa/Xop_fxt.java
M 400_xowa/src/gplx/xowa/Xow_wiki.java
M 400_xowa/src/gplx/xowa/Xowe_wiki.java
M 400_xowa/src/gplx/xowa/Xowe_wiki_.java
D 400_xowa/src/gplx/xowa/apis/Xoapi_doc.java
D 400_xowa/src/gplx/xowa/apis/Xoapi_root.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_app.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_app_wiki.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_app_wikis.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_bldr.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_gui.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_html.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_nav.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_net.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_special.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_usr.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_xtns.java
D 400_xowa/src/gplx/xowa/apis/xowa/apps/Xoapi_fsys.java
D 400_xowa/src/gplx/xowa/apis/xowa/bldrs/Xoapi_bldr_wiki.java
D 400_xowa/src/gplx/xowa/apis/xowa/bldrs/filters/Xoapi_filter.java
D 
400_xowa/src/gplx/xowa/apis/xowa/bldrs/filters/dansguardians/Xoapi_dansguardian.java
D 400_xowa/src/gplx/xowa/apis/xowa/bldrs/filters/titles/Xoapi_title.java
D 400_xowa/src/gplx/xowa/apis/xowa/bldrs/imports/Xoapi_import.java
D 400_xowa/src/gplx/xowa/apis/xowa/envs/Xoapi_env.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/Xoapi_browser.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/Xoapi_font.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/Xoapi_page.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_find.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_html_box.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_info.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_prog.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_prog_log.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_search.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_tabs.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_url.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/pages/Xoapi_edit.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/pages/Xoapi_selection.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/pages/Xoapi_view.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_modules.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_page.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_skins.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_tidy.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_toggle_itm.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_toggle_mgr.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/modules/Xoapi_collapsible.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/modules/Xoapi_navframe.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/modules/Xoapi_popups.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/modules/Xoapi_toc.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/skins/Xoapi_skin_app_base.java
D 400_xowa/src/gplx/xowa/apis/xowa/navs/Xoapi_wiki.java
D 400_xowa/src/gplx/xowa/apis/xowa/specials/Xoapi_search.java
D 400_xowa/src/gplx/xowa/apis/xowa/startups/Xoapi_startups.java
D 400_xowa/src/gplx/xowa/apis/xowa/startups/tabs/Xoapi_startup_tabs.java
D 

[MediaWiki-commits] [Gerrit] v2.10.3.1 - change (xowa)

2015-10-18 Thread Gnosygnu (Code Review)
Gnosygnu has submitted this change and it was merged.

Change subject: v2.10.3.1
..


v2.10.3.1

Change-Id: Ieb1d657011f49125cf0bd3a43ddc854a92d41451
---
M 100_core/src/gplx/core/btries/Btrie_slim_mgr.java
M 100_core/src_100_types_primitive/gplx/Byte_ascii.java
M 100_core/src_130_brys/gplx/Bry_bfr_mkr.java
M 150_gfui/src_200_ipt/gplx/gfui/IptEvtDataKey.java
M 150_gfui/src_300_gxw/gplx/gfui/GxwCbkHost_.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_clipboard.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_clipboard_.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_dlg_file.java
A 150_gfui/src_700_env/gplx/gfui/Gfui_dlg_file_.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_dlg_msg.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_dlg_msg_.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_kit_base.java
M 150_gfui/src_700_env/gplx/gfui/Gfui_mnu_grp.java
A 150_gfui/src_700_env/gplx/gfui/Gfui_mnu_grp_.java
M 150_gfui/xtn/gplx/gfui/Swt_html.java
A 150_gfui/xtn/gplx/gfui/Swt_html_eval_rslt.java
A 400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_itm.java
A 400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr.java
A 400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_tst.java
D 400_xowa/src/gplx/langs/htmls/parsers/Gfo_html_node.java
D 400_xowa/src/gplx/langs/htmls/parsers/Gfo_html_parser.java
D 400_xowa/src/gplx/langs/htmls/parsers/Gfo_html_wkr.java
D 400_xowa/src/gplx/langs/htmls/parsers/Xob_html_tkn.java
M 400_xowa/src/gplx/xowa/Xoa_app.java
M 400_xowa/src/gplx/xowa/Xoa_app_.java
M 400_xowa/src/gplx/xowa/Xoa_app_fxt.java
M 400_xowa/src/gplx/xowa/Xoa_page.java
M 400_xowa/src/gplx/xowa/Xoa_ttl.java
M 400_xowa/src/gplx/xowa/Xoa_url.java
M 400_xowa/src/gplx/xowa/Xoae_app.java
M 400_xowa/src/gplx/xowa/Xoae_page.java
M 400_xowa/src/gplx/xowa/Xop_fxt.java
M 400_xowa/src/gplx/xowa/Xow_wiki.java
M 400_xowa/src/gplx/xowa/Xowe_wiki.java
M 400_xowa/src/gplx/xowa/Xowe_wiki_.java
D 400_xowa/src/gplx/xowa/apis/Xoapi_doc.java
D 400_xowa/src/gplx/xowa/apis/Xoapi_root.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_app.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_app_wiki.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_app_wikis.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_bldr.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_gui.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_html.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_nav.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_net.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_special.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_usr.java
D 400_xowa/src/gplx/xowa/apis/xowa/Xoapi_xtns.java
D 400_xowa/src/gplx/xowa/apis/xowa/apps/Xoapi_fsys.java
D 400_xowa/src/gplx/xowa/apis/xowa/bldrs/Xoapi_bldr_wiki.java
D 400_xowa/src/gplx/xowa/apis/xowa/bldrs/filters/Xoapi_filter.java
D 
400_xowa/src/gplx/xowa/apis/xowa/bldrs/filters/dansguardians/Xoapi_dansguardian.java
D 400_xowa/src/gplx/xowa/apis/xowa/bldrs/filters/titles/Xoapi_title.java
D 400_xowa/src/gplx/xowa/apis/xowa/bldrs/imports/Xoapi_import.java
D 400_xowa/src/gplx/xowa/apis/xowa/envs/Xoapi_env.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/Xoapi_browser.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/Xoapi_font.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/Xoapi_page.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_find.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_html_box.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_info.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_prog.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_prog_log.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_search.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_tabs.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/browsers/Xoapi_url.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/pages/Xoapi_edit.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/pages/Xoapi_selection.java
D 400_xowa/src/gplx/xowa/apis/xowa/gui/pages/Xoapi_view.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_modules.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_page.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_skins.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_tidy.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_toggle_itm.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/Xoapi_toggle_mgr.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/modules/Xoapi_collapsible.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/modules/Xoapi_navframe.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/modules/Xoapi_popups.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/modules/Xoapi_toc.java
D 400_xowa/src/gplx/xowa/apis/xowa/html/skins/Xoapi_skin_app_base.java
D 400_xowa/src/gplx/xowa/apis/xowa/navs/Xoapi_wiki.java
D 400_xowa/src/gplx/xowa/apis/xowa/specials/Xoapi_search.java
D 400_xowa/src/gplx/xowa/apis/xowa/startups/Xoapi_startups.java
D 400_xowa/src/gplx/xowa/apis/xowa/startups/tabs/Xoapi_startup_tabs.java
D 400_xowa/src/gplx/xowa/apis/xowa/startups/tabs/Xoapi_startup_tabs_tid_.java
D 

[MediaWiki-commits] [Gerrit] Hygiene: move View concerns to ArticleHeaderView - change (apps...wikipedia)

2015-10-18 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review.

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

Change subject: Hygiene: move View concerns to ArticleHeaderView
..

Hygiene: move View concerns to ArticleHeaderView

Continue to prune the LeadImagesHandler class by moving some View
concerns to ArticleHeaderView and encapsulating some of the presentation
logic in ArticleHeaderView by hiding internal View implementation
details.

Change-Id: I12341a8fa7b6fd75c5c443dd609d4a11f755209f
---
M app/src/main/java/org/wikipedia/Utils.java
M app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
M app/src/main/java/org/wikipedia/views/ArticleHeaderView.java
M app/src/main/res/layout/view_article_header.xml
M app/src/main/res/values/attrs.xml
M app/src/main/res/values/styles_light.xml
6 files changed, 236 insertions(+), 184 deletions(-)


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

diff --git a/app/src/main/java/org/wikipedia/Utils.java 
b/app/src/main/java/org/wikipedia/Utils.java
index 4fce8be..4056391 100644
--- a/app/src/main/java/org/wikipedia/Utils.java
+++ b/app/src/main/java/org/wikipedia/Utils.java
@@ -424,13 +424,13 @@
 /**
  * Resolves the resource ID of a theme-dependent attribute (for example, a 
color value
  * that changes based on the selected theme)
- * @param activity The activity whose theme contains the attribute.
+ * @param context The Context whose theme contains the attribute.
  * @param id Theme-dependent attribute ID to be resolved.
  * @return The actual resource ID of the requested theme-dependent 
attribute.
  */
-public static int getThemedAttributeId(Activity activity, int id) {
+public static int getThemedAttributeId(Context context, int id) {
 TypedValue tv = new TypedValue();
-activity.getTheme().resolveAttribute(id, tv, true);
+context.getTheme().resolveAttribute(id, tv, true);
 return tv.resourceId;
 }
 
diff --git 
a/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java 
b/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
index 6d6e8f2..71fd001 100755
--- a/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
+++ b/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
@@ -2,12 +2,6 @@
 
 import android.content.res.Resources;
 import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Color;
-import android.graphics.Typeface;
-import android.graphics.drawable.Drawable;
-import android.support.annotation.ColorInt;
-import android.support.annotation.ColorRes;
 import android.support.annotation.DimenRes;
 import android.support.annotation.NonNull;
 import android.support.annotation.Nullable;
@@ -21,16 +15,10 @@
 import android.text.style.AbsoluteSizeSpan;
 import android.util.TypedValue;
 import android.graphics.PointF;
-import android.view.Gravity;
-import android.view.View;
-import android.view.ViewGroup;
 import android.view.animation.Animation;
 import android.view.animation.AnimationUtils;
 import android.widget.FrameLayout;
 import android.widget.ImageView;
-
-import com.squareup.picasso.Picasso;
-import com.squareup.picasso.Target;
 
 import org.json.JSONException;
 import org.json.JSONObject;
@@ -48,12 +36,9 @@
 import org.wikipedia.richtext.ParagraphSpan;
 import org.wikipedia.richtext.RichTextUtil;
 import org.wikipedia.util.DimenUtil;
-import org.wikipedia.util.GradientUtil;
 import org.wikipedia.util.StringUtil;
 import org.wikipedia.views.ArticleHeaderView;
 import org.wikipedia.views.ObservableWebView;
-import org.wikipedia.views.ConfigurableTextView;
-import org.wikipedia.views.ViewUtil;
 
 public class LeadImagesHandler {
 /**
@@ -97,7 +82,6 @@
 }
 
 @NonNull private final PageFragment parentFragment;
-@NonNull private final ViewGroup imageContainer;
 @NonNull private final CommunicationBridge bridge;
 @NonNull private final ObservableWebView webView;
 
@@ -108,10 +92,9 @@
  */
 private boolean leadImagesEnabled;
 
+@NonNull private final ArticleHeaderView articleHeaderView;
 private ImageView imagePlaceholder;
 private ImageViewWithFace image;
-private ConfigurableTextView pageTitleText;
-private Drawable pageTitleGradient;
 
 private int displayHeightDp;
 private int imageBaseYOffset;
@@ -123,17 +106,13 @@
  @NonNull CommunicationBridge bridge,
  @NonNull ObservableWebView webView,
  @NonNull ArticleHeaderView articleHeaderView) {
+this.articleHeaderView = articleHeaderView;
 this.parentFragment = parentFragment;
-this.imageContainer = articleHeaderView;
 this.bridge = bridge;
 this.webView = webView;
 
 imagePlaceholder = articleHeaderView.getPlaceholder();
 image = 

[MediaWiki-commits] [Gerrit] adds context param and observer routing for external linking... - change (wikidata...dashboard)

2015-10-18 Thread Christopher Johnson (WMDE) (Code Review)
Christopher Johnson (WMDE) has uploaded a new change for review.

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

Change subject: adds context param and observer routing for external linking 
moves all dependency loading to global.R adds external link icon to 
server-recent
..

adds context param and observer routing for external linking
moves all dependency loading to global.R
adds external link icon to server-recent

Change-Id: If4b8fb87669b59b5c83399b9a095b042506560ef
---
A bulk_sparql.Re.Rout
M config.R
A global.R
M server.R
M ui.R
5 files changed, 41 insertions(+), 25 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikidata/analytics/dashboard 
refs/changes/81/247181/1

diff --git a/bulk_sparql.Re.Rout b/bulk_sparql.Re.Rout
new file mode 100644
index 000..dacfe5f
--- /dev/null
+++ b/bulk_sparql.Re.Rout
@@ -0,0 +1 @@
+Fatal error: cannot open file 'bulk_sparql.Re': No such file or directory
diff --git a/config.R b/config.R
index 7c05030..c5a8089 100644
--- a/config.R
+++ b/config.R
@@ -1,4 +1,8 @@
-#Dependent libs
+options(scipen = 500)
+
+library(shiny)
+library(shinydashboard)
+library(dygraphs)
 library(plyr)
 library(readr)
 library(xts)
@@ -14,10 +18,11 @@
 library(data.table)
 library(DT)
 library(XML)
+
 data_uri <- "/srv/dashboards/shiny-server/wdm/data/"
 sparql_data_uri <- "/srv/dashboards/shiny-server/wdm/data/sparql/"
 source_data_uri <- "http://wdm-data.wmflabs.org/data/;
 agg_data_uri <- "http://datasets.wikimedia.org/aggregate-datasets/wikidata/;
 wdqs_uri <- "https://query.wikidata.org/bigdata/namespace/wdq/sparql?query=;
 custom_css <- "./assets/css/custom.css"
-metrics_rdf = "/srv/dashboards/shiny-server/wdm/assets/metrics.owl"
+metrics_rdf <- "/srv/dashboards/shiny-server/wdm/assets/metrics.owl"
diff --git a/global.R b/global.R
new file mode 100644
index 000..75fd140
--- /dev/null
+++ b/global.R
@@ -0,0 +1,8 @@
+options(scipen = 500)
+
+library(shiny)
+library(shinydashboard)
+library(dygraphs)
+source("config.R")
+source("model.R")
+source("utils.R")
\ No newline at end of file
diff --git a/server.R b/server.R
index 47c598a..92109d9 100644
--- a/server.R
+++ b/server.R
@@ -1,8 +1,3 @@
-## Version 0.2.0
-source("config.R")
-source("model.R")
-source("utils.R")
-
 #Load Data
 get_data <- function(updateProgress = NULL) {
   if (is.function(updateProgress)) {
@@ -20,17 +15,26 @@
 #Start Server
 function(input, output, session) {
 
-  progress <- shiny::Progress$new()
-  progress$set(message = "Fetching data", value = 0)
-  on.exit(progress$close())
-  updateProgress <- function(value = NULL, detail = NULL) {
-if (is.null(value)) {
-  value <- progress$getValue()
-  value <- value + (progress$getMax() - value) / 5
+progress <- shiny::Progress$new()
+progress$set(message = "Fetching data", value = 0)
+on.exit(progress$close())
+updateProgress <- function(value = NULL, detail = NULL) {
+  if (is.null(value)) {
+value <- progress$getValue()
+value <- value + (progress$getMax() - value) / 5
+  }
+  progress$set(value = value, detail = detail)
 }
-progress$set(value = value, detail = detail)
-  }
-  get_data(updateProgress)
+get_data(updateProgress)
+
+observe({
+  context <- parseQueryString(session$clientData$url_search)
+  if (!is.null(context$t)) {
+observeEvent(context$t, {
+  updateTabItems(session, "tabs", context$t)
+})
+  }
+})
 
 observeEvent(input$switchtab, {
 updateTabItems(session, "tabs", input$switchtab)
diff --git a/ui.R b/ui.R
index 71c16c1..bab6f07 100644
--- a/ui.R
+++ b/ui.R
@@ -1,8 +1,3 @@
-library(shiny)
-library(shinydashboard)
-library(dygraphs)
-options(scipen = 500)
-
 #Header elements for the visualisation
 header <- dashboardHeader(title = "Wikidata Metrics", disable = FALSE)
 
@@ -72,7 +67,8 @@
 tags$br(),
 fluidRow(
   uiOutput("metric_meta_recent_edits_seeAlso")
-)),
+),
+tags$a(href="./?t=wikidata_daily_edits_delta", "Link here: ", 
icon("external-link"))),
 tabItem(tabName = "wikidata_daily_pages_delta",
 dygraphOutput("wikidata_daily_pages_delta_plot"),
 tags$br(),
@@ -82,7 +78,8 @@
 tags$br(),
 fluidRow(
   uiOutput("metric_meta_recent_pages_seeAlso")
-)),
+),
+tags$a(href="./?t=wikidata_daily_pages_delta", "Link here: ", 
icon("external-link"))),
 tabItem(tabName = "wikidata_daily_users_delta",
 dygraphOutput("wikidata_daily_users_delta_plot"),
 tags$br(),
@@ -91,7 +88,8 @@
 tags$br(),
 fluidRow(
   uiOutput("metric_meta_recent_users_seeAlso")
-)),
+),
+tags$a(href="./?t=wikidata_daily_users_delta", "Link here: ", 
icon("external-link"))),
 tabItem(tabName = "wikidata_daily_social",
 

[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 5732bd2..0df380a - change (mediawiki/extensions)

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

Change subject: Syncronize VisualEditor: 5732bd2..0df380a
..


Syncronize VisualEditor: 5732bd2..0df380a

Change-Id: I38710068066b4e09b47e6b9926325b0f308c8edc
---
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 5732bd2..0df380a 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 5732bd26fb351223e306d2171d7ae6b239121482
+Subproject commit 0df380a3d58c0ba7be55c19c315b5112e19bca61

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

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

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 5732bd2..0df380a - change (mediawiki/extensions)

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

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

Change subject: Syncronize VisualEditor: 5732bd2..0df380a
..

Syncronize VisualEditor: 5732bd2..0df380a

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


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

diff --git a/VisualEditor b/VisualEditor
index 5732bd2..0df380a 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 5732bd26fb351223e306d2171d7ae6b239121482
+Subproject commit 0df380a3d58c0ba7be55c19c315b5112e19bca61

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

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

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


[MediaWiki-commits] [Gerrit] Fix Maintenance typo - change (mediawiki/core)

2015-10-18 Thread Reedy (Code Review)
Reedy has uploaded a new change for review.

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

Change subject: Fix Maintenance typo
..

Fix Maintenance typo

Change-Id: I3e0ae4446f74fac25e1cc79a86ff6e0738ada52d
---
M maintenance/populateCategory.php
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/79/247179/1

diff --git a/maintenance/populateCategory.php b/maintenance/populateCategory.php
index 66553bc..65d272b 100644
--- a/maintenance/populateCategory.php
+++ b/maintenance/populateCategory.php
@@ -25,7 +25,7 @@
 require_once __DIR__ . '/Maintenance.php';
 
 /**
- * Mainteance script to populate the category table.
+ * Maintenance script to populate the category table.
  *
  * @ingroup Maintenance
  */

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

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

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


[MediaWiki-commits] [Gerrit] Fix Maintenance typo - change (mediawiki/core)

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

Change subject: Fix Maintenance typo
..


Fix Maintenance typo

Change-Id: I3e0ae4446f74fac25e1cc79a86ff6e0738ada52d
---
M maintenance/populateCategory.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/maintenance/populateCategory.php b/maintenance/populateCategory.php
index 66553bc..65d272b 100644
--- a/maintenance/populateCategory.php
+++ b/maintenance/populateCategory.php
@@ -25,7 +25,7 @@
 require_once __DIR__ . '/Maintenance.php';
 
 /**
- * Mainteance script to populate the category table.
+ * Maintenance script to populate the category table.
  *
  * @ingroup Maintenance
  */

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3e0ae4446f74fac25e1cc79a86ff6e0738ada52d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Reedy 
Gerrit-Reviewer: Aaron Schulz 
Gerrit-Reviewer: Parent5446 
Gerrit-Reviewer: Ricordisamoa 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] adds context param and observer routing for external linking... - change (wikidata...dashboard)

2015-10-18 Thread Christopher Johnson (WMDE) (Code Review)
Christopher Johnson (WMDE) has submitted this change and it was merged.

Change subject: adds context param and observer routing for external linking 
moves base file loading to global.R and dependency libraries to config.R adds 
external link icon to server-recent
..


adds context param and observer routing for external linking
moves base file loading to global.R and dependency libraries to config.R
adds external link icon to server-recent

Change-Id: If4b8fb87669b59b5c83399b9a095b042506560ef
---
A .arclint
M config.R
A global.R
M server.R
M ui.R
5 files changed, 92 insertions(+), 25 deletions(-)

Approvals:
  Christopher Johnson (WMDE): Verified; Looks good to me, approved



diff --git a/.arclint b/.arclint
new file mode 100644
index 000..9c27335
--- /dev/null
+++ b/.arclint
@@ -0,0 +1,57 @@
+{
+  "exclude": [],
+  "linters": {
+"chmod": {
+  "type": "chmod"
+},
+"filename": {
+  "type": "filename"
+},
+"generated": {
+  "type": "generated"
+},
+"json": {
+  "type": "json",
+   "include": [
+ "(^\\.arcconfig$)",
+ "(^\\.arclint$)",
+ "(\\.json$)"
+   ]
+},
+"merge-conflict": {
+  "type": "merge-conflict"
+},
+"nolint": {
+  "type": "nolint"
+},
+"phutil-library": {
+  "type": "phutil-library",
+  "include": "(^\\.php$)"
+},
+"phutil-xhpast": {
+  "type": "phutil-xhpast"
+},
+"spelling": {
+  "type": "spelling"
+},
+"text": {
+  "type": "text"
+},
+"text-without-length": {
+  "type": "text",
+  "severity": {
+"3": "disabled"
+  }
+},
+"xhpast": {
+  "type": "xhpast",
+  "include": "(\\.php$)",
+  "severity": {
+"16": "advice",
+"34": "error"
+  },
+  "xhpast.php-version": "5.3.0",
+  "xhpast.php-version.windows": "5.3.0"
+}
+  }
+}
diff --git a/config.R b/config.R
index 7c05030..c5a8089 100644
--- a/config.R
+++ b/config.R
@@ -1,4 +1,8 @@
-#Dependent libs
+options(scipen = 500)
+
+library(shiny)
+library(shinydashboard)
+library(dygraphs)
 library(plyr)
 library(readr)
 library(xts)
@@ -14,10 +18,11 @@
 library(data.table)
 library(DT)
 library(XML)
+
 data_uri <- "/srv/dashboards/shiny-server/wdm/data/"
 sparql_data_uri <- "/srv/dashboards/shiny-server/wdm/data/sparql/"
 source_data_uri <- "http://wdm-data.wmflabs.org/data/;
 agg_data_uri <- "http://datasets.wikimedia.org/aggregate-datasets/wikidata/;
 wdqs_uri <- "https://query.wikidata.org/bigdata/namespace/wdq/sparql?query=;
 custom_css <- "./assets/css/custom.css"
-metrics_rdf = "/srv/dashboards/shiny-server/wdm/assets/metrics.owl"
+metrics_rdf <- "/srv/dashboards/shiny-server/wdm/assets/metrics.owl"
diff --git a/global.R b/global.R
new file mode 100644
index 000..8bbfdda
--- /dev/null
+++ b/global.R
@@ -0,0 +1,3 @@
+source("config.R")
+source("model.R")
+source("utils.R")
\ No newline at end of file
diff --git a/server.R b/server.R
index 47c598a..92109d9 100644
--- a/server.R
+++ b/server.R
@@ -1,8 +1,3 @@
-## Version 0.2.0
-source("config.R")
-source("model.R")
-source("utils.R")
-
 #Load Data
 get_data <- function(updateProgress = NULL) {
   if (is.function(updateProgress)) {
@@ -20,17 +15,26 @@
 #Start Server
 function(input, output, session) {
 
-  progress <- shiny::Progress$new()
-  progress$set(message = "Fetching data", value = 0)
-  on.exit(progress$close())
-  updateProgress <- function(value = NULL, detail = NULL) {
-if (is.null(value)) {
-  value <- progress$getValue()
-  value <- value + (progress$getMax() - value) / 5
+progress <- shiny::Progress$new()
+progress$set(message = "Fetching data", value = 0)
+on.exit(progress$close())
+updateProgress <- function(value = NULL, detail = NULL) {
+  if (is.null(value)) {
+value <- progress$getValue()
+value <- value + (progress$getMax() - value) / 5
+  }
+  progress$set(value = value, detail = detail)
 }
-progress$set(value = value, detail = detail)
-  }
-  get_data(updateProgress)
+get_data(updateProgress)
+
+observe({
+  context <- parseQueryString(session$clientData$url_search)
+  if (!is.null(context$t)) {
+observeEvent(context$t, {
+  updateTabItems(session, "tabs", context$t)
+})
+  }
+})
 
 observeEvent(input$switchtab, {
 updateTabItems(session, "tabs", input$switchtab)
diff --git a/ui.R b/ui.R
index 71c16c1..bab6f07 100644
--- a/ui.R
+++ b/ui.R
@@ -1,8 +1,3 @@
-library(shiny)
-library(shinydashboard)
-library(dygraphs)
-options(scipen = 500)
-
 #Header elements for the visualisation
 header <- dashboardHeader(title = "Wikidata Metrics", disable = FALSE)
 
@@ -72,7 +67,8 @@
 tags$br(),
 fluidRow(
   uiOutput("metric_meta_recent_edits_seeAlso")
-)),
+),
+

[MediaWiki-commits] [Gerrit] Replace call to old wfMsg function - change (mediawiki...DonationInterface)

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

Change subject: Replace call to old wfMsg function
..


Replace call to old wfMsg function

This was deprecated in MW 1.18.

Change-Id: If07830d5743f6886098891c11889682dbc95caf4
---
M gateway_common/GatewayPage.php
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/gateway_common/GatewayPage.php b/gateway_common/GatewayPage.php
index 69cf4a5..e0b7484 100644
--- a/gateway_common/GatewayPage.php
+++ b/gateway_common/GatewayPage.php
@@ -373,8 +373,8 @@
$f_message = 'No active donation in the session';
}
 
-   if ( $forbidden ){
-   wfHttpError( 403, 'Forbidden', wfMsg( 
'donate_interface-error-http-403' ) );
+   if ( $forbidden ) {
+   wfHttpError( 403, 'Forbidden', wfMessage( 
'donate_interface-error-http-403' )->text() );
}
$oid = $this->adapter->getData_Unstaged_Escaped( 'order_id' );
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If07830d5743f6886098891c11889682dbc95caf4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/DonationInterface
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 
Gerrit-Reviewer: AndyRussG 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
Gerrit-Reviewer: Ejegg 
Gerrit-Reviewer: Ssmith 
Gerrit-Reviewer: XenoRyet 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Display 'cite_error_references_duplicate_key' next to the af... - change (mediawiki...Cite)

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

Change subject: Display 'cite_error_references_duplicate_key' next to the 
affected ref
..


Display 'cite_error_references_duplicate_key' next to the affected ref

Follow-up to 5d0fb0309bca864a6680c007eaf03645f590dc58.

Bug: T114898
Change-Id: Id6d0b7f2c0b76b67a50fc981b9255dff99137bed
---
M Cite_body.php
M citeParserTests.txt
2 files changed, 7 insertions(+), 8 deletions(-)

Approvals:
  Alex Monk: Looks good to me, but someone else must approve
  Amire80: Looks good to me, approved
  Eranroz: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/Cite_body.php b/Cite_body.php
index 48b9930..75749c8 100644
--- a/Cite_body.php
+++ b/Cite_body.php
@@ -398,7 +398,7 @@
if ( $follow != null ) {
if ( isset( $this->mRefs[$group][$follow] ) && 
is_array( $this->mRefs[$group][$follow] ) ) {
// add text to the note that is being followed
-   $this->mRefs[$group][$follow]['text'] = 
$this->mRefs[$group][$follow]['text'] . ' ' . $str;
+   $this->mRefs[$group][$follow]['text'] .= ' ' . 
$str;
} else {
// insert part of note at the beginning of the 
group
$groupsCount = count( $this->mRefs[$group] );
@@ -460,7 +460,8 @@
} else {
if ( $str != null && $str !== '' && $str !== 
$this->mRefs[$group][$key]['text'] ) {
// two refs with same key and different content
-   $this->mReferencesErrors[] = $this->error( 
'cite_error_references_duplicate_key', $key );
+   // add error message to the original ref
+   $this->mRefs[$group][$key]['text'] .= ' ' . 
$this->error( 'cite_error_references_duplicate_key', $key );
}
$this->mRefCallStack[] = array( 'increment', $call, 
$str, $key, $group,
$this->mRefs[$group][$key]['key'] );
diff --git a/citeParserTests.txt b/citeParserTests.txt
index d4dc163..b160059 100644
--- a/citeParserTests.txt
+++ b/citeParserTests.txt
@@ -210,11 +210,10 @@
 [1]
 
 
-↑ 1.0 1.1 0
+↑ 1.0 1.1 0 
Cite error: Invalid 
ref tag; name "blank" defined multiple times with 
different content
 
 
-Cite error: Invalid 
ref tag; name "blank" defined multiple times with 
different content
-
+
 !! end
 
 !! test
@@ -230,11 +229,10 @@
 [1]
 
 
-↑ 1.0 1.1 1
+↑ 1.0 1.1 1 
Cite error: Invalid 
ref tag; name "blank" defined multiple times with 
different content
 
 
-Cite error: Invalid 
ref tag; name "blank" defined multiple times with 
different content
-
+
 !! end
 
 !! test

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Id6d0b7f2c0b76b67a50fc981b9255dff99137bed
Gerrit-PatchSet: 6
Gerrit-Project: mediawiki/extensions/Cite
Gerrit-Branch: master
Gerrit-Owner: Bartosz Dziewoński 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: Amire80 
Gerrit-Reviewer: Anomie 
Gerrit-Reviewer: Eranroz 
Gerrit-Reviewer: Jackmcbarn 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Broadcast mw-ext-ORES changes to #wikimedia-ai - change (labs...grrrit)

2015-10-18 Thread Awight (Code Review)
Awight has uploaded a new change for review.

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

Change subject: Broadcast mw-ext-ORES changes to #wikimedia-ai
..

Broadcast mw-ext-ORES changes to #wikimedia-ai

More components coming soon?  This project is mostly developed under
https://github.com/wiki-ai/

Change-Id: Iaae7ed2870e7f8ba0b70e8f3e0476c974cbfb198
---
M config.yaml
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/tools/grrrit 
refs/changes/83/247183/1

diff --git a/config.yaml b/config.yaml
index 98b7cc7..4f583a7 100644
--- a/config.yaml
+++ b/config.yaml
@@ -55,6 +55,8 @@
 mediawiki/extensions/Maps:
 mediawiki/extensions/RDFIO:
 mediawiki/extensions/SolrStore:
+"#wikimedia-ai":
+mediawiki/extensions/ORES:
 "#wikimedia-analytics":
 analytics/.*:
 "#wikimedia-perf":

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iaae7ed2870e7f8ba0b70e8f3e0476c974cbfb198
Gerrit-PatchSet: 1
Gerrit-Project: labs/tools/grrrit
Gerrit-Branch: master
Gerrit-Owner: Awight 

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


[MediaWiki-commits] [Gerrit] Convert to extension.json - change (mediawiki...GoogleAPIClient)

2015-10-18 Thread Florianschmidtwelzow (Code Review)
Florianschmidtwelzow has uploaded a new change for review.

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

Change subject: Convert to extension.json
..

Convert to extension.json

Clear php entry point.

Change-Id: I2562e2976955eba1f0cdab88b9ddb7675e065c19
---
M GoogleAPIClient.php
A extension.json
2 files changed, 41 insertions(+), 47 deletions(-)


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

diff --git a/GoogleAPIClient.php b/GoogleAPIClient.php
index 42d9c23..ab3dc2d 100644
--- a/GoogleAPIClient.php
+++ b/GoogleAPIClient.php
@@ -1,49 +1,14 @@
  __FILE__,
-   'name' => 'GoogleAPIClient',
-   'author' => 'Florian Schmidt',
-   'url' => 
'https://www.mediawiki.org/wiki/Extension:GoogleAPIClient',
-   'descriptionmsg' => 'googleapiclient-desc',
-   'version'  => '01.0',
-   'license-name' => "MIT/Apache",
-   );
-
-   $dir = __DIR__;
-
-   // Load message file
-   $wgMessagesDirs['GoogleAPIClient'] = $dir . '/i18n';
-
-   // Autoload Classes
-   $wgAutoloadClasses[ 'Google_Client' ] = $dir . 
'/lib/src/Google/Client.php';
-   $wgAutoloadClasses[ 'GoogleAPIClientHooks' ] = $dir . 
'/GoogleAPIClient.hooks.php';
-
-   // Hook handlers
-   $wgHooks['UnitTestsList'][] = 'GoogleAPIClientHooks::onUnitTestsList';
+if ( function_exists( 'wfLoadExtension' ) ) {
+   wfLoadExtension( 'GoogleAPIClient' );
+   // Keep i18n globals so mergeMessageFileList.php doesn't break
+   $wgMessagesDirs['GoogleAPIClient'] = __DIR__ . '/i18n';
+   /* wfWarn(
+   'Deprecated PHP entry point used for GoogleAPIClient extension. 
Please use wfLoadExtension instead, ' .
+   'see https://www.mediawiki.org/wiki/Extension_registration for 
more details.'
+   ); */
+   return true;
+} else {
+   die( 'This version of the GoogleAPIClient extension requires MediaWiki 
1.25+' );
+}
diff --git a/extension.json b/extension.json
new file mode 100644
index 000..434d3ee
--- /dev/null
+++ b/extension.json
@@ -0,0 +1,29 @@
+{
+   "name": "GoogleAPIClient",
+   "version": "0.1.1",
+   "author": [
+   "Florian Schmidt"
+   ],
+   "url": "https://www.mediawiki.org/wiki/Extension:GoogleAPIClient;,
+   "descriptionmsg": "googleapiclient-desc",
+   "license-name": "MIT",
+   "type": "other",
+   "requires": {
+   "MediaWiki": ">= 1.25.0"
+   },
+   "MessagesDirs": {
+   "GoogleAPIClient": [
+   "i18n"
+   ]
+   },
+   "Hooks": {
+   "UnitTestsList": [
+   "GoogleAPIClientHooks::onUnitTestsList"
+   ]
+   },
+   "AutoloadClasses": {
+   "Google_Client": "lib/src/Google/Client.php",
+   "GoogleAPIClientHooks": "GoogleAPIClient.hooks.php"
+   },
+   "manifest_version": 1
+}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2562e2976955eba1f0cdab88b9ddb7675e065c19
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/GoogleAPIClient
Gerrit-Branch: master
Gerrit-Owner: Florianschmidtwelzow 

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


[MediaWiki-commits] [Gerrit] DSR: Fix bugs in LTR propagation + fix buggy tests in DOMUti... - change (mediawiki...parsoid)

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

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

Change subject: DSR: Fix bugs in LTR propagation + fix buggy tests in DOMUtil 
helpers
..

DSR: Fix bugs in LTR propagation + fix buggy tests in DOMUtil helpers

* DSR computation has a check to stop LTR propagation if it
  won't change anything. This check is present to prevent
  O(n^2) behavior where n = # of children of a node.

  However, the checks were buggy and were preventing the
  LTR propagation from terminating in some scenarios.
  The net effect was that in those scenarios, this resulted in
  O(n^2) behavior since for every child that was encountered in
  the RTL sweep, information was being propagated to all children after!

* Encountered this while debugging timeout on iawikibooks:Interlexico_c

* Fixed the checks and better documented them.

* While fixing failing parser tests, discovered buggy tests in
  DOMUtils helpers testing for tpl-start meta type (which we have
  been implicitly assuming covers param types as well). In a separate
  patch, the helpers could probably be renamed.

Change-Id: Idd978f84faef1a231d06a502f17ab26159d1c073
---
M lib/dom.computeDSR.js
M lib/mediawiki.DOMUtils.js
2 files changed, 17 insertions(+), 9 deletions(-)


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

diff --git a/lib/dom.computeDSR.js b/lib/dom.computeDSR.js
index 5229ffe..6c10693 100644
--- a/lib/dom.computeDSR.js
+++ b/lib/dom.computeDSR.js
@@ -496,15 +496,24 @@
newCE = newCE + 
DU.decodedCommentLength(sibling);
} else if (nType === node.ELEMENT_NODE) 
{
var siblingDP = 
DU.getDataParsoid(sibling);
-   if (siblingDP.dsr && 
siblingDP.tsr && siblingDP.dsr[0] <= newCE && e !== null) {
-   // sibling's dsr wont 
change => ltr propagation stops here.
-   break;
-   }
 
if (!siblingDP.dsr) {
siblingDP.dsr = [null, 
null];
}
 
+
+   if (siblingDP.fostered ||
+   (siblingDP.dsr[0] !== 
null && siblingDP.dsr[0] === newCE) ||
+   (siblingDP.dsr[0] !== 
null && siblingDP.tsr && siblingDP.dsr[0] < newCE)) {
+   // sibling is fostered
+   //   => nothing to 
propagate past it
+   // sibling's dsr[0] 
matches what we might propagate
+   //   => nothing will 
change
+   // sibling's dsr value 
came from tsr and it is not outside expected range
+   //   => stop 
propagation so you don't overwrite it
+   break;
+   }
+
// Update and move right
env.log("trace/dsr", function() 
{
var str = " 
CHANGING ce.start of " + sibling.nodeName +
diff --git a/lib/mediawiki.DOMUtils.js b/lib/mediawiki.DOMUtils.js
index aae95af..67cdd4b 100644
--- a/lib/mediawiki.DOMUtils.js
+++ b/lib/mediawiki.DOMUtils.js
@@ -585,8 +585,8 @@
return this.isNodeOfType(n, "meta", type);
},
 
-   // FIXME: What is the convention we should use for constants like this?
-   // Or, is there one for node.js already?
+   // Regep for checking marker metas typeofs representing
+   // transclusion markup or template param markup.
TPL_META_TYPE_REGEXP: 
/(?:^|\s)(mw:(?:Transclusion|Param)(?:\/End)?)(?=$|\s)/,
 
/**
@@ -623,8 +623,7 @@
isTplStartMarkerMeta: function(node) {
if (this.hasNodeName(node, "meta")) {
var t = node.getAttribute("typeof");
-   var tMatch = 
/(?:^|\s)mw:Transclusion(\/[^\s]+)*(?=$|\s)/.test(t);
-   return tMatch && !/\/End(?=$|\s)/.test(t);
+   return this.isTplMetaType(t) && 
!/\/End(?=$|\s)/.test(t);
} else {
return false;
}
@@ -639,7 +638,7 @@
isTplEndMarkerMeta: function(n) {
if (this.hasNodeName(n, "meta")) {
  

[MediaWiki-commits] [Gerrit] config: Add Apertium MT pairs - change (mediawiki...cxserver)

2015-10-18 Thread KartikMistry (Code Review)
KartikMistry has uploaded a new change for review.

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

Change subject: config: Add Apertium MT pairs
..

config: Add Apertium MT pairs

* ar <-> mt
* es <-> it
* is <-> sv
* ro -> es

Bug: T111902
Change-Id: I0d5be030611366dc1cf3918a1d3f9ab3a6daf2c5
---
M config.defaults.js
1 file changed, 7 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/cxserver 
refs/changes/87/247187/1

diff --git a/config.defaults.js b/config.defaults.js
index 81a612a..430f72e 100644
--- a/config.defaults.js
+++ b/config.defaults.js
@@ -49,31 +49,35 @@
Apertium: {
af: [ 'nl' ],
an: [ 'es' ],
+   ar: [ 'mt' ],
ast: [ 'es' ],
bg: [ 'mk' ],
ca: [ 'en', 'es', 'eo', 'fr', 'oc', 'pt', 
'simple' ],
cy: [ 'en', 'simple' ],
en: [ 'ca', 'eo', 'es', 'gl', 'sh' ],
eo: [ 'en', 'simple' ],
-   es: [ 'an', 'ast', 'ca', 'en', 'eo', 'fr', 
'gl', 'oc', 'pt', 'simple' ],
+   es: [ 'an', 'ast', 'ca', 'en', 'eo', 'fr', 
'gl', 'it', 'oc', 'pt', 'simple' ],
eu: [ 'en', 'es', 'simple' ],
fr: [ 'ca', 'eo', 'es' ],
gl: [ 'en', 'es', 'simple' ],
hi: [ 'ur' ],
id: [ 'ms' ],
-   it: [ 'ca' ],
+   is: [ 'sv' ],
+   it: [ 'ca', 'es' ],
kk: [ 'tt' ],
mk: [ 'bg', 'sr' ],
ms: [ 'id' ],
+   mt: [ 'ar' ],
nl: [ 'af' ],
nn: [ 'da', 'nb', 'no' ],
no: [ 'nn' ],
oc: [ 'ca', 'es' ],
pt: [ 'ca', 'es', 'gl' ],
+   ro: [ 'es' ],
sh: [ 'en', 'simple', 'sl' ],
simple: [ 'ca', 'eo', 'es', 'gl', 'sh' ],
sl: [ 'sh', 'sr' ],
-   sv: [ 'da' ],
+   sv: [ 'da', 'is' ],
tt: [ 'kk' ],
ur: [ 'hi' ]
},

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0d5be030611366dc1cf3918a1d3f9ab3a6daf2c5
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/cxserver
Gerrit-Branch: master
Gerrit-Owner: KartikMistry 

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


[MediaWiki-commits] [Gerrit] Cleanup - change (mediawiki...ORES)

2015-10-18 Thread Awight (Code Review)
Awight has uploaded a new change for review.

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

Change subject: Cleanup
..

Cleanup

Change-Id: I4f57a5a06853345f34623f12b06cef06f8c1fd15
---
M includes/Hooks.php
1 file changed, 35 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ORES 
refs/changes/84/247184/1

diff --git a/includes/Hooks.php b/includes/Hooks.php
index 40b9ec2..d463400 100644
--- a/includes/Hooks.php
+++ b/includes/Hooks.php
@@ -12,14 +12,25 @@
 use RCCacheEntry;
 use RecentChange;
 
+/**
+ * TODO:
+ * - Fix mw-core EnhancedChangesList::recentChangesBlockGroup to rollup
+ * extension recentChangesFlags into the top-level grouped line.
+ * - Fix mw-core "old" recent changes view to respect recentChangesFlags.
+ */
 class Hooks {
/**
 * @param DatabaseUpdater $updater
 */
public static function onLoadExtensionSchemaUpdates( DatabaseUpdater 
$updater ) {
$updater->addExtensionTable( 'ores_classification', __DIR__ . 
'/../ores.sql' );
+
+   return true;
}
 
+   /**
+* Ask the ORES server for scores on this recent change
+*/
public static function onRecentChange_save( RecentChange $rc ) {
if ( $rc->getAttribute( 'rc_type' ) === RC_EDIT ) {
$job = new FetchScoreJob( $rc->getTitle(), array(
@@ -27,9 +38,13 @@
) );
JobQueueGroup::singleton()->push( $job );
}
+
+   return true;
}
 
/**
+* Add an ORES filter to the recent changes results
+*
 * @param ChangesListSpecialPage $clsp
 * @param $filters
 */
@@ -38,9 +53,13 @@
'msg' => 'ores-reverted-filter',
'default' => false,
);
+
+   return true;
}
 
/**
+* Pull in ORES score columns during recent changes queries
+*
 * @param $name
 * @param array $tables
 * @param array $fields
@@ -54,15 +73,22 @@
array &$query_options, array &$join_conds, FormOptions $opts
) {
if ( !$opts->getValue( 'hidereverted' ) ) {
-   $tables[] = 'ores_classification';
-   $fields[] = 'ores_probability';
-   $join_conds['ores_classification'] = array( 'LEFT JOIN',
-   'rc_this_oldid = ores_rev AND ores_model = 
\'reverted\' ' .
-   'AND ores_is_predicted = 1 AND ores_class = 
\'true\'' );
+   // Don't bother querying ORES predictions when the 
information is hidden.
+   return;
}
+
+   $tables[] = 'ores_classification';
+   $fields[] = 'ores_probability';
+   $join_conds['ores_classification'] = array( 'LEFT JOIN',
+   'rc_this_oldid = ores_rev AND ores_model = \'reverted\' 
' .
+   'AND ores_is_predicted = 1 AND ores_class = \'true\'' );
+
+   return true;
}
 
/**
+* Label recent changes with ORES scores (for each change in an 
expanded group)
+*
 * @param EnhancedChangesList $ecl
 * @param array $data
 * @param RCCacheEntry[] $block
@@ -81,9 +107,12 @@
$ecl->getOutput()->addModuleStyles( 
'ext.ores.styles' );
}
}
+   return true;
}
 
/**
+* Label recent changes with ORES scores (for top-level ungrouped lines)
+*
 * @param EnhancedChangesList $ecl
 * @param array $data
 * @param RCCacheEntry $rcObj
@@ -101,6 +130,7 @@
$ecl->getOutput()->addModuleStyles( 
'ext.ores.styles' );
}
}
+   return true;
}
 
// FIXME: Repeated code.

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

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

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


[MediaWiki-commits] [Gerrit] Flag reverted risk rows using the recentChangesFlag - change (mediawiki...ORES)

2015-10-18 Thread Awight (Code Review)
Awight has uploaded a new change for review.

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

Change subject: Flag reverted risk rows using the recentChangesFlag
..

Flag reverted risk rows using the recentChangesFlag

This is simpler to maintain and is consistent with other recent changes flags.

Regresses slightly, by not rolling up child "R" flags into the top-level grouped
lines, but I'd prefer to implement that in a general way in mw-core.

Bug: T112856
Change-Id: Ic49a355a2a4a35d78dbd8dc720db2da4de2e628f
---
M README
M extension.json
M i18n/en.json
M i18n/qqq.json
M includes/Hooks.php
M includes/OresScoring.php
6 files changed, 56 insertions(+), 58 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ORES 
refs/changes/85/247185/1

diff --git a/README b/README
index a8f8091..dcbc1d5 100644
--- a/README
+++ b/README
@@ -7,5 +7,4 @@
 the database.
 
 $wgOresRevertTagThresholds - Map from threshold name to score cutoff.  These
-thresholds are used to flag recent changes for potential revert.  Must be
-listed in ascending order (FIXME).
+thresholds are used to flag recent changes for potential revert.
diff --git a/extension.json b/extension.json
index 2542ed7..6c19190 100644
--- a/extension.json
+++ b/extension.json
@@ -63,6 +63,14 @@
"low": 0.8,
"medium": 0.87,
"high": 0.94
+   },
+   "RecentChangesFlags": {
+   "revertedRisk": {
+   "letter": "ores-reverted-letter",
+   "title": "ores-reverted-title",
+   "legend": "ores-reverted-legend",
+   "class": "ores-reverted"
+   }
}
},
"manifest_version": 1
diff --git a/i18n/en.json b/i18n/en.json
index f3d32f5..e378da1 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -6,5 +6,9 @@
"ores-reverted-filter": "$1 revert predictions",
"ores-reverted-high": "High risk, probability of revert $1%",
"ores-reverted-medium": "Medium risk, probability of revert $1%",
-   "ores-reverted-low": "Some risk, probability of revert $1%"
+   "ores-reverted-low": "Some risk, probability of revert $1%",
+
+   "ores-reverted-letter": "R",
+   "ores-reverted-title": "Revert risk",
+   "ores-reverted-legend": "ORES predicts that this change might be at 
risk of revert."
 }
diff --git a/i18n/qqq.json b/i18n/qqq.json
index f06f4d7..c736043 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -4,5 +4,9 @@
"ores-reverted-filter": "Label to toggle filtering of ORES data. 
Parameters:\n* $1 - Action to be performed by toggling.",
"ores-reverted-high": "Title for high probability revert risk. 
Parameters:\n* $1 - Score as a percentage.",
"ores-reverted-medium": "Title for medium probability revert risk. 
Parameters:\n* $1 - Score as a percentage.",
-   "ores-reverted-low": "Title for low probability revert risk. 
Parameters:\n* $1 - Score as a percentage."
+   "ores-reverted-low": "Title for low probability revert risk. 
Parameters:\n* $1 - Score as a percentage.",
+
+   "ores-reverted-letter": "Single letter for tagging recent changes at 
risk of revert.",
+   "ores-reverted-title": "Tooltip for revert risk icon.",
+   "ores-reverted-legend": "Legend for revert risk icon."
 }
diff --git a/includes/Hooks.php b/includes/Hooks.php
index d463400..4e6c2ca 100644
--- a/includes/Hooks.php
+++ b/includes/Hooks.php
@@ -97,16 +97,8 @@
public static function onEnhancedChangesListModifyLineData( 
EnhancedChangesList $ecl, array &$data,
array $block, RCCacheEntry $rcObj
) {
-   $score = $rcObj->getAttribute( 'ores_probability' );
-   if ( $score !== null ) {
-   $type = self::getRevertThreshold( $score );
+   self::processRecentChangesList( $rcObj, $data );
 
-   if ( $type ) {
-   $data[] = self::getScoreHtml( $type, $score );
-
-   $ecl->getOutput()->addModuleStyles( 
'ext.ores.styles' );
-   }
-   }
return true;
}
 
@@ -120,59 +112,24 @@
public static function onEnhancedChangesListModifyBlockLineData( 
EnhancedChangesList $ecl,
array &$data, RCCacheEntry $rcObj
) {
-   $score = $rcObj->getAttribute( 'ores_probability' );
-   if ( $score !== null ) {
-   $type = self::getRevertThreshold( $score );
+   self::processRecentChangesList( $rcObj, $data );
 
-   if ( $type ) {
-   $data[] = self::getScoreHtml( $type, $score );
-
-   $ecl->getOutput()->addModuleStyles( 
'ext.ores.styles' 

[MediaWiki-commits] [Gerrit] New Wikidata Build - 2015-10-18T10:00:01+0000 - change (mediawiki...Wikidata)

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

Change subject: New Wikidata Build - 2015-10-18T10:00:01+
..


New Wikidata Build - 2015-10-18T10:00:01+

Change-Id: Id985b3c4b0ba4ce06178cfedf64c4504690e5775
---
M composer.lock
M 
extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
M 
extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
M vendor/composer/installed.json
4 files changed, 41 insertions(+), 12 deletions(-)

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



diff --git a/composer.lock b/composer.lock
index 74e86e5..c59867e 100644
--- a/composer.lock
+++ b/composer.lock
@@ -1441,12 +1441,12 @@
 "source": {
 "type": "git",
 "url": 
"https://github.com/wikimedia/mediawiki-extensions-Wikibase.git;,
-"reference": "050d3dbf95d5b86c01336428adbb486ec4c5f8fe"
+"reference": "fd5c0d2fe4b729d74e8e4389c5e21be88cf15dbb"
 },
 "dist": {
 "type": "zip",
-"url": 
"https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/050d3dbf95d5b86c01336428adbb486ec4c5f8fe;,
-"reference": "050d3dbf95d5b86c01336428adbb486ec4c5f8fe",
+"url": 
"https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/fd5c0d2fe4b729d74e8e4389c5e21be88cf15dbb;,
+"reference": "fd5c0d2fe4b729d74e8e4389c5e21be88cf15dbb",
 "shasum": ""
 },
 "require": {
@@ -1515,7 +1515,7 @@
 "wikibaserepo",
 "wikidata"
 ],
-"time": "2015-10-17 23:59:12"
+"time": "2015-10-18 01:07:44"
 },
 {
 "name": "wikibase/wikimedia-badges",
diff --git 
a/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
 
b/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
index 4eb0ab4..4f2fa62 100644
--- 
a/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
+++ 
b/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
@@ -30,6 +30,20 @@
);
}
 
+   protected function setUp() {
+   parent::setUp();
+
+   $settings = WikibaseClient::getDefaultInstance()->getSettings();
+   $this->oldAllowDataAccessInUserLanguage = 
$settings->getSetting( 'allowDataAccessInUserLanguage' );
+   $this->setAllowDataAccessInUserLanguage( false );
+   }
+
+   protected function tearDown() {
+   parent::tearDown();
+
+   $this->setAllowDataAccessInUserLanguage( 
$this->oldAllowDataAccessInUserLanguage );
+   }
+
public function testConstructor() {
$engine = Scribunto::newDefaultEngine( array() );
$luaWikibaseLibrary = new Scribunto_LuaWikibaseEntityLibrary( 
$engine );
@@ -102,4 +116,12 @@
return new Scribunto_LuaWikibaseEntityLibrary( $engine );
}
 
+   /**
+* @param bool $value
+*/
+   private function setAllowDataAccessInUserLanguage( $value ) {
+   $settings = WikibaseClient::getDefaultInstance()->getSettings();
+   $settings->setSetting( 'allowDataAccessInUserLanguage', $value 
);
+   }
+
 }
diff --git 
a/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
 
b/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
index 9d3912f..3dd9c13 100644
--- 
a/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
+++ 
b/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
@@ -51,6 +51,7 @@
 
$settings = WikibaseClient::getDefaultInstance()->getSettings();
$this->oldAllowDataAccessInUserLanguage = 
$settings->getSetting( 'allowDataAccessInUserLanguage' );
+   $this->setAllowDataAccessInUserLanguage( false );
}
 
protected function tearDown() {
@@ -254,11 +255,17 @@
$entityArr = $luaWikibaseLibrary->getEntity( 'Q32487' );
 
$snaks = $entityArr[0]['claims']['P342'][1]['qualifiers'];
-   $this->assertSame(
-   array( 'A qualifier Snak, Moar qualifiers' ),
-   $luaWikibaseLibrary->renderSnaks( $snaks )
-   );
+   $expected = array( 'A qualifier Snak, Moar qualifiers' );
+   if ( 

[MediaWiki-commits] [Gerrit] Hygiene: replace Views with custom View - change (apps...wikipedia)

2015-10-18 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review.

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

Change subject: Hygiene: replace Views with custom View
..

Hygiene: replace Views with custom View

Replace Views associated with the lead image and article title with a
custom View, ArticleHeaderView. Additional patches forthcoming to keep
the diffs small and intelligible.

Change-Id: Ide61249cad6a1a2522d2a315dfb7c58e4ce46408
---
M app/src/main/java/org/wikipedia/page/PageFragment.java
M app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
A app/src/main/java/org/wikipedia/views/ArticleHeaderView.java
M app/src/main/res/layout/fragment_page.xml
A app/src/main/res/layout/view_article_header.xml
5 files changed, 122 insertions(+), 41 deletions(-)


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

diff --git a/app/src/main/java/org/wikipedia/page/PageFragment.java 
b/app/src/main/java/org/wikipedia/page/PageFragment.java
index f654917..8bfd426 100755
--- a/app/src/main/java/org/wikipedia/page/PageFragment.java
+++ b/app/src/main/java/org/wikipedia/page/PageFragment.java
@@ -32,6 +32,7 @@
 import org.wikipedia.util.ShareUtils;
 import org.wikipedia.util.ThrowableUtil;
 import org.wikipedia.util.log.L;
+import org.wikipedia.views.ArticleHeaderView;
 import org.wikipedia.views.ObservableWebView;
 import org.wikipedia.views.SwipeRefreshLayoutWithScroll;
 import org.wikipedia.views.WikiDrawerLayout;
@@ -76,6 +77,7 @@
 
 import javax.net.ssl.SSLException;
 
+import static org.wikipedia.views.ViewUtil.findView;
 
 public class PageFragment extends Fragment implements BackPressedHandler {
 public static final int TOC_ACTION_SHOW = 0;
@@ -115,7 +117,7 @@
  */
 private boolean saveOnComplete = false;
 
-private ViewGroup leadSectionContainer;
+private ArticleHeaderView articleHeaderView;
 private LeadImagesHandler leadImagesHandler;
 private SearchBarHideHandler searchBarHideHandler;
 private ObservableWebView webView;
@@ -315,7 +317,7 @@
 @Override
 int getDialogHeight() {
 // could have scrolled up a bit but the page info links must 
still be visible else they couldn't have been clicked
-return webView.getHeight() + webView.getScrollY() - 
leadSectionContainer.getHeight();
+return webView.getHeight() + webView.getScrollY() - 
articleHeaderView.getHeight();
 }
 };
 
@@ -341,8 +343,9 @@
 
 tocHandler = new ToCHandler(getPageActivity(), tocDrawer, bridge);
 
-leadSectionContainer = (ViewGroup) 
getView().findViewById(R.id.page_image_container);
-leadImagesHandler = new LeadImagesHandler(this, bridge, webView, 
leadSectionContainer);
+// TODO: initialize View references in onCreateView().
+articleHeaderView = findView(getView(), R.id.page_header_view);
+leadImagesHandler = new LeadImagesHandler(this, bridge, webView, 
articleHeaderView);
 searchBarHideHandler = getPageActivity().getSearchBarHideHandler();
 searchBarHideHandler.setScrollView(webView);
 
diff --git 
a/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java 
b/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
index 20caea0..6d6e8f2 100755
--- a/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
+++ b/app/src/main/java/org/wikipedia/page/leadimages/LeadImagesHandler.java
@@ -50,11 +50,10 @@
 import org.wikipedia.util.DimenUtil;
 import org.wikipedia.util.GradientUtil;
 import org.wikipedia.util.StringUtil;
+import org.wikipedia.views.ArticleHeaderView;
 import org.wikipedia.views.ObservableWebView;
 import org.wikipedia.views.ConfigurableTextView;
 import org.wikipedia.views.ViewUtil;
-
-import static org.wikipedia.views.ViewUtil.findView;
 
 public class LeadImagesHandler {
 /**
@@ -123,15 +122,15 @@
 public LeadImagesHandler(@NonNull final PageFragment parentFragment,
  @NonNull CommunicationBridge bridge,
  @NonNull ObservableWebView webView,
- @NonNull ViewGroup hidingView) {
+ @NonNull ArticleHeaderView articleHeaderView) {
 this.parentFragment = parentFragment;
-this.imageContainer = hidingView;
+this.imageContainer = articleHeaderView;
 this.bridge = bridge;
 this.webView = webView;
 
-imagePlaceholder = findView(imageContainer, 
R.id.page_image_placeholder);
-image = findView(imageContainer, R.id.page_image);
-pageTitleText = findView(imageContainer, R.id.page_title_text);
+imagePlaceholder = articleHeaderView.getPlaceholder();
+image = articleHeaderView.getImage();
+pageTitleText = articleHeaderView.getText();
 
 pageTitleGradient = 

[MediaWiki-commits] [Gerrit] Add Butter Knife - change (apps...wikipedia)

2015-10-18 Thread Niedzielski (Code Review)
Niedzielski has uploaded a new change for review.

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

Change subject: Add Butter Knife
..

Add Butter Knife

The Android app wants to do more with native Views. A tool that is
helpful in eliminating some of the boilerplate of native Views is Butter
Knife. This dependency increases the size of the dev release apk from
4201830B to 4220733B, about ~18KiB.

To verify that the library is working properly, one usage of it is made
in ArticleHeaderView.

Change-Id: I08af3779dba038f4e349a68f1e600782cda1fc52
---
M app/build.gradle
M app/proguard-rules.pro
A app/src/main/assets/licenses/ButterKnife
M app/src/main/java/org/wikipedia/page/PageFragment.java
M app/src/main/java/org/wikipedia/views/ArticleHeaderView.java
M app/src/main/java/org/wikipedia/views/ViewUtil.java
M app/src/main/res/values/credits.xml
7 files changed, 47 insertions(+), 33 deletions(-)


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

diff --git a/app/build.gradle b/app/build.gradle
index 829b7d9..9cbe2d0 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -126,6 +126,11 @@
 lintOptions {
 disable 'MissingTranslation'
 warning 'NewApi' // until 
https://code.google.com/p/android/issues/detail?id=137195 is released
+disable 'InvalidPackage' // required by Butter Knife
+}
+
+packagingOptions {
+exclude 'META-INF/services/javax.annotation.processing.Processor' // 
required by Butter Knife
 }
 }
 
@@ -157,6 +162,7 @@
 compile 'com.mobsandgeeks:android-saripaar:1.0.3'
 compile 'com.github.chrisbanes.photoview:library:1.2.3'
 compile 'com.github.ryanjohn1:onboarding:1.0.3'
+compile 'com.jakewharton:butterknife:7.0.1'
 compile 'com.jakewharton:disklrucache:2.0.2'
 compile('com.mapbox.mapboxsdk:mapbox-android-sdk:0.7.4@aar') {
 transitive = true
diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro
index 4aeae09..71292cd 100644
--- a/app/proguard-rules.pro
+++ b/app/proguard-rules.pro
@@ -49,6 +49,20 @@
 -keepattributes Exceptions
 # --- /Retrofit ---
 
+# --- Butter Knife ---
+-keep class butterknife.** { *; }
+-dontwarn butterknife.internal.**
+-keep class **$$ViewBinder { *; }
+
+-keepclasseswithmembernames class * {
+@butterknife.* ;
+}
+
+-keepclasseswithmembernames class * {
+@butterknife.* ;
+}
+# --- /Butter Knife ---
+
 # --- Gson ---
 # 
https://github.com/google/gson/blob/master/examples/android-proguard-example/proguard.cfg
 
diff --git a/app/src/main/assets/licenses/ButterKnife 
b/app/src/main/assets/licenses/ButterKnife
new file mode 100644
index 000..5a0cb31
--- /dev/null
+++ b/app/src/main/assets/licenses/ButterKnife
@@ -0,0 +1,13 @@
+Copyright 2013 Jake Wharton
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+   http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
\ No newline at end of file
diff --git a/app/src/main/java/org/wikipedia/page/PageFragment.java 
b/app/src/main/java/org/wikipedia/page/PageFragment.java
index 8bfd426..e2d0b8e 100755
--- a/app/src/main/java/org/wikipedia/page/PageFragment.java
+++ b/app/src/main/java/org/wikipedia/page/PageFragment.java
@@ -77,7 +77,7 @@
 
 import javax.net.ssl.SSLException;
 
-import static org.wikipedia.views.ViewUtil.findView;
+import static butterknife.ButterKnife.findById;
 
 public class PageFragment extends Fragment implements BackPressedHandler {
 public static final int TOC_ACTION_SHOW = 0;
@@ -344,7 +344,7 @@
 tocHandler = new ToCHandler(getPageActivity(), tocDrawer, bridge);
 
 // TODO: initialize View references in onCreateView().
-articleHeaderView = findView(getView(), R.id.page_header_view);
+articleHeaderView = findById(getView(), R.id.page_header_view);
 leadImagesHandler = new LeadImagesHandler(this, bridge, webView, 
articleHeaderView);
 searchBarHideHandler = getPageActivity().getSearchBarHideHandler();
 searchBarHideHandler.setScrollView(webView);
diff --git a/app/src/main/java/org/wikipedia/views/ArticleHeaderView.java 
b/app/src/main/java/org/wikipedia/views/ArticleHeaderView.java
index fbac51c..6f0f8e4 100644
--- a/app/src/main/java/org/wikipedia/views/ArticleHeaderView.java
+++ b/app/src/main/java/org/wikipedia/views/ArticleHeaderView.java
@@ -3,19 +3,20 @@
 import android.annotation.TargetApi;
 import android.content.Context;
 import android.os.Build;
-import android.support.annotation.IdRes;
 import android.util.AttributeSet;
-import 

[MediaWiki-commits] [Gerrit] [WIP] Add proper {{GRAMMAR}} support for Hungarian suffixes ... - change (mediawiki/core)

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

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

Change subject: [WIP] Add proper {{GRAMMAR}} support for Hungarian suffixes + 
articles
..

[WIP] Add proper {{GRAMMAR}} support for Hungarian suffixes + articles

Change-Id: I1d21efec1b4160b9005e6788e0b03dafe2f0749a
---
M languages/classes/LanguageHu.php
M resources/src/mediawiki.language/languages/hu.js
M tests/phpunit/languages/classes/LanguageHuTest.php
A tests/qunit/suites/resources/mediawiki.language/languages/hu.js
4 files changed, 503 insertions(+), 22 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/02/247102/1

diff --git a/languages/classes/LanguageHu.php b/languages/classes/LanguageHu.php
index bbf3b05..6b80faf 100644
--- a/languages/classes/LanguageHu.php
+++ b/languages/classes/LanguageHu.php
@@ -27,26 +27,208 @@
  * @ingroup Language
  */
 class LanguageHu extends Language {
+   protected static $vowelsBack = array( 'a', 'á', 'o', 'ó', 'u', 'ú' );
+   protected static $vowelsFrontIllabial = array( 'e', 'é', 'i', 'í' );
+   protected static $vowelsFrontLabial = array( 'ö', 'ő', 'ü', 'ű' );
+   protected static $digraphs = array( 'cs', 'dz', 'gy', 'ly', 'ny', 'sz', 
'zs' );
 
/**
-* @param string $word
-* @param string $case
+* Callback for {{GRAMMAR:||...}}
+* See other functions for documentation of each type:
+*   - suffix: {@link addSuffix() addSuffix} 
+*   - article: {@link getArticle() getArticle}
+*   - rol/ba/k: {@link addSuffixBC() addSuffixBC}
+*
+* @param string $type
+* @param string $param1
+* @param string $param2
+* @param string $param3
+* @param string $param4
 * @return string
 */
-   function convertGrammar( $word, $case ) {
-   global $wgGrammarForms;
-   if ( isset( $wgGrammarForms[$this->getCode()][$case][$word] ) ) 
{
-   return $wgGrammarForms[$this->getCode()][$case][$word];
+   public function convertGrammar( $type, $param1, $param2 = null, $param3 
= null, $param4 = null ) {
+   switch ( $type ) {
+   case 'suffix':
+   return $this->addSuffix( $param1, $param2, 
$param3, $param4 );
+   case 'article':
+   return $this->getArticle( $param1 );
+   default:
+   return $this->addSuffixBC( $type, $param1 );
+   }
+   }
+
+   /**
+* Combine word (presumably a noun) with suffix according to Hungarian 
grammar.
+* Takes vowel harmony and assimilation into account - for details see:
+*   - https://en.wikipedia.org/wiki/Vowel_harmony#Hungarian
+*   - https://en.wikipedia.org/wiki/Hungarian_phonology#Vowel_harmony
+*   - https://en.wikipedia.org/wiki/Hungarian_noun_phrase#Case_endings
+*
+* This is far from perfect (and some of the rules are not 
algorithmizable at all)
+* but this function should work with the suffixes following 
{{SITENAME}} in the
+* interface messages, unless sitename is some tricky compound or 
foreign word.
+* 
+* The function does three things:
+* 1) select the suffix with matching vowel harmony (first parameter 
should be back,
+*second front, third rounded (labial); second and third might be 
omitted if the
+*suffix has less forms).
+* 2) if the last letter of the word is 'a', 'e' or 'o', change it to 
'á', 'é' or 'ó'
+*respectively.
+* 3) if the first letter of the suffix is 'v', change it according to 
assimilation
+*rules. (This can get complicated if the last letter of the word 
is a
+*digraph/trigraph or a double consonant.)
+* 
+* @param string $word
+* @param string $backSuffix The variant with back vowel (or the 
suffix, if it has
+*   no variants)
+* @param string $frontSuffix The variant with front vowel (illabial 
front vowel if
+*   there are three forms).
+* @param string $labialSuffix The variant with labial front vowel
+* @return string
+*/
+   protected function addSuffix( $word, $backSuffix, $frontSuffix = null, 
$labialSuffix = null ) {
+   $word = trim($word);
+   $backSuffix = trim( $backSuffix );
+   $frontSuffix = trim( $frontSuffix );
+   $labialSuffix = trim( $labialSuffix );
+
+   $vowels = array_merge( static::$vowelsBack, 
static::$vowelsFrontIllabial,
+   static::$vowelsFrontLabial );
+
+   // calculate vowel harmony + get last vowel
+   if ( strtolower( mb_substr( $word, -4 ) ) === 'wiki' ) {
+   

[MediaWiki-commits] [Gerrit] Added initial Debian package for apertium-es-ro - change (operations...apertium-es-ro)

2015-10-18 Thread Alexandros Kosiaris (Code Review)
Alexandros Kosiaris has submitted this change and it was merged.

Change subject: Added initial Debian package for apertium-es-ro
..


Added initial Debian package for apertium-es-ro

Bug: T111902
Change-Id: I88e7afdd547585eb8ac43be92314b3d8e2eca28a
---
A debian/changelog
A debian/compat
A debian/control
A debian/copyright
A debian/docs
A debian/rules
A debian/source/format
A debian/watch
8 files changed, 144 insertions(+), 0 deletions(-)

Approvals:
  Alexandros Kosiaris: Verified; Looks good to me, approved



diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 000..d13b6ff
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,36 @@
+apertium-es-ro (0.7.3~r57551-1) trusty; urgency=low
+
+  [ Tino Didriksen ]
+  * New upstream release
+  * No significant changes in svn since tarball, so taking directly from svn
+  * Re-done packaging to take advantage of debhelper 9
+
+ -- Kartik Mistry   Wed, 07 Oct 2015 21:10:16 +0530
+
+apertium-es-ro (0.7.1-2.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Fix built against apertium 3.1: bump build deps and port configure.ac.
+Fix FTBFS. (Closes: #527785)
+  * Fix apertium-es-ro.trules-ro-es.xml to match (new) DTD: make explicit
+former implicit s.
+
+ -- Stefano Zacchiroli   Wed, 23 Sep 2009 10:39:07 +0200
+
+apertium-es-ro (0.7.1-2) unstable; urgency=low
+
+  * Fixed Build-Depends (Closes: #447243)
+
+ -- Francis Tyers   Mon, 22 Oct 2007 16:28:46 +0100
+
+apertium-es-ro (0.7.1-1) unstable; urgency=low
+
+  * New upstream release (Fixes major bug)
+
+ -- Francis Tyers   Thu, 11 Oct 2007 20:14:37 +0100
+
+apertium-es-ro (0.7.0-1) unstable; urgency=low
+
+  * Initial release (Closes: #445784)
+
+ -- Francis Tyers   Mon, 08 Oct 2007 10:30:29 +0100
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 000..ec63514
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+9
diff --git a/debian/control b/debian/control
new file mode 100644
index 000..340b817
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,26 @@
+Source: apertium-es-ro
+Section: science
+Priority: optional
+Maintainer: Kartik Mistry 
+Build-Depends: apertium (>= 3.3),
+   autotools-dev,
+   debhelper (>= 9),
+   dh-autoreconf,
+   gawk,
+   libapertium3-3.3-dev,
+   liblttoolbox3-3.3-dev (>= 3.3),
+   locales,
+   pkg-config (>= 0.21)
+Standards-Version: 3.9.6
+Homepage: http://apertium.org/
+Vcs-Git: git://anonscm.debian.org/debian-science/packages/apertium-es-ro.git
+Vcs-Browser: 
https://anonscm.debian.org/cgit/debian-science/packages/apertium-es-ro.git
+
+Package: apertium-es-ro
+Architecture: all
+Depends: apertium (>= 3.3), ${misc:Depends}, ${shlibs:Depends}
+Provides: apertium-ro-es
+Conflicts: apertium-ro-es
+Description: Apertium translation data for the Spanish-Romanian pair
+ Data package providing Apertium language resources for translating
+ between the Spanish and Romanian languages.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 000..1e5d106
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,46 @@
+Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Source: http://apertium.org/
+
+Files: *
+Copyright: 2006-2008, Universitat d'Alacant (Transducens group)
+2008, Prompsit Language Engineering
+License: GPL-2
+
+Files: autogen.sh
+Copyright: 2002, Daniel Elstner  
+License: GPL-2
+
+License: GPL-2
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, version 2 of the License
+ .
+ This package is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ GNU General Public License for more details.
+ .
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+ .
+ On Debian systems, the complete text of the GNU General
+ Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
+
+Files: debian/*
+Copyright: 2014, Apertium Project Management Committee 

+License: GPL-2+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 2 of the License, or
+ (at your option) any later version.
+ .
+ This package is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ GNU 

[MediaWiki-commits] [Gerrit] correct grammar in azharauth-notlegitreply [i18n] - change (mediawiki...AzharAuth)

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

Change subject: correct grammar in azharauth-notlegitreply [i18n]
..


correct grammar in azharauth-notlegitreply [i18n]

Fixed interface message as per discussion at:
https://translatewiki.net/w/i.php?oldid=6469708

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

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



diff --git a/i18n/en.json b/i18n/en.json
index e573f81..f53883a 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -9,7 +9,7 @@
"azharauth-login": "Login through $1",
"azharauth-nosuchspecialpageparameter": "No such special page 
parameter.",
"azharauth-notremotelyloggedin": "You're not logged in remotely. Try to 
visit the page again.",
-   "azharauth-notlegitreply": "We can't ensure the authenticity of the 
remote server response, and so can't proceed to login. Try to visit again the 
page, and if you still have the same error, contact your system administrator 
or support resource.",
+   "azharauth-notlegitreply": "We can't ensure the authenticity of the 
remote server response, and so can't proceed to login. Try to visit the page 
again, and if you still have the same error, contact your system administrator 
or support resource.",
"azharauth-cantcreateaccount": "You've been successfully authentified 
by external providers, but we can't match the information with an already 
existing account. Current configuration forbids to create new accounts through 
this authentication methods. You can only use it to sign in.",
"azharauth-technicaldifficulty": "An error occured between our server 
and the external identity provider server. We suggest you try another 
authentication method. If you contact technical support, the error code is $1.",
"azharauth-usercreatereason": "Account automatically created on login 
through $1.",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic1c6a24710644d07e4326b87b9c272de849eabaa
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/AzharAuth
Gerrit-Branch: master
Gerrit-Owner: Gerrit Patch Uploader 
Gerrit-Reviewer: Gerrit Patch Uploader 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Microchip08 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Update i18n messages - change (mediawiki...HitCounters)

2015-10-18 Thread Paladox (Code Review)
Paladox has uploaded a new change for review.

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

Change subject: Update i18n messages
..

Update i18n messages

This adds missing @metadata field was causing npm to fail.

Also update qqq.json message.

Change-Id: I5a8921864e5bd550a49af6c354b8aea6fae73dcb
---
M i18n/af.json
M i18n/avk.json
M i18n/az.json
M i18n/be-tarask.json
M i18n/be.json
M i18n/bm.json
M i18n/br.json
M i18n/bs.json
M i18n/ca.json
M i18n/co.json
M i18n/crh-cyrl.json
M i18n/crh-latn.json
M i18n/cs.json
M i18n/csb.json
M i18n/qqq.json
15 files changed, 43 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/HitCounters 
refs/changes/82/247082/1

diff --git a/i18n/af.json b/i18n/af.json
index b006a5b..36bb308 100644
--- a/i18n/af.json
+++ b/i18n/af.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Gewilde bladsye"
 }
diff --git a/i18n/avk.json b/i18n/avk.json
index fa58f96..8a2349b 100644
--- a/i18n/avk.json
+++ b/i18n/avk.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Tel lorupen bueem"
 }
diff --git a/i18n/az.json b/i18n/az.json
index 1978bec..05637e6 100644
--- a/i18n/az.json
+++ b/i18n/az.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Məşhur səhifələr"
 }
diff --git a/i18n/be-tarask.json b/i18n/be-tarask.json
index 7750eeb..95d89e7 100644
--- a/i18n/be-tarask.json
+++ b/i18n/be-tarask.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Папулярныя старонкі"
 }
diff --git a/i18n/be.json b/i18n/be.json
index 7750eeb..95d89e7 100644
--- a/i18n/be.json
+++ b/i18n/be.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Папулярныя старонкі"
 }
diff --git a/i18n/bm.json b/i18n/bm.json
index 7cbb616..47a7e22 100644
--- a/i18n/bm.json
+++ b/i18n/bm.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Nyɛw les plus consultées"
 }
diff --git a/i18n/br.json b/i18n/br.json
index 54f8c54..a305410 100644
--- a/i18n/br.json
+++ b/i18n/br.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Pajennoù sellet ar muiañ"
 }
diff --git a/i18n/bs.json b/i18n/bs.json
index 635e9af..35515a7 100644
--- a/i18n/bs.json
+++ b/i18n/bs.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Popularne stranice"
 }
diff --git a/i18n/ca.json b/i18n/ca.json
index 52e3bc6..65e017f 100644
--- a/i18n/ca.json
+++ b/i18n/ca.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Pàgines populars"
 }
diff --git a/i18n/co.json b/i18n/co.json
index e8d0388..92956cd 100644
--- a/i18n/co.json
+++ b/i18n/co.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Pagine populare"
 }
diff --git a/i18n/crh-cyrl.json b/i18n/crh-cyrl.json
index d51c605..3d159df 100644
--- a/i18n/crh-cyrl.json
+++ b/i18n/crh-cyrl.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Популяр саифелер"
 }
diff --git a/i18n/crh-latn.json b/i18n/crh-latn.json
index 4824d2d..f404af1 100644
--- a/i18n/crh-latn.json
+++ b/i18n/crh-latn.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Populâr saifeler"
 }
diff --git a/i18n/cs.json b/i18n/cs.json
index 5290b97..8d1fd3c 100644
--- a/i18n/cs.json
+++ b/i18n/cs.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Nejnavštěvovanější stránky"
 }
diff --git a/i18n/csb.json b/i18n/csb.json
index 8bde600..ce34f41 100644
--- a/i18n/csb.json
+++ b/i18n/csb.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Nôwidzalszé starnë"
 }
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 3ef99bd..3c72ab1 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -12,7 +12,7 @@
"hitcounters-page-label": "{{notranslate}} Shows title of pages that 
are the most viewed pages.",
"hitcounters-nviews": "This message is used on [[Special:PopularPages]] 
to say how many times each page has been viewed.\n\nPreceded by the page title, 
like: Page title ($1 views)\n\nParameters:\n* $1 - the number of 
views\n{{Identical|View}}",
"popularpages": "{{doc-special|PopularPages}}",
-   "popularpages-summary": "{{doc-specialpagesummary|popularpages}}",
+   "popularpages-summary": "{{notranslate}} 
{{doc-specialpagesummary|popularpages}}",
"hitcounters-pageinfo-views": "The number of times 

[MediaWiki-commits] [Gerrit] correct grammar in azharauth-notlegitreply [i18n] - change (mediawiki...AzharAuth)

2015-10-18 Thread Gerrit Patch Uploader (Code Review)
Gerrit Patch Uploader has uploaded a new change for review.

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

Change subject: correct grammar in azharauth-notlegitreply [i18n]
..

correct grammar in azharauth-notlegitreply [i18n]

Fixed interface message as per discussion at:
https://translatewiki.net/w/i.php?oldid=6469708

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/AzharAuth 
refs/changes/81/247081/1

diff --git a/i18n/en.json b/i18n/en.json
index e573f81..f53883a 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -9,7 +9,7 @@
"azharauth-login": "Login through $1",
"azharauth-nosuchspecialpageparameter": "No such special page 
parameter.",
"azharauth-notremotelyloggedin": "You're not logged in remotely. Try to 
visit the page again.",
-   "azharauth-notlegitreply": "We can't ensure the authenticity of the 
remote server response, and so can't proceed to login. Try to visit again the 
page, and if you still have the same error, contact your system administrator 
or support resource.",
+   "azharauth-notlegitreply": "We can't ensure the authenticity of the 
remote server response, and so can't proceed to login. Try to visit the page 
again, and if you still have the same error, contact your system administrator 
or support resource.",
"azharauth-cantcreateaccount": "You've been successfully authentified 
by external providers, but we can't match the information with an already 
existing account. Current configuration forbids to create new accounts through 
this authentication methods. You can only use it to sign in.",
"azharauth-technicaldifficulty": "An error occured between our server 
and the external identity provider server. We suggest you try another 
authentication method. If you contact technical support, the error code is $1.",
"azharauth-usercreatereason": "Account automatically created on login 
through $1.",

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic1c6a24710644d07e4326b87b9c272de849eabaa
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/AzharAuth
Gerrit-Branch: master
Gerrit-Owner: Gerrit Patch Uploader 
Gerrit-Reviewer: Microchip08 

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


[MediaWiki-commits] [Gerrit] Added initial Debian package for apertium-es-it - change (operations...apertium-es-it)

2015-10-18 Thread Alexandros Kosiaris (Code Review)
Alexandros Kosiaris has submitted this change and it was merged.

Change subject: Added initial Debian package for apertium-es-it
..


Added initial Debian package for apertium-es-it

Bug: T111902
Change-Id: I8bb7a48124870502e8374e985c1cc8897f404550
---
A debian/changelog
A debian/compat
A debian/control
A debian/copyright
A debian/docs
A debian/rules
A debian/source/format
7 files changed, 108 insertions(+), 0 deletions(-)

Approvals:
  Alexandros Kosiaris: Verified; Looks good to me, approved



diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 000..c83368b
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,7 @@
+apertium-es-it (0.1.0~r51165-1) trusty; urgency=low
+
+  [ Tino Didriksen ]
+  * Initial release
+  * No tarball release, so taking directly from svn
+
+ -- Kartik Mistry   Wed, 07 Oct 2015 20:06:52 +0530
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 000..ec63514
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+9
diff --git a/debian/control b/debian/control
new file mode 100644
index 000..39a56d6
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,26 @@
+Source: apertium-es-it
+Section: science
+Priority: optional
+Maintainer: Kartik Mistry 
+Build-Depends: apertium (>= 3.3),
+   autotools-dev,
+   debhelper (>= 9),
+   dh-autoreconf,
+   gawk,
+   libapertium3-3.3-dev,
+   liblttoolbox3-3.3-dev (>= 3.3),
+   locales,
+   pkg-config (>= 0.21)
+Standards-Version: 3.9.6
+Homepage: http://apertium.org/
+Vcs-Git: git://anonscm.debian.org/debian-science/packages/apertium-es-it.git
+Vcs-Browser: 
https://anonscm.debian.org/cgit/debian-science/packages/apertium-es-it.git
+
+Package: apertium-es-it
+Architecture: all
+Depends: apertium (>= 3.3), ${misc:Depends}, ${shlibs:Depends}
+Provides: apertium-it-es
+Conflicts: apertium-it-es
+Description: Apertium translation data for the Spanish-Italian pair
+ Data package providing Apertium language resources for translating
+ between the Spanish and Italian languages.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 000..a90cb15
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,44 @@
+Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Source: http://apertium.org/
+
+Files: *
+Copyright: 2007-2008, Prompsit Language Engineering S.L. 
(http://www.prompsit.com)
+2008, Universitat d'Alacant, Grup Transducens 
(http://transducens.dlsi.ua.es)
+License: GPL-2
+
+Files: autogen.sh
+Copyright: 2002, Daniel Elstner  
+License: GPL-2
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, version 2 of the License
+ .
+ This package is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ GNU General Public License for more details.
+ .
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+ .
+ On Debian systems, the complete text of the GNU General
+ Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
+
+Files: debian/*
+Copyright: 2014, Apertium Project Management Committee 

+License: GPL-2+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 2 of the License, or
+ (at your option) any later version.
+ .
+ This package is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ GNU General Public License for more details.
+ .
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+ .
+ On Debian systems, the complete text of the GNU General
+ Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
diff --git a/debian/docs b/debian/docs
new file mode 100644
index 000..6f12db5
--- /dev/null
+++ b/debian/docs
@@ -0,0 +1,2 @@
+AUTHORS
+README
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 000..11004df
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,27 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+#
+# This file was originally written by Joey Hess and Craig Small.
+# As a special exception, when this file is copied by dh-make into a
+# dh-make output file, you may use that output file without restriction.
+# This special exception was 

[MediaWiki-commits] [Gerrit] New Wikidata Build - 2015-10-18T10:00:01+0000 - change (mediawiki...Wikidata)

2015-10-18 Thread WikidataBuilder (Code Review)
WikidataBuilder has uploaded a new change for review.

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

Change subject: New Wikidata Build - 2015-10-18T10:00:01+
..

New Wikidata Build - 2015-10-18T10:00:01+

Change-Id: Id985b3c4b0ba4ce06178cfedf64c4504690e5775
---
M composer.lock
M 
extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
M 
extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
M vendor/composer/installed.json
4 files changed, 41 insertions(+), 12 deletions(-)


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

diff --git a/composer.lock b/composer.lock
index 74e86e5..c59867e 100644
--- a/composer.lock
+++ b/composer.lock
@@ -1441,12 +1441,12 @@
 "source": {
 "type": "git",
 "url": 
"https://github.com/wikimedia/mediawiki-extensions-Wikibase.git;,
-"reference": "050d3dbf95d5b86c01336428adbb486ec4c5f8fe"
+"reference": "fd5c0d2fe4b729d74e8e4389c5e21be88cf15dbb"
 },
 "dist": {
 "type": "zip",
-"url": 
"https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/050d3dbf95d5b86c01336428adbb486ec4c5f8fe;,
-"reference": "050d3dbf95d5b86c01336428adbb486ec4c5f8fe",
+"url": 
"https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/fd5c0d2fe4b729d74e8e4389c5e21be88cf15dbb;,
+"reference": "fd5c0d2fe4b729d74e8e4389c5e21be88cf15dbb",
 "shasum": ""
 },
 "require": {
@@ -1515,7 +1515,7 @@
 "wikibaserepo",
 "wikidata"
 ],
-"time": "2015-10-17 23:59:12"
+"time": "2015-10-18 01:07:44"
 },
 {
 "name": "wikibase/wikimedia-badges",
diff --git 
a/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
 
b/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
index 4eb0ab4..4f2fa62 100644
--- 
a/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
+++ 
b/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseEntityLibraryTest.php
@@ -30,6 +30,20 @@
);
}
 
+   protected function setUp() {
+   parent::setUp();
+
+   $settings = WikibaseClient::getDefaultInstance()->getSettings();
+   $this->oldAllowDataAccessInUserLanguage = 
$settings->getSetting( 'allowDataAccessInUserLanguage' );
+   $this->setAllowDataAccessInUserLanguage( false );
+   }
+
+   protected function tearDown() {
+   parent::tearDown();
+
+   $this->setAllowDataAccessInUserLanguage( 
$this->oldAllowDataAccessInUserLanguage );
+   }
+
public function testConstructor() {
$engine = Scribunto::newDefaultEngine( array() );
$luaWikibaseLibrary = new Scribunto_LuaWikibaseEntityLibrary( 
$engine );
@@ -102,4 +116,12 @@
return new Scribunto_LuaWikibaseEntityLibrary( $engine );
}
 
+   /**
+* @param bool $value
+*/
+   private function setAllowDataAccessInUserLanguage( $value ) {
+   $settings = WikibaseClient::getDefaultInstance()->getSettings();
+   $settings->setSetting( 'allowDataAccessInUserLanguage', $value 
);
+   }
+
 }
diff --git 
a/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
 
b/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
index 9d3912f..3dd9c13 100644
--- 
a/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
+++ 
b/extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php
@@ -51,6 +51,7 @@
 
$settings = WikibaseClient::getDefaultInstance()->getSettings();
$this->oldAllowDataAccessInUserLanguage = 
$settings->getSetting( 'allowDataAccessInUserLanguage' );
+   $this->setAllowDataAccessInUserLanguage( false );
}
 
protected function tearDown() {
@@ -254,11 +255,17 @@
$entityArr = $luaWikibaseLibrary->getEntity( 'Q32487' );
 
$snaks = $entityArr[0]['claims']['P342'][1]['qualifiers'];
-   $this->assertSame(
-   array( 'A qualifier Snak, Moar qualifiers' ),
-   $luaWikibaseLibrary->renderSnaks( $snaks )
-   );
+   $expected = array( 'A qualifier 

[MediaWiki-commits] [Gerrit] Add initial Debian package for apertium-is-sv - change (operations...apertium-is-sv)

2015-10-18 Thread Alexandros Kosiaris (Code Review)
Alexandros Kosiaris has submitted this change and it was merged.

Change subject: Add initial Debian package for apertium-is-sv
..


Add initial Debian package for apertium-is-sv

Bug: T111902
Change-Id: I9f20f27dab389d32611ba56a63d7b3d0641be73b
---
A debian/changelog
A debian/compat
A debian/control
A debian/copyright
A debian/docs
A debian/rules
A debian/source/format
A debian/watch
8 files changed, 116 insertions(+), 0 deletions(-)

Approvals:
  Alexandros Kosiaris: Verified; Looks good to me, approved



diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 000..4674c67
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,7 @@
+apertium-is-sv (0.1.0~r56030-1) trusty; urgency=low
+
+  [ Tino Didriksen ]
+  * Initial release
+  * No significant changes in svn since tarball, so taking directly from svn
+
+ -- Kartik Mistry   Thu, 08 Oct 2015 11:51:15 +0530
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 000..ec63514
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+9
diff --git a/debian/control b/debian/control
new file mode 100644
index 000..5202915
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,27 @@
+Source: apertium-is-sv
+Section: science
+Priority: optional
+Maintainer: Kartik Mistry 
+Build-Depends: apertium (>= 3.3),
+   autotools-dev,
+   cg3,
+   debhelper (>= 9),
+   dh-autoreconf,
+   gawk,
+   libapertium3-3.3-dev,
+   liblttoolbox3-3.3-dev (>= 3.3),
+   locales,
+   pkg-config (>= 0.21)
+Standards-Version: 3.9.6
+Homepage: http://apertium.org/
+Vcs-Git: git://anonscm.debian.org/debian-science/packages/apertium-is-sv.git
+Vcs-Browser: 
https://anonscm.debian.org/cgit/debian-science/packages/apertium-is-sv.git
+
+Package: apertium-is-sv
+Architecture: all
+Depends: apertium (>= 3.3), cg3, ${misc:Depends}, ${shlibs:Depends}
+Provides: apertium-sv-is
+Conflicts: apertium-sv-is
+Description: Apertium translation data for the Icelandic-Swedish pair
+ Data package providing Apertium language resources for translating
+ between the Icelandic and Swedish languages.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 000..2593cf2
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,46 @@
+Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Source: http://apertium.org/
+
+Files: *
+Copyright: 2010-2013, Tihomir Rangelov 
+   2011-2013, Francis M. Tyers 
+2013, Kevin Brubeck Unhammer 
+2013, Trond Trosterud 
+License: GPL-2
+
+Files: autogen.sh
+Copyright: 2002, Daniel Elstner  
+License: GPL-2
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, version 2 of the License
+ .
+ This package is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ GNU General Public License for more details.
+ .
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+ .
+ On Debian systems, the complete text of the GNU General
+ Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
+
+Files: debian/*
+Copyright: 2014, Apertium Project Management Committee 

+License: GPL-3+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+ .
+ This package is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ GNU General Public License for more details.
+ .
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+ .
+ On Debian systems, the complete text of the GNU General
+ Public License version 3 can be found in "/usr/share/common-licenses/GPL-3".
diff --git a/debian/docs b/debian/docs
new file mode 100644
index 000..6f83607
--- /dev/null
+++ b/debian/docs
@@ -0,0 +1,3 @@
+AUTHORS
+NEWS
+README
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 000..11004df
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,27 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+#
+# This file was originally written by Joey Hess and Craig Small.
+# As a special 

[MediaWiki-commits] [Gerrit] package_builder: Keep environments updated - change (operations/puppet)

2015-10-18 Thread Alexandros Kosiaris (Code Review)
Alexandros Kosiaris has uploaded a new change for review.

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

Change subject: package_builder: Keep environments updated
..

package_builder: Keep environments updated

create a cron entry per environment to execute cowbuilder --update once
per day to keep the build environments updated, removing the need to
manually either update or clear manually the environment so it can be
recreated

Change-Id: Ie019df522449902e75de14c2d0e2e5496bf5088c
---
M modules/package_builder/manifests/pbuilder_base.pp
1 file changed, 10 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/84/247084/1

diff --git a/modules/package_builder/manifests/pbuilder_base.pp 
b/modules/package_builder/manifests/pbuilder_base.pp
index f3990cd..0cbe591 100644
--- a/modules/package_builder/manifests/pbuilder_base.pp
+++ b/modules/package_builder/manifests/pbuilder_base.pp
@@ -64,6 +64,16 @@
 creates => $cowdir,
 }
 
+$update_command = "/usr/sbin/cowbuilder --update \
+--basepath \"${cowdir}\" \
+"
+
+cron { "cowbuilder_update_${distribution}-${architecture}":
+command => $update_command,
+hour=> 7,
+minute  => 34,
+}
+
 if $distribution_alias {
 file { "${basepath}/base-${distribution_alias}-${architecture}.cow":
 ensure => link,

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie019df522449902e75de14c2d0e2e5496bf5088c
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Alexandros Kosiaris 

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


[MediaWiki-commits] [Gerrit] Update qqq.json i18n message - change (mediawiki...HitCounters)

2015-10-18 Thread Paladox (Code Review)
Paladox has uploaded a new change for review.

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

Change subject: Update qqq.json i18n message
..

Update qqq.json i18n message

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/HitCounters 
refs/changes/86/247086/1

diff --git a/i18n/qqq.json b/i18n/qqq.json
index 3ef99bd..3c72ab1 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -12,7 +12,7 @@
"hitcounters-page-label": "{{notranslate}} Shows title of pages that 
are the most viewed pages.",
"hitcounters-nviews": "This message is used on [[Special:PopularPages]] 
to say how many times each page has been viewed.\n\nPreceded by the page title, 
like: Page title ($1 views)\n\nParameters:\n* $1 - the number of 
views\n{{Identical|View}}",
"popularpages": "{{doc-special|PopularPages}}",
-   "popularpages-summary": "{{doc-specialpagesummary|popularpages}}",
+   "popularpages-summary": "{{notranslate}} 
{{doc-specialpagesummary|popularpages}}",
"hitcounters-pageinfo-views": "The number of times the page has been 
viewed.",
"hitcounters-statistics-header-views": "Used in [[Special:Statistics]]",
"hitcounters-statistics-views-total": "Used in [[Special:Statistics]]",

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: If763f5724b48c69e2b018d7bd7f4eb0bb0fcd1ca
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/HitCounters
Gerrit-Branch: master
Gerrit-Owner: Paladox 

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


[MediaWiki-commits] [Gerrit] Update grunt-jsonlint to 1.0.5 - change (mediawiki...HitCounters)

2015-10-18 Thread Paladox (Code Review)
Paladox has uploaded a new change for review.

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

Change subject: Update grunt-jsonlint to 1.0.5
..

Update grunt-jsonlint to 1.0.5

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/HitCounters 
refs/changes/87/247087/1

diff --git a/package.json b/package.json
index f2c9a2a..8b9186a 100644
--- a/package.json
+++ b/package.json
@@ -6,6 +6,6 @@
 "grunt": "0.4.5",
 "grunt-cli": "0.1.13",
 "grunt-banana-checker": "0.4.0",
-"grunt-jsonlint": "1.0.4"
+"grunt-jsonlint": "1.0.5"
   }
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I448e2cee0719f79061ff14093095e436e748c22e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/HitCounters
Gerrit-Branch: master
Gerrit-Owner: Paladox 

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


[MediaWiki-commits] [Gerrit] Update i18n messages - change (mediawiki...HitCounters)

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

Change subject: Update i18n messages
..


Update i18n messages

This adds missing @metadata field which was causing npm to fail.

https://integration.wikimedia.org/ci/job/npm/32063/console

Change-Id: I5a8921864e5bd550a49af6c354b8aea6fae73dcb
---
M i18n/af.json
M i18n/avk.json
M i18n/az.json
M i18n/be-tarask.json
M i18n/be.json
M i18n/bm.json
M i18n/br.json
M i18n/bs.json
M i18n/ca.json
M i18n/co.json
M i18n/crh-cyrl.json
M i18n/crh-latn.json
M i18n/cs.json
M i18n/csb.json
M i18n/el.json
M i18n/eo.json
M i18n/eu.json
M i18n/fi.json
M i18n/fur.json
M i18n/gan-hans.json
M i18n/gan-hant.json
M i18n/gsw.json
M i18n/he.json
M i18n/hr.json
M i18n/hsb.json
M i18n/hu.json
M i18n/ia.json
M i18n/id.json
M i18n/io.json
M i18n/ka.json
M i18n/kk-arab.json
M i18n/kk-cyrl.json
M i18n/kk-latn.json
M i18n/kn.json
M i18n/ku-latn.json
M i18n/la.json
M i18n/lfn.json
M i18n/li.json
M i18n/lt.json
M i18n/lzh.json
M i18n/mg.json
M i18n/mn.json
M i18n/mr.json
M i18n/ms.json
M i18n/nan.json
M i18n/nb.json
M i18n/ne.json
M i18n/nn.json
M i18n/nov.json
M i18n/pms.json
M i18n/pt-br.json
M i18n/scn.json
M i18n/sl.json
M i18n/sr-ec.json
M i18n/sr-el.json
M i18n/su.json
M i18n/sv.json
M i18n/te.json
M i18n/tl.json
M i18n/to.json
M i18n/ur.json
M i18n/vi.json
M i18n/vro.json
M i18n/wa.json
M i18n/wuu.json
M i18n/yue.json
66 files changed, 198 insertions(+), 0 deletions(-)

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



diff --git a/i18n/af.json b/i18n/af.json
index b006a5b..36bb308 100644
--- a/i18n/af.json
+++ b/i18n/af.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Gewilde bladsye"
 }
diff --git a/i18n/avk.json b/i18n/avk.json
index fa58f96..8a2349b 100644
--- a/i18n/avk.json
+++ b/i18n/avk.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Tel lorupen bueem"
 }
diff --git a/i18n/az.json b/i18n/az.json
index 1978bec..05637e6 100644
--- a/i18n/az.json
+++ b/i18n/az.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Məşhur səhifələr"
 }
diff --git a/i18n/be-tarask.json b/i18n/be-tarask.json
index 7750eeb..95d89e7 100644
--- a/i18n/be-tarask.json
+++ b/i18n/be-tarask.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Папулярныя старонкі"
 }
diff --git a/i18n/be.json b/i18n/be.json
index 7750eeb..95d89e7 100644
--- a/i18n/be.json
+++ b/i18n/be.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Папулярныя старонкі"
 }
diff --git a/i18n/bm.json b/i18n/bm.json
index 7cbb616..47a7e22 100644
--- a/i18n/bm.json
+++ b/i18n/bm.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Nyɛw les plus consultées"
 }
diff --git a/i18n/br.json b/i18n/br.json
index 54f8c54..a305410 100644
--- a/i18n/br.json
+++ b/i18n/br.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Pajennoù sellet ar muiañ"
 }
diff --git a/i18n/bs.json b/i18n/bs.json
index 635e9af..35515a7 100644
--- a/i18n/bs.json
+++ b/i18n/bs.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Popularne stranice"
 }
diff --git a/i18n/ca.json b/i18n/ca.json
index 52e3bc6..65e017f 100644
--- a/i18n/ca.json
+++ b/i18n/ca.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Pàgines populars"
 }
diff --git a/i18n/co.json b/i18n/co.json
index e8d0388..92956cd 100644
--- a/i18n/co.json
+++ b/i18n/co.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Pagine populare"
 }
diff --git a/i18n/crh-cyrl.json b/i18n/crh-cyrl.json
index d51c605..3d159df 100644
--- a/i18n/crh-cyrl.json
+++ b/i18n/crh-cyrl.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Популяр саифелер"
 }
diff --git a/i18n/crh-latn.json b/i18n/crh-latn.json
index 4824d2d..f404af1 100644
--- a/i18n/crh-latn.json
+++ b/i18n/crh-latn.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Populâr saifeler"
 }
diff --git a/i18n/cs.json b/i18n/cs.json
index 5290b97..8d1fd3c 100644
--- a/i18n/cs.json
+++ b/i18n/cs.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": "Nejnavštěvovanější stránky"
 }
diff --git a/i18n/csb.json b/i18n/csb.json
index 8bde600..ce34f41 100644
--- a/i18n/csb.json
+++ b/i18n/csb.json
@@ -1,3 +1,6 @@
 {
+   "@metadata": {
+   "authors": []
+   },
"popularpages": 

[MediaWiki-commits] [Gerrit] Enable four new namespaces at thwikitionary - change (operations/mediawiki-config)

2015-10-18 Thread Luke081515 (Code Review)
Luke081515 has uploaded a new change for review.

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

Change subject: Enable four new namespaces at thwikitionary
..

Enable four new namespaces at thwikitionary

Namespaces Index, Appendix, and talkpages for that added.

Bug: T114458
Change-Id: Ic8bca24fce0b801cac373688d3082f10db38d436
---
M wmf-config/InitialiseSettings.php
1 file changed, 4 insertions(+), 0 deletions(-)


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

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index c0d602a..f4040c1 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -3585,6 +3585,10 @@
),
'+thwiktionary' => array(
'คุยเรื่องWiktionary' => NS_PROJECT_TALK,
+   'ดัชนี' => 100, // T114458
+   'คุยเรื่องดัชนี' => 101, // T114458
+   'ภาคผนวก' => 102, // T114458
+   'คุยเรื่องภาคผนวก' => 103, // T114458
),
'+trwikibooks' => array(
'VK' => NS_PROJECT,

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

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

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


[MediaWiki-commits] [Gerrit] Add support for renaming tables in mediawiki and extensions - change (mediawiki/core)

2015-10-18 Thread Paladox (Code Review)
Paladox has uploaded a new change for review.

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

Change subject: Add support for renaming tables in mediawiki and extensions
..

Add support for renaming tables in mediawiki and extensions

This will be the layout of code

For example

$updater->renameExtensionTable( 'old_table', 'rename_table_to_this',
__DIR__ . '/db_patches/patch-rename-table.sql' );

This is to allow us to rename tables.

Change-Id: Ie570ebe8a1d8cc3290eb509723b1ad692be99080
---
M includes/installer/DatabaseUpdater.php
1 file changed, 69 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/85/247085/1

diff --git a/includes/installer/DatabaseUpdater.php 
b/includes/installer/DatabaseUpdater.php
index 57084cb..6505c1a 100644
--- a/includes/installer/DatabaseUpdater.php
+++ b/includes/installer/DatabaseUpdater.php
@@ -328,6 +328,31 @@
}
 
/**
+* Rename a table on an extension database
+*
+* @since 1.27
+*
+* @param string $tableName The table name
+* @param string $oldIndexName The old table name
+* @param string $newIndexName The new table name
+* @param string $sqlPath The path to the SQL change path
+* @param bool $skipBothIndexExistWarning Whether to warn if both the 
old
+* and the new tables exist. [facultative; by default, false]
+*/
+   public function renameExtensionTable( $oldTableName, $newTableName,
+   $sqlPath, $skipBothIndexExistWarning = false
+   ) {
+   $this->extensionUpdates[] = array(
+   'renameTable',
+   $oldTableName,
+   $newTableName,
+   $skipBothTableExistWarning,
+   $sqlPath,
+   true
+   );
+   }
+
+   /**
 * @since 1.21
 *
 * @param string $tableName The table name
@@ -846,6 +871,50 @@
}
 
/**
+* Rename a table from an existing table
+*
+* @param string $oldTable Old name of the table
+* @param string $newTable New name of the table
+* @param bool $skipBothIndexExistWarning Whether to warn if both the
+* old and the new tables exist.
+* @param string $patch Path to the patch file
+* @param bool $fullpath Whether to treat $patch path as a relative or 
not
+* @return bool False if this was skipped because schema changes are 
skipped
+*/
+   protected function renameTable( $oldIndex, $newIndex,
+   $skipBothIndexExistWarning, $patch, $fullpath = false
+   ) {
+
+   // Second requirement: the new table must be missing
+   if ( $this->db->indexExists( $newTable, __METHOD__ ) ) {
+   $this->output( "...table $newTable already created\n" );
+   if ( !$skipBothIndexExistWarning &&
+   $this->db->indexExists( $oldTable, __METHOD__ )
+   ) {
+   $this->output( "...WARNING: $oldTable still 
exists, despite it has " .
+   "been renamed to $newTable (which also 
exists).\n" .
+   "$oldTable table should be 
manually removed if not needed anymore.\n" );
+   }
+
+   return true;
+   }
+
+   // Third requirement: the old table must exist
+   if ( !$this->db->indexExists( $table, $oldTable, __METHOD__ ) ) 
{
+   $this->output( "...skipping: table $oldTable doesn't 
exist.\n" );
+
+   return true;
+   }
+
+   // Requirements have been satisfied, patch can be applied
+   return $this->applyPatch(
+   $patch,
+   $fullpath,
+   "Renaming table $oldTable to $newTable"
+   );
+   }
+
+   /**
 * If the specified table exists, drop it, or execute the
 * patch if one is provided.
 *

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

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

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


[MediaWiki-commits] [Gerrit] Update qqq.json i18n message - change (mediawiki...HitCounters)

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

Change subject: Update qqq.json i18n message
..


Update qqq.json i18n message

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

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



diff --git a/i18n/qqq.json b/i18n/qqq.json
index 3ef99bd..3c72ab1 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -12,7 +12,7 @@
"hitcounters-page-label": "{{notranslate}} Shows title of pages that 
are the most viewed pages.",
"hitcounters-nviews": "This message is used on [[Special:PopularPages]] 
to say how many times each page has been viewed.\n\nPreceded by the page title, 
like: Page title ($1 views)\n\nParameters:\n* $1 - the number of 
views\n{{Identical|View}}",
"popularpages": "{{doc-special|PopularPages}}",
-   "popularpages-summary": "{{doc-specialpagesummary|popularpages}}",
+   "popularpages-summary": "{{notranslate}} 
{{doc-specialpagesummary|popularpages}}",
"hitcounters-pageinfo-views": "The number of times the page has been 
viewed.",
"hitcounters-statistics-header-views": "Used in [[Special:Statistics]]",
"hitcounters-statistics-views-total": "Used in [[Special:Statistics]]",

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If763f5724b48c69e2b018d7bd7f4eb0bb0fcd1ca
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/HitCounters
Gerrit-Branch: master
Gerrit-Owner: Paladox 
Gerrit-Reviewer: MarkAHershberger 
Gerrit-Reviewer: Peachey88 
Gerrit-Reviewer: Raimond Spekking 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: Umherirrender 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 760d9c1..07b66e4 - change (mediawiki/extensions)

2015-10-18 Thread Umherirrender (Code Review)
Umherirrender has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: 760d9c1..07b66e4
..


Syncronize VisualEditor: 760d9c1..07b66e4

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

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



diff --git a/VisualEditor b/VisualEditor
index 760d9c1..07b66e4 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 760d9c130c191c86ac312021d962a447a3fe49bc
+Subproject commit 07b66e47035a109eef7a9271edfe1397aa59c278

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia333acb1b1f20c325aa00d985a84f8d006d9a5f8
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 
Gerrit-Reviewer: Jenkins-mwext-sync 
Gerrit-Reviewer: Umherirrender 

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


[MediaWiki-commits] [Gerrit] Add missing message. Initial statistic overview. - change (mediawiki...WikiLexicalData)

2015-10-18 Thread Purodha (Code Review)
Purodha has uploaded a new change for review.

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

Change subject: Add missing message. Initial statistic overview.
..

Add missing message. Initial statistic overview.

Change-Id: Ic6aae8c933cc01c50f8d06365b38491bd8aa2ed7
---
M i18n/lexicaldata/en.json
M includes/specials/SpecialOWStatistics.php
2 files changed, 49 insertions(+), 7 deletions(-)


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

diff --git a/i18n/lexicaldata/en.json b/i18n/lexicaldata/en.json
index 08f98b6..9630710 100644
--- a/i18n/lexicaldata/en.json
+++ b/i18n/lexicaldata/en.json
@@ -126,6 +126,7 @@
"ow_ExactMeanings": "Exact meanings",
"ow_Expression": "Expression",
"ow_ExpressionMeanings": "Expression meanings",
+   "ow-syntrans": "Syntrans",
"ow_Expressions": "Expressions",
"ow_IdenticalMeaning": "Identical meaning?",
"ow_IncomingRelations": "Incoming relations",
diff --git a/includes/specials/SpecialOWStatistics.php 
b/includes/specials/SpecialOWStatistics.php
index bb67049..224fcca 100644
--- a/includes/specials/SpecialOWStatistics.php
+++ b/includes/specials/SpecialOWStatistics.php
@@ -20,7 +20,7 @@
. $this->linkHeader ( 
wfMessage('ow_DefinedMeaning')->text(), "dm", $showstat ) . " — "
. $this->linkHeader ( 
wfMessage('ow_Definition')->text(), "def", $showstat ) . " — "
. $this->linkHeader ( 
wfMessage('ow_Expression')->text(), "exp", $showstat ) . " — "
-   . $this->linkHeader ( "Syntrans", "syntrans", $showstat 
) . " — "
+   . $this->linkHeader ( wfMessage('ow-syntrans')->text(), 
"syntrans", $showstat ) . " — "
. $this->linkHeader ( 
wfMessage('ow_Annotation')->text(), "annot", $showstat )
. Html::closeElement('div')
. Html::element('br');
@@ -37,6 +37,8 @@
$wgOut->addHTML ( $this->getExpressionPerLanguage () ) ;
} elseif ( $showstat == 'annot' ) {
$wgOut->addHTML ( $this->getAnnotationStats () ) ;
+   } else {
+   $wgOut->addHTML ( $this->getFigures () ) ;
}
}
 
@@ -64,10 +66,52 @@
return $nbdm;
}
 
+   function getFigures ( ) {
+   $dc = wdGetDataSetContext();
+   $dbr = wfGetDB( DB_SLAVE );
+   $output = "";
+
+   $nbsyntrans = $dbr->selectField(
+   array( "{$dc}_syntrans" ),
+   'COUNT(DISTINCT syntrans_sid)',
+   array( 'remove_transaction_id' => null ),
+   __METHOD__
+   );
+   $nbdef = $dbr->selectField(
+   array( "{$dc}_defined_meaning" ),
+   'COUNT(DISTINCT defined_meaning_id)',
+   array( 'remove_transaction_id' => null ),
+   __METHOD__
+   );
+   $nbexp = $dbr->selectField(
+   "{$dc}_expression",
+   'COUNT(DISTINCT expression_id)',
+   array( 'remove_transaction_id' => null ),
+   __METHOD__
+   );
+   $nblang = $dbr->selectField(
+   array( "{$dc}_expression" ),
+   'COUNT(DISTINCT language_id)',
+   array( 'remove_transaction_id' => null ),
+   __METHOD__
+   );
+   $nbdm = $this->getNumberOfDM() ;
+
+   $output .= Html::openElement( 'table', array('class' => 
'owstatbig') );
+#  $output .= $this->addTableRow( array( 
wfMessage('ow_Annotation')->text(), $nbanot ) );
+   $output .= $this->addTableRow( array( 
wfMessage('ow-syntrans')->text(), $nbsyntrans ) );
+   $output .= $this->addTableRow( array( 
wfMessage('ow_Definition')->text(), $nbdef ) );
+   $output .= $this->addTableRow( array( 
wfMessage('ow_Expression')->text(), $nbexp ) );
+   $output .= $this->addTableRow( array( 
wfMessage('ow_DefinedMeaning')->text(), $nbdm ) );
+   $output .= $this->addTableRow( array( 
wfMessage('ow_Language')->text(), $nblang ) );
+   $output .= Html::closeElement( 'table' );
+
+   return $output ;
+   }
+
function getDefinedMeaningPerLanguage () {
$dc = wdGetDataSetContext();
$dbr = wfGetDB( DB_SLAVE );
-   global $wgUploadPath ;
$output = "";
 
$languageNames = getOwLanguageNames();
@@ -118,7 +162,6 @@
function getDefinitionPerLanguage () {
$dc = wdGetDataSetContext();
$dbr = wfGetDB( 

[MediaWiki-commits] [Gerrit] getNodeAndOffset: handle slugless nodes with zero DM length - change (VisualEditor/VisualEditor)

2015-10-18 Thread Divec (Code Review)
Divec has uploaded a new change for review.

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

Change subject: getNodeAndOffset: handle slugless nodes with zero DM length
..

getNodeAndOffset: handle slugless nodes with zero DM length

Change Iea6656882293e8e3cc78df87c31afe58ff59c7e8 fixed getNodeAndOffset in
slugless nodes with zero DM length, by re-rendering the nodes to add slugs.
However re-rendering can close IME candidate windows and prematurely commit
text, so we should avoid such a call inside an apparently pure function.

This change fixes the getNodeAndOffset logic so that an answer is given for
slugless nodes with zero DM length.

ve.ce.Document getNodeAndOffset:
* For a DOM leaf at the offset with DM length 0, return the position just inside
* Back out the call to renderContents, for IME stability

ve.ce.Document.test.js:
* Add getNodeAndOffset tests that simulate the browser removing all content

Bug: T110378
Bug: T115811
Change-Id: I82f1fcf707746ad06bc9e8ce4027a32ecb1812b1
---
M src/ce/ve.ce.BranchNode.js
M src/ce/ve.ce.Document.js
M tests/ce/ve.ce.Document.test.js
3 files changed, 73 insertions(+), 28 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/90/247090/1

diff --git a/src/ce/ve.ce.BranchNode.js b/src/ce/ve.ce.BranchNode.js
index 05de7d3..f107bc5 100644
--- a/src/ce/ve.ce.BranchNode.js
+++ b/src/ce/ve.ce.BranchNode.js
@@ -251,6 +251,20 @@
 };
 
 /**
+ * Remove all slugs in this branch
+ */
+ve.ce.BranchNode.prototype.removeSlugs = function () {
+   var i;
+   // Remove all slugs in this branch
+   for ( i in this.slugNodes ) {
+   if ( this.slugNodes[ i ] !== undefined && this.slugNodes[ i 
].parentNode ) {
+   this.slugNodes[ i ].parentNode.removeChild( 
this.slugNodes[ i ] );
+   }
+   delete this.slugNodes[ i ];
+   }
+};
+
+/**
  * Setup slugs where needed.
  *
  * Existing slugs will be removed before new ones are added.
@@ -261,13 +275,7 @@
var i, slugTemplate, slugNode, child, slugButton,
doc = this.getElementDocument();
 
-   // Remove all slugs in this branch
-   for ( i in this.slugNodes ) {
-   if ( this.slugNodes[ i ] !== undefined && this.slugNodes[ i 
].parentNode ) {
-   this.slugNodes[ i ].parentNode.removeChild( 
this.slugNodes[ i ] );
-   }
-   delete this.slugNodes[ i ];
-   }
+   this.removeSlugs();
 
if ( isBlock ) {
slugTemplate = ve.ce.BranchNode.blockSlugTemplate;
diff --git a/src/ce/ve.ce.Document.js b/src/ce/ve.ce.Document.js
index 16b72eb..09ff378 100644
--- a/src/ce/ve.ce.Document.js
+++ b/src/ce/ve.ce.Document.js
@@ -152,27 +152,28 @@
  * @return {number} return.offset location offset within the node
  */
 ve.ce.Document.prototype.getNodeAndOffsetUnadjustedForUnicorn = function ( 
offset ) {
-   var node, startOffset, current, stack, item, $item, length, model, slug,
-   countedNodes = [];
-
-   // Ask for the node first, so we can ask it to render, because that 
fixes up various things
-   // and _creates_ the slug if necessary.
-   node = this.getBranchNodeFromOffset( offset );
-   if ( node instanceof ve.ce.ContentBranchNode ) {
-   node.renderContents();
-   }
-
-   slug = this.getSlugAtOffset( offset );
+   var node, startOffset, current, stack, item, $item, length, model,
+   countedNodes = [],
+   slug = this.getSlugAtOffset( offset );
 
// If we're a block slug, or an empty inline slug, return its location
// Start at the current branch node; get its start offset
-   // Walk the tree, summing offsets until the sum reaches the desired 
offset value
-   // - If a whole branch is entirely before the offset, then don't 
descend into it
-   // - If the desired offset is in a text node, return that node and the 
correct remainder offset
-   // - If the desired offset is between an empty unicorn pair, return 
inter-unicorn location
-   // - Assume no other outcome is possible (because we would be inside a 
slug)
+   // Walk the tree, summing offsets until the sum reaches the desired 
offset value.
+   // If the desired offset:
+   // - is after a ve-ce-branchNode/ve-ce-leafNode: skip the node
+   // - is inside a ve-ce-branchNode/ve-ce-leafNode: descend into node
+   // - is in a text node: return that node and the correct remainder 
offset
+   // - is between an empty unicorn pair: return inter-unicorn location
+   // - is in a non-branchNode/leafNode DOM element: return first 
maximally deep such element
+   // Otherwise, signal an error
+
+   // Unfortunately, there is no way to avoid slugless block nodes with no 
DM length:
+   // an IME can remove all the text from a node at a time when it is 
unsafe 

[MediaWiki-commits] [Gerrit] Update the privacy policy - change (wikimedia/iegreview)

2015-10-18 Thread Niharika29 (Code Review)
Niharika29 has uploaded a new change for review.

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

Change subject: Update the privacy policy
..

Update the privacy policy

Change-Id: I38f8c46ba32a3d2c76c7be1a019c924135eafba7
---
M data/i18n/en.json
M data/i18n/qqq.json
M data/templates/privacy.html
3 files changed, 177 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/iegreview 
refs/changes/91/247091/1

diff --git a/data/i18n/en.json b/data/i18n/en.json
index da16580..aee4326 100644
--- a/data/i18n/en.json
+++ b/data/i18n/en.json
@@ -34,7 +34,6 @@
"credits-page-logo": "The https://commons.wikimedia.org/wiki/File%3AIEG_glasses_lightblue.png\;>glasses
 logo is by Wikimedia Commons user Heatherawalls and used under the 
Creative Commons CC0 1.0 Universal Public Domain Dedication license.",
 
"privacy": "Privacy",
-   "privacy-page": "All personal information will be held strictly 
confidential by the grants reviewers and the http://wikimediafoundation.org\;>Wikimedia Foundation, in accordance 
to the Wikimedia Foundation http://wikimediafoundation.org/wiki/Privacy_policy\;>privacy 
policy.",
 
"footer-credits": "credits",
"footer-privacy": "privacy",
diff --git a/data/i18n/qqq.json b/data/i18n/qqq.json
index 272ce4c..f649f95 100644
--- a/data/i18n/qqq.json
+++ b/data/i18n/qqq.json
@@ -120,7 +120,6 @@
"password": "Input label, followed by text 
box.\n{{Identical|Password}}",
"password-username": "Input label, followed by authenticated user's 
username.\n{{Identical|Username}}",
"privacy": "Privacy page title",
-   "privacy-page": "Privacy policy page content.",
"proposal-summary": "Section title",
"proposals-edit-amount": "Input label, followed by text box.",
"proposals-edit-amount-placeholder": "Placeholder for input text box",
diff --git a/data/templates/privacy.html b/data/templates/privacy.html
index ce6e2ad..058da84 100644
--- a/data/templates/privacy.html
+++ b/data/templates/privacy.html
@@ -8,8 +8,184 @@
 
   
 {{ 'privacy'|message }}
-{{ 'privacy-page'|message|raw }}
   
+  
+   Welcome! 
+   Welcome to the Wikimedia Foundation’s grant review application. The 
grant review app is a
+   flexible scoring system for grant administrators and volunteers to 
review and score grant proposals.
+
+  Definitions
+
+   For the sake of clarity, “WMF”, “us”, “we”, and “our” refer to the http://www.wikimediafoundation.org/;>Wikimedia Foundation;
+   the “app” refers to the grant review application, and the “app privacy 
policy” refers to this document.
+   
+   “Personal information” means information you provide us or information 
we collect from you
+   that could be used to personally identify you. To be clear, while we do 
not necessarily collect
+   all of the following types of information, we consider at least the 
following to be
+   “personal information” if it is otherwise nonpublic and can be used to 
identify you:
+   (a) your real name, address, phone number, email address, password, 
identification number on
+   government-issued ID, IP address, user-agent information, credit card 
number; (b) when associated
+   with one of the items in subsection (a), any sensitive data such as 
date of birth, gender,
+   sexual orientation, racial or ethnic origins, marital or familial 
status, medical conditions or disabilities,
+   political affiliation, and religion; and (c) any of the items in 
subsections (a) or (b) when associated
+   with your user account.
+
+  Important Information
+
+   By using the app, you agree to the terms of this grant review app 
privacy policy and the WMF https://wikimediafoundation.org/wiki/Terms_of_Use;>terms of use.
+   Furthermore, by using the app, you consent to the collection, transfer, 
processing, storage, disclosure,
+   and use of your information as described in this app privacy policy.
+   
+   If you do not agree to these terms, you may not use this app.
+   
+   If you have any questions or suggestions about the app privacy policy 
or WMF terms of use, please https://wikimediafoundation.org/wiki/Contact_us;>contact us.
+
+  What This Policy Covers
+
+   This app privacy policy applies to our collection and handling of 
information about you that we
+   receive as a result of your use of the app. As a http://www.mediawiki.org/wiki/Wikimedia_Labs;>Wikimedia Labs project, 
the grant review app is
+   http://wikimediafoundation.org/wiki/Privacy_policy#What_This_Privacy_Policy_Does_.26_Doesn.27t_Cover;>not
 covered by the general http://wikimediafoundation.org/wiki/Privacy_policy;>Wikimedia Privacy 
Policy. This app privacy policy only applies to use
+   of this Wikimedia grant review application and does not cover use of 
any other Wikimedia projects,
+   sites, or services.

[MediaWiki-commits] [Gerrit] Rename two namespaces at bswiki - change (operations/mediawiki-config)

2015-10-18 Thread Luke081515 (Code Review)
Luke081515 has uploaded a new change for review.

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

Change subject: Rename two namespaces at bswiki
..

Rename two namespaces at bswiki

Rename NS_PROJECT_TALK and NS_USER_TALK at bswiki

Bug: T115812
Change-Id: If5fa59351c5a0e6a56976aa9bcc813f07fae12f1
---
M wmf-config/InitialiseSettings.php
1 file changed, 2 insertions(+), 0 deletions(-)


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

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index c0d602a..c4cda10 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -2687,6 +2687,8 @@
),
'+bswiki' => array(
'Portal_talk' => 101, // T39226
+   'Razgovor s Wikipedijom' => NS_PROJECT_TALK, // T115812
+   'Razgovor s korisnikom' => NS_USER_TALK, // T115812
),
'+cawikisource' => array(
'Author' => 106,

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

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

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


[MediaWiki-commits] [Gerrit] Add betawikipedia and betawikidata family files - change (pywikibot/core)

2015-10-18 Thread Ladsgroup (Code Review)
Ladsgroup has uploaded a new change for review.

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

Change subject: Add betawikipedia and betawikidata family files
..

Add betawikipedia and betawikidata family files

Having them makes testing and writing tests much easier.

Change-Id: Ibe7be229d7b8d9f8a67e9d4a5733df5b9b2693d8
---
A pywikibot/families/betawikidata_family.py
A pywikibot/families/betawikipedia_family.py
2 files changed, 66 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/94/247094/1

diff --git a/pywikibot/families/betawikidata_family.py 
b/pywikibot/families/betawikidata_family.py
new file mode 100644
index 000..024c792
--- /dev/null
+++ b/pywikibot/families/betawikidata_family.py
@@ -0,0 +1,25 @@
+# -*- coding: utf-8 -*-
+"""Family module for Beta Wikidata."""
+from __future__ import absolute_import, unicode_literals
+
+__version__ = '$Id$'
+
+from pywikibot import family
+
+
+class Family(family.Family):
+def __init__(self):
+family.Family.__init__(self)
+self.name = 'betawikidata'
+self.langs = {
+'betawikidata': 'wikidata.beta.wmflabs.org',
+}
+
+def scriptpath(self, code):
+return '/w'
+
+def protocol(self, code):
+return 'http'
+
+def shared_data_repository(self, code, transcluded=False):
+return (code, self.name)
diff --git a/pywikibot/families/betawikipedia_family.py 
b/pywikibot/families/betawikipedia_family.py
new file mode 100644
index 000..68b709b
--- /dev/null
+++ b/pywikibot/families/betawikipedia_family.py
@@ -0,0 +1,41 @@
+# -*- coding: utf-8 -*-
+"""Family module for Beta Wikipedia."""
+from __future__ import absolute_import, unicode_literals
+
+__version__ = '$Id$'
+
+from pywikibot import family
+
+
+class Family(family.Family):
+def __init__(self):
+family.Family.__init__(self)
+self.name = 'betawikipedia'
+self.langs = {
+'ru': 'ru.wikipedia.beta.wmflabs.org',
+'uk': 'uk.wikipedia.beta.wmflabs.org',
+'es': 'es.wikipedia.beta.wmflabs.org',
+'zh': 'zh.wikipedia.beta.wmflabs.org',
+'he': 'he.wikipedia.beta.wmflabs.org',
+'hi': 'hi.wikipedia.beta.wmflabs.org',
+'ca': 'ca.wikipedia.beta.wmflabs.org',
+'fa': 'fa.wikipedia.beta.wmflabs.org',
+'en': 'en.wikipedia.beta.wmflabs.org',
+'en': 'simple.wikipedia.beta.wmflabs.org',
+'ja': 'ja.wikipedia.beta.wmflabs.org',
+'ar': 'ar.wikipedia.beta.wmflabs.org',
+'de': 'de.wikipedia.beta.wmflabs.org',
+'ko': 'ko.wikipedia.beta.wmflabs.org',
+'eo': 'eo.wikipedia.beta.wmflabs.org',
+'aa': 'aa.wikipedia.beta.wmflabs.org',
+'sq': 'sq.wikipedia.beta.wmflabs.org',
+}
+
+def scriptpath(self, code):
+return '/w'
+
+def protocol(self, code):
+return 'http'
+
+def shared_data_repository(self, code, transcluded=False):
+return ('betawikidata', 'betawikidata')

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

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

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


[MediaWiki-commits] [Gerrit] SelectFileWidget: Show image preview - change (oojs/ui)

2015-10-18 Thread Esanders (Code Review)
Esanders has uploaded a new change for review.

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

Change subject: SelectFileWidget: Show image preview
..

SelectFileWidget: Show image preview

Change-Id: Ieedc9c6337e459d3a2042fcc34455086d07c1929
---
M src/styles/widgets/SelectFileWidget.less
M src/themes/apex/widgets.less
M src/themes/mediawiki/widgets.less
M src/widgets/SelectFileWidget.js
4 files changed, 124 insertions(+), 26 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/ui refs/changes/92/247092/1

diff --git a/src/styles/widgets/SelectFileWidget.less 
b/src/styles/widgets/SelectFileWidget.less
index 64bbd9d..c56d86a 100644
--- a/src/styles/widgets/SelectFileWidget.less
+++ b/src/styles/widgets/SelectFileWidget.less
@@ -2,12 +2,12 @@
 
 .oo-ui-selectFileWidget {
display: inline-block;
-   vertical-align: middle;
+
+   .oo-ui-actionFieldLayout-button {
+   vertical-align: top;
+   }
 
&-selectButton {
-   display: table-cell;
-   vertical-align: middle;
-
> .oo-ui-buttonElement-button {
position: relative;
overflow: hidden;
@@ -39,12 +39,15 @@
 
&-info {
width: 100%;
-   display: table-cell;
-   vertical-align: middle;
position: relative;
overflow: hidden;
+   cursor: default;
 
.oo-ui-box-sizing(border-box);
+
+   > .oo-ui-selectFileWidget-preview > img {
+   display: block;
+   }
 
> .oo-ui-selectFileWidget-label {
position: absolute;
@@ -67,6 +70,9 @@
 
> .oo-ui-selectFileWidget-clearButton {
z-index: 2;
+   > .oo-ui-buttonElement-button {
+   display: block;
+   }
}
}
 
diff --git a/src/themes/apex/widgets.less b/src/themes/apex/widgets.less
index 49bc2a7..19e56bc 100644
--- a/src/themes/apex/widgets.less
+++ b/src/themes/apex/widgets.less
@@ -172,6 +172,7 @@
 .theme-oo-ui-selectFileWidget () {
width: 100%;
max-width: 50em;
+   @select-file-preview-size: 6em;
 
.oo-ui-inline-spacing(0.5em);
 
@@ -182,9 +183,18 @@
}
 
&-info {
-   height: 2.4em;
+   min-height: 2.4em;
border: 1px solid rgba(0,0,0,0.1);
border-radius: 0.25em;
+   padding: 0;
+
+   > .oo-ui-selectFileWidget-preview {
+   margin: 0.5em;
+   & > img {
+   max-width: @select-file-preview-size;
+   max-height: @select-file-preview-size;
+   }
+   }
 
> .oo-ui-indicatorElement-indicator {
right: 0;
@@ -233,6 +243,12 @@
}
}
 
+   &-info-previewed {
+   > .oo-ui-selectFileWidget-label {
+   left: 7em;
+   }
+   }
+
&.oo-ui-widget-disabled {
.oo-ui-selectFileWidget-info {
color: #ccc;
@@ -253,9 +269,17 @@
}
}
 
-   &.oo-ui-iconElement .oo-ui-selectFileWidget-info {
+   &.oo-ui-iconElement .oo-ui-selectFileWidget-info-previewed {
.oo-ui-selectFileWidget-label {
-   left: @icon-size + 0.6em;
+   left: @icon-size + 0.5em + @select-file-preview-size + 
1em;
+   }
+
+   > .oo-ui-iconElement-icon {
+   margin-left: @select-file-preview-size + 1em;
+   }
+
+   > .oo-ui-selectFileWidget-preview {
+   margin-left: 0.5em;
}
}
 
diff --git a/src/themes/mediawiki/widgets.less 
b/src/themes/mediawiki/widgets.less
index c9ea2b3..9b0a93f 100644
--- a/src/themes/mediawiki/widgets.less
+++ b/src/themes/mediawiki/widgets.less
@@ -174,6 +174,7 @@
 .theme-oo-ui-selectFileWidget () {
width: 100%;
max-width: 50em;
+   @select-file-preview-size: 6em;
 
.oo-ui-inline-spacing(0.5em);
 
@@ -184,9 +185,18 @@
}
 
&-info {
-   height: 2.4em;
+   min-height: 2.4em;
border: 1px solid #ccc;
border-radius: 0.1em;
+   padding: 0;
+
+   > .oo-ui-selectFileWidget-preview {
+   margin: 0.5em;
+   & > img {
+   max-width: @select-file-preview-size;
+   max-height: @select-file-preview-size;
+   }
+   }
 
> .oo-ui-indicatorElement-indicator {
right: 0;
@@ -235,6 +245,12 

[MediaWiki-commits] [Gerrit] adds sparql bulk query and output write script adds daily so... - change (wikidata...dashboard)

2015-10-18 Thread Christopher Johnson (WMDE) (Code Review)
Christopher Johnson (WMDE) has submitted this change and it was merged.

Change subject: adds sparql bulk query and output write script adds daily 
social metrics adds datavalues count table to home
..


adds sparql bulk query and output write script
adds daily social metrics
adds datavalues count table to home

Change-Id: I5662bbab52e26d39faa34968c2f33412fdd63c20
---
M README.md
M assets/metrics.owl
M assets/rdfq.xml
A bulk_sparql.R
A bulk_sparql.Rout
M config.R
D data/Wikidata community engagement tracking - Sheet1.ods
A data/sparql/spql1.tsv
A data/sparql/spql10.tsv
A data/sparql/spql11.tsv
A data/sparql/spql12.tsv
A data/sparql/spql13.tsv
A data/sparql/spql14.tsv
A data/sparql/spql15.tsv
A data/sparql/spql16.tsv
A data/sparql/spql17.tsv
A data/sparql/spql18.tsv
A data/sparql/spql19.tsv
A data/sparql/spql2.tsv
A data/sparql/spql20.tsv
A data/sparql/spql21.tsv
A data/sparql/spql3.tsv
A data/sparql/spql4.tsv
A data/sparql/spql5.tsv
A data/sparql/spql6.tsv
A data/sparql/spql7.tsv
A data/sparql/spql8.tsv
A data/sparql/spql9.tsv
D data/wikidata-todo-stats-2015-09-15.json
M model.R
M output/server-RDFQ.R
M output/server-engagement.R
M output/server-home.R
M output/server-recent.R
M server.R
M ui.R
M utils.R
37 files changed, 272 insertions(+), 52 deletions(-)

Approvals:
  Christopher Johnson (WMDE): Verified; Looks good to me, approved




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

Gerrit-MessageType: merged
Gerrit-Change-Id: I5662bbab52e26d39faa34968c2f33412fdd63c20
Gerrit-PatchSet: 2
Gerrit-Project: wikidata/analytics/dashboard
Gerrit-Branch: master
Gerrit-Owner: Christopher Johnson (WMDE) 
Gerrit-Reviewer: Christopher Johnson (WMDE) 

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


[MediaWiki-commits] [Gerrit] Add extension.json, remove php entry point - change (mediawiki...WikimediaIncubator)

2015-10-18 Thread Paladox (Code Review)
Paladox has uploaded a new change for review.

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

Change subject: Add extension.json, remove php entry point
..

Add extension.json, remove php entry point

Change-Id: I3bb7e0f6b24ec94c6e45192804202e0e9349fb75
---
M WikimediaIncubator.class.php
A extension.json
2 files changed, 215 insertions(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikimediaIncubator 
refs/changes/95/247095/1

diff --git a/WikimediaIncubator.class.php b/WikimediaIncubator.class.php
index c7290cb..38cac87 100644
--- a/WikimediaIncubator.class.php
+++ b/WikimediaIncubator.class.php
@@ -11,6 +11,22 @@
 
 class WikimediaIncubator {
 
+   public static function registerExtension() {
+   global $wgGroupPermissions;
+   /* Test wiki admin user group */
+   $wgGroupPermissions['test-sysop']['delete'] = true;
+   $wgGroupPermissions['test-sysop']['undelete'] = true;
+   $wgGroupPermissions['test-sysop']['deletedhistory'] = true;
+   $wgGroupPermissions['test-sysop']['block'] = true;
+   $wgGroupPermissions['test-sysop']['blockemail'] = true;
+   $wgGroupPermissions['test-sysop']['rollback'] = true;
+   $wgGroupPermissions['test-sysop']['suppressredirect'] = true;
+   $wgGroupPermissions['test-sysop']['autopatrol'] = true;
+
+   $wgGroupPermissions['*']['viewuserlang'] = false;
+   $wgGroupPermissions['sysop']['viewuserlang'] = true;
+   }
+
/**
 * Add default preference
 * @param $defOpt Array
diff --git a/extension.json b/extension.json
new file mode 100644
index 000..0f3a13d
--- /dev/null
+++ b/extension.json
@@ -0,0 +1,199 @@
+{
+   "name": "Wikimedia Incubator",
+   "version": "5.3.0",
+   "author": [
+   "SPQRobin",
+   "Hydriz"
+   ],
+   "url": "https://www.mediawiki.org/wiki/Extension:WikimediaIncubator;,
+   "descriptionmsg": "wminc-desc",
+   "type": "other",
+   "callback": "WikimediaIncubator::registerExtension",
+   "AddGroups": {
+   "bureaucrat": [
+   "test-sysop"
+   ]
+   },
+   "RemoveGroups": {
+   "bureaucrat": [
+   "test-sysop"
+   ]
+   },
+   "AvailableRights": [
+   "viewuserlang"
+   ],
+   "SpecialPages": {
+   "ViewUserLang": "SpecialViewUserLang",
+   "MyMainPage": "SpecialMyMainPage",
+   "RandomByTest": "SpecialRandomByTest",
+   "SearchWiki": "SpecialSearchWiki",
+   "IncubatorFirstSteps": "SpecialIncubatorFirstSteps"
+   },
+   "MessagesDirs": {
+   "WikimediaIncubator": [
+   "i18n"
+   ]
+   },
+   "ExtensionMessagesFiles": {
+   "WikimediaIncubatorAlias": "WikimediaIncubator.alias.php",
+   "WikimediaIncubatorMagic": "WikimediaIncubator.i18n.magic.php"
+   },
+   "AutoloadClasses": {
+   "SpecialViewUserLang": "SpecialViewUserLang.php",
+   "WikimediaIncubator": "WikimediaIncubator.class.php",
+   "SpecialMyMainPage": "SpecialMyMainPage.php",
+   "TestWikiRC": "TestWikiRC.php",
+   "AutoTestWiki": "CreateAccountTestWiki.php",
+   "SpecialRandomByTest": "SpecialRandomByTest.php",
+   "InfoPage": "InfoPage.php",
+   "ListUsersTestWiki": "ListUsersTestWiki.php",
+   "SpecialSearchWiki": "SpecialSearchWiki.php",
+   "SpecialIncubatorFirstSteps": "SpecialIncubatorFirstSteps.php"
+   },
+   "ResourceModules": {
+   "WikimediaIncubator.InfoPage": {
+   "styles": "InfoPage.css"
+   }
+   },
+   "ResourceFileModulePaths": {
+   "localBasePath": "",
+   "remoteExtPath": "WikimediaIncubator"
+   },
+   "Hooks": {
+   "ContributionsToolLinks": [
+   "WikimediaIncubator::efLoadViewUserLangLink"
+   ],
+   "GetPreferences": [
+   "WikimediaIncubator::onGetPreferences"
+   ],
+   "UserGetDefaultOptions": [
+   "WikimediaIncubator::onUserGetDefaultOptions"
+   ],
+   "MagicWordwgVariableIDs": [
+   "WikimediaIncubator::magicWordVariable"
+   ],
+   "ParserGetVariableValueSwitch": [
+   "WikimediaIncubator::magicWordValue"
+   ],
+   "getUserPermissionsErrors": [
+   "WikimediaIncubator::onGetUserPermissionsErrors"
+   ],
+   "MovePageIsValidMove": [
+   

[MediaWiki-commits] [Gerrit] Replace call to old wfMsg function - change (mediawiki...DonationInterface)

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

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

Change subject: Replace call to old wfMsg function
..

Replace call to old wfMsg function

This was deprecated in MW 1.18.

Change-Id: If07830d5743f6886098891c11889682dbc95caf4
---
M gateway_common/GatewayPage.php
1 file changed, 2 insertions(+), 2 deletions(-)


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

diff --git a/gateway_common/GatewayPage.php b/gateway_common/GatewayPage.php
index 69cf4a5..e0b7484 100644
--- a/gateway_common/GatewayPage.php
+++ b/gateway_common/GatewayPage.php
@@ -373,8 +373,8 @@
$f_message = 'No active donation in the session';
}
 
-   if ( $forbidden ){
-   wfHttpError( 403, 'Forbidden', wfMsg( 
'donate_interface-error-http-403' ) );
+   if ( $forbidden ) {
+   wfHttpError( 403, 'Forbidden', wfMessage( 
'donate_interface-error-http-403' )->text() );
}
$oid = $this->adapter->getData_Unstaged_Escaped( 'order_id' );
 

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

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

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


[MediaWiki-commits] [Gerrit] Replace call to old wfMsgForContent function - change (mediawiki...ProofreadPage)

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

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

Change subject: Replace call to old wfMsgForContent function
..

Replace call to old wfMsgForContent function

This was deprecated in MW 1.18.

Change-Id: I016bcd2a30e8af82d0dd06b440439d8b942b7ee2
---
M SpecialPagesWithoutScans.php
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/SpecialPagesWithoutScans.php b/SpecialPagesWithoutScans.php
index a1a42b9..7f713c3 100644
--- a/SpecialPagesWithoutScans.php
+++ b/SpecialPagesWithoutScans.php
@@ -43,7 +43,7 @@
 * @return mixed
 */
function disambiguation_templates( $dbr ) {
-   $dMsgText = 
wfMsgForContent('proofreadpage-disambiguationspage');
+   $dMsgText = wfMessage( 'proofreadpage-disambiguationspage' 
)->inContentLanguage()->text();
 
$linkBatch = new LinkBatch;
 

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

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

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 07b66e4..5732bd2 - change (mediawiki/extensions)

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

Change subject: Syncronize VisualEditor: 07b66e4..5732bd2
..


Syncronize VisualEditor: 07b66e4..5732bd2

Change-Id: Iedfdecbfcbba902486f6c1f2903da154634c5689
---
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 07b66e4..5732bd2 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 07b66e47035a109eef7a9271edfe1397aa59c278
+Subproject commit 5732bd26fb351223e306d2171d7ae6b239121482

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

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

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 07b66e4..5732bd2 - change (mediawiki/extensions)

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

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

Change subject: Syncronize VisualEditor: 07b66e4..5732bd2
..

Syncronize VisualEditor: 07b66e4..5732bd2

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/99/247099/1

diff --git a/VisualEditor b/VisualEditor
index 07b66e4..5732bd2 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 07b66e47035a109eef7a9271edfe1397aa59c278
+Subproject commit 5732bd26fb351223e306d2171d7ae6b239121482

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

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

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


[MediaWiki-commits] [Gerrit] ApiVisualEditor: Switch RESTbase config from 'scrubWikitext'... - change (mediawiki...VisualEditor)

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

Change subject: ApiVisualEditor: Switch RESTbase config from 'scrubWikitext' to 
'scrub_wikitext'
..


ApiVisualEditor: Switch RESTbase config from 'scrubWikitext' to 'scrub_wikitext'

Change-Id: I08ca5eab1423232b96faf39f12b25b679a0d77bd
---
M ApiVisualEditor.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/ApiVisualEditor.php b/ApiVisualEditor.php
index 04989b6..c7f4371 100644
--- a/ApiVisualEditor.php
+++ b/ApiVisualEditor.php
@@ -162,7 +162,7 @@
$path,
array(
'html' => $html,
-   'scrubWikitext' => 1,
+   'scrub_wikitext' => 1,
)
);
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I08ca5eab1423232b96faf39f12b25b679a0d77bd
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Replace call to old wfMsg function - change (mediawiki...SecurePoll)

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

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

Change subject: Replace call to old wfMsg function
..

Replace call to old wfMsg function

This was deprecated in MW 1.18.

Change-Id: If15f70024d03c3010823411f668fa34b1839d775
---
M includes/pages/TranslatePage.php
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/includes/pages/TranslatePage.php b/includes/pages/TranslatePage.php
index 89e4d20..24045de 100644
--- a/includes/pages/TranslatePage.php
+++ b/includes/pages/TranslatePage.php
@@ -126,7 +126,7 @@
if ( $wgSecurePollUseNamespace ) {
$s .=
'' .
-   wfMsgHtml( 
'securepoll-translate-label-comment' ) .
+   wfMessage( 
'securepoll-translate-label-comment' )->text() .
Xml::input( 'comment', 45, false, 
array( 'maxlength' => 250 ) )  .
"";
}

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

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

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


[MediaWiki-commits] [Gerrit] getNodeAndOffset: handle slugless nodes with zero DM length - change (VisualEditor/VisualEditor)

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

Change subject: getNodeAndOffset: handle slugless nodes with zero DM length
..


getNodeAndOffset: handle slugless nodes with zero DM length

Change Iea6656882293e8e3cc78df87c31afe58ff59c7e8 fixed getNodeAndOffset in
slugless nodes with zero DM length, by re-rendering the nodes to add slugs.
However re-rendering can close IME candidate windows and prematurely commit
text, so we should avoid such a call inside an apparently pure function.

This change fixes the getNodeAndOffset logic so that an answer is given for
slugless nodes with zero DM length.

ve.ce.Document getNodeAndOffset:
* Support offsets that have no text node
* Back out the call to renderContents, for IME stability

ve.ce.Document.test.js:
* Add getNodeAndOffset tests that simulate the browser removing all content

Bug: T110378
Bug: T115811
Change-Id: I82f1fcf707746ad06bc9e8ce4027a32ecb1812b1
---
M src/ce/ve.ce.BranchNode.js
M src/ce/ve.ce.Document.js
M tests/ce/ve.ce.Document.test.js
3 files changed, 74 insertions(+), 28 deletions(-)

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



diff --git a/src/ce/ve.ce.BranchNode.js b/src/ce/ve.ce.BranchNode.js
index 05de7d3..f107bc5 100644
--- a/src/ce/ve.ce.BranchNode.js
+++ b/src/ce/ve.ce.BranchNode.js
@@ -251,6 +251,20 @@
 };
 
 /**
+ * Remove all slugs in this branch
+ */
+ve.ce.BranchNode.prototype.removeSlugs = function () {
+   var i;
+   // Remove all slugs in this branch
+   for ( i in this.slugNodes ) {
+   if ( this.slugNodes[ i ] !== undefined && this.slugNodes[ i 
].parentNode ) {
+   this.slugNodes[ i ].parentNode.removeChild( 
this.slugNodes[ i ] );
+   }
+   delete this.slugNodes[ i ];
+   }
+};
+
+/**
  * Setup slugs where needed.
  *
  * Existing slugs will be removed before new ones are added.
@@ -261,13 +275,7 @@
var i, slugTemplate, slugNode, child, slugButton,
doc = this.getElementDocument();
 
-   // Remove all slugs in this branch
-   for ( i in this.slugNodes ) {
-   if ( this.slugNodes[ i ] !== undefined && this.slugNodes[ i 
].parentNode ) {
-   this.slugNodes[ i ].parentNode.removeChild( 
this.slugNodes[ i ] );
-   }
-   delete this.slugNodes[ i ];
-   }
+   this.removeSlugs();
 
if ( isBlock ) {
slugTemplate = ve.ce.BranchNode.blockSlugTemplate;
diff --git a/src/ce/ve.ce.Document.js b/src/ce/ve.ce.Document.js
index 16b72eb..fc78b8a 100644
--- a/src/ce/ve.ce.Document.js
+++ b/src/ce/ve.ce.Document.js
@@ -152,27 +152,29 @@
  * @return {number} return.offset location offset within the node
  */
 ve.ce.Document.prototype.getNodeAndOffsetUnadjustedForUnicorn = function ( 
offset ) {
-   var node, startOffset, current, stack, item, $item, length, model, slug,
-   countedNodes = [];
-
-   // Ask for the node first, so we can ask it to render, because that 
fixes up various things
-   // and _creates_ the slug if necessary.
-   node = this.getBranchNodeFromOffset( offset );
-   if ( node instanceof ve.ce.ContentBranchNode ) {
-   node.renderContents();
-   }
-
-   slug = this.getSlugAtOffset( offset );
+   var node, startOffset, current, stack, item, $item, length, model,
+   countedNodes = [],
+   slug = this.getSlugAtOffset( offset );
 
// If we're a block slug, or an empty inline slug, return its location
// Start at the current branch node; get its start offset
-   // Walk the tree, summing offsets until the sum reaches the desired 
offset value
-   // - If a whole branch is entirely before the offset, then don't 
descend into it
-   // - If the desired offset is in a text node, return that node and the 
correct remainder offset
-   // - If the desired offset is between an empty unicorn pair, return 
inter-unicorn location
-   // - Assume no other outcome is possible (because we would be inside a 
slug)
+   // Walk the tree, summing offsets until the sum reaches the desired 
offset value.
+   // If the desired offset:
+   // - is after a ve-ce-branchNode/ve-ce-leafNode: skip the node
+   // - is inside a ve-ce-branchNode/ve-ce-leafNode: descend into node
+   // - is between an empty unicorn pair: return inter-unicorn location
+   // At the desired offset:
+   // - If is a text node: return that node and the correct remainder 
offset
+   // - Else return the first maximally deep element at the offset
+   // Otherwise, signal an error
+
+   // Unfortunately, there is no way to avoid slugless block nodes with no 
DM length: an
+   // IME can remove all the text from a node at a time when it is unsafe 
to fixup the node
+ 

[MediaWiki-commits] [Gerrit] Replace call to old wfMsgForContent function - change (mediawiki...ProofreadPage)

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

Change subject: Replace call to old wfMsgForContent function
..


Replace call to old wfMsgForContent function

This was deprecated in MW 1.18.

Change-Id: I016bcd2a30e8af82d0dd06b440439d8b942b7ee2
---
M SpecialPagesWithoutScans.php
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/SpecialPagesWithoutScans.php b/SpecialPagesWithoutScans.php
index a1a42b9..7f713c3 100644
--- a/SpecialPagesWithoutScans.php
+++ b/SpecialPagesWithoutScans.php
@@ -43,7 +43,7 @@
 * @return mixed
 */
function disambiguation_templates( $dbr ) {
-   $dMsgText = 
wfMsgForContent('proofreadpage-disambiguationspage');
+   $dMsgText = wfMessage( 'proofreadpage-disambiguationspage' 
)->inContentLanguage()->text();
 
$linkBatch = new LinkBatch;
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I016bcd2a30e8af82d0dd06b440439d8b942b7ee2
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ProofreadPage
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 
Gerrit-Reviewer: Tpt 
Gerrit-Reviewer: jenkins-bot <>

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