[MediaWiki-commits] [Gerrit] remove nfs2 from ldap and base config - change (operations/puppet)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review.

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

Change subject: remove nfs2 from ldap and base config
..

remove nfs2 from ldap and base config

decom per

RT #7341

Change-Id: I650d5dc2fe35d0742cfaeb11cdd1d241fef49e82
---
M modules/base/manifests/init.pp
M modules/ldap/manifests/role/config.pp
2 files changed, 2 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/08/129108/1

diff --git a/modules/base/manifests/init.pp b/modules/base/manifests/init.pp
index 74087ee..b6b5c73 100644
--- a/modules/base/manifests/init.pp
+++ b/modules/base/manifests/init.pp
@@ -257,7 +257,6 @@
 class base::remote-syslog {
 if ($::lsbdistid == 'Ubuntu') and
 ($::hostname != 'nfs1') and
-($::hostname != 'nfs2') and
 ($::hostname != 'aluminium') and
 ($::instancename != 'deployment-bastion') {
 
diff --git a/modules/ldap/manifests/role/config.pp 
b/modules/ldap/manifests/role/config.pp
index 29ded25..d700e74 100644
--- a/modules/ldap/manifests/role/config.pp
+++ b/modules/ldap/manifests/role/config.pp
@@ -39,8 +39,8 @@
 
 $basedn = 'dc=wikimedia,dc=org'
 $servernames = $site ? {
-'pmtpa' => [ 'nfs1.pmtpa.wmnet', 'nfs2.pmtpa.wmnet' ],
-'eqiad' => [ 'nfs2.pmtpa.wmnet', 'nfs1.pmtpa.wmnet' ],
+'pmtpa' => [ 'nfs1.pmtpa.wmnet' ],
+'eqiad' => [ 'nfs1.pmtpa.wmnet' ],
 }
 $sudobasedn = "ou=sudoers,${basedn}"
 $ldapconfig = {

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

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

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


[MediaWiki-commits] [Gerrit] remove nfs2 from backup list, dsh, dhcp - change (operations/puppet)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review.

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

Change subject: remove nfs2 from backup list,dsh,dhcp
..

remove nfs2 from backup list,dsh,dhcp

decom per

RT #7341

Change-Id: Ic76a6e173bea49cbce01c8eedd13f1bb57bf91f1
---
M files/backup/disklist-daily
M files/dsh/group/ALL
M files/dsh/group/pmtpa
M modules/install-server/files/dhcpd/linux-host-entries.ttyS1-57600
4 files changed, 0 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/07/129107/1

diff --git a/files/backup/disklist-daily b/files/backup/disklist-daily
index 3282f0d..9faa252 100644
--- a/files/backup/disklist-daily
+++ b/files/backup/disklist-daily
@@ -1,7 +1,6 @@
 mchenry.wikimedia.org   /root default
 sanger.wikimedia.org   /var/vmail  default
 nfs1.pmtpa.wmnet/var/opendj/backups default
-nfs2.pmtpa.wmnet/var/opendj/backups default
 ytterbium.wikimedia.org /var/lib/gerrit2/review_site/git default
 sodium.wikimedia.org   /var/lib/mailmandefault
 stat1002.eqiad.wmnet/home default
diff --git a/files/dsh/group/ALL b/files/dsh/group/ALL
index cc4b537..4c7c493 100644
--- a/files/dsh/group/ALL
+++ b/files/dsh/group/ALL
@@ -60,7 +60,6 @@
 linne
 
 nfs1
-nfs2
 wikitech
 civicrm
 fenari
diff --git a/files/dsh/group/pmtpa b/files/dsh/group/pmtpa
index ff782fa..6d6e3c1 100644
--- a/files/dsh/group/pmtpa
+++ b/files/dsh/group/pmtpa
@@ -7,6 +7,5 @@
 tarin
 tridge
 nfs1
-nfs2
 pdf2
 pdf3
diff --git a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-57600 
b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-57600
index 24fe578..3c7a7b3 100644
--- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-57600
+++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-57600
@@ -33,11 +33,6 @@
fixed-address nfs1.pmtpa.wmnet;
 }
 
-host nfs2 {
-   hardware ethernet 00:1E:C9:EA:AB:68;
-   fixed-address nfs2.pmtpa.wmnet;
-}
-
 host sanger {
hardware ethernet 00:19:B9:DD:86:EB;
fixed-address sanger.wikimedia.org;

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

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

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


[MediaWiki-commits] [Gerrit] update db dsh group file - change (operations/puppet)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged.

Change subject: update db dsh group file
..


update db dsh group file

- remove db's that are gone
- add db's that are actually up

Change-Id: Id838d6f7d7ae893f8c1ae644a784d7af0024eae9
---
M files/dsh/group/db
1 file changed, 7 insertions(+), 2 deletions(-)

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



diff --git a/files/dsh/group/db b/files/dsh/group/db
index 3c16d6e..c31d371 100644
--- a/files/dsh/group/db
+++ b/files/dsh/group/db
@@ -1,4 +1,3 @@
-db10
 db1001
 db1002
 db1003
@@ -39,5 +38,11 @@
 db1047
 db1048
 
-db48
 db60
+db68
+db69
+db71
+db72
+db73
+db74
+

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

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

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


[MediaWiki-commits] [Gerrit] remove db48, db63, db75, db76, db77 - change (operations/dns)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged.

Change subject: remove db48,db63,db75,db76,db77
..


remove db48,db63,db75,db76,db77

db48 - RT #7321
db63 - RT #7320
db75 - not in config or monitoring
db76 - not in config or monitoring
db77 - RT #7332

switch s1-secondary from db63 to db60

Change-Id: Ie1b9b9725504f7a1f630b1b7f68e0adcf8cbd58c
---
M templates/10.in-addr.arpa
M templates/wmnet
2 files changed, 1 insertion(+), 22 deletions(-)

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



diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa
index e05d722..fe9197f 100644
--- a/templates/10.in-addr.arpa
+++ b/templates/10.in-addr.arpa
@@ -89,18 +89,13 @@
 $ORIGIN 6.0.{{ zonename }}.
 
 
-58 1H  IN PTR  db48.pmtpa.wmnet.
 70 1H  IN PTR  db60.pmtpa.wmnet.
-73 1H  IN PTR  db63.pmtpa.wmnet.
 78 1H  IN PTR  db68.pmtpa.wmnet.
 79 1H  IN PTR  db69.pmtpa.wmnet.
 81 1H  IN PTR  db71.pmtpa.wmnet.
 82 1H  IN PTR  db72.pmtpa.wmnet.
 83 1H  IN PTR  db73.pmtpa.wmnet.
 84 1H  IN PTR  db74.pmtpa.wmnet.
-85 1H  IN PTR  db75.pmtpa.wmnet.
-86 1H  IN PTR  db76.pmtpa.wmnet.
-87 1H  IN PTR  db77.pmtpa.wmnet.
 
 $ORIGIN 8.0.{{ zonename }}.
 
@@ -203,20 +198,15 @@
 $ORIGIN 6.1.{{ zonename }}.
 50 1H  IN PTR db40.mgmt.pmtpa.wmnet.
 51 1H  IN PTR manutius.mgmt.pmtpa.wmnet.
-58 1H  IN PTR db48.mgmt.pmtpa.wmnet.
 70 1H  IN PTR db60.mgmt.pmtpa.wmnet.
 71 1H  IN PTR WMF3709.mgmt.pmtpa.wmnet.
 72 1H  IN PTR db62.mgmt.pmtpa.wmnet.
-73  1H  IN PTR db63.mgmt.pmtpa.wmnet.
 78  1H  IN PTR db68.mgmt.pmtpa.wmnet.
 79  1H  IN PTR db69.mgmt.pmtpa.wmnet.
 81  1H  IN PTR db71.mgmt.pmtpa.wmnet.
 82  1H  IN PTR db72.mgmt.pmtpa.wmnet.
 83  1H  IN PTR db73.mgmt.pmtpa.wmnet.
 84  1H  IN PTR db74.mgmt.pmtpa.wmnet.
-85  1H  IN PTR db75.mgmt.pmtpa.wmnet.
-86  1H  IN PTR db76.mgmt.pmtpa.wmnet.
-87  1H  IN PTR db77.mgmt.pmtpa.wmnet.
 
 ; Media Servers & SSL Servers & ES Servers & Memcached Servers
 $ORIGIN 7.1.{{ zonename }}.
diff --git a/templates/wmnet b/templates/wmnet
index 8afabf0..4ccee70 100644
--- a/templates/wmnet
+++ b/templates/wmnet
@@ -37,27 +37,21 @@
 puppet 1H  IN CNAMEpalladium.eqiad.wmnet.
 syslog 1H  IN CNAMEnfs-home
 ntp1H  IN CNAMElinne.wikimedia.org.
-s1-secondary   5M  IN CNAMEdb63.pmtpa.wmnet.
+s1-secondary   5M  IN CNAMEdb60.pmtpa.wmnet.
 s5-secondary   5M  IN CNAMEdb73.pmtpa.wmnet.
-m2-secondary   5M  IN CNAMEdb48.pmtpa.wmnet.
 es1-secondary  5M  IN CNAMEes3.pmtpa.wmnet.
 es2-secondary  5M  IN CNAMEes5.pmtpa.wmnet.
 es3-secondary  5M  IN CNAMEes8.pmtpa.wmnet.
 
 ; Servers (alphabetic order)
 
-db481H  IN A10.0.6.58
 db60   1H  IN A10.0.6.70
-db63   1H  IN A10.0.6.73
 db68   1H  IN A10.0.6.78
 db69   1H  IN A10.0.6.79
 db71   1H  IN A10.0.6.81
 db72   1H  IN A10.0.6.82
 db73   1H  IN A10.0.6.83
 db74   1H  IN A10.0.6.84
-db75   1H  IN A10.0.6.85
-db76   1H  IN A10.0.6.86
-db77   1H  IN A10.0.6.87
 es11H  IN A10.0.0.225
 es21H  IN A10.0.0.226
 es31H  IN A10.0.0.227
@@ -164,20 +158,15 @@
 amaranth   1H  IN A10.1.8.16
 dataset2   1H  IN A10.1.8.55
 manutius   1H  IN A10.1.6.51
-db48   1H  IN A10.1.6.58
 db60   1H  IN A10.1.6.70
 WMF37091H  IN A10.1.6.71
 db62   1H  IN A10.1.6.72
-db63   1H  IN A10.1.6.73
 db68   1H  IN A10.1.6.78
 db69   1H  IN A10.1.6.79
 db71   1H  IN A10.1.6.81
 db72   1H  IN A10.1.6.82
 db73   1H  IN A10.1.6.83
 db74   1H  IN A10.1.6.84
-db75   1H  IN A10.1.6.85
-db76   1H  IN A10.1.6.86
-db77   1H  IN 

[MediaWiki-commits] [Gerrit] update db dsh group file - change (operations/puppet)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review.

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

Change subject: update db dsh group file
..

update db dsh group file

- remove db's that are gone
- add db's that are actually up

Change-Id: Id838d6f7d7ae893f8c1ae644a784d7af0024eae9
---
M files/dsh/group/db
1 file changed, 6 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/06/129106/1

diff --git a/files/dsh/group/db b/files/dsh/group/db
index 3c16d6e..d015d71 100644
--- a/files/dsh/group/db
+++ b/files/dsh/group/db
@@ -1,4 +1,3 @@
-db10
 db1001
 db1002
 db1003
@@ -39,5 +38,10 @@
 db1047
 db1048
 
-db48
 db60
+db69
+db71
+db72
+db73
+db74
+

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

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

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


[MediaWiki-commits] [Gerrit] mwgrep: account for db names with underscores - change (operations/puppet)

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

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

Change subject: mwgrep: account for db names with underscores
..

mwgrep: account for db names with underscores

To derive the dbname from the index name, split on the second-last underscore
rather than the first.

Bug: 64273
Change-Id: I841865da800971eee039f03ce85641cd8efe66db
---
M files/misc/scripts/mwgrep
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/05/129105/1

diff --git a/files/misc/scripts/mwgrep b/files/misc/scripts/mwgrep
index 63773f0..9c58d12 100755
--- a/files/misc/scripts/mwgrep
+++ b/files/misc/scripts/mwgrep
@@ -88,7 +88,7 @@
 result = json.load(req)['hits']
 
 for hit in result['hits']:
-db = hit['_index'].split('_', 1)[0]
+db = hit['_index'].rsplit('_', 2)[0]
 title = hit['_source']['title']
 print('{:<20}{}'.format(db, title))
 

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

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

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


[MediaWiki-commits] [Gerrit] fix typo re: db68 in DHCP - change (operations/puppet)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged.

Change subject: fix typo re: db68 in DHCP
..


fix typo re: db68 in DHCP

Change-Id: Iba2c6863c9b53bdd21118adcb01c8c46731b97d6
---
M modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
index 23a05c4..d02a53c 100644
--- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -723,7 +723,7 @@
 }
 
 host db68 {
-   hardware ethernet d4:ae:52:8b:eb:2e;;
+   hardware ethernet d4:ae:52:8b:eb:2e;
fixed-address db68.pmtpa.wmnet;
 }
 

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

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

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


[MediaWiki-commits] [Gerrit] fix typo re: db68 in DHCP - change (operations/puppet)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review.

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

Change subject: fix typo re: db68 in DHCP
..

fix typo re: db68 in DHCP

Change-Id: Iba2c6863c9b53bdd21118adcb01c8c46731b97d6
---
M modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/04/129104/1

diff --git a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
index 23a05c4..d02a53c 100644
--- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -723,7 +723,7 @@
 }
 
 host db68 {
-   hardware ethernet d4:ae:52:8b:eb:2e;;
+   hardware ethernet d4:ae:52:8b:eb:2e;
fixed-address db68.pmtpa.wmnet;
 }
 

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

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

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


[MediaWiki-commits] [Gerrit] Set $wgBabelCategoryNames for betawikiversity - change (operations/mediawiki-config)

2014-04-22 Thread Withoutaname (Code Review)
Withoutaname has uploaded a new change for review.

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

Change subject: Set $wgBabelCategoryNames for betawikiversity
..

Set $wgBabelCategoryNames for betawikiversity

This change sets the $wgBabelCategoryNames configuration variable for Beta 
Wikiversity per community consensus at 
https://beta.wikiversity.org/w/index.php?oldid=154519#List_of_active_users_for_a_specific_language

Bug: 64168
Change-Id: I72b9d57b4297c3a0f3d187bb9651ab63be47c1c8
---
M wmf-config/InitialiseSettings.php
1 file changed, 10 insertions(+), 0 deletions(-)


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

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index f6cf074..bcdcd80 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -11320,6 +11320,15 @@
'5' => false,
'N' => false,
),
+   'betawikiversity' => array( // bug 64168
+   '0' => false,
+   '1' => 'User %code%-1',
+   '2' => 'User %code%-2',
+   '3' => 'User %code%-3',
+   '4' => 'User %code%-4',
+   '5' => 'User %code%-5',
+   'N' => 'User %code%-N',
+   ),
'cawiki' => array(
'0' => false,
'1' => 'Usuaris %code%-1',
@@ -11891,6 +11900,7 @@
 ),
 'wmgBabelMainCategory' => array(
'default' => false,
+   'betawikiversity' => 'User %code%', // bug 64168
'cawiki' => 'Usuaris %code%',
'cawiktionary' => 'Usuaris %code%', // Bug 47287
'checkuserwiki' => 'User %code%',

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

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

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


[MediaWiki-commits] [Gerrit] remove db48, db63, db75, db76, db77 from dhcp - change (operations/puppet)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has submitted this change and it was merged.

Change subject: remove db48,db63,db75,db76,db77 from dhcp
..


remove db48,db63,db75,db76,db77 from dhcp

db48 - RT #7321
db63 - RT #7320
db75 - not in monitoring or config
db76 - not in monitoring or config
db77 - RT #7332

([Ops] [3668] pdns-templates/wmnet: added up to db77) from SVN

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

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



diff --git a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
index fae220d..23a05c4 100644
--- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -717,23 +717,13 @@
fixed-address dataset1001.wikimedia.org;
 }
 
-host db48 {
-   hardware ethernet 78:2b:cb:6b:dd:4c;
-   fixed-address db48.pmtpa.wmnet;
-}
-
 host db60 {
hardware ethernet d4:ae:52:65:8c:1e;
fixed-address db60.pmtpa.wmnet;
 }
 
-host db63 {
-   hardware ethernet d4:ae:52:90:39:8c;
-   fixed-address db63.pmtpa.wmnet;
-}
-
 host db68 {
-   hardware ethernet d4:ae:52:8b:eb:2e;
+   hardware ethernet d4:ae:52:8b:eb:2e;;
fixed-address db68.pmtpa.wmnet;
 }
 
@@ -760,21 +750,6 @@
 host db74 {
hardware ethernet d4:ae:52:90:3b:5c;
fixed-address db74.pmtpa.wmnet;
-}
-
-host db75 {
-   hardware ethernet d4:ae:52:95:4d:9e;
-   fixed-address db75.pmtpa.wmnet;
-}
-
-host db76 {
-   hardware ethernet d4:ae:52:8f:21:24;
-   fixed-address db76.pmtpa.wmnet;
-}
-
-host db77 {
-   hardware ethernet d4:ae:52:93:41:6d;
-   fixed-address db77.pmtpa.wmnet;
 }
 
 host db1001 {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I08e7710459897f60cbd5dae853837414644f4312
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Dzahn 
Gerrit-Reviewer: ArielGlenn 
Gerrit-Reviewer: Dzahn 
Gerrit-Reviewer: Springle 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] remove db48, db63, db75, db76, db77 - change (operations/dns)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review.

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

Change subject: remove db48,db63,db75,db76,db77
..

remove db48,db63,db75,db76,db77

db48 - RT #7321
db63 - RT #7320
db75 - not in config or monitoring
db76 - not in config or monitoring
db77 - RT #7332

Change-Id: Ie1b9b9725504f7a1f630b1b7f68e0adcf8cbd58c
---
M templates/10.in-addr.arpa
M templates/wmnet
2 files changed, 0 insertions(+), 22 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/dns 
refs/changes/02/129102/1

diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa
index e05d722..fe9197f 100644
--- a/templates/10.in-addr.arpa
+++ b/templates/10.in-addr.arpa
@@ -89,18 +89,13 @@
 $ORIGIN 6.0.{{ zonename }}.
 
 
-58 1H  IN PTR  db48.pmtpa.wmnet.
 70 1H  IN PTR  db60.pmtpa.wmnet.
-73 1H  IN PTR  db63.pmtpa.wmnet.
 78 1H  IN PTR  db68.pmtpa.wmnet.
 79 1H  IN PTR  db69.pmtpa.wmnet.
 81 1H  IN PTR  db71.pmtpa.wmnet.
 82 1H  IN PTR  db72.pmtpa.wmnet.
 83 1H  IN PTR  db73.pmtpa.wmnet.
 84 1H  IN PTR  db74.pmtpa.wmnet.
-85 1H  IN PTR  db75.pmtpa.wmnet.
-86 1H  IN PTR  db76.pmtpa.wmnet.
-87 1H  IN PTR  db77.pmtpa.wmnet.
 
 $ORIGIN 8.0.{{ zonename }}.
 
@@ -203,20 +198,15 @@
 $ORIGIN 6.1.{{ zonename }}.
 50 1H  IN PTR db40.mgmt.pmtpa.wmnet.
 51 1H  IN PTR manutius.mgmt.pmtpa.wmnet.
-58 1H  IN PTR db48.mgmt.pmtpa.wmnet.
 70 1H  IN PTR db60.mgmt.pmtpa.wmnet.
 71 1H  IN PTR WMF3709.mgmt.pmtpa.wmnet.
 72 1H  IN PTR db62.mgmt.pmtpa.wmnet.
-73  1H  IN PTR db63.mgmt.pmtpa.wmnet.
 78  1H  IN PTR db68.mgmt.pmtpa.wmnet.
 79  1H  IN PTR db69.mgmt.pmtpa.wmnet.
 81  1H  IN PTR db71.mgmt.pmtpa.wmnet.
 82  1H  IN PTR db72.mgmt.pmtpa.wmnet.
 83  1H  IN PTR db73.mgmt.pmtpa.wmnet.
 84  1H  IN PTR db74.mgmt.pmtpa.wmnet.
-85  1H  IN PTR db75.mgmt.pmtpa.wmnet.
-86  1H  IN PTR db76.mgmt.pmtpa.wmnet.
-87  1H  IN PTR db77.mgmt.pmtpa.wmnet.
 
 ; Media Servers & SSL Servers & ES Servers & Memcached Servers
 $ORIGIN 7.1.{{ zonename }}.
diff --git a/templates/wmnet b/templates/wmnet
index 8afabf0..83ba3a6 100644
--- a/templates/wmnet
+++ b/templates/wmnet
@@ -37,27 +37,20 @@
 puppet 1H  IN CNAMEpalladium.eqiad.wmnet.
 syslog 1H  IN CNAMEnfs-home
 ntp1H  IN CNAMElinne.wikimedia.org.
-s1-secondary   5M  IN CNAMEdb63.pmtpa.wmnet.
 s5-secondary   5M  IN CNAMEdb73.pmtpa.wmnet.
-m2-secondary   5M  IN CNAMEdb48.pmtpa.wmnet.
 es1-secondary  5M  IN CNAMEes3.pmtpa.wmnet.
 es2-secondary  5M  IN CNAMEes5.pmtpa.wmnet.
 es3-secondary  5M  IN CNAMEes8.pmtpa.wmnet.
 
 ; Servers (alphabetic order)
 
-db481H  IN A10.0.6.58
 db60   1H  IN A10.0.6.70
-db63   1H  IN A10.0.6.73
 db68   1H  IN A10.0.6.78
 db69   1H  IN A10.0.6.79
 db71   1H  IN A10.0.6.81
 db72   1H  IN A10.0.6.82
 db73   1H  IN A10.0.6.83
 db74   1H  IN A10.0.6.84
-db75   1H  IN A10.0.6.85
-db76   1H  IN A10.0.6.86
-db77   1H  IN A10.0.6.87
 es11H  IN A10.0.0.225
 es21H  IN A10.0.0.226
 es31H  IN A10.0.0.227
@@ -164,20 +157,15 @@
 amaranth   1H  IN A10.1.8.16
 dataset2   1H  IN A10.1.8.55
 manutius   1H  IN A10.1.6.51
-db48   1H  IN A10.1.6.58
 db60   1H  IN A10.1.6.70
 WMF37091H  IN A10.1.6.71
 db62   1H  IN A10.1.6.72
-db63   1H  IN A10.1.6.73
 db68   1H  IN A10.1.6.78
 db69   1H  IN A10.1.6.79
 db71   1H  IN A10.1.6.81
 db72   1H  IN A10.1.6.82
 db73   1H  IN A10.1.6.83
 db74   1H  IN A10.1.6.84
-db75   1H  IN A10.1.6.85
-db76   1H  IN A10.1.6.86
-db77   1H  IN A10.1.6.87
 dobson 1H  IN A10.1.8.4
 ekrem  1H  IN A  

[MediaWiki-commits] [Gerrit] remove db48, db63, db68, db75, db76, db77 from dhcp - change (operations/puppet)

2014-04-22 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review.

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

Change subject: remove db48,db63,db68,db75,db76,db77 from dhcp
..

remove db48,db63,db68,db75,db76,db77 from dhcp

db48 - RT #7321
db63 - RT #7320
db75 - not in monitoring or config
db76 - not in monitoring or config
db77 - RT #7332

([Ops] [3668] pdns-templates/wmnet: added up to db77) from SVN

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


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/01/129101/1

diff --git a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 
b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
index fae220d..c7e7205 100644
--- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
+++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200
@@ -717,24 +717,9 @@
fixed-address dataset1001.wikimedia.org;
 }
 
-host db48 {
-   hardware ethernet 78:2b:cb:6b:dd:4c;
-   fixed-address db48.pmtpa.wmnet;
-}
-
 host db60 {
hardware ethernet d4:ae:52:65:8c:1e;
fixed-address db60.pmtpa.wmnet;
-}
-
-host db63 {
-   hardware ethernet d4:ae:52:90:39:8c;
-   fixed-address db63.pmtpa.wmnet;
-}
-
-host db68 {
-   hardware ethernet d4:ae:52:8b:eb:2e;
-   fixed-address db68.pmtpa.wmnet;
 }
 
 host db69 {
@@ -760,21 +745,6 @@
 host db74 {
hardware ethernet d4:ae:52:90:3b:5c;
fixed-address db74.pmtpa.wmnet;
-}
-
-host db75 {
-   hardware ethernet d4:ae:52:95:4d:9e;
-   fixed-address db75.pmtpa.wmnet;
-}
-
-host db76 {
-   hardware ethernet d4:ae:52:8f:21:24;
-   fixed-address db76.pmtpa.wmnet;
-}
-
-host db77 {
-   hardware ethernet d4:ae:52:93:41:6d;
-   fixed-address db77.pmtpa.wmnet;
 }
 
 host db1001 {

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

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

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


[MediaWiki-commits] [Gerrit] HHVM compatibility - change (mediawiki...luasandbox)

2014-04-22 Thread Tim Starling (Code Review)
Tim Starling has uploaded a new change for review.

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

Change subject: HHVM compatibility
..

HHVM compatibility

Support both PHP and HHVM with a single source tree, by means of the
following changes:

* Use the HashPosition interface instead of pListHead/pListNext
* Use zend_hash_num_elements() instead of nNumOfElements.
* HHVM lacks nApplyCount, there's just no space to store that data. When
  compiling for HHVM, use an external std::set instead.
* In luasandbox_timer_enable_profiler(), use ALLOC_HASHTABLE() instead
  of emalloc().
* In luasandbox_push_zval() switch, remove IS_CONSTANT and
  IS_CONSTANT_ARRAY, since they are duplicates in HHVM and are not
  needed anyway, since the default case is there already.
* Add casts where necessary to avoid C++ warnings.
* LUASANDBOX_G(allowed_globals) cannot be persistent in HHVM, due to the
  lack of persistent hashtable support, so reinitialise it with each
  request.
* In LuaSandbox::setCPULimit(), use "z" instead of "Z" to
  zend_parse_parameter(). Not sure why "Z" was ever used -- it is very
  rare.
* Use convert_to_double_ex() instead of unimplemented
  convert_scalar_to_number_ex(). I think it is an improvement anyway.
* In LuaSandboxFunction_construct.phpt, relax error format so that it
  matches both PHP and HHVM error strings.

Change-Id: I784459fdf2e84fba81f6eff55cb183878ecec86d
---
M data_conversion.c
A ext_luasandbox.php
A hhvm-cmake.patch
M library.c
M luasandbox.c
M luasandbox_lstrlib.c
M php_luasandbox.h
M tests/LuaSandboxFunction_construct.phpt
M timer.c
9 files changed, 208 insertions(+), 75 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/php/luasandbox 
refs/changes/00/129100/1

diff --git a/data_conversion.c b/data_conversion.c
index fcdd305..ed70730 100644
--- a/data_conversion.c
+++ b/data_conversion.c
@@ -13,6 +13,16 @@
 #include "php_luasandbox.h"
 #include "zend_exceptions.h"
 
+#ifdef HHVM
+#include 
+static HPHP::ThreadLocal> protectionSet;
+using std::isfinite;
+#endif
+
+static inline int luasandbox_is_recursive(HashTable * ht);
+static inline void luasandbox_protect_recursion(HashTable * ht);
+static inline void luasandbox_unprotect_recursion(HashTable * ht);
+
 static int luasandbox_lua_to_array(HashTable *ht, lua_State *L, int index,
zval * sandbox_zval, HashTable * recursionGuard TSRMLS_DC);
 static int luasandbox_free_zval_userdata(lua_State * L);
@@ -97,8 +107,6 @@
lua_pushlstring(L, Z_STRVAL_P(z), Z_STRLEN_P(z));
break;
case IS_RESOURCE:
-   case IS_CONSTANT:
-   case IS_CONSTANT_ARRAY:
default:
return 0;
}
@@ -152,40 +160,51 @@
  */
 static int luasandbox_push_hashtable(lua_State * L, HashTable * ht)
 {
-   Bucket * p;
+   HashPosition p;
 
// Recursion requires an arbitrary amount of stack space so we have to 
// check the stack.
luaL_checkstack(L, 10, "converting PHP array to Lua");
 
lua_newtable(L);
-   if (!ht || !ht->nNumOfElements) {
+   if (!ht || !zend_hash_num_elements(ht)) {
return 1;
}
-   if (ht->nApplyCount) {
+   
+   if (luasandbox_is_recursive(ht)) {
TSRMLS_FETCH();
php_error_docref(NULL TSRMLS_CC, E_WARNING, "recursion 
detected");
return 0;
}
-   ht->nApplyCount++;
-   for (p = ht->pListHead; p; p = p->pListNext) {
-   if (p->nKeyLength) {
-   lua_pushlstring(L, p->arKey, p->nKeyLength - 1);
+   luasandbox_protect_recursion(ht);
+   for (zend_hash_internal_pointer_reset_ex(ht, &p);
+   zend_hash_get_current_key_type_ex(ht, &p) != 
HASH_KEY_NON_EXISTENT;
+   zend_hash_move_forward_ex(ht, &p))
+   {
+   char * key = "";
+   uint key_length = 0;
+   ulong lkey = 0;
+   zval ** value;
+   int key_type = zend_hash_get_current_key_ex(ht, &key, 
&key_length,
+   &lkey, 0, &p);
+   zend_hash_get_current_data_ex(ht, (void**)&value, &p);
+   if (key_type == HASH_KEY_IS_STRING) {
+   lua_pushlstring(L, key, key_length - 1);
} else {
-   lua_pushinteger(L, p->h);
+   lua_pushinteger(L, lkey);
}

-   if (!luasandbox_push_zval(L, *(zval**)p->pData)) {
+   if (!luasandbox_push_zval(L, *value)) {
// Failed to process that data value
// Pop the key and the half-constructed table
lua_pop(L, 2);
-   ht->nApplyCount--;
+   luasandbox_unprotect_recursion(ht);
r

[MediaWiki-commits] [Gerrit] Remove unwanted new line and tab characters from the parsed ... - change (mediawiki...cxserver)

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

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

Change subject: Remove unwanted new line and tab characters from the parsed 
output
..

Remove unwanted new line and tab characters from the parsed output

This was introduced to help debugging. Removing them now

Change-Id: Ia02457f9d771598f0e702d8a5cecfccce055be67
---
M segmentation/languages/CXParser.js
1 file changed, 2 insertions(+), 2 deletions(-)


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

diff --git a/segmentation/languages/CXParser.js 
b/segmentation/languages/CXParser.js
index 9562eb7..532d538 100644
--- a/segmentation/languages/CXParser.js
+++ b/segmentation/languages/CXParser.js
@@ -82,7 +82,7 @@
this.inSentence = true;
this.sawSentenceEndCandidate = false;
this.inReference = false;
-   return '\n\t';
+   return '';
 };
 
 /**
@@ -252,7 +252,7 @@
// Avoid dangling sentence.
this.print( this.endSentence() );
}
-   this.print( '\n' );
+   this.print( '' );
} else {
this.print( '' );
}

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

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

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


[MediaWiki-commits] [Gerrit] Have getPageAsDescription follow redirects - change (mediawiki...GuidedTour)

2014-04-22 Thread Mattflaschen (Code Review)
Mattflaschen has uploaded a new change for review.

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

Change subject: Have getPageAsDescription follow redirects
..

Have getPageAsDescription follow redirects

Bug: 64138
Change-Id: I7c54b0be0cf0be0ce45f70faee75be6524504c07
---
M modules/ext.guidedTour.lib/ext.guidedTour.lib.main.js
1 file changed, 5 insertions(+), 0 deletions(-)


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

diff --git a/modules/ext.guidedTour.lib/ext.guidedTour.lib.main.js 
b/modules/ext.guidedTour.lib/ext.guidedTour.lib.main.js
index 220494c..4fe9a88 100644
--- a/modules/ext.guidedTour.lib/ext.guidedTour.lib.main.js
+++ b/modules/ext.guidedTour.lib/ext.guidedTour.lib.main.js
@@ -132,6 +132,11 @@
}
ajaxData[source] = guider.description;
 
+   if ( source === 'page' ) {
+   // If page name is a redirect, follow it.
+   ajaxData.redirects = 'true';
+   }
+
ajaxParams = {
async: false,
type: 'POST',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7c54b0be0cf0be0ce45f70faee75be6524504c07
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/GuidedTour
Gerrit-Branch: master
Gerrit-Owner: Mattflaschen 

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


[MediaWiki-commits] [Gerrit] Performance improvement - change (pywikibot/core)

2014-04-22 Thread Xqt (Code Review)
Xqt has uploaded a new change for review.

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

Change subject: Performance improvement
..

Performance improvement

It is not necessary to load the whole version history to restore
the last one. total=2 is enough to do the job.

Change-Id: Id739b8765aa90d89c66bde351dcfa9fb28820c27
---
M scripts/revertbot.py
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/97/129097/1

diff --git a/scripts/revertbot.py b/scripts/revertbot.py
index c8900fd..e23dfee 100644
--- a/scripts/revertbot.py
+++ b/scripts/revertbot.py
@@ -69,8 +69,8 @@
 return 'top' in item
 
 def revert(self, item):
-if len(pywikibot.Page(pywikibot.Site(), 
item['title']).fullVersionHistory()) > 1:
-rev = pywikibot.Page(pywikibot.Site(), 
item['title']).fullVersionHistory()[1]
+if len(pywikibot.Page(pywikibot.Site(), 
item['title']).fullVersionHistory(total=2)) > 1:
+rev = pywikibot.Page(pywikibot.Site(), 
item['title']).fullVersionHistory(total=2)[1]
 else:
 return False
 

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

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

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


[MediaWiki-commits] [Gerrit] Remove 6 unused watchlist messages - change (mediawiki/core)

2014-04-22 Thread PleaseStand (Code Review)
PleaseStand has uploaded a new change for review.

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

Change subject: Remove 6 unused watchlist messages
..

Remove 6 unused watchlist messages

Follows-up r10378 (597ec6c685d8):
* watchmethod-recent
* watchmethod-list

Follows-up r23693 (a4536a5a72b2):
* watchlistcontains
* iteminvalidname

Follows-up r92231 (8c73abd507bf):
* watchlistedit-numitems
* watchlistedit-noitems

Change-Id: I9e4d67c2ea34f1e6dd99f4ea2597abd64bb7281e
---
M languages/i18n/en.json
1 file changed, 0 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/96/129096/1

diff --git a/languages/i18n/en.json b/languages/i18n/en.json
index bbc2339..4c844c3 100644
--- a/languages/i18n/en.json
+++ b/languages/i18n/en.json
@@ -1824,10 +1824,6 @@
 "watchlist-details": "{{PLURAL:$1|$1 page|$1 pages}} on your watchlist, 
not separately counting talk pages.",
 "wlheader-enotif": "Email notification is enabled.",
 "wlheader-showupdated": "Pages that have been changed since you last 
visited them are shown in bold.",
-"watchmethod-recent": "checking recent edits for watched pages",
-"watchmethod-list": "checking watched pages for recent edits",
-"watchlistcontains": "Your watchlist contains $1 
{{PLURAL:$1|page|pages}}.",
-"iteminvalidname": "Problem with item \"$1\", invalid name...",
 "wlnote2": "Below are the changes in the last 
{{PLURAL:$1|hour|$1 hours}}, as of $2, $3.",
 "wlshowlast": "Show last $1 hours $2 days $3",
 "watchlist-options": "Watchlist options",
@@ -3141,8 +3137,6 @@
 "lag-warn-normal": "Changes newer than $1 {{PLURAL:$1|second|seconds}} may 
not be shown in this list.",
 "lag-warn-high": "Due to high database server lag, changes newer than $1 
{{PLURAL:$1|second|seconds}} may not be shown in this list.",
 "editwatchlist-summary": "",
-"watchlistedit-numitems": "Your watchlist contains {{PLURAL:$1|1 title|$1 
titles}}, excluding talk pages.",
-"watchlistedit-noitems": "Your watchlist contains no titles.",
 "watchlistedit-normal-title": "Edit watchlist",
 "watchlistedit-normal-legend": "Remove titles from watchlist",
 "watchlistedit-normal-explain": "Titles on your watchlist are shown 
below.\nTo remove a title, check the box next to it, and click 
\"{{int:Watchlistedit-normal-submit}}\".\nYou can also 
[[Special:EditWatchlist/raw|edit the raw list]].",

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

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

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


[MediaWiki-commits] [Gerrit] update language by size - change (pywikibot/core)

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

Change subject: update language by size
..


update language by size

Change-Id: If34bacef4380f2eca708d62ea2dfbd3f1cc1689b
---
M pywikibot/families/wikibooks_family.py
M pywikibot/families/wikipedia_family.py
M pywikibot/families/wiktionary_family.py
3 files changed, 10 insertions(+), 10 deletions(-)

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



diff --git a/pywikibot/families/wikibooks_family.py 
b/pywikibot/families/wikibooks_family.py
index 9f61c00..a3a6476 100644
--- a/pywikibot/families/wikibooks_family.py
+++ b/pywikibot/families/wikibooks_family.py
@@ -13,7 +13,7 @@
 self.languages_by_size = [
 'en', 'de', 'fr', 'hu', 'ja', 'it', 'es', 'pt', 'nl', 'pl', 'he',
 'vi', 'id', 'sq', 'ca', 'fi', 'ru', 'fa', 'cs', 'zh', 'sv', 'da',
-'hr', 'tr', 'no', 'ar', 'th', 'sr', 'gl', 'ko', 'ta', 'mk', 'tl',
+'hr', 'tr', 'no', 'th', 'sr', 'ar', 'gl', 'ko', 'ta', 'mk', 'tl',
 'ro', 'is', 'ka', 'tt', 'lt', 'az', 'eo', 'uk', 'bg', 'sk', 'sl',
 'el', 'hy', 'ms', 'si', 'li', 'la', 'ml', 'ang', 'ur', 'ia', 'cv',
 'et', 'bn', 'hi', 'mr', 'oc', 'km', 'kk', 'eu', 'fy', 'ie', 'ne',
diff --git a/pywikibot/families/wikipedia_family.py 
b/pywikibot/families/wikipedia_family.py
index 2ebd060..1f2aa80 100644
--- a/pywikibot/families/wikipedia_family.py
+++ b/pywikibot/families/wikipedia_family.py
@@ -12,19 +12,19 @@
 
 self.languages_by_size = [
 'en', 'nl', 'de', 'sv', 'fr', 'it', 'ru', 'es', 'pl', 'war', 'ja',
-'ceb', 'vi', 'pt', 'zh', 'uk', 'ca', 'no', 'fa', 'fi', 'id', 'cs',
+'ceb', 'vi', 'pt', 'zh', 'uk', 'ca', 'no', 'fa', 'id', 'fi', 'cs',
 'ar', 'ko', 'hu', 'ms', 'sr', 'ro', 'tr', 'min', 'kk', 'eo', 'sk',
 'da', 'eu', 'lt', 'bg', 'sh', 'he', 'hr', 'sl', 'uz', 'et', 'vo',
 'hy', 'nn', 'gl', 'simple', 'hi', 'la', 'az', 'el', 'th', 'oc',
 'ka', 'mk', 'be', 'new', 'pms', 'tl', 'ta', 'te', 'tt', 'cy', 'lv',
 'ht', 'be-x-old', 'sq', 'bs', 'br', 'jv', 'mg', 'ur', 'lb', 'mr',
-'is', 'ml', 'pnb', 'ba', 'my', 'af', 'yo', 'ga', 'an', 'tg', 'lmo',
-'fy', 'bn', 'zh-yue', 'cv', 'ky', 'sw', 'io', 'ne', 'gu', 'bpy',
+'is', 'ml', 'pnb', 'ba', 'my', 'af', 'yo', 'ga', 'an', 'zh-yue',
+'tg', 'bn', 'lmo', 'fy', 'cv', 'ky', 'sw', 'io', 'ne', 'gu', 'bpy',
 'scn', 'ce', 'sco', 'nds', 'ku', 'ast', 'qu', 'su', 'als', 'kn',
-'am', 'ia', 'nap', 'bug', 'ckb', 'bat-smg', 'wa', 'map-bms', 'mn',
-'gd', 'arz', 'hif', 'mzn', 'zh-min-nan', 'yi', 'si', 'sah', 'vec',
-'pa', 'sa', 'nah', 'bar', 'os', 'roa-tara', 'fo', 'pam', 'hsb',
-'or', 'se', 'li', 'mi', 'ilo', 'co', 'gan', 'frr', 'bo', 'glk',
+'am', 'ia', 'nap', 'bug', 'ckb', 'bat-smg', 'wa', 'map-bms', 'gd',
+'mn', 'arz', 'mzn', 'zh-min-nan', 'yi', 'si', 'sah', 'pa', 'vec',
+'sa', 'nah', 'bar', 'os', 'roa-tara', 'fo', 'pam', 'hsb', 'or',
+'se', 'li', 'mi', 'ilo', 'co', 'hif', 'gan', 'frr', 'bo', 'glk',
 'rue', 'bcl', 'nds-nl', 'fiu-vro', 'mrj', 'ps', 'tk', 'vls', 'gv',
 'xmf', 'pag', 'diq', 'km', 'zea', 'kv', 'mhr', 'csb', 'vep', 'ay',
 'hak', 'dv', 'so', 'nrm', 'rm', 'udm', 'koi', 'sc', 'zh-classical',
@@ -36,7 +36,7 @@
 'cbk-zam', 'av', 'ty', 'srn', 'bxr', 'ig', 'kg', 'tet', 'na', 'ab',
 'ltg', 'nso', 'za', 'kaa', 'zu', 'ha', 'chy', 'rmy', 'cu', 'chr',
 'tn', 'cdo', 'roa-rup', 'bi', 'pih', 'tyv', 'got', 'tw', 'sm', 
'bm',
-'iu', 'ss', 'sd', 'pnt', 'ki', 'rn', 'ee', 'om', 'ts', 'xh', 'ak',
+'iu', 'ss', 'sd', 'pnt', 'ki', 'rn', 'om', 'ee', 'ts', 'xh', 'ak',
 'fj', 'ti', 'ks', 'sg', 'ff', 've', 'cr', 'lg', 'st', 'dz', 'tum',
 'ik', 'ny', 'ch',
 ]
diff --git a/pywikibot/families/wiktionary_family.py 
b/pywikibot/families/wiktionary_family.py
index 80dc5b1..db1544e 100644
--- a/pywikibot/families/wiktionary_family.py
+++ b/pywikibot/families/wiktionary_family.py
@@ -12,7 +12,7 @@
 
 self.languages_by_size = [
 'en', 'mg', 'fr', 'sh', 'zh', 'es', 'lt', 'ru', 'el', 'pl', 'nl',
-'sv', 'ko', 'de', 'tr', 'ku', 'ta', 'hu', 'kn', 'it', 'fi', 'io',
+'sv', 'ko', 'de', 'tr', 'ku', 'ta', 'hu', 'it', 'kn', 'fi', 'io',
 'vi', 'chr', 'pt', 'no', 'ml', 'my', 'id', 'li', 'ro', 'ja', 'et',
 'te', 'jv', 'fa', 'cs', 'ca', 'ar', 'eu', 'gl', 'lo', 'uk', 'hy',
 'br', 'fj', 'eo', 'bg', 'hr', 'th', 'oc', 'is', 'vo', 'ps', 'uz',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If34bacef4380f2eca708d62ea2dfbd3f1cc168

[MediaWiki-commits] [Gerrit] update language by size - change (pywikibot/compat)

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

Change subject: update language by size
..


update language by size

Change-Id: I594b97eceac3f8ff3610f15203ef7b9449d05bb9
---
M families/wikibooks_family.py
M families/wikipedia_family.py
M families/wiktionary_family.py
3 files changed, 10 insertions(+), 10 deletions(-)

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



diff --git a/families/wikibooks_family.py b/families/wikibooks_family.py
index 479caf1..766bc56 100644
--- a/families/wikibooks_family.py
+++ b/families/wikibooks_family.py
@@ -13,7 +13,7 @@
 self.languages_by_size = [
 'en', 'de', 'fr', 'hu', 'ja', 'it', 'es', 'pt', 'nl', 'pl', 'he',
 'vi', 'id', 'sq', 'ca', 'fi', 'ru', 'fa', 'cs', 'zh', 'sv', 'da',
-'hr', 'tr', 'no', 'ar', 'th', 'sr', 'gl', 'ko', 'ta', 'mk', 'tl',
+'hr', 'tr', 'no', 'th', 'sr', 'ar', 'gl', 'ko', 'ta', 'mk', 'tl',
 'ro', 'is', 'ka', 'tt', 'lt', 'az', 'eo', 'uk', 'bg', 'sk', 'sl',
 'el', 'hy', 'ms', 'si', 'li', 'la', 'ml', 'ang', 'ur', 'ia', 'cv',
 'et', 'bn', 'hi', 'mr', 'oc', 'km', 'kk', 'eu', 'fy', 'ie', 'ne',
diff --git a/families/wikipedia_family.py b/families/wikipedia_family.py
index 38f0cef..e5cce33 100644
--- a/families/wikipedia_family.py
+++ b/families/wikipedia_family.py
@@ -12,19 +12,19 @@
 
 self.languages_by_size = [
 'en', 'nl', 'de', 'sv', 'fr', 'it', 'ru', 'es', 'pl', 'war', 'ja',
-'ceb', 'vi', 'pt', 'zh', 'uk', 'ca', 'no', 'fa', 'fi', 'id', 'cs',
+'ceb', 'vi', 'pt', 'zh', 'uk', 'ca', 'no', 'fa', 'id', 'fi', 'cs',
 'ar', 'ko', 'hu', 'ms', 'sr', 'ro', 'tr', 'min', 'kk', 'eo', 'sk',
 'da', 'eu', 'lt', 'bg', 'sh', 'he', 'hr', 'sl', 'uz', 'et', 'vo',
 'hy', 'nn', 'gl', 'simple', 'hi', 'la', 'az', 'el', 'th', 'oc',
 'ka', 'mk', 'be', 'new', 'pms', 'tl', 'ta', 'te', 'tt', 'cy', 'lv',
 'ht', 'be-x-old', 'sq', 'bs', 'br', 'jv', 'mg', 'ur', 'lb', 'mr',
-'is', 'ml', 'pnb', 'ba', 'my', 'af', 'yo', 'ga', 'an', 'tg', 'lmo',
-'fy', 'bn', 'zh-yue', 'cv', 'ky', 'sw', 'io', 'ne', 'gu', 'bpy',
+'is', 'ml', 'pnb', 'ba', 'my', 'af', 'yo', 'ga', 'an', 'zh-yue',
+'tg', 'bn', 'lmo', 'fy', 'cv', 'ky', 'sw', 'io', 'ne', 'gu', 'bpy',
 'scn', 'ce', 'sco', 'nds', 'ku', 'ast', 'qu', 'su', 'als', 'kn',
-'am', 'ia', 'nap', 'bug', 'ckb', 'bat-smg', 'wa', 'map-bms', 'mn',
-'gd', 'arz', 'hif', 'mzn', 'zh-min-nan', 'yi', 'si', 'sah', 'vec',
-'pa', 'sa', 'nah', 'bar', 'os', 'roa-tara', 'fo', 'pam', 'hsb',
-'or', 'se', 'li', 'mi', 'ilo', 'co', 'gan', 'frr', 'bo', 'glk',
+'am', 'ia', 'nap', 'bug', 'ckb', 'bat-smg', 'wa', 'map-bms', 'gd',
+'mn', 'arz', 'mzn', 'zh-min-nan', 'yi', 'si', 'sah', 'pa', 'vec',
+'sa', 'nah', 'bar', 'os', 'roa-tara', 'fo', 'pam', 'hsb', 'or',
+'se', 'li', 'mi', 'ilo', 'co', 'hif', 'gan', 'frr', 'bo', 'glk',
 'rue', 'bcl', 'nds-nl', 'fiu-vro', 'mrj', 'ps', 'tk', 'vls', 'gv',
 'xmf', 'pag', 'diq', 'km', 'zea', 'kv', 'mhr', 'csb', 'vep', 'ay',
 'hak', 'dv', 'so', 'nrm', 'rm', 'udm', 'koi', 'sc', 'zh-classical',
@@ -36,7 +36,7 @@
 'cbk-zam', 'av', 'ty', 'srn', 'bxr', 'ig', 'kg', 'tet', 'na', 'ab',
 'ltg', 'nso', 'za', 'kaa', 'zu', 'ha', 'chy', 'rmy', 'cu', 'chr',
 'tn', 'cdo', 'roa-rup', 'bi', 'pih', 'tyv', 'got', 'tw', 'sm', 
'bm',
-'iu', 'ss', 'sd', 'pnt', 'ki', 'rn', 'ee', 'om', 'ts', 'xh', 'ak',
+'iu', 'ss', 'sd', 'pnt', 'ki', 'rn', 'om', 'ee', 'ts', 'xh', 'ak',
 'fj', 'ti', 'ks', 'sg', 'ff', 've', 'cr', 'lg', 'st', 'dz', 'tum',
 'ik', 'ny', 'ch',
 ]
diff --git a/families/wiktionary_family.py b/families/wiktionary_family.py
index 9be0dae..a75737b 100644
--- a/families/wiktionary_family.py
+++ b/families/wiktionary_family.py
@@ -12,7 +12,7 @@
 
 self.languages_by_size = [
 'en', 'mg', 'fr', 'sh', 'zh', 'es', 'lt', 'ru', 'el', 'pl', 'nl',
-'sv', 'ko', 'de', 'tr', 'ku', 'ta', 'hu', 'kn', 'it', 'fi', 'io',
+'sv', 'ko', 'de', 'tr', 'ku', 'ta', 'hu', 'it', 'kn', 'fi', 'io',
 'vi', 'chr', 'pt', 'no', 'ml', 'my', 'id', 'li', 'ro', 'ja', 'et',
 'te', 'jv', 'fa', 'cs', 'ca', 'ar', 'eu', 'gl', 'lo', 'uk', 'hy',
 'br', 'fj', 'eo', 'bg', 'hr', 'th', 'oc', 'is', 'vo', 'ps', 'uz',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I594b97eceac3f8ff3610f15203ef7b9449d05bb9
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/compat
Gerrit-Branch: master
Gerrit-Owner: Maintenance-bot 
Gerrit-Reviewer: Ladsgroup 
Gerrit-Reviewer: 

[MediaWiki-commits] [Gerrit] Document Special:Diff and Special:PermanentLink - change (mediawiki/core)

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

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

Change subject: Document Special:Diff and Special:PermanentLink
..

Document Special:Diff and Special:PermanentLink

* If no revision is given to Special:Diff or Special:PermaLink, show a form (a 
la Special:ComparePages or Special:Thanks in Thanks extension).
* List on Special:SpecialPages

Bug: 45221
Change-Id: I77edd4a1bbd342d4d18c27d5bc10dac76b8ab6c9
---
M includes/specials/SpecialDiff.php
M includes/specials/SpecialPermanentLink.php
M languages/i18n/en.json
M languages/i18n/qqq.json
4 files changed, 118 insertions(+), 18 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/95/129095/1

diff --git a/includes/specials/SpecialDiff.php 
b/includes/specials/SpecialDiff.php
index 77d2317..48c322d 100644
--- a/includes/specials/SpecialDiff.php
+++ b/includes/specials/SpecialDiff.php
@@ -36,26 +36,76 @@
  * @ingroup SpecialPage
  * @since 1.23
  */
-class SpecialDiff extends RedirectSpecialPage {
+class SpecialDiff extends SpecialPage {
function __construct() {
parent::__construct( 'Diff' );
-   $this->mAllowedRedirectParams = array();
}
 
-   function getRedirect( $subpage ) {
+   public function execute( $subpage ) {
+   global $wgRequest;
+   $opts = new FormOptions;
+   $opts->add( 'diff', '' );
+   $opts->add( 'oldid', '' );
+   $opts->fetchValuesFromRequest( $wgRequest );
+
+   $params = array();
+
+   $out = $this->getOutput();
$parts = explode( '/', $subpage );
 
// Try to parse the values given, generating somewhat pretty 
URLs if possible
if ( count( $parts ) === 1 && $parts[0] !== '' ) {
-   $this->mAddedRedirectParams['diff'] = $parts[0];
+   $params['diff'] = $parts[0];
} elseif ( count( $parts ) === 2 ) {
-   $this->mAddedRedirectParams['oldid'] = $parts[0];
-   $this->mAddedRedirectParams['diff'] = $parts[1];
+   $params['oldid'] = $parts[0];
+   $params['diff'] = $parts[1];
+   } elseif ( $opts->getValue( 'diff' ) || $opts->getValue( 
'oldid' ) ) {
+   $params['oldid'] = $opts->getValue( 'oldid' );
+   $params['diff'] = $opts->getValue( 'diff' );
} else {
-   // Wrong number of parameters, bail out
-   throw new ErrorPageError( 'nopagetitle', 'nopagetext' );
-   }
+   // Wrong number of parameters, show form
 
+   $this->setHeaders();
+   $this->outputHeader();
+
+   $form = new HTMLForm( array(
+   'oldid' => array(
+   'name' => 'oldid',
+   'type' => 'int',
+   'label-message' => 'diff-form-oldid',
+   ),
+   'diff' => array(
+   'name' => 'diff',
+   'class' => 'HTMLTextField',
+   'label-message' => 'diff-form-revid',
+   ),
+   ), $this->getContext(), 'diff-form' );
+   $form->setSubmitTextMsg( 'diff-form-submit' );
+   $form->setMethod( 'get' );
+   $form->setSubmitCallback( array( __CLASS__, 
'callbackDiff' ) );
+   $form->setDisplayFormat( 'vform' );
+   $form->show();
+   return true;
+   }
+   $url = wfAppendQuery( wfScript( 'index' ), $params );
+   $out->redirect( $url );
return true;
}
+
+   static function callbackDiff( $formData ) {
+   return false;
+   }
+
+   function getDescription() {
+   // 'diff' message is in lowercase, using own message
+   return $this->msg( 'diff-form' )->text();
+   }
+
+   function getName() {
+   return 'diff-form';
+   }
+
+   protected function getGroupName() {
+   return 'redirects';
+   }
 }
diff --git a/includes/specials/SpecialPermanentLink.php 
b/includes/specials/SpecialPermanentLink.php
index 17115e8..51dad23 100644
--- a/includes/specials/SpecialPermanentLink.php
+++ b/includes/specials/SpecialPermanentLink.php
@@ -26,20 +26,51 @@
  *
  * @ingroup SpecialPage
  */
-class SpecialPermanentLink extends RedirectSpecialPage {
+class SpecialPermanentLink extends SpecialPage {
function __construct() {

[MediaWiki-commits] [Gerrit] Update lessphp to 2cc77e3c7b - change (mediawiki/core)

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

Change subject: Update lessphp to 2cc77e3c7b
..


Update lessphp to 2cc77e3c7b

Source:
* https://github.com/leafo/lessphp/compare/b7cd5c79e8...2cc77e3c7b
* 
https://github.com/leafo/lessphp/blob/2cc77e3c7b9e84cf30ca64fccf2a45a84fbcf0d3/lessc.inc.php

Updates:
* 84b1fda0d4 Set visibility of lessc::compileValue to 'public'

Change-Id: I499ddb01a662896fdcfe56d18021de5314e4d5d2
---
M includes/libs/lessc.inc.php
1 file changed, 2 insertions(+), 2 deletions(-)

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



diff --git a/includes/libs/lessc.inc.php b/includes/libs/lessc.inc.php
index 57d45ed..e57dbcf 100644
--- a/includes/libs/lessc.inc.php
+++ b/includes/libs/lessc.inc.php
@@ -1,7 +1,7 @@
 http://leafo.net/lessphp
  *
  * LESS CSS compiler, adapted from http://lesscss.org
@@ -847,7 +847,7 @@
 * The input is expected to be reduced. This function will not work on
 * things like expressions and variables.
 */
-   protected function compileValue($value) {
+   public function compileValue($value) {
switch ($value[0]) {
case 'list':
// [1] - delimiter

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I499ddb01a662896fdcfe56d18021de5314e4d5d2
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: EBernhardson 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Resolve complex arguments to LESS helper functions - change (mediawiki/core)

2014-04-22 Thread EBernhardson (Code Review)
EBernhardson has uploaded a new change for review.

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

Change subject: Resolve complex arguments to LESS helper functions
..

Resolve complex arguments to LESS helper functions

The icons in Flow and the Compact Personal Bar beta feature are missing,
their generated background-image url is empty.

The lessphp implementation passes full data frames into the helper
functions.  Utilize the now-public compileValue method of less
to evaluate the data frame into a string.

Additionally adds a small abstraction to run pairs of less/css files
as unit tests by executing the less file and comparing it to the
equivilent css file.

Change-Id: I1b03196353c16104b8ea342c2de1c66e15141510
---
M includes/resourceloader/ResourceLoaderLESSFunctions.php
A tests/phpunit/includes/resourceloader/ResourceLoaderLESSTest.php
A tests/phpunit/includes/resourceloader/fixtures/001-embeddable.css
A tests/phpunit/includes/resourceloader/fixtures/001-embeddable.less
4 files changed, 68 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/94/129094/1

diff --git a/includes/resourceloader/ResourceLoaderLESSFunctions.php 
b/includes/resourceloader/ResourceLoaderLESSFunctions.php
index c7570f6..66253e2 100644
--- a/includes/resourceloader/ResourceLoaderLESSFunctions.php
+++ b/includes/resourceloader/ResourceLoaderLESSFunctions.php
@@ -37,7 +37,7 @@
 */
public static function embeddable( $frame, $less ) {
$base = pathinfo( $less->parser->sourceName, PATHINFO_DIRNAME );
-   $url = $frame[2][0];
+   $url = trim( $less->compileValue( $frame ), '"\'' );
$file = realpath( $base . '/' . $url );
return $less->toBool( $file
&& strpos( $url, '//' ) === false
@@ -57,11 +57,20 @@
 */
public static function embed( $frame, $less ) {
$base = pathinfo( $less->parser->sourceName, PATHINFO_DIRNAME );
-   $url = $frame[2][0];
+   $url = trim( $less->compileValue( $frame ), '"\'' );
$file = realpath( $base . '/' . $url );
 
$data = CSSMin::encodeImageAsDataURI( $file );
$less->addParsedFile( $file );
return 'url(' . $data . ')';
}
+
+   public static function compileValue( $less, $value ) {
+   static $reflMethod;
+   if ( $reflMethod === null ) {
+   $reflMethod = new ReflectionMethod( $less, 
'compileValue' );
+   $reflMethod->setAccessible( true );
+   }
+   return trim( $reflMethod->invoke( $less, $value ), '"\'' );
+   }
 }
diff --git a/tests/phpunit/includes/resourceloader/ResourceLoaderLESSTest.php 
b/tests/phpunit/includes/resourceloader/ResourceLoaderLESSTest.php
new file mode 100644
index 000..3b12e6f
--- /dev/null
+++ b/tests/phpunit/includes/resourceloader/ResourceLoaderLESSTest.php
@@ -0,0 +1,28 @@
+compile( $content, 
$lessFile );
+   $this->assertEquals( $expect, $result );
+   }
+}
diff --git a/tests/phpunit/includes/resourceloader/fixtures/001-embeddable.css 
b/tests/phpunit/includes/resourceloader/fixtures/001-embeddable.css
new file mode 100644
index 000..129ff68
--- /dev/null
+++ b/tests/phpunit/includes/resourceloader/fixtures/001-embeddable.css
@@ -0,0 +1,9 @@
+.box {
+  after: not-embeddable;
+}
+.box {
+  after: embeddable;
+}
+.box {
+  after: embeddable;
+}
diff --git a/tests/phpunit/includes/resourceloader/fixtures/001-embeddable.less 
b/tests/phpunit/includes/resourceloader/fixtures/001-embeddable.less
new file mode 100644
index 000..e7c4ac4
--- /dev/null
+++ b/tests/phpunit/includes/resourceloader/fixtures/001-embeddable.less
@@ -0,0 +1,20 @@
+@base: '../fixtures/';
+
+.helper(@url) when (embeddable(@url)) {
+   after: embeddable;
+}
+.helper(@url) when not (embeddable(@url)) {
+   after: not-embeddable;
+}
+
+.box {
+   .helper('path/to/nonexistant/file');
+}
+
+.box {
+   .helper('001-embeddable.css');
+}
+
+.box {
+   .helper("@{base}001-embeddable.css");
+}

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

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

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


[MediaWiki-commits] [Gerrit] Update lessphp to 2cc77e3c7b - change (mediawiki/core)

2014-04-22 Thread EBernhardson (Code Review)
EBernhardson has uploaded a new change for review.

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

Change subject: Update lessphp to 2cc77e3c7b
..

Update lessphp to 2cc77e3c7b

Source:
* https://github.com/leafo/lessphp/compare/b7cd5c79e8...2cc77e3c7b
* 
https://github.com/leafo/lessphp/blob/2cc77e3c7b9e84cf30ca64fccf2a45a84fbcf0d3/lessc.inc.php

Updates:
* 84b1fda0d4 Set visibility of lessc::compileValue to 'public'

Change-Id: I499ddb01a662896fdcfe56d18021de5314e4d5d2
---
M includes/libs/lessc.inc.php
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/93/129093/1

diff --git a/includes/libs/lessc.inc.php b/includes/libs/lessc.inc.php
index 57d45ed..e57dbcf 100644
--- a/includes/libs/lessc.inc.php
+++ b/includes/libs/lessc.inc.php
@@ -1,7 +1,7 @@
 http://leafo.net/lessphp
  *
  * LESS CSS compiler, adapted from http://lesscss.org
@@ -847,7 +847,7 @@
 * The input is expected to be reduced. This function will not work on
 * things like expressions and variables.
 */
-   protected function compileValue($value) {
+   public function compileValue($value) {
switch ($value[0]) {
case 'list':
// [1] - delimiter

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

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

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


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

2014-04-22 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: c034e31..0c82889
..


Syncronize VisualEditor: c034e31..0c82889

Change-Id: I392e03b10de1319ee1bcc981c771715ebbb1adb9
---
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 c034e31..0c82889 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit c034e31404226eee4d868f4e884d2b6399f37e4e
+Subproject commit 0c82889ac5062afedf36412aa3c67cf81caf78cb

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I392e03b10de1319ee1bcc981c771715ebbb1adb9
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: c034e31..0c82889 - change (mediawiki/extensions)

2014-04-22 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

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

Change subject: Syncronize VisualEditor: c034e31..0c82889
..

Syncronize VisualEditor: c034e31..0c82889

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/92/129092/1

diff --git a/VisualEditor b/VisualEditor
index c034e31..0c82889 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit c034e31404226eee4d868f4e884d2b6399f37e4e
+Subproject commit 0c82889ac5062afedf36412aa3c67cf81caf78cb

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I392e03b10de1319ee1bcc981c771715ebbb1adb9
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] Update built html files - change (mediawiki...VisualEditor)

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

Change subject: Update built html files
..


Update built html files

Change-Id: Iae32c35aca7cbdcce83b424763318a2609c3e9f1
---
M .docs/eg-iframe.html
1 file changed, 1 insertion(+), 2 deletions(-)

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



diff --git a/.docs/eg-iframe.html b/.docs/eg-iframe.html
index cd95f17..61307d4 100644
--- a/.docs/eg-iframe.html
+++ b/.docs/eg-iframe.html
@@ -237,12 +237,11 @@



-   



-   

+   




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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iae32c35aca7cbdcce83b424763318a2609c3e9f1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: 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] Update built html files - change (VisualEditor/VisualEditor)

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

Change subject: Update built html files
..


Update built html files

Change-Id: Ied44643e0557a45fc9ce93d322f47fc66e6d4c21
---
M .docs/eg-iframe.html
M demos/ve/index.html
M modules/ve/test/index.html
3 files changed, 3 insertions(+), 6 deletions(-)

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



diff --git a/.docs/eg-iframe.html b/.docs/eg-iframe.html
index e7dd4ec..e0c5fc7 100644
--- a/.docs/eg-iframe.html
+++ b/.docs/eg-iframe.html
@@ -237,12 +237,11 @@



-   



-   

+   



diff --git a/demos/ve/index.html b/demos/ve/index.html
index 51b49e6..a9a60e2 100644
--- a/demos/ve/index.html
+++ b/demos/ve/index.html
@@ -252,12 +252,11 @@



-   



-   

+   



diff --git a/modules/ve/test/index.html b/modules/ve/test/index.html
index ebccfbc..f1cade4 100644
--- a/modules/ve/test/index.html
+++ b/modules/ve/test/index.html
@@ -200,12 +200,11 @@



-   



-   

+   




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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ied44643e0557a45fc9ce93d322f47fc66e6d4c21
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: 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 resolve spec sheet issues - change (wikimedia...tools)

2014-04-22 Thread Adamw (Code Review)
Adamw has uploaded a new change for review.

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

Change subject: WIP resolve spec sheet issues
..

WIP resolve spec sheet issues

Change-Id: I9dc9a3fba9b0383444351da64507a369524086f5
---
M fundraising_ab_tests/spec.py
M fundraising_ab_tests/spec_gdoc.py
M google/gdocs.py
M live_analysis/.gitignore
4 files changed, 10 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/tools 
refs/changes/91/129091/1

diff --git a/fundraising_ab_tests/spec.py b/fundraising_ab_tests/spec.py
index 9598331..3764ce2 100644
--- a/fundraising_ab_tests/spec.py
+++ b/fundraising_ab_tests/spec.py
@@ -1,5 +1,6 @@
 '''
 TODO:
+* lots of refinement and clarification around test vs spec
 * match start_time to discriminate between mutations of an otherwise identical 
test...
 '''
 
@@ -51,6 +52,7 @@
 
 def update_from_logs(self):
 '''Try to reconstruct actual tests by parsing centralnotice change 
logs'''
+# FIXME: bad things happen here.  We're currently picking up one extra 
test duplicate  at the end of the list.
 
 for test_ending, test_beginning in campaign_log.get_relevant_events():
 if test_ending:
diff --git a/fundraising_ab_tests/spec_gdoc.py 
b/fundraising_ab_tests/spec_gdoc.py
index 9af5012..2fda42a 100644
--- a/fundraising_ab_tests/spec_gdoc.py
+++ b/fundraising_ab_tests/spec_gdoc.py
@@ -3,7 +3,8 @@
 from process.logging import Logger as log
 
 def read_gdoc_spec(doc=None):
-return 
FrTestSpec(spec=list(parse_spec(Spreadsheet(doc=doc).get_all_rows(
+rows = list(Spreadsheet(doc=doc).get_all_rows())
+return FrTestSpec(spec=list(parse_spec(rows)))
 
 def update_gdoc_spec(doc=None, spec=None):
 log.info("Updating test specs with latest CentralNotice changes... 
{url}".format(url=doc))
@@ -16,16 +17,16 @@
 
 doc = Spreadsheet(doc=doc)
 for index, test in enumerate(spec.spec, 0):
-test = spec.spec[index]
-rownum = index + 1
-if rownum < doc.num_rows():
+api_rownum = index + 1
+rownum = index + 2
+if api_rownum < doc.num_rows():
 if not hasattr(test, 'modified') or not test.modified:
 continue
 log.debug("updating spec end time in row {rownum}: 
{spec}".format(rownum=rownum, spec=test))
 if test.end_time:
-doc.update_row({'end': test.end_time}, index=rownum)
+doc.update_row({'end': test.end_time}, index=api_rownum)
 else:
-log.debug("appending spec row {rownum}: 
{spec}".format(rownum=index, spec=test))
+log.debug("appending spec row {rownum}: 
{spec}".format(rownum=rownum, spec=test))
 doc.append_row({
 'label': test.label,
 'type': "banner",
diff --git a/google/gdocs.py b/google/gdocs.py
index edad349..c987b12 100644
--- a/google/gdocs.py
+++ b/google/gdocs.py
@@ -131,7 +131,7 @@
 
 def get_all_rows(self):
 '''
-Dump entire spreadsheet to json
+Dump entire spreadsheet and return as a list of dicts
 '''
 feed = self.client.GetListFeed( self.doc_key, 
wksht_id=self.worksheet_id )
 for line in feed.entry:
diff --git a/live_analysis/.gitignore b/live_analysis/.gitignore
index a2b34d2..7a9f3bf 100644
--- a/live_analysis/.gitignore
+++ b/live_analysis/.gitignore
@@ -1,3 +1 @@
-*.pyc
-config.py
 jailenv

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9dc9a3fba9b0383444351da64507a369524086f5
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/tools
Gerrit-Branch: master
Gerrit-Owner: Adamw 

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


[MediaWiki-commits] [Gerrit] Show caption on thumbnails - change (mediawiki...MultimediaViewer)

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

Change subject: Show caption on thumbnails
..


Show caption on thumbnails

processThumb() is a mess. This change is kept small since we might
want to backport it per the bugzilla comments; I might follow up
with some refactoring in a separate commit.

Bug: 62518
Change-Id: I1f916b88fe1b667c6c7e51c9bdca186d4aa2ef2c
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/338
---
M resources/mmv/mmv.bootstrap.js
1 file changed, 3 insertions(+), 0 deletions(-)

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



diff --git a/resources/mmv/mmv.bootstrap.js b/resources/mmv/mmv.bootstrap.js
index 293600e..23f0c02 100755
--- a/resources/mmv/mmv.bootstrap.js
+++ b/resources/mmv/mmv.bootstrap.js
@@ -164,6 +164,9 @@
if ( $thumbContain.length !== 0 && $thumbContain.is( '.thumb' ) 
) {
$thumbCaption = $thumbContain.find( '.thumbcaption' 
).clone();
$thumbCaption.find( '.magnify' ).remove();
+   if ( !$thumbCaption.length ) { // gallery, maybe
+   $thumbCaption = $thumbContain.closest( 
'.gallerybox' ).find( '.gallerytext' ).clone();
+   }
caption = this.htmlUtils.htmlToTextWithLinks( 
$thumbCaption.html() || '' );
}
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1f916b88fe1b667c6c7e51c9bdca186d4aa2ef2c
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza 
Gerrit-Reviewer: Gilles 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Add git submodule update to hhvm build - change (integration/jenkins-job-builder-config)

2014-04-22 Thread BryanDavis (Code Review)
BryanDavis has uploaded a new change for review.

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

Change subject: Add git submodule update to hhvm build
..

Add git submodule update to hhvm build

The upstream repo changed to use a submodule for third-party
components on 2014-04-12 [0].

[0]: 
https://github.com/facebook/hhvm/commit/4c3be41811bea45f2f3be55541c05b817806738b

Change-Id: I60b3c931a5eb5d1359393490b8b4536a45021696
---
M hhvm.yaml
1 file changed, 1 insertion(+), 0 deletions(-)


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

diff --git a/hhvm.yaml b/hhvm.yaml
index 11dcdf6..10d784e 100644
--- a/hhvm.yaml
+++ b/hhvm.yaml
@@ -25,6 +25,7 @@
 
 builders:
   - shell: |
+  git submodule update --init --recursive
   cmake .
   make -j4
   cp "$WORKSPACE/hphp/hhvm/hhvm" /data/project/hhvm-builds/hhvm

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I60b3c931a5eb5d1359393490b8b4536a45021696
Gerrit-PatchSet: 1
Gerrit-Project: integration/jenkins-job-builder-config
Gerrit-Branch: master
Gerrit-Owner: BryanDavis 

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


[MediaWiki-commits] [Gerrit] Show caption on thumbnails - change (mediawiki...MultimediaViewer)

2014-04-22 Thread Code Review
Gergő Tisza has uploaded a new change for review.

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

Change subject: Show caption on thumbnails
..

Show caption on thumbnails

processThumb() is a mess. This change is kept small since we might
want to backport it per the bugzilla comments; I might follow up
with some refactoring in a separate commit.

Bug: 62518
Change-Id: I1f916b88fe1b667c6c7e51c9bdca186d4aa2ef2c
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/338
---
M resources/mmv/mmv.bootstrap.js
1 file changed, 3 insertions(+), 0 deletions(-)


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

diff --git a/resources/mmv/mmv.bootstrap.js b/resources/mmv/mmv.bootstrap.js
index 293600e..23f0c02 100755
--- a/resources/mmv/mmv.bootstrap.js
+++ b/resources/mmv/mmv.bootstrap.js
@@ -164,6 +164,9 @@
if ( $thumbContain.length !== 0 && $thumbContain.is( '.thumb' ) 
) {
$thumbCaption = $thumbContain.find( '.thumbcaption' 
).clone();
$thumbCaption.find( '.magnify' ).remove();
+   if ( !$thumbCaption.length ) { // gallery, maybe
+   $thumbCaption = $thumbContain.closest( 
'.gallerybox' ).find( '.gallerytext' ).clone();
+   }
caption = this.htmlUtils.htmlToTextWithLinks( 
$thumbCaption.html() || '' );
}
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1f916b88fe1b667c6c7e51c9bdca186d4aa2ef2c
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza 

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


[MediaWiki-commits] [Gerrit] Unclusterfuck per-char and -sentence trimming from ApiQueryE... - change (mediawiki...TextExtracts)

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

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

Change subject: Unclusterfuck per-char and -sentence trimming from 
ApiQueryExtracts
..

Unclusterfuck per-char and -sentence trimming from ApiQueryExtracts

Add tests. Comment out things that need to be fixed.

Change-Id: I21e1e3d99959147d89e6390c0572d2e16d6a3cbc
---
M ApiQueryExtracts.php
M ExtractFormatter.php
M ExtractFormatterTest.php
3 files changed, 140 insertions(+), 42 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/TextExtracts 
refs/changes/88/129088/1

diff --git a/ApiQueryExtracts.php b/ApiQueryExtracts.php
index 7178bdc..f8d6a09 100644
--- a/ApiQueryExtracts.php
+++ b/ApiQueryExtracts.php
@@ -59,8 +59,7 @@
break;
}
$text = $this->getExtract( $t );
-   $pageName = $t->getText();
-   $text = $this->truncate( $text, $pageName );
+   $text = $this->truncate( $text );
if ( $this->params['plaintext'] ) {
$text = $this->doSections( $text );
}
@@ -226,14 +225,13 @@
/**
 * Truncate the given text to a certain number of characters or 
sentences
 * @param string $text The text to truncate
-* @param string $pageName Title of the page (for debugging)
 * @return string
 */
-   private function truncate( $text, $pageName ) {
+   private function truncate( $text ) {
if ( $this->params['chars'] ) {
return $this->getFirstChars( $text, 
$this->params['chars'] );
} elseif ( $this->params['sentences'] ) {
-   return $this->getFirstSentences( $text, 
$this->params['sentences'], $pageName );
+   return $this->getFirstSentences( $text, 
$this->params['sentences'] );
}
return $text;
}
@@ -246,14 +244,7 @@
 */
private function getFirstChars( $text, $requestedLength ) {
wfProfileIn( __METHOD__ );
-   $length = mb_strlen( $text );
-   if ( $length <= $requestedLength ) {
-   wfProfileOut( __METHOD__ );
-   return $text;
-   }
-   $pattern = "#^.{{$requestedLength}}[\\w/]*>?#su";
-   preg_match( $pattern, $text, $m );
-   $text = $m[0];
+   $text = ExtractFormatter::getFirstChars( $text, 
$requestedLength );
// Fix possibly unclosed tags
$text = $this->tidy( $text );
$text .= wfMessage( 'ellipsis' )->inContentLanguage()->text();
@@ -264,35 +255,12 @@
/**
 * @param string $text
 * @param int $requestedSentenceCount
-* @param string $pageName Title of the page (for debugging)
 * @return string
 */
-   private function getFirstSentences( $text, $requestedSentenceCount, 
$pageName ) {
+   private function getFirstSentences( $text, $requestedSentenceCount ) {
wfProfileIn( __METHOD__ );
-   // Based on code from OpenSearchXml by Brion Vibber
-   $endchars = array(
-   '([^\d])\.\s', '\!\s', '\?\s', // regular ASCII
-   '。', // full-width ideographic full-stop
-   '.', '!', '?', // double-width roman forms
-   '。', // half-width ideographic full stop
-   );
 
-   $endgroup = implode( '|', $endchars );
-   $end = "(?:$endgroup)";
-   $sentence = ".+?$end+";
-   $regexp = "/^($sentence){1,{$requestedSentenceCount}}/u";
-   $matches = array();
-   $res = preg_match( $regexp, $text, $matches );
-   if( $res ) {
-   $text = $matches[0];
-   } else {
-   if ( $res === false ) {
-   wfLogWarning( "Regular expresssion compilation 
failure. Page: $pageName; RegEx: $regexp" );
-   }
-   // Just return the first line
-   $lines = explode( "\n", $text );
-   $text = trim( $lines[0] );
-   }
+   $text = ExtractFormatter::getFirstSentences( $text, 
$requestedSentenceCount );
$text = $this->tidy( $text );
wfProfileOut( __METHOD__ );
return $text;
diff --git a/ExtractFormatter.php b/ExtractFormatter.php
index 1508a7f..dc6d9e3 100644
--- a/ExtractFormatter.php
+++ b/ExtractFormatter.php
@@ -71,4 +71,58 @@
wfProfileOut( __METHOD__ );
return $html;
}
+
+   /**
+* @param string $text
+* @param int $

[MediaWiki-commits] [Gerrit] update language by size - change (pywikibot/core)

2014-04-22 Thread Maintenance-bot (Code Review)
Maintenance-bot has uploaded a new change for review.

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

Change subject: update language by size
..

update language by size

Change-Id: If34bacef4380f2eca708d62ea2dfbd3f1cc1689b
---
M pywikibot/families/wikibooks_family.py
M pywikibot/families/wikipedia_family.py
M pywikibot/families/wiktionary_family.py
3 files changed, 10 insertions(+), 10 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/87/129087/1

diff --git a/pywikibot/families/wikibooks_family.py 
b/pywikibot/families/wikibooks_family.py
index 9f61c00..a3a6476 100644
--- a/pywikibot/families/wikibooks_family.py
+++ b/pywikibot/families/wikibooks_family.py
@@ -13,7 +13,7 @@
 self.languages_by_size = [
 'en', 'de', 'fr', 'hu', 'ja', 'it', 'es', 'pt', 'nl', 'pl', 'he',
 'vi', 'id', 'sq', 'ca', 'fi', 'ru', 'fa', 'cs', 'zh', 'sv', 'da',
-'hr', 'tr', 'no', 'ar', 'th', 'sr', 'gl', 'ko', 'ta', 'mk', 'tl',
+'hr', 'tr', 'no', 'th', 'sr', 'ar', 'gl', 'ko', 'ta', 'mk', 'tl',
 'ro', 'is', 'ka', 'tt', 'lt', 'az', 'eo', 'uk', 'bg', 'sk', 'sl',
 'el', 'hy', 'ms', 'si', 'li', 'la', 'ml', 'ang', 'ur', 'ia', 'cv',
 'et', 'bn', 'hi', 'mr', 'oc', 'km', 'kk', 'eu', 'fy', 'ie', 'ne',
diff --git a/pywikibot/families/wikipedia_family.py 
b/pywikibot/families/wikipedia_family.py
index 2ebd060..1f2aa80 100644
--- a/pywikibot/families/wikipedia_family.py
+++ b/pywikibot/families/wikipedia_family.py
@@ -12,19 +12,19 @@
 
 self.languages_by_size = [
 'en', 'nl', 'de', 'sv', 'fr', 'it', 'ru', 'es', 'pl', 'war', 'ja',
-'ceb', 'vi', 'pt', 'zh', 'uk', 'ca', 'no', 'fa', 'fi', 'id', 'cs',
+'ceb', 'vi', 'pt', 'zh', 'uk', 'ca', 'no', 'fa', 'id', 'fi', 'cs',
 'ar', 'ko', 'hu', 'ms', 'sr', 'ro', 'tr', 'min', 'kk', 'eo', 'sk',
 'da', 'eu', 'lt', 'bg', 'sh', 'he', 'hr', 'sl', 'uz', 'et', 'vo',
 'hy', 'nn', 'gl', 'simple', 'hi', 'la', 'az', 'el', 'th', 'oc',
 'ka', 'mk', 'be', 'new', 'pms', 'tl', 'ta', 'te', 'tt', 'cy', 'lv',
 'ht', 'be-x-old', 'sq', 'bs', 'br', 'jv', 'mg', 'ur', 'lb', 'mr',
-'is', 'ml', 'pnb', 'ba', 'my', 'af', 'yo', 'ga', 'an', 'tg', 'lmo',
-'fy', 'bn', 'zh-yue', 'cv', 'ky', 'sw', 'io', 'ne', 'gu', 'bpy',
+'is', 'ml', 'pnb', 'ba', 'my', 'af', 'yo', 'ga', 'an', 'zh-yue',
+'tg', 'bn', 'lmo', 'fy', 'cv', 'ky', 'sw', 'io', 'ne', 'gu', 'bpy',
 'scn', 'ce', 'sco', 'nds', 'ku', 'ast', 'qu', 'su', 'als', 'kn',
-'am', 'ia', 'nap', 'bug', 'ckb', 'bat-smg', 'wa', 'map-bms', 'mn',
-'gd', 'arz', 'hif', 'mzn', 'zh-min-nan', 'yi', 'si', 'sah', 'vec',
-'pa', 'sa', 'nah', 'bar', 'os', 'roa-tara', 'fo', 'pam', 'hsb',
-'or', 'se', 'li', 'mi', 'ilo', 'co', 'gan', 'frr', 'bo', 'glk',
+'am', 'ia', 'nap', 'bug', 'ckb', 'bat-smg', 'wa', 'map-bms', 'gd',
+'mn', 'arz', 'mzn', 'zh-min-nan', 'yi', 'si', 'sah', 'pa', 'vec',
+'sa', 'nah', 'bar', 'os', 'roa-tara', 'fo', 'pam', 'hsb', 'or',
+'se', 'li', 'mi', 'ilo', 'co', 'hif', 'gan', 'frr', 'bo', 'glk',
 'rue', 'bcl', 'nds-nl', 'fiu-vro', 'mrj', 'ps', 'tk', 'vls', 'gv',
 'xmf', 'pag', 'diq', 'km', 'zea', 'kv', 'mhr', 'csb', 'vep', 'ay',
 'hak', 'dv', 'so', 'nrm', 'rm', 'udm', 'koi', 'sc', 'zh-classical',
@@ -36,7 +36,7 @@
 'cbk-zam', 'av', 'ty', 'srn', 'bxr', 'ig', 'kg', 'tet', 'na', 'ab',
 'ltg', 'nso', 'za', 'kaa', 'zu', 'ha', 'chy', 'rmy', 'cu', 'chr',
 'tn', 'cdo', 'roa-rup', 'bi', 'pih', 'tyv', 'got', 'tw', 'sm', 
'bm',
-'iu', 'ss', 'sd', 'pnt', 'ki', 'rn', 'ee', 'om', 'ts', 'xh', 'ak',
+'iu', 'ss', 'sd', 'pnt', 'ki', 'rn', 'om', 'ee', 'ts', 'xh', 'ak',
 'fj', 'ti', 'ks', 'sg', 'ff', 've', 'cr', 'lg', 'st', 'dz', 'tum',
 'ik', 'ny', 'ch',
 ]
diff --git a/pywikibot/families/wiktionary_family.py 
b/pywikibot/families/wiktionary_family.py
index 80dc5b1..db1544e 100644
--- a/pywikibot/families/wiktionary_family.py
+++ b/pywikibot/families/wiktionary_family.py
@@ -12,7 +12,7 @@
 
 self.languages_by_size = [
 'en', 'mg', 'fr', 'sh', 'zh', 'es', 'lt', 'ru', 'el', 'pl', 'nl',
-'sv', 'ko', 'de', 'tr', 'ku', 'ta', 'hu', 'kn', 'it', 'fi', 'io',
+'sv', 'ko', 'de', 'tr', 'ku', 'ta', 'hu', 'it', 'kn', 'fi', 'io',
 'vi', 'chr', 'pt', 'no', 'ml', 'my', 'id', 'li', 'ro', 'ja', 'et',
 'te', 'jv', 'fa', 'cs', 'ca', 'ar', 'eu', 'gl', 'lo', 'uk', 'hy',
 'br', 'fj', 'eo', 'bg', 'hr', 'th', 'oc', 'is', 'vo', 'ps', 'uz',

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

Gerrit-MessageType: newchange
Gerrit-C

[MediaWiki-commits] [Gerrit] update language by size - change (pywikibot/compat)

2014-04-22 Thread Maintenance-bot (Code Review)
Maintenance-bot has uploaded a new change for review.

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

Change subject: update language by size
..

update language by size

Change-Id: I594b97eceac3f8ff3610f15203ef7b9449d05bb9
---
M families/wikibooks_family.py
M families/wikipedia_family.py
M families/wiktionary_family.py
3 files changed, 10 insertions(+), 10 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/compat 
refs/changes/86/129086/1

diff --git a/families/wikibooks_family.py b/families/wikibooks_family.py
index 479caf1..766bc56 100644
--- a/families/wikibooks_family.py
+++ b/families/wikibooks_family.py
@@ -13,7 +13,7 @@
 self.languages_by_size = [
 'en', 'de', 'fr', 'hu', 'ja', 'it', 'es', 'pt', 'nl', 'pl', 'he',
 'vi', 'id', 'sq', 'ca', 'fi', 'ru', 'fa', 'cs', 'zh', 'sv', 'da',
-'hr', 'tr', 'no', 'ar', 'th', 'sr', 'gl', 'ko', 'ta', 'mk', 'tl',
+'hr', 'tr', 'no', 'th', 'sr', 'ar', 'gl', 'ko', 'ta', 'mk', 'tl',
 'ro', 'is', 'ka', 'tt', 'lt', 'az', 'eo', 'uk', 'bg', 'sk', 'sl',
 'el', 'hy', 'ms', 'si', 'li', 'la', 'ml', 'ang', 'ur', 'ia', 'cv',
 'et', 'bn', 'hi', 'mr', 'oc', 'km', 'kk', 'eu', 'fy', 'ie', 'ne',
diff --git a/families/wikipedia_family.py b/families/wikipedia_family.py
index 38f0cef..e5cce33 100644
--- a/families/wikipedia_family.py
+++ b/families/wikipedia_family.py
@@ -12,19 +12,19 @@
 
 self.languages_by_size = [
 'en', 'nl', 'de', 'sv', 'fr', 'it', 'ru', 'es', 'pl', 'war', 'ja',
-'ceb', 'vi', 'pt', 'zh', 'uk', 'ca', 'no', 'fa', 'fi', 'id', 'cs',
+'ceb', 'vi', 'pt', 'zh', 'uk', 'ca', 'no', 'fa', 'id', 'fi', 'cs',
 'ar', 'ko', 'hu', 'ms', 'sr', 'ro', 'tr', 'min', 'kk', 'eo', 'sk',
 'da', 'eu', 'lt', 'bg', 'sh', 'he', 'hr', 'sl', 'uz', 'et', 'vo',
 'hy', 'nn', 'gl', 'simple', 'hi', 'la', 'az', 'el', 'th', 'oc',
 'ka', 'mk', 'be', 'new', 'pms', 'tl', 'ta', 'te', 'tt', 'cy', 'lv',
 'ht', 'be-x-old', 'sq', 'bs', 'br', 'jv', 'mg', 'ur', 'lb', 'mr',
-'is', 'ml', 'pnb', 'ba', 'my', 'af', 'yo', 'ga', 'an', 'tg', 'lmo',
-'fy', 'bn', 'zh-yue', 'cv', 'ky', 'sw', 'io', 'ne', 'gu', 'bpy',
+'is', 'ml', 'pnb', 'ba', 'my', 'af', 'yo', 'ga', 'an', 'zh-yue',
+'tg', 'bn', 'lmo', 'fy', 'cv', 'ky', 'sw', 'io', 'ne', 'gu', 'bpy',
 'scn', 'ce', 'sco', 'nds', 'ku', 'ast', 'qu', 'su', 'als', 'kn',
-'am', 'ia', 'nap', 'bug', 'ckb', 'bat-smg', 'wa', 'map-bms', 'mn',
-'gd', 'arz', 'hif', 'mzn', 'zh-min-nan', 'yi', 'si', 'sah', 'vec',
-'pa', 'sa', 'nah', 'bar', 'os', 'roa-tara', 'fo', 'pam', 'hsb',
-'or', 'se', 'li', 'mi', 'ilo', 'co', 'gan', 'frr', 'bo', 'glk',
+'am', 'ia', 'nap', 'bug', 'ckb', 'bat-smg', 'wa', 'map-bms', 'gd',
+'mn', 'arz', 'mzn', 'zh-min-nan', 'yi', 'si', 'sah', 'pa', 'vec',
+'sa', 'nah', 'bar', 'os', 'roa-tara', 'fo', 'pam', 'hsb', 'or',
+'se', 'li', 'mi', 'ilo', 'co', 'hif', 'gan', 'frr', 'bo', 'glk',
 'rue', 'bcl', 'nds-nl', 'fiu-vro', 'mrj', 'ps', 'tk', 'vls', 'gv',
 'xmf', 'pag', 'diq', 'km', 'zea', 'kv', 'mhr', 'csb', 'vep', 'ay',
 'hak', 'dv', 'so', 'nrm', 'rm', 'udm', 'koi', 'sc', 'zh-classical',
@@ -36,7 +36,7 @@
 'cbk-zam', 'av', 'ty', 'srn', 'bxr', 'ig', 'kg', 'tet', 'na', 'ab',
 'ltg', 'nso', 'za', 'kaa', 'zu', 'ha', 'chy', 'rmy', 'cu', 'chr',
 'tn', 'cdo', 'roa-rup', 'bi', 'pih', 'tyv', 'got', 'tw', 'sm', 
'bm',
-'iu', 'ss', 'sd', 'pnt', 'ki', 'rn', 'ee', 'om', 'ts', 'xh', 'ak',
+'iu', 'ss', 'sd', 'pnt', 'ki', 'rn', 'om', 'ee', 'ts', 'xh', 'ak',
 'fj', 'ti', 'ks', 'sg', 'ff', 've', 'cr', 'lg', 'st', 'dz', 'tum',
 'ik', 'ny', 'ch',
 ]
diff --git a/families/wiktionary_family.py b/families/wiktionary_family.py
index 9be0dae..a75737b 100644
--- a/families/wiktionary_family.py
+++ b/families/wiktionary_family.py
@@ -12,7 +12,7 @@
 
 self.languages_by_size = [
 'en', 'mg', 'fr', 'sh', 'zh', 'es', 'lt', 'ru', 'el', 'pl', 'nl',
-'sv', 'ko', 'de', 'tr', 'ku', 'ta', 'hu', 'kn', 'it', 'fi', 'io',
+'sv', 'ko', 'de', 'tr', 'ku', 'ta', 'hu', 'it', 'kn', 'fi', 'io',
 'vi', 'chr', 'pt', 'no', 'ml', 'my', 'id', 'li', 'ro', 'ja', 'et',
 'te', 'jv', 'fa', 'cs', 'ca', 'ar', 'eu', 'gl', 'lo', 'uk', 'hy',
 'br', 'fj', 'eo', 'bg', 'hr', 'th', 'oc', 'is', 'vo', 'ps', 'uz',

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I594b97eceac3f8ff3610f15203ef7b9449d05bb9
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/compat
Gerrit-Branch: master
Gerrit-Owner: Maintenance

[MediaWiki-commits] [Gerrit] Add mediawiki.jqueryMsg as a dependency for mmv.ui.fileUsage - change (mediawiki...MultimediaViewer)

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

Change subject: Add mediawiki.jqueryMsg as a dependency for mmv.ui.fileUsage
..


Add mediawiki.jqueryMsg as a dependency for mmv.ui.fileUsage

The Hebrew translation of a message there uses GRAMMAR,
so this module is needed.

Change-Id: I1ffe9a936a071709e7049bc0ffec77123cb42fd1
---
M MultimediaViewer.php
1 file changed, 1 insertion(+), 0 deletions(-)

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



diff --git a/MultimediaViewer.php b/MultimediaViewer.php
index b8bbe55..f67b30d 100644
--- a/MultimediaViewer.php
+++ b/MultimediaViewer.php
@@ -340,6 +340,7 @@
),
 
'dependencies' => array(
+   'mediawiki.jqueryMsg',
'mmv.ui',
'oojs',
'jquery.tipsy',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1ffe9a936a071709e7049bc0ffec77123cb42fd1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: master
Gerrit-Owner: Amire80 
Gerrit-Reviewer: Gilles 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Hygiene: Standardise on our icons - change (mediawiki...MobileFrontend)

2014-04-22 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

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

Change subject: Hygiene: Standardise on our icons
..

Hygiene: Standardise on our icons

Effects
* clean up templates
* user profile talk icon
* nearby refresh icon
* special uploads upload button
* pagelist images
* user icons
* page actions icon
* left menu icons
* main navigation icons

Change-Id: I36b77cfa605d561fcbb8a5ed84fcbfd87722411f
---
M includes/MobilePage.php
M includes/Resources.php
M includes/skins/MinervaTemplate.php
M includes/skins/SkinMinerva.php
M includes/skins/SkinMinervaAlpha.php
M includes/specials/MobileSpecialPageFeed.php
M includes/specials/SpecialMobileContributions.php
M includes/specials/SpecialMobileDiff.php
M includes/specials/SpecialMobileWatchlist.php
M includes/specials/SpecialUserProfile.php
M javascripts/modules/editor/editor.js
M javascripts/modules/mf-watchstar.js
M javascripts/modules/nearby/NearbyApi.js
M javascripts/modules/nearby/PagePreviewOverlay.js
M javascripts/modules/nearbypages.js
M javascripts/modules/notifications/NotificationsOverlay.js
M javascripts/modules/search/pageImages.js
M javascripts/specials/nearby.js
M less/common/OverlayNew.less
M less/common/common-js.less
A less/common/icons.less
D less/common/overlays.less
M less/common/pageactions.less
M less/common/pagelist.less
M less/common/secondaryPageActions.less
M less/common/ui.less
M less/common/uiNew.less
M less/minerva.less/minerva.variables.less
M less/modules/issues.less
M less/modules/uploads/PhotoUploaderButton.less
M less/specials/nearby.less
M less/specials/pagefeed.less
M less/specials/userprofile.less
M templates/modules/editor/EditorOverlayBase.html
M templates/page.html
M templates/uploads/PhotoUploaderButton.html
M tests/javascripts/modules/nearby/test_NearbyApi.js
37 files changed, 109 insertions(+), 190 deletions(-)


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

diff --git a/includes/MobilePage.php b/includes/MobilePage.php
index 7323609..c02ed92 100644
--- a/includes/MobilePage.php
+++ b/includes/MobilePage.php
@@ -29,7 +29,7 @@
 
static function getPlaceHolderThumbnailHtml( $className ) {
return Html::element( 'div', array(
-   'class' => 'listThumb list-thumb-placeholder ' . 
$className,
+   'class' => 'listThumb list-thumb-placeholder icon 
icon-32px ' . $className,
) );
}
 
@@ -64,8 +64,8 @@
if ( $thumb && $thumb->getUrl() ) {
$className = 'listThumb ';
$className .= $thumb->getWidth() > 
$thumb->getHeight()
-   ? 'listThumbH'
-   : 'listThumbV';
+   ? 'icon icon-max-y'
+   : 'icon icon-max-x';
$props = array(
'class' => $className,
);
diff --git a/includes/Resources.php b/includes/Resources.php
index b42633d..e1311a1 100644
--- a/includes/Resources.php
+++ b/includes/Resources.php
@@ -129,6 +129,7 @@
'skins.minerva.content.styles' => $wgMFMobileResourceBoilerplate + 
array(
'styles' => array(
'less/common/common.less',
+   'less/common/icons.less',
'less/common/typography.less',
'less/modules/toggle.less',
'less/common/hacks.less',
@@ -666,8 +667,6 @@
),
'styles' => array(
'less/common/OverlayNew.less',
-   // @todo FIXME: remove when all new overlays moved to 
stable
-   'less/common/overlays.less',
)
),
 
diff --git a/includes/skins/MinervaTemplate.php 
b/includes/skins/MinervaTemplate.php
index 40f4939..bbac33a 100644
--- a/includes/skins/MinervaTemplate.php
+++ b/includes/skins/MinervaTemplate.php
@@ -122,7 +122,8 @@
$languageLabel = wfMessage( 
'mobile-frontend-language-article-heading' )->text();
 
echo Html::element( 'a', array(
-   'class' => 'mw-ui-button mw-ui-progressive 
button languageSelector is-border-box',
+   'class' => 'mw-ui-button mw-ui-progressive 
button
+   languageSelector is-border-box icon 
icon-30px',
'href' => $languageUrl
), $languageLabel );
}
diff --git a/includes/skins/SkinMinerva.php b/includes/skins/SkinMinerva.php
index 4be7eb6..6109061 100644
--- a/includes/skins/SkinM

[MediaWiki-commits] [Gerrit] Hygiene: Introduce is-border-box class - change (mediawiki...MobileFrontend)

2014-04-22 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

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

Change subject: Hygiene: Introduce is-border-box class
..

Hygiene: Introduce is-border-box class

Apply to
* Carousel for first time uploaders
* Overlays and inputs inside them
* Inputs on login form
* Left navigation drawer and main content drawer
* Upload Progress bar
* Secondary page action links to languages and geonotahack
* Main search input form
* toast
* Textarea in photo upload overlay
* User info box in diff page
* profile page captions

Change-Id: Ifd377b2310f806d002ac2d3e9846765aea59eb9f
---
M includes/skins/MinervaTemplate.php
M includes/skins/SkinMinerva.php
M includes/skins/UserLoginMobileTemplate.php
M includes/specials/SpecialMobileDiff.php
M includes/specials/SpecialUserProfile.php
M javascripts/common/OverlayNew.js
M javascripts/common/toast.js
M javascripts/modules/editor/EditorOverlayBase.js
M javascripts/modules/editor/VisualEditorOverlay.js
M javascripts/modules/nearbypages.js
M javascripts/modules/notifications/NotificationsOverlay.js
M javascripts/modules/uploads/PhotoUploadOverlay.js
M javascripts/modules/uploads/UploadTutorial.js
M javascripts/widgets/progress-bar.js
M less/common/OverlayNew.less
M less/common/common-js.less
M less/common/common.less
M less/common/mainmenu.less
M less/common/secondaryPageActions.less
M less/common/toast.less
M less/common/ui.less
M less/modules/uploads/PhotoUploadOverlay.less
M less/modules/uploads/UploadTutorial.less
M less/specials/mobilediff.less
M less/specials/userprofile.less
M templates/OverlayNew.html
M templates/modules/editor/EditorOverlay.html
M templates/modules/editor/EditorOverlayBase.html
M templates/modules/search/SearchOverlay.html
M templates/overlays/talkSectionAdd.html
M templates/page.html
M templates/talkSection.html
M templates/uploads/PhotoUploadOverlay.html
M templates/uploads/PhotoUploadProgress.html
M tests/browser/features/support/pages/article_page.rb
35 files changed, 48 insertions(+), 60 deletions(-)


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

diff --git a/includes/skins/MinervaTemplate.php 
b/includes/skins/MinervaTemplate.php
index bc29a4d..40f4939 100644
--- a/includes/skins/MinervaTemplate.php
+++ b/includes/skins/MinervaTemplate.php
@@ -122,7 +122,7 @@
$languageLabel = wfMessage( 
'mobile-frontend-language-article-heading' )->text();
 
echo Html::element( 'a', array(
-   'class' => 'mw-ui-button mw-ui-progressive 
button languageSelector',
+   'class' => 'mw-ui-button mw-ui-progressive 
button languageSelector is-border-box',
'href' => $languageUrl
), $languageLabel );
}
@@ -224,12 +224,12 @@
echo $data[ 'headelement' ];
?>

-   
+   
renderMainMenu( $data );
?>

-   
+   
data['banners'] as 
$banner ):
echo $banner;
diff --git a/includes/skins/SkinMinerva.php b/includes/skins/SkinMinerva.php
index 4102a41..4be7eb6 100644
--- a/includes/skins/SkinMinerva.php
+++ b/includes/skins/SkinMinerva.php
@@ -466,6 +466,7 @@
return $link;
}
 
+   // FIXME: Move to MinervaTemplate
protected function getSearchPlaceHolderText() {
return wfMessage( 'mobile-frontend-placeholder' )->text();
}
@@ -514,10 +515,11 @@
}
}
 
+   // FIXME: Move to MinervaTemplate
protected function prepareSearch( BaseTemplate $tpl ) {
$searchBox = array(
'id' => 'searchInput',
-   'class' => 'search',
+   'class' => 'search is-border-box',
'autocomplete' => 'off',
// The placeholder gets fed to HTML::element later 
which escapes all
// attribute values, so no need to escape the string 
here.
diff --git a/includes/skins/UserLoginMobileTemplate.php 
b/includes/skins/UserLoginMobileTemplate.php
index 49102b5..e53ae35 100644
--- a/includes/skins/UserLoginMobileTemplate.php
+++ b/includes/skins/UserLoginMobileTemplate.php
@@ -62,14 +62,14 @@
'class' => 'inputs-box',
) ) .
Html::input( 'wpName', $username, 'text',
-   array( 'class' => 'loginText',
+   array( 'class' => 'loginText is-border-box',
'placeholder' => wfMessage( 
'mobile-frontend-username-placeho

[MediaWiki-commits] [Gerrit] Update to localCache should sync with bufferCache - change (mediawiki...Flow)

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

Change subject: Update to localCache should sync with bufferCache
..


Update to localCache should sync with bufferCache

Currently update to localCache is purged immediately while bufferCache
waits till db transaction is complete.  If we access a cache key in the
middle of the two events, localCache would cache the out of date
cache again, any subsequent access to the same cache key would have
invalid data.

This is causing a problem in moderation, for example, 'unhide' won't appear
on the action menu after a 'hide' action untill the page refreshes,

Bug: 64200
Change-Id: I4db8248b493d1b85bcf2230613c47c44a1e5e729
---
M includes/Data/LocalBufferedCache.php
1 file changed, 33 insertions(+), 2 deletions(-)

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



diff --git a/includes/Data/LocalBufferedCache.php 
b/includes/Data/LocalBufferedCache.php
index 0b3d975..766dc87 100644
--- a/includes/Data/LocalBufferedCache.php
+++ b/includes/Data/LocalBufferedCache.php
@@ -5,7 +5,20 @@
 // Untested method of handling duplicate requests for the same data
 // Preserves any BagOStuff semantics like BufferedCache does
 class LocalBufferedCache extends BufferedCache {
+
+   /**
+* Local cache
+*
+* @var array
+*/
protected $internal = array();
+
+   /**
+* List of update to localCache upon cache commit
+*
+* @var \Closure[]
+*/
+   protected $bufferUpdate = array();
 
/**
 * Returns true if the data is in own "storage" already, or false if it 
will
@@ -55,6 +68,8 @@
return $found;
}
 
+   // @Todo - Use bufferUpdate[] to update local cache if buffer cache is 
enabled,
+   // need to make sure that no code relies on the new dangling local 
cache value
public function add( $key, $value ) {
if ( $this->buffer === null ) {
if ( $this->cache->add( $key, $value, $this->exptime ) 
) {
@@ -73,6 +88,8 @@
}
}
 
+   // @Todo - Use bufferUpdate[] to update local cache if buffer cache is 
enabled,
+   // need to make sure that no code relies on the new dangling local 
cache value
public function set( $key, $value ) {
parent::set( $key, $value );
$this->internal[$key] = $value;
@@ -82,8 +99,22 @@
parent::merge( $key, $callback, $attempts );
 
// data is being merged into this key, so invalidate the cached 
version
-   unset( $this->internal[$key] );
+   if ( $this->buffer === null ) {
+   unset( $this->internal[$key] );
+   } else {
+   $internal =& $this->internal;
+   $this->bufferUpdate[] = function() use ( $key, 
&$internal ) {
+   unset( $internal[$key] );
+   };
+   }
+   }
 
-   // @todo: we should figure out a way to properly implement this
+   public function commit() {
+   parent::commit();
+
+   foreach ( $this->bufferUpdate as $closure ) {
+   call_user_func( $closure );
+   }
+   $this->bufferUpdate = array();
}
 }

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I4db8248b493d1b85bcf2230613c47c44a1e5e729
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: Bsitu 
Gerrit-Reviewer: EBernhardson 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Hygiene: Rewrite ContentOverlay as child of OverlayNew, kill... - change (mediawiki...MobileFrontend)

2014-04-22 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

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

Change subject: Hygiene: Rewrite ContentOverlay as child of OverlayNew, kill 
LoadingOverlay
..

Hygiene: Rewrite ContentOverlay as child of OverlayNew, kill LoadingOverlay

This begins deprecation of the old Overlay class.

Change-Id: Icfdbdfde4ee831261d57013b4b790400d7426044
---
M includes/Resources.php
D javascripts/common/LoadingOverlay.js
M javascripts/modules/nearby/Nearby.js
M javascripts/modules/tutorials/ContentOverlay.js
4 files changed, 2 insertions(+), 19 deletions(-)


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

diff --git a/includes/Resources.php b/includes/Resources.php
index b42633d..d401b35 100644
--- a/includes/Resources.php
+++ b/includes/Resources.php
@@ -647,7 +647,6 @@
'scripts' => array(
// @todo FIXME: remove when all new overlays moved to 
stable
'javascripts/common/Overlay.js',
-   'javascripts/common/LoadingOverlay.js',
 
'javascripts/common/OverlayNew.js',
'javascripts/common/LoadingOverlayNew.js',
diff --git a/javascripts/common/LoadingOverlay.js 
b/javascripts/common/LoadingOverlay.js
deleted file mode 100644
index 2605bb3..000
--- a/javascripts/common/LoadingOverlay.js
+++ /dev/null
@@ -1,16 +0,0 @@
-( function( M ) {
-   var Overlay = M.require( 'Overlay' ), LoadingOverlay;
-
-   /**
-* @name LoadingOverlay
-* @class
-* @extends Overlay
-*/
-   LoadingOverlay = Overlay.extend( {
-   templatePartials: {
-   content: M.template.get( 'LoadingOverlay' )
-   }
-   } );
-
-   M.define( 'LoadingOverlay', LoadingOverlay );
-}( mw.mobileFrontend ) );
diff --git a/javascripts/modules/nearby/Nearby.js 
b/javascripts/modules/nearby/Nearby.js
index d9d984c..05c9913 100644
--- a/javascripts/modules/nearby/Nearby.js
+++ b/javascripts/modules/nearby/Nearby.js
@@ -2,7 +2,7 @@
var NearbyApi = M.require( 'modules/nearby/NearbyApi' ),
View = M.require( 'View' ),
MobileWebClickTracking = M.require( 
'loggingSchemas/MobileWebClickTracking' ),
-   LoadingOverlay = M.require( 'LoadingOverlay' ),
+   LoadingOverlay = M.require( 'LoadingOverlayNew' ),
loader = new LoadingOverlay(),
Nearby;
 
diff --git a/javascripts/modules/tutorials/ContentOverlay.js 
b/javascripts/modules/tutorials/ContentOverlay.js
index 81a148c..42ef1aa 100644
--- a/javascripts/modules/tutorials/ContentOverlay.js
+++ b/javascripts/modules/tutorials/ContentOverlay.js
@@ -1,6 +1,6 @@
 ( function( M, $ ) {
 
-   var Overlay = M.require( 'Overlay' ), ContentOverlay;
+   var Overlay = M.require( 'OverlayNew' ), ContentOverlay;
 
/**
 * An {@link Overlay} that points at an element on the page.

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

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

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


[MediaWiki-commits] [Gerrit] Fix Chrome bug where popstate could still reset scroll position - change (mediawiki...MultimediaViewer)

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

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

Change subject: Fix Chrome bug where popstate could still reset scroll position
..

Fix Chrome bug where popstate could still reset scroll position

Change-Id: I3418b2e446a210a406daacc1321103df1f09caa1
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/486
---
M resources/mmv/mmv.bootstrap.js
1 file changed, 4 insertions(+), 2 deletions(-)


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

diff --git a/resources/mmv/mmv.bootstrap.js b/resources/mmv/mmv.bootstrap.js
index 293600e..9e5448a 100755
--- a/resources/mmv/mmv.bootstrap.js
+++ b/resources/mmv/mmv.bootstrap.js
@@ -373,6 +373,8 @@
 * Cleans up the overlay
 */
MMVB.cleanupOverlay = function () {
+   var bootstrap = this;
+
$( document.body ).removeClass( 'mw-mmv-lightbox-open' );
 
if ( this.$overlay ) {
@@ -380,8 +382,8 @@
}
 
if ( this.savedScroll ) {
-   $.scrollTo( this.savedScroll, 0 );
-   this.savedScroll = undefined;
+   // setTimeout because otherwise Chrome will scroll back 
to top after the popstate event handlers run
+   setTimeout( function() { $.scrollTo( 
bootstrap.savedScroll, 0 ); bootstrap.savedScroll = undefined; }, 0 );
}
};
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3418b2e446a210a406daacc1321103df1f09caa1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: master
Gerrit-Owner: Gilles 

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


[MediaWiki-commits] [Gerrit] Prevent SurfaceWidgets from focussing themselves - change (VisualEditor/VisualEditor)

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

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

Change subject: Prevent SurfaceWidgets from focussing themselves
..

Prevent SurfaceWidgets from focussing themselves

Bug: 63909
Change-Id: I45537ba813bc177667de75463e4e53e19378d3e3
---
M modules/ve/ui/widgets/ve.ui.SurfaceWidget.js
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/81/129081/1

diff --git a/modules/ve/ui/widgets/ve.ui.SurfaceWidget.js 
b/modules/ve/ui/widgets/ve.ui.SurfaceWidget.js
index 90a0173..8f7a11a 100644
--- a/modules/ve/ui/widgets/ve.ui.SurfaceWidget.js
+++ b/modules/ve/ui/widgets/ve.ui.SurfaceWidget.js
@@ -99,7 +99,6 @@
 ve.ui.SurfaceWidget.prototype.initialize = function () {
this.toolbar.initialize();
this.surface.initialize();
-   this.surface.view.documentView.getDocumentNode().$element.focus();
 };
 
 /**

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I45537ba813bc177667de75463e4e53e19378d3e3
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders 

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


[MediaWiki-commits] [Gerrit] Add debug bars to surface widgets - change (VisualEditor/VisualEditor)

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

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

Change subject: Add debug bars to surface widgets
..

Add debug bars to surface widgets

Change-Id: Ic0fff2e65c76562f986a6bc6f0a34f2d594d462b
---
M modules/ve/ui/styles/widgets/ve.ui.SurfaceWidget.css
M modules/ve/ui/widgets/ve.ui.SurfaceWidget.js
2 files changed, 18 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/80/129080/1

diff --git a/modules/ve/ui/styles/widgets/ve.ui.SurfaceWidget.css 
b/modules/ve/ui/styles/widgets/ve.ui.SurfaceWidget.css
index 65482e1..66bcd23 100644
--- a/modules/ve/ui/styles/widgets/ve.ui.SurfaceWidget.css
+++ b/modules/ve/ui/styles/widgets/ve.ui.SurfaceWidget.css
@@ -7,9 +7,6 @@
 
 .ve-ui-surfaceWidget-surface {
border: 1px solid #ddd;
-   border-radius: 0.25em;
-   border-top-right-radius: 0;
-   border-top-left-radius: 0;
 }
 
 .ve-ui-surfaceWidget-surface .ve-ce-documentNode {
@@ -27,3 +24,15 @@
border-bottom-left-radius: 0;
border-bottom-width: 0;
 }
+
+.ve-ui-surfaceWidget > .ve-init-debugBar {
+   border: 1px solid #ddd;
+   border-top-width: 0;
+   margin: 0;
+}
+
+.ve-ui-surfaceWidget > div:last-child {
+   border-radius: 0.25em;
+   border-top-right-radius: 0;
+   border-top-left-radius: 0;
+}
\ No newline at end of file
diff --git a/modules/ve/ui/widgets/ve.ui.SurfaceWidget.js 
b/modules/ve/ui/widgets/ve.ui.SurfaceWidget.js
index db56599..90a0173 100644
--- a/modules/ve/ui/widgets/ve.ui.SurfaceWidget.js
+++ b/modules/ve/ui/widgets/ve.ui.SurfaceWidget.js
@@ -45,6 +45,12 @@
if ( config.pasteRules ) {
this.surface.setPasteRules( config.pasteRules );
}
+
+   if ( ve.debug ) {
+   var debugBar = new ve.init.DebugBar();
+   debugBar.attachToSurface( this.surface );
+   this.$element.append( debugBar.$element );
+   }
 };
 
 /* Inheritance */

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic0fff2e65c76562f986a6bc6f0a34f2d594d462b
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders 

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


[MediaWiki-commits] [Gerrit] Some cleanup + trace dom range identification - change (mediawiki...parsoid)

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

Change subject: Some cleanup + trace dom range identification
..


Some cleanup + trace dom range identification

* Refactored some common code.

* After wasting an hour tracing a non-bug after being confused by
  different tables marked by identical about-ids, fixed trace
  output to prominently emit tag-ids for tables so it is clear
  that different table elements are being examined.

* Added tracing for finding DOM ranges and marked a potential
  bug with a FIXME.

Change-Id: I19ac27f57ccce31580069279df3fa835aa038d73
---
M lib/dom.wrapTemplates.js
1 file changed, 35 insertions(+), 25 deletions(-)

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



diff --git a/lib/dom.wrapTemplates.js b/lib/dom.wrapTemplates.js
index 874a773..61b1d87 100644
--- a/lib/dom.wrapTemplates.js
+++ b/lib/dom.wrapTemplates.js
@@ -47,32 +47,26 @@
// now find common ancestor
var elem = endElem;
var parentNode = endElem.parentNode;
-   var range = null;
+   var range = {
+   startElem: startElem,
+   endElem: endMeta,
+   id: env.stripIdPrefix(startElem.getAttribute("about")),
+   startOffset: DU.getDataParsoid( startElem ).tsr[0],
+   flipped: false
+   };
while (parentNode && parentNode.nodeType !== doc.DOCUMENT_NODE) {
var i = startAncestors.indexOf( parentNode );
-   var tsr0 = DU.getDataParsoid( startElem ).tsr[0];
if (i === 0) {
// widen the scope to include the full subtree
-   range = {
-   'root': startElem,
-   startElem: startElem,
-   endElem: endMeta,
-   start: startElem.firstChild,
-   end: startElem.lastChild,
-   id: 
env.stripIdPrefix(startElem.getAttribute("about")),
-   startOffset: tsr0
-   };
+   range.root = startElem;
+   range.start = startElem.firstChild;
+   // SSS FIXME: startElem.lastChild might not be an 
ELEMENT_NODE
+   range.end = startElem.lastChild;
break;
-   } else if ( i > 0) {
-   range = {
-   'root': parentNode,
-   startElem: startElem,
-   endElem: endMeta,
-   start: startAncestors[i - 1],
-   end: elem,
-   id: 
env.stripIdPrefix(startElem.getAttribute("about")),
-   startOffset: tsr0
-   };
+   } else if (i > 0) {
+   range.root = parentNode;
+   range.start = startAncestors[i - 1];
+   range.end = elem;
break;
}
elem = parentNode;
@@ -179,12 +173,26 @@
}
}
 
-   if (!DU.inSiblingOrder(range.start, range.end)) {
+   if (DU.inSiblingOrder(range.end, range.start)) {
// In foster-parenting situations, the end-meta tag (and hence 
r.end)
// can show up before the r.start which would be the table 
itself.
// So, we record this info for later analysis.
range.flipped = true;
}
+
+   env.log("trace/tplwrap/findranges", function() {
+   var msg = "";
+   var dp1 = DU.getDataParsoid(range.start);
+   var dp2 = DU.getDataParsoid(range.end);
+   msg += 
"\n--";
+   msg += "\nFound range : " + range.id + "; flipped? " + 
range.flipped + "; offset: " + range.startOffset;
+   msg += "\nstart-elem : " + range.startElem.outerHTML + 
"; DP: " + JSON.stringify(DU.getDataParsoid(range.startElem));
+   msg += "\nend-elem : " + range.endElem.outerHTML + "; 
DP: " + JSON.stringify(DU.getDataParsoid(range.endElem));
+   msg += "\nstart : [TAG_ID " + dp1.tagId + "]: " + 
range.start.outerHTML + "; DP: " + JSON.stringify(dp1);
+   msg += "\nend : [TAG_ID " + dp2.tagId + "]: " + 
range.end.outerHTML + "; DP: " + JSON.stringify(dp2);
+   msg += 
"\n--";
+   return msg;
+   });
 
return range;
 }
@@ -401,18 +409,20 @@
 
env.log("trace/tplwrap/merge", function() {
var msg = "";
+   var dp1 = DU

[MediaWiki-commits] [Gerrit] Use slave DB connections for LocalFile cache misses - change (mediawiki/core)

2014-04-22 Thread Aaron Schulz (Code Review)
Aaron Schulz has uploaded a new change for review.

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

Change subject: Use slave DB connections for LocalFile cache misses
..

Use slave DB connections for LocalFile cache misses

* Previously LocalFile cache misses would hit the master DB
  (even for shared repos like Commons).
* Since lock() is always called before file changes, this has
  been modified to call a new markVolatile() method to track
  changing (or recently changed) files in memcached. On cache
  miss this tracking is used to decide whether to use the
  slave or the master DB.

Change-Id: I942f5e28dd9e0953b6382cc2247ca480494d5718
---
M includes/filerepo/file/LocalFile.php
M includes/filerepo/file/OldLocalFile.php
2 files changed, 56 insertions(+), 5 deletions(-)


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

diff --git a/includes/filerepo/file/LocalFile.php 
b/includes/filerepo/file/LocalFile.php
index dbf6918..0334e4e 100644
--- a/includes/filerepo/file/LocalFile.php
+++ b/includes/filerepo/file/LocalFile.php
@@ -121,7 +121,13 @@
/** @var bool True if file is not present in file system. Not to be 
cached in memcached */
private $missing;
 
+   /** @var int UNIX timestamp of last markVolatile() call */
+   private $volateTime = 0;
+
const LOAD_ALL = 1; // integer; load all the lazy fields too (like 
metadata)
+   const LOAD_VIA_SLAVE = 2; // integer; use a slave to load the data
+
+   const VOLATILE_TTL = 300; // integer; seconds
 
/**
 * Create a LocalFile from a title
@@ -226,7 +232,7 @@
/**
 * Get the memcached key for the main data for this file, or false if
 * there is no access to the shared cache.
-* @return bool
+* @return string|bool
 */
function getCacheKey() {
$hashedName = md5( $this->getName() );
@@ -374,7 +380,7 @@
/**
 * Load file metadata from the DB
 */
-   function loadFromDB() {
+   function loadFromDB( $flags = 0 ) {
# Polymorphic function name to distinguish foreign and local 
fetches
$fname = get_class( $this ) . '::' . __FUNCTION__;
wfProfileIn( $fname );
@@ -383,7 +389,10 @@
$this->dataLoaded = true;
$this->extraDataLoaded = true;
 
-   $dbr = $this->repo->getMasterDB();
+   $dbr = ( $flags & self::LOAD_VIA_SLAVE )
+   ? $this->repo->getSlaveDB()
+   : $this->repo->getMasterDB();
+
$row = $dbr->selectRow( 'image', $this->getCacheFields( 'img_' 
),
array( 'img_name' => $this->getName() ), $fname );
 
@@ -509,7 +518,7 @@
function load( $flags = 0 ) {
if ( !$this->dataLoaded ) {
if ( !$this->loadFromCache() ) {
-   $this->loadFromDB();
+   $this->loadFromDB( $this->isVolatile() ? 0 : 
self::LOAD_VIA_SLAVE );
$this->saveToCache();
}
$this->dataLoaded = true;
@@ -1851,6 +1860,8 @@
} );
}
 
+   $this->markVolatile(); // file may change soon
+
return $dbw->selectField( 'image', '1',
array( 'img_name' => $this->getName() ), __METHOD__, 
array( 'FOR UPDATE' ) );
}
@@ -1871,6 +1882,45 @@
}
 
/**
+* Mark a file as about to be changed
+*
+* This sets a cache key that alters master/slave DB loading behavior
+*
+* @return bool Success
+*/
+   protected function markVolatile() {
+   global $wgMemc;
+
+   $key = $this->repo->getSharedCacheKey( 'file-volatile', md5( 
$this->getName() ) );
+   if ( $key ) {
+   $this->volateTime = time();
+   return $wgMemc->set( $key, $this->volateTime, 
self::VOLATILE_TTL );
+   }
+
+   return true;
+   }
+
+   /**
+* Check if a file as about to be changed or has been changed recently
+*
+* @see LocalFile::isVolatile()
+* @return bool Whether the file is volatile
+*/
+   protected function isVolatile() {
+   global $wgMemc;
+
+   $key = $this->repo->getSharedCacheKey( 'file-volatile', md5( 
$this->getName() ) );
+   if ( $key ) {
+   if ( $this->volateTime && ( time() - $this->volateTime 
) <= self::VOLATILE_TTL ) {
+   return true; // sanity
+   }
+   return ( $wgMemc->get( $key ) !== false );
+   }
+
+   return false;
+   }
+
+   /**
 * Roll back the DB transac

[MediaWiki-commits] [Gerrit] Update built html files - change (VisualEditor/VisualEditor)

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

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

Change subject: Update built html files
..

Update built html files

Change-Id: Ied44643e0557a45fc9ce93d322f47fc66e6d4c21
---
M .docs/eg-iframe.html
M demos/ve/index.html
M modules/ve/test/index.html
3 files changed, 3 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/78/129078/1

diff --git a/.docs/eg-iframe.html b/.docs/eg-iframe.html
index e7dd4ec..e0c5fc7 100644
--- a/.docs/eg-iframe.html
+++ b/.docs/eg-iframe.html
@@ -237,12 +237,11 @@



-   



-   

+   



diff --git a/demos/ve/index.html b/demos/ve/index.html
index 51b49e6..a9a60e2 100644
--- a/demos/ve/index.html
+++ b/demos/ve/index.html
@@ -252,12 +252,11 @@



-   



-   

+   



diff --git a/modules/ve/test/index.html b/modules/ve/test/index.html
index ebccfbc..f1cade4 100644
--- a/modules/ve/test/index.html
+++ b/modules/ve/test/index.html
@@ -200,12 +200,11 @@



-   



-   

+   




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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ied44643e0557a45fc9ce93d322f47fc66e6d4c21
Gerrit-PatchSet: 1
Gerrit-Project: VisualEditor/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders 

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


[MediaWiki-commits] [Gerrit] Update built html files - change (mediawiki...VisualEditor)

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

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

Change subject: Update built html files
..

Update built html files

Change-Id: Iae32c35aca7cbdcce83b424763318a2609c3e9f1
---
M .docs/eg-iframe.html
1 file changed, 1 insertion(+), 2 deletions(-)


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

diff --git a/.docs/eg-iframe.html b/.docs/eg-iframe.html
index cd95f17..61307d4 100644
--- a/.docs/eg-iframe.html
+++ b/.docs/eg-iframe.html
@@ -237,12 +237,11 @@



-   



-   

+   




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

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

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


[MediaWiki-commits] [Gerrit] Add AnnotationAction.test.js - change (mediawiki...VisualEditor)

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

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

Change subject: Add AnnotationAction.test.js
..

Add AnnotationAction.test.js

Depends on I1868130 in core.

Change-Id: I13372efabe91212c10a75df20125365a422919d3
---
M VisualEditor.hooks.php
1 file changed, 1 insertion(+), 0 deletions(-)


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

diff --git a/VisualEditor.hooks.php b/VisualEditor.hooks.php
index 90daf94..75872e1 100644
--- a/VisualEditor.hooks.php
+++ b/VisualEditor.hooks.php
@@ -593,6 +593,7 @@

'lib/ve/modules/ve/test/ce/ve.ce.LeafNode.test.js',

'lib/ve/modules/ve/test/ce/nodes/ve.ce.TextNode.test.js',
// VisualEditor Actions Tests
+   
'lib/ve/modules/ve/test/ui/actions/ve.ui.AnnotationAction.test.js',

'lib/ve/modules/ve/test/ui/actions/ve.ui.FormatAction.test.js',

'modules/ve-mw/test/ui/actions/ve.ui.FormatAction.test.js',

'lib/ve/modules/ve/test/ui/actions/ve.ui.IndentationAction.test.js',

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

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

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


[MediaWiki-commits] [Gerrit] miscellaneous improvements for diamond module - change (operations/puppet)

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

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

Change subject: miscellaneous improvements for diamond module
..

miscellaneous improvements for diamond module

* Remove a lot of awful cruft from the sample configuration file that ships
  with Diamond, leaving only what actually needs to be specified.
* Log to standard out; it will be captured by Upstart and rotated
  automatically.
* Manage collector and handler configuration files recursively.
* Accept Puppet hashes for collector and handler configurations.
* Add documentation and examples.
* Remove CPU & network collector resources; these belong in a base role class
  instead.

Change-Id: Iee6b0fa772798f75282e639754e8dd8dc8a06eff
---
M modules/diamond/manifests/collector.pp
M modules/diamond/manifests/init.pp
A modules/diamond/templates/collector.conf.erb
M modules/diamond/templates/diamond.conf.erb
A modules/diamond/templates/handler.conf.erb
5 files changed, 123 insertions(+), 186 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/75/129075/1

diff --git a/modules/diamond/manifests/collector.pp 
b/modules/diamond/manifests/collector.pp
index d7f419e..16d2b18 100644
--- a/modules/diamond/manifests/collector.pp
+++ b/modules/diamond/manifests/collector.pp
@@ -1,11 +1,52 @@
-define diamond::collector(
-$ensure = 'present',
-$config = undef,
-) {
-file { "/etc/diamond/collectors/${name}.conf":
-ensure => $ensure,
-content=> $config,
-subscribe  => Package['diamond'],
-notify => Service['diamond'],
+# == Define: diamond::collector
+#
+# Diamond Collectors are Python modules that run within the Diamond
+# process, collecting metrics about some subsystem, and feeding these
+# metrics into Diamond for aggregation and reporting.
+#
+# If you are familiar with Ganglia, you can think of Collectors as
+# being Diamond's answer to gmond modules.
+#
+# === Parameters
+#
+# [*ensure*]
+#   Specifies whether or not to configure Diamond to use this collector.
+#   May be 'present' or 'absent'. The default is 'present'.
+#
+# [*name*]
+#   The name of the collector class. The 'Collector' suffix may be
+#   omitted from the name.
+#
+# [*settings*]
+#   A hash of configuration settings for the collector.
+#   The 'enabled' setting is set to true by default.
+#
+# === Examples
+#
+# Configure an Nginx metric collector:
+#
+#  diamond::collector { 'Nginx':
+#settings => {
+#  req_host => 'gdash.wikimedia.org',
+#  req_path => '/status',
+#},
+#  }
+#
+# Configure a CPU utilization metric collector:
+#
+#  diamond::collector { 'CPU':
+#settings => {
+#  percore   => false,
+#  normalize => true,
+#},
+#  }
+#
+define diamond::collector( $settings ) {
+$collector = regsubst($name, '(Collector)?$', 'Collector')
+
+file { "/etc/diamond/collectors/${collector}.conf":
+content => template('diamond/handler.conf.erb'),
+require => File['/etc/diamond/collectors'],
+notify  => Service['diamond'],
 }
 }
diff --git a/modules/diamond/manifests/init.pp 
b/modules/diamond/manifests/init.pp
index 93e96b9..627002d 100644
--- a/modules/diamond/manifests/init.pp
+++ b/modules/diamond/manifests/init.pp
@@ -1,14 +1,66 @@
+# == Class: diamond
+#
+# Diamond is a Python network daemon that collects system metrics and
+# publishes them to a metric aggregator like Graphite or StatsD. Diamond
+# ships with a suite of metric collectors for CPU, memory, network, disk,
+# etc. Diamond also features an API for implementing custom collectors
+# that gather metrics from almost any source.
+#
+# === Parameters
+#
+# [*handler*]
+#   Import path and class name of diamond.handler.Handler subclass to
+#   use as the metric sink. Set to 'diamond.handler.stats_d.StatsdHandler'
+#   by default. To have Diamond write to Graphite instead, set this to
+#   'diamond.handler.graphite.GraphiteHandler'.
+#
+#   See 
+#   for a full list of available metric handlers.
+#
+# [*settings*]
+#   A hash of configuration options for the desired handler.
+#   See 
+#   for a listing of configuration options.
+#
+# === Examples
+#
+# A Graphite configuration for Diamond:
+#
+#  class { '::diamond':
+#handler  => 'diamond.handler.graphite.GraphiteHandler',
+#settings => {
+#  host => 'graphite.wikimedia.org',
+#  port => 2003,
+#},
+#  }
+#
 class diamond(
-$statsd_host='127.0.0.1',
-$statsd_port='8125',
-){
+$handler  = 'diamond.handler.stats_d.StatsdHandler',
+$settings = {},
+) {
 package { 'python-diamond':
 ensure => present,
 }
 
 file { '/etc/diamond/diamond.conf':
 content => template('diamond/diamond.conf.erb'),
+require => File['/etc/diamond/collectors', '/etc/diamond/ha

[MediaWiki-commits] [Gerrit] fix MediawikiTemplate::getTitle() method - change (mediawiki...GWToolset)

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

Change subject: fix MediawikiTemplate::getTitle() method
..


fix MediawikiTemplate::getTitle() method

* set $file_extension_length to an initial value of 0
* modified the title max length test so that it actually tests the
  working title’s strlen()

Bug: 64086
Change-Id: Ic964f214ce80d707c9d76140f8f9749aaf1b1d72
---
M includes/Models/MediawikiTemplate.php
1 file changed, 2 insertions(+), 1 deletion(-)

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



diff --git a/includes/Models/MediawikiTemplate.php 
b/includes/Models/MediawikiTemplate.php
index 03042d1..3636c4e 100644
--- a/includes/Models/MediawikiTemplate.php
+++ b/includes/Models/MediawikiTemplate.php
@@ -388,6 +388,7 @@
 */
public function getTitle( array &$options ) {
$result = null;
+   $file_extension_length = 0;
 
if ( empty( 
$this->mediawiki_template_array['gwtoolset-title-identifier'] ) ) {
throw new GWTException( 
'gwtoolset-mapping-no-title-identifier' );
@@ -426,7 +427,7 @@
$result .= 
$this->mediawiki_template_array['gwtoolset-title-identifier'];
$result .= '.' . $options['evaluated-media-file-extension'];
 
-   if ( $result > Config::$title_max_length ) {
+   if ( strlen( $result ) > Config::$title_max_length ) {
$result = substr(

$this->mediawiki_template_array['gwtoolset-title-identifier'],
0,

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic964f214ce80d707c9d76140f8f9749aaf1b1d72
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/GWToolset
Gerrit-Branch: master
Gerrit-Owner: Dan-nl 
Gerrit-Reviewer: Brian Wolff 
Gerrit-Reviewer: Gilles 
Gerrit-Reviewer: MarkTraceur 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Look for comparable annotations when toggling - change (VisualEditor/VisualEditor)

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

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

Change subject: Look for comparable annotations when toggling
..

Look for comparable annotations when toggling

* Add tests for AnnotationSet comparable methods
* Add test case for newFromAnnotation
* Add AnnotationAction tests

Bug: 64244
Change-Id: I1868130b2cba5d23b06a6ce57d2cc6db85fe986b
---
M modules/ve/dm/lineardata/ve.dm.ElementLinearData.js
M modules/ve/dm/ve.dm.AnnotationSet.js
M modules/ve/dm/ve.dm.Transaction.js
M modules/ve/test/dm/ve.dm.AnnotationSet.test.js
M modules/ve/test/dm/ve.dm.Transaction.test.js
M modules/ve/test/index.html
M modules/ve/test/index.html.template
A modules/ve/test/ui/actions/ve.ui.AnnotationAction.test.js
8 files changed, 165 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/VisualEditor/VisualEditor 
refs/changes/74/129074/1

diff --git a/modules/ve/dm/lineardata/ve.dm.ElementLinearData.js 
b/modules/ve/dm/lineardata/ve.dm.ElementLinearData.js
index 82ce919..f723076 100644
--- a/modules/ve/dm/lineardata/ve.dm.ElementLinearData.js
+++ b/modules/ve/dm/lineardata/ve.dm.ElementLinearData.js
@@ -439,8 +439,8 @@
if ( right.isEmpty() ) {
return new ve.dm.AnnotationSet( this.getStore() 
);
}
-   // Exclude annotations that are in left but not right
-   left.removeNotInSet( right );
+   // Exclude comparable annotations that are in left but 
not right
+   left = left.getComparableAnnotationsFromSet( right );
// If we've reduced left down to nothing, just stop 
looking
if ( left.isEmpty() ) {
break;
diff --git a/modules/ve/dm/ve.dm.AnnotationSet.js 
b/modules/ve/dm/ve.dm.AnnotationSet.js
index 44aefd4..3d69005 100644
--- a/modules/ve/dm/ve.dm.AnnotationSet.js
+++ b/modules/ve/dm/ve.dm.AnnotationSet.js
@@ -69,6 +69,20 @@
 };
 
 /**
+ * Get an annotation set containing only annotations within the set which are 
comparable
+ * to an annotation from another set.
+ *
+ * @method
+ * @param {ve.dm.AnnotationSet} annotations Annotation set to compare to
+ * @returns {ve.dm.AnnotationSet} Copy of annotation set
+ */
+ve.dm.AnnotationSet.prototype.getComparableAnnotationsFromSet = function ( 
annotations ) {
+   return this.filter( function ( a ) {
+   return annotations.containsComparable( a );
+   } );
+};
+
+/**
  * Check if any annotations in the set have a specific name.
  *
  * @method
diff --git a/modules/ve/dm/ve.dm.Transaction.js 
b/modules/ve/dm/ve.dm.Transaction.js
index f3bc85f..ceabe76 100644
--- a/modules/ve/dm/ve.dm.Transaction.js
+++ b/modules/ve/dm/ve.dm.Transaction.js
@@ -337,7 +337,15 @@
if ( data.isElementData( i ) ) {
insideContentNode = true;
}
-   covered = data.getAnnotationsFromOffset( i 
).containsComparable( annotation );
+   if ( method === 'set' ) {
+   // Don't re-apply matching annotation
+   covered = data.getAnnotationsFromOffset( i 
).containsComparable( annotation );
+   } else {
+   // Expect comparable annotations to be removed 
individually otherwise
+   // we might try to remove more than one 
annotation per character, which
+   // a single transaction can't do.
+   covered = data.getAnnotationsFromOffset( i 
).contains( annotation );
+   }
if ( ( covered && method === 'set' ) || ( !covered && 
method === 'clear' ) ) {
// Skip annotated content
if ( on ) {
diff --git a/modules/ve/test/dm/ve.dm.AnnotationSet.test.js 
b/modules/ve/test/dm/ve.dm.AnnotationSet.test.js
index 4ca9907..6be7074 100644
--- a/modules/ve/test/dm/ve.dm.AnnotationSet.test.js
+++ b/modules/ve/test/dm/ve.dm.AnnotationSet.test.js
@@ -75,3 +75,30 @@
assert.equal( annotationSet3.getLength(), 1, 'set intersected with set2 
has length 1' );
assert.equal( annotationSet3.contains( italic ), true, 'set intersected 
with set2 contains italic' );
 } );
+
+QUnit.test( 'Comparable', 7, function ( assert ) {
+   var annotationSet3,
+   store = new ve.dm.IndexValueStore(),
+   bold = new ve.dm.TextStyleBoldAnnotation(),
+   italic = new ve.dm.TextStyleItalicAnnotation(),
+   strong = new ve.dm.TextStyleBoldAnnotation( { 'type': 
'textStyle/bold', 'attributes': { 'nodeName': 'strong' } } ),
+   underline = new ve.dm.TextStyleUnderlineAnnotation(),
+   annotation

[MediaWiki-commits] [Gerrit] (Bug 64017) Fixed longstanding tpl-range overlap detection bug - change (mediawiki...parsoid)

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

Change subject: (Bug 64017) Fixed longstanding tpl-range overlap detection bug
..


(Bug 64017) Fixed longstanding tpl-range overlap detection bug

* Consider this following template range overlap scenario:

  tpl-start-1 --- tpl-start-2 --- tpl-end-1 --- tpl-end-2

  where each of the 4 nodes above are sibling elements at some
  dom level of the document. Clearly, TPL-1 and TPL-2 overlap
  and the two ranges should be merged.

  However, the overlap detection code was using a special
  case check of "prev.end === current.start" which only works
  if tpl-end-1 and tpl-start-2 were the same element but fails
  on the DOM shown above.

  In "normal" transclusion scenarios, these kinds of overlaps
  should not be seen. But, fostering of template content can
  generate DOMs like this.

* The following snippet on enwiki reproduces this bug:
--
{{col-begin}}
{{div col}}
{{col-end}}
--

* This patch also adds a missing initialization of a data struct.
  which occasionally caused failures merging ranges and introduced
  the undefined 'length' error as in Bug 64028.

* This fix eliminates template encapsulation failures on
  enwiki:Dirrty, enwiki:Bangerz, enwiki:Back_to_Black and possibly
  other song-related pages (and possibly other pages as well). I'll
  test all the pages separately and update the bug report.

* This patch also adds a "--trace tplwrap" functionality that emits
  start/end nodes for identified tpl ranges and displays whether
  any of them overlap/nest and get merged.

* Added a simplified test case to parserTests.txt (wt2html fails
  without this patch).

Change-Id: I8c3c78f7437f31ace10bbb0ff213157c94488cbe
---
M lib/dom.markFosteredContent.js
M lib/dom.wrapTemplates.js
M lib/mediawiki.Util.js
M tests/parserTests-blacklist.js
M tests/parserTests.txt
5 files changed, 42 insertions(+), 14 deletions(-)

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



diff --git a/lib/dom.markFosteredContent.js b/lib/dom.markFosteredContent.js
index 386c94b..10cc0fd 100644
--- a/lib/dom.markFosteredContent.js
+++ b/lib/dom.markFosteredContent.js
@@ -94,6 +94,10 @@
 function markFosteredContent( node, env ) {
var span, sibling, next, dp, fosteredTransclusions, c = node.firstChild;
 
+   // if (node.nodeName === 'BODY') {
+   //  console.log(" PRE:BODY " + node.outerHTML);
+   // }
+
while ( c ) {
sibling = c.nextSibling;
fosteredTransclusions = false;
diff --git a/lib/dom.wrapTemplates.js b/lib/dom.wrapTemplates.js
index d98411e..874a773 100644
--- a/lib/dom.wrapTemplates.js
+++ b/lib/dom.wrapTemplates.js
@@ -399,21 +399,26 @@
r.startElem.removeAttribute("data-mw-arginfo");
}
 
-   /*
-   console.warn("##");
-   console.warn("range " + r.id + "; r-start-elem: " + 
r.startElem.outerHTML + "; DP: " + 
JSON.stringify(DU.getDataParsoid(r.startElem)));
-   console.warn("range " + r.id + "; r-end-elem: " + 
r.endElem.outerHTML + "; DP: " + JSON.stringify(DU.getDataParsoid(r.endElem)));
-   console.warn("-");
-   */
+   env.log("trace/tplwrap/merge", function() {
+   var msg = "";
+   msg += 
"\n##";
+   msg += "\nrange " + r.id + "; r-start-elem: " + 
r.startElem.outerHTML + "; DP: " + 
JSON.stringify(DU.getDataParsoid(r.startElem));
+   msg += "\nrange " + r.id + "; r-end-elem: " + 
r.endElem.outerHTML + "; DP: " + JSON.stringify(DU.getDataParsoid(r.endElem));
+   msg += "\nrange " + r.id + "; r-start: " + 
r.start.outerHTML + "; DP: " + JSON.stringify(DU.getDataParsoid(r.start));
+   msg += "\nrange " + r.id + "; r-end: " + 
r.end.outerHTML + "; DP: " + JSON.stringify(DU.getDataParsoid(r.end));
+   msg += 
"\n--";
+   return msg;
+   });
 
var enclosingRangeId = null;
if (nestedRangesMap[r.id]) {
-   // console.warn("--possibly nested--");
+   env.log("trace/tplwrap/merge", "--possibly nested--");
enclosingRangeId = 
findToplevelEnclosingRange(nestedRangesMap, r.id);
}
 
if (nestedRangesMap[r.id] && enclosingRangeId) {
-   // console.warn("--nested in " + enclosingRangeId + 
"--");
+   env.log("trace/tplwrap/merge", "--nested in ", 
enclosingRangeId, "--");
+
// Nested -- ignore r

[MediaWiki-commits] [Gerrit] explicitly ignore some columns when checking spreadsheet schema - change (wikimedia...tools)

2014-04-22 Thread Adamw (Code Review)
Adamw has uploaded a new change for review.

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

Change subject: explicitly ignore some columns when checking spreadsheet schema
..

explicitly ignore some columns when checking spreadsheet schema

Change-Id: I7ca8683db9a974e3bed55a97a89b099bb48f7c90
---
M fundraising_ab_tests/fundraising_test.py
M live_analysis/config.yaml.example
2 files changed, 12 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/tools 
refs/changes/73/129073/1

diff --git a/fundraising_ab_tests/fundraising_test.py 
b/fundraising_ab_tests/fundraising_test.py
index 60ef04b..63ce271 100644
--- a/fundraising_ab_tests/fundraising_test.py
+++ b/fundraising_ab_tests/fundraising_test.py
@@ -1,10 +1,15 @@
 import mediawiki.centralnotice.api
-from results import get_banner_results
 from process.logging import Logger as log
+from process.globals import config
+from results import get_banner_results
 
 class FrTest(object):
 def __init__(self, label=None, type="", campaign=None, banners=None, 
start=None, end=None, disabled=False, **ignore):
-log.warn("ignoring columns: {columns}".format(columns=", 
".join(ignore.keys(
+for key in config.ignored_columns:
+if key in ignore:
+ignore.pop(key)
+if ignore:
+log.warn("ignoring columns: {columns}".format(columns=", 
".join(ignore.keys(
 
 self.campaign = mediawiki.centralnotice.api.get_campaign(campaign)
 if not self.campaign:
diff --git a/live_analysis/config.yaml.example 
b/live_analysis/config.yaml.example
index 143984c..3b00daa 100644
--- a/live_analysis/config.yaml.example
+++ b/live_analysis/config.yaml.example
@@ -25,6 +25,11 @@
 passwd: ""
 private_key: ./api-key.p12
 
+# If any columns not listed below are encountered, emit warnings about 
unexpected document structure.
+ignored_columns:
+- notes
+- ""
+
 centralnotice_mw_api: "http://meta.wikimedia.org/w/api.php";
 centralnotice_history_days: 14
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7ca8683db9a974e3bed55a97a89b099bb48f7c90
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/tools
Gerrit-Branch: master
Gerrit-Owner: Adamw 

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


[MediaWiki-commits] [Gerrit] Hygiene: Ensure bridge css never makes it on to Minerva skin - change (mediawiki...MobileFrontend)

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

Change subject: Hygiene: Ensure bridge css never makes it on to Minerva skin
..


Hygiene: Ensure bridge css never makes it on to Minerva skin

Restrict it to the Vector skin

Change-Id: I122798368fa017ec9319ee76357c45effd29d7e3
---
M includes/Resources.php
1 file changed, 4 insertions(+), 2 deletions(-)

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



diff --git a/includes/Resources.php b/includes/Resources.php
index 6bd4043..b42633d 100644
--- a/includes/Resources.php
+++ b/includes/Resources.php
@@ -44,8 +44,10 @@
// @todo FIXME: Remove need for this module
// Mobile Bridge - Tweaks the desktop UI so mobile code can run on it
'mobile.bridge' => $wgMFMobileResourceBoilerplate + array(
-   'styles' => array(
-   'less/desktop/mobileBridge.less',
+   'skinStyles' => array(
+   'vector' => array(
+   'less/desktop/mobileBridge.less',
+   ),
),
'scripts' => array(
'javascripts/desktop/mobileBridge.js',

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I122798368fa017ec9319ee76357c45effd29d7e3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 
Gerrit-Reviewer: Awjrichards 
Gerrit-Reviewer: JGonera 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Kaldari 
Gerrit-Reviewer: MaxSem 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Move the messages to describe novalue and somevalue Snaks to... - change (mediawiki...Wikibase)

2014-04-22 Thread Hoo man (Code Review)
Hoo man has uploaded a new change for review.

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

Change subject: Move the messages to describe novalue and somevalue Snaks to lib
..

Move the messages to describe novalue and somevalue Snaks to lib

As those are needed on client in order to display novalue and
somevalue Snaks correctly.

Change-Id: Ia375cb095c0b7cc40172f4f000655cf2061dc587
---
M lib/i18n/en.json
M repo/i18n/en.json
2 files changed, 2 insertions(+), 2 deletions(-)


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

diff --git a/lib/i18n/en.json b/lib/i18n/en.json
index ad700ec..2af020d 100644
--- a/lib/i18n/en.json
+++ b/lib/i18n/en.json
@@ -60,6 +60,8 @@
 "wikibase-sitelinks-sitename-columnheading-special": "Site",
 "wikibase-sitelinks-siteid-columnheading": "Code",
 "wikibase-sitelinks-link-columnheading": "Linked page",
+"wikibase-snakview-snaktypeselector-somevalue": "unknown value",
+"wikibase-snakview-snaktypeselector-novalue": "no value",
 "wikibase-tooltip-error-details": "Details",
 "wikibase-undeserializable-value": "The value is invalid and cannot be 
displayed.",
 "wikibase-validator-invalid": "Invalid value",
diff --git a/repo/i18n/en.json b/repo/i18n/en.json
index 2cd48f6..cb56c0e 100644
--- a/repo/i18n/en.json
+++ b/repo/i18n/en.json
@@ -82,8 +82,6 @@
 "wikibase-snakview-variations-somevalue-label": "unknown value",
 "wikibase-snakview-variations-novalue-label": "no value",
 "wikibase-snakview-snaktypeselector-value": "custom value",
-"wikibase-snakview-snaktypeselector-somevalue": "unknown value",
-"wikibase-snakview-snaktypeselector-novalue": "no value",
 "wikibase-snakformat-invalid-value": "Invalid value.",
 "wikibase-snakformat-propertynotfound": "Property not found.",
 "wikibase-shortcopyrightwarning": "By clicking \"$1\", you agree to the 
[[$2|terms of use]], and you irrevocably agree to release your contribution 
under the $3.",

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

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

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


[MediaWiki-commits] [Gerrit] auto-add additional mediawiki template parameters as creator... - change (mediawiki...GWToolset)

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

Change subject: auto-add additional mediawiki template parameters as creator 
template values
..


auto-add additional mediawiki template parameters as creator template values

* expanded on the $_sub_templates array for creator so that it now contains
  a list of mediawiki template parameters that use the template
* the new array list is used to test whether or not the mediawiki template
  being used has any matching parameters and if so, use the template if a value
  for the parameter exists in the metadata

Bug: 63822
Change-Id: I6e414b4d1c552a532812cf62c5642327a968366d
---
M includes/Models/MediawikiTemplate.php
1 file changed, 16 insertions(+), 3 deletions(-)

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



diff --git a/includes/Models/MediawikiTemplate.php 
b/includes/Models/MediawikiTemplate.php
index e3aa360..03042d1 100644
--- a/includes/Models/MediawikiTemplate.php
+++ b/includes/Models/MediawikiTemplate.php
@@ -52,7 +52,20 @@
protected $_sub_templates = array(
'language' => '{{%s|%s}}',
'institution' => '{{Institution:%s}}',
-   'creator' => '{{Creator:%s}}'
+   'creator' => array(
+   'template' => '{{Creator:%s}}',
+   'parameters' => array(
+   'artist',
+   'author',
+   'Author',
+   'composer',
+   'lyrics_writer',
+   'performer',
+   'photographer',
+   'printer',
+   'publisher'
+   )
+   )
);
 
/**
@@ -222,7 +235,7 @@
Utils::sanitizeString( 
$content )
) . PHP_EOL;
}
-   } elseif ( $parameter === 'artist' ) {
+   } elseif ( in_array( $parameter, 
$this->_sub_templates['creator']['parameters'] ) ) {
// assumes that there could be more 
than one creator and uses the
// configured metadata separator to 
determine that
$creators = explode( 
Config::$metadata_separator, $content );
@@ -242,7 +255,7 @@
}
 
$sections .= sprintf(
-   
$this->_sub_templates['creator'],
+   
$this->_sub_templates['creator']['template'],

Utils::sanitizeString( $creator )
) . PHP_EOL;
}

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I6e414b4d1c552a532812cf62c5642327a968366d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/GWToolset
Gerrit-Branch: master
Gerrit-Owner: Dan-nl 
Gerrit-Reviewer: Brian Wolff 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: Dan-nl 
Gerrit-Reviewer: Gergő Tisza 
Gerrit-Reviewer: Gilles 
Gerrit-Reviewer: MarkTraceur 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Regression: Push history back to stable - change (mediawiki...MobileFrontend)

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

Change subject: Regression: Push history back to stable
..


Regression: Push history back to stable

Bug introduced by If81fee954025b1ebc11d7d4a86eb70377b1f2233

Change-Id: I1eddf0fabdff92b8dde133fa75d2bc3065fca836
---
M includes/specials/SpecialMobileHistory.php
1 file changed, 0 insertions(+), 1 deletion(-)

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



diff --git a/includes/specials/SpecialMobileHistory.php 
b/includes/specials/SpecialMobileHistory.php
index f4b06b6..39c72b1 100644
--- a/includes/specials/SpecialMobileHistory.php
+++ b/includes/specials/SpecialMobileHistory.php
@@ -4,7 +4,6 @@
 class SpecialMobileHistory extends MobileSpecialPageFeed {
const LIMIT = 50;
const DB_REVISIONS_TABLE = 'revision';
-   protected $mode = 'beta';
/**  @var String|null timestamp to offset results from */
protected $offset;
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1eddf0fabdff92b8dde133fa75d2bc3065fca836
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 
Gerrit-Reviewer: Awjrichards 
Gerrit-Reviewer: JGonera 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Kaldari 
Gerrit-Reviewer: MaxSem 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Enable survey option in MediaViewer on a few more wikis - change (operations/mediawiki-config)

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

Change subject: Enable survey option in MediaViewer on a few more wikis
..


Enable survey option in MediaViewer on a few more wikis

Related MediaViewer commit:
I595446dc59c1bca2ea0b977be9d26f17192d3bc4

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

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



diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index 2485d9f..f6cf074 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -10765,6 +10765,10 @@
'cawiki' => true,
'huwiki' => true,
'enwikivoyage' => true,
+   // TODO disable 2014-05-22
+   'dewiki' => true,
+   'frwiki' => true,
+   'ptwiki' => true,
 ),
 
 'wmgNetworkPerformanceSamplingFactor' => array(

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If2c57846f4dfb05ea58f36b25e3d8185d2a6e70e
Gerrit-PatchSet: 2
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza 
Gerrit-Reviewer: Gilles 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Hygiene: Clean up profile page dead code - change (mediawiki...MobileFrontend)

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

Change subject: Hygiene: Clean up profile page dead code
..


Hygiene: Clean up profile page dead code

Change-Id: I0d8d56a6ea5dbf308da6bd1de86d535d41fc5264
---
M includes/specials/SpecialUserProfile.php
M less/specials/userprofile.less
2 files changed, 0 insertions(+), 82 deletions(-)

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



diff --git a/includes/specials/SpecialUserProfile.php 
b/includes/specials/SpecialUserProfile.php
index 6bef211..713bb0b 100644
--- a/includes/specials/SpecialUserProfile.php
+++ b/includes/specials/SpecialUserProfile.php
@@ -16,16 +16,6 @@
 * @var MobileUserInfo
 */
private $userInfo;
-   /**
-* The user's description of himself or herself
-* @var String
-*/
-   public $userDescription;
-   /**
-* Whether or not the page is editable by the current user
-* @var Boolean
-*/
-   private $editable = false;
 
public function __construct() {
parent::__construct( 'UserProfile' );
@@ -71,35 +61,6 @@
Html::closeElement( 'div' );
wfProfileOut( __METHOD__ );
return $img;
-   }
-
-   /**
-* Returns HTML to show the user's description as well as a hidden form 
for editing
-* the description.
-*
-* @return String HTML
-*
-*/
-   protected function getUserSummary() {
-   $out = '';
-   if ( $this->editable || $this->userDescription ) {
-   $out = Html::openElement( 'div', array( 'class' => 
'user-description-container' ) );
-   if ( $this->userDescription ) {
-   $out .= Html::openElement( 'p', array( 
'class' => 'user-description' ) );
-   // FIXME: Use quotation-marks message
-   // NOTE: This outputs WikiText as raw 
text (not parsed). This is on
-   // purpose, but may be changed in the 
future.
-   $out .= htmlspecialchars( 
$this->userDescription );
-   $out .= Html::closeElement( 'p' );
-   } elseif ( $this->editable ) {
-   $out .= Html::openElement( 'p', array( 
'class' => 'user-description-placeholder' ) );
-   $out .= $this->msg( 
'mobile-frontend-profile-description-placeholder',
-   $this->targetUser );
-   $out .= Html::closeElement( 'p' );
-   }
-   $out .= Html::closeElement( 'div' );
-   }
-   return $out;
}
 
/**
diff --git a/less/specials/userprofile.less b/less/specials/userprofile.less
index 7c67c49..946d7aa 100644
--- a/less/specials/userprofile.less
+++ b/less/specials/userprofile.less
@@ -25,49 +25,6 @@
font-size: 0.9em;
}
 
-   .user-description-container {
-   padding: 0 (@contentMargin * 2) 1.5em;
-   position: relative;
-
-   .user-description-placeholder,
-   .user-description {
-   display: inline;
-   font-family: @fontFamilyHeading;
-   font-style: italic;
-   font-size: 1.2em;
-   line-height: @contentLineHeight;
-   }
-
-   .edit-button {
-   display: inline-block;
-   vertical-align: middle;
-   background: url(images/profile/edit.png) 50% 30% 
no-repeat;
-   .background-size( 16px, auto );
-   text-indent: px;
-   width: 32px;
-   height: 32px;
-   cursor: pointer;
-   }
-
-   .editor {
-   text-align: right;
-   }
-
-   textarea {
-   .box-sizing( border-box );
-   width: 100%;
-   height: 120px;
-   margin-bottom: 1em;
-   }
-
-   .character-counter {
-   margin-right: 1em;
-   &.warning {
-   color: @redBase;
-   }
-   }
-   }
-
h2 {
color: @grayLight;
text-transform: uppercase;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I0d8d56a6ea5dbf308da6bd1d

[MediaWiki-commits] [Gerrit] Update EventLogging for Iaa232298e - change (mediawiki/core)

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

Change subject: Update EventLogging for Iaa232298e
..


Update EventLogging for Iaa232298e

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

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



diff --git a/extensions/EventLogging b/extensions/EventLogging
index c5fd385..4f0aad5 16
--- a/extensions/EventLogging
+++ b/extensions/EventLogging
-Subproject commit c5fd385927d95dfac0652238040af2fdc4405cf9
+Subproject commit 4f0aad555f3f897f716a8a100c23ba6ab87b4382

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I95f947bca40b45f508937ecbbd5913351acf9b1f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.24wmf1
Gerrit-Owner: Ori.livneh 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] move the FrTest module into its own file - change (wikimedia...tools)

2014-04-22 Thread Adamw (Code Review)
Adamw has uploaded a new change for review.

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

Change subject: move the FrTest module into its own file
..

move the FrTest module into its own file

plus some other minor junk

Change-Id: I27617a3bd08f5e6c1b73a809243428e036e38f64
---
M fundraising_ab_tests/__init__.py
M fundraising_ab_tests/campaign_log.py
A fundraising_ab_tests/fundraising_test.py
M fundraising_ab_tests/spec.py
M live_analysis/README
5 files changed, 101 insertions(+), 95 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/tools 
refs/changes/71/129071/1

diff --git a/fundraising_ab_tests/__init__.py b/fundraising_ab_tests/__init__.py
index 6f8b05e..3f38a62 100644
--- a/fundraising_ab_tests/__init__.py
+++ b/fundraising_ab_tests/__init__.py
@@ -3,94 +3,3 @@
 
 These are not unit tests ;) they are WMF Fundraising A/B tests.
 '''
-
-import mediawiki.centralnotice.api
-from results import get_banner_results
-from process.logging import Logger as log
-
-class FrTest(object):
-def __init__(self, label=None, type="", campaign=None, banners=None, 
start=None, end=None, disabled=False, **ignore):
-log.warn("ignoring columns: {columns}".format(columns=", 
".join(ignore.keys(
-
-self.campaign = mediawiki.centralnotice.api.get_campaign(campaign)
-if not self.campaign:
-log.warn("no such campaign '{campaign}'".format(campaign=campaign))
-
-self.type = type.lower()
-
-if self.type.count('banner') > 0:
-self.is_banner_test = True
-if banners:
-if hasattr(banners, 'strip'):
-banners = [ s.strip() for s in banners.split(",") ]
-self.banners = banners
-else:
-if self.campaign['banners']:
-self.banners = self.campaign['banners'].keys()
-
-#self.variations = [ FrTestVariation(banner=name) for name in 
self.banners ]
-
-self.is_country_test = (self.type.count('country') > 0)
-self.is_lp_test = (self.type.count('lp') > 0)
-
-self.start_time = start
-self.end_time = end
-
-self.label = label
-if not self.label:
-# FIXME
-self.label = campaign
-
-self.enabled = not disabled
-
-self.results = []
-
-def load_results(self):
-if self.is_banner_test and self.banners:
-cases = []
-for name in self.banners:
-test_case = self.get_case(
-campaign=self.campaign['name'],
-banner=name
-)
-cases.append(test_case)
-
-self.results.extend(get_banner_results(cases))
-
-if self.is_country_test:
-#results = [ calculate_result(country=code) for code in 
campaign['countries'] ]
-#self.results.extend(results)
-log.warn("country test type not implemented")
-
-if self.is_lp_test:
-log.warn("LP test type not implemented")
-
-def get_case(self, **kw):
-conditions = {
-'start': self.start_time,
-'end': self.end_time,
-}
-conditions.update(**kw)
-
-return conditions
-
-def __repr__(self):
-description = '''
-Test: %(label)s (%(campaigns)s) %(start)s - %(end)s
-''' % {
-'label': self.label,
-'campaigns': self.campaign['name'],
-'start': self.start_time,
-'end': self.end_time,
-}
-if not self.enabled:
-description += " DISABLED "
-if self.is_banner_test:
-description += " banners: " + str(self.banners)
-if self.is_country_test:
-description += " countries: " + str(self.countries)
-if self.is_lp_test:
-description += " lps: " + str(self.lps)
-return description
-
-#class FrTestVariation(object):
diff --git a/fundraising_ab_tests/campaign_log.py 
b/fundraising_ab_tests/campaign_log.py
index e1a7bca..c0ecd07 100644
--- a/fundraising_ab_tests/campaign_log.py
+++ b/fundraising_ab_tests/campaign_log.py
@@ -1,4 +1,5 @@
-from fundraising_ab_tests import FrTest
+from fundraising_ab_tests.fundraising_test import FrTest
+from process.globals import config
 
 def tests_from_entry(entry):
 '''
@@ -47,5 +48,5 @@
 if 'enabled' in entry['added'] or entry['begin']['enabled'] is 1:
 return True
 
-logs = get_campaign_logs(since=time_util.str_time_offset(days=-1))
+logs = 
get_campaign_logs(since=time_util.str_time_offset(days=-config.centralnotice_history_days))
 return [ tests_from_entry(e) for e in reversed(logs) if is_relevant(e) ]
diff --git a/fundraising_ab_tests/fundraising_test.py 
b/fundraising_ab_tests/fundraising_test.py
new file mode 100644
index 000..60ef04b
--- /dev/null
+++ b/fundraising_ab_tests/fundraising_test.py
@@ -0,0 +1,90 @@
+

[MediaWiki-commits] [Gerrit] Update EventLogging for Iaa232298e - change (mediawiki/core)

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

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

Change subject: Update EventLogging for Iaa232298e
..

Update EventLogging for Iaa232298e

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/70/129070/1

diff --git a/extensions/EventLogging b/extensions/EventLogging
index c5fd385..4f0aad5 16
--- a/extensions/EventLogging
+++ b/extensions/EventLogging
-Subproject commit c5fd385927d95dfac0652238040af2fdc4405cf9
+Subproject commit 4f0aad555f3f897f716a8a100c23ba6ab87b4382

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I95f947bca40b45f508937ecbbd5913351acf9b1f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.24wmf1
Gerrit-Owner: Ori.livneh 

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


[MediaWiki-commits] [Gerrit] don’t place sub-template into main template when no value is... - change (mediawiki...GWToolset)

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

Change subject: don’t place sub-template into main template when no value is 
present
..


don’t place sub-template into main template when no value is present

* added logic that will not place the sub-template for {{Creator}} or
  {{Institution}} into the main template if the corresponding fields
  have no values.

Bug: 63646
Change-Id: Ica75e892edaf3c1069da01ac695fa28607e35435
---
M includes/Models/MediawikiTemplate.php
1 file changed, 14 insertions(+), 6 deletions(-)

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



diff --git a/includes/Models/MediawikiTemplate.php 
b/includes/Models/MediawikiTemplate.php
index 1a13a0b..e3aa360 100644
--- a/includes/Models/MediawikiTemplate.php
+++ b/includes/Models/MediawikiTemplate.php
@@ -214,10 +214,14 @@
$content = trim( $content );
 
if ( $parameter === 'institution' ) {
-   $sections .= sprintf(
+   if ( trim( $content ) === '' ) {
+   $sections .= PHP_EOL;
+   } else {
+   $sections .= sprintf(

$this->_sub_templates['institution'],
Utils::sanitizeString( 
$content )
) . PHP_EOL;
+   }
} elseif ( $parameter === 'artist' ) {
// assumes that there could be more 
than one creator and uses the
// configured metadata separator to 
determine that
@@ -228,16 +232,20 @@
// no other assumptions are 
made other than this one
$creator = explode( ',', 
$creator, 2 );
 
-   if ( count( $creator ) === 2 ) {
-   $creator = trim( 
$creator[1] ) . ' ' . trim( $creator[0] );
+   if ( count( $creator ) <= 1 && 
trim( $creator[0] ) === '' ) {
+   $sections .= PHP_EOL;
} else {
-   $creator = trim( 
$creator[0] );
-   }
+   if ( count( $creator ) 
=== 2 ) {
+   $creator = 
trim( $creator[1] ) . ' ' . trim( $creator[0] );
+   } else {
+   $creator = 
trim( $creator[0] );
+   }
 
-   $sections .= sprintf(
+   $sections .= sprintf(

$this->_sub_templates['creator'],

Utils::sanitizeString( $creator )
) . PHP_EOL;
+   }
}
} elseif ( $parameter === 'permission' ) {
// 
http://commons.wikimedia.org/wiki/Category:Creative_Commons_licenses

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ica75e892edaf3c1069da01ac695fa28607e35435
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/GWToolset
Gerrit-Branch: master
Gerrit-Owner: Dan-nl 
Gerrit-Reviewer: Brian Wolff 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: Dan-nl 
Gerrit-Reviewer: Gergő Tisza 
Gerrit-Reviewer: Gilles 
Gerrit-Reviewer: MarkTraceur 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Special-case history and diff desktop links - change (mediawiki...MobileFrontend)

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

Change subject: Special-case history and diff desktop links
..


Special-case history and diff desktop links

Bug: 64112
Change-Id: Ifa7539c277afc239abee2fa3e3019b03d34f295f
---
M includes/MobileFrontend.hooks.php
M includes/skins/SkinMinerva.php
M includes/specials/MobileSpecialPage.php
M includes/specials/SpecialMobileDiff.php
M includes/specials/SpecialMobileHistory.php
A tests/specials/MobileSpecialPageTest.php
6 files changed, 117 insertions(+), 13 deletions(-)

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



diff --git a/includes/MobileFrontend.hooks.php 
b/includes/MobileFrontend.hooks.php
index 904ebe0..1c350a6 100644
--- a/includes/MobileFrontend.hooks.php
+++ b/includes/MobileFrontend.hooks.php
@@ -694,15 +694,23 @@
public static function onUnitTestsList( &$files ) {
$dir = dirname( dirname( __FILE__ ) ) . '/tests';
 
-   $files[] = "$dir/ApiMobileViewTest.php";
-   $files[] = "$dir/ApiParseExtenderTest.php";
-   $files[] = "$dir/DeviceDetectionTest.php";
-   $files[] = "$dir/MobileContextTest.php";
-   $files[] = "$dir/MobileFormatterTest.php";
-   $files[] = "$dir/modules/MFResourceLoaderModuleTest.php";
-
-   // special page tests
-   $files[] = "$dir/specials/SpecialMobileDiffTest.php";
+   $callback = function( $file ) use ( $dir ) {
+   return "$dir/$file";
+   };
+   $files = array_merge( $files,
+   array_map( $callback,
+   array(
+   'ApiMobileViewTest.php',
+   'ApiParseExtenderTest.php',
+   'DeviceDetectionTest.php',
+   'MobileContextTest.php',
+   'MobileFormatterTest.php',
+   
'modules/MFResourceLoaderModuleTest.php',
+   'specials/MobileSpecialPageTest.php',
+   'specials/SpecialMobileDiffTest.php',
+   )
+   )
+   );
return true;
}
 
diff --git a/includes/skins/SkinMinerva.php b/includes/skins/SkinMinerva.php
index 6d960ee..fa5dcac 100644
--- a/includes/skins/SkinMinerva.php
+++ b/includes/skins/SkinMinerva.php
@@ -825,10 +825,13 @@
protected function prepareMobileFooterLinks( $tpl ) {
$req = $this->getRequest();
 
-   $url = $this->mobileContext->getDesktopUrl( wfExpandUrl(
-   $req->appendQuery( 'mobileaction=toggle_view_desktop' )
-   ) );
-   $url = htmlspecialchars( $url );
+   $url = $this->getOutput()->getProperty( 'desktopUrl' );
+   if ( $url ) {
+   $url = wfAppendQuery( $url, 
'mobileaction=toggle_view_desktop' );
+   } else {
+   $url = $req->appendQuery( 
'mobileaction=toggle_view_desktop' );
+   }
+   $url = htmlspecialchars( $this->mobileContext->getDesktopUrl( 
wfExpandUrl( $url ) ) );
 
$desktop = wfMessage( 'mobile-frontend-view-desktop' 
)->escaped();
$mobile = wfMessage( 'mobile-frontend-view-mobile' )->escaped();
diff --git a/includes/specials/MobileSpecialPage.php 
b/includes/specials/MobileSpecialPage.php
index 7d29dd5..feeb0d2 100644
--- a/includes/specials/MobileSpecialPage.php
+++ b/includes/specials/MobileSpecialPage.php
@@ -18,6 +18,7 @@
 
public function execute( $subPage ) {
$ctx = MobileContext::singleton();
+   $this->getOutput()->setProperty( 'desktopUrl', 
$this->getDesktopUrl( $subPage ) );
if ( !$ctx->shouldDisplayMobileView() && 
!$this->hasDesktopVersion ) {
$this->renderUnavailableBanner( $this->msg( 
'mobile-frontend-requires-mobile' ) );
} elseif ( $this->mode !== 'stable' ) {
@@ -86,4 +87,13 @@
wfHttpError( 404, $this->msg( 
'mobile-frontend-generic-404-title' )->text(),
$this->msg( 'mobile-frontend-generic-404-desc' 
)->text() );
}
+
+   /**
+* When overridden in a descendant class, returns desktop URL for this 
special page
+* @param string $subPage Subpage passed in URL
+* @return string|null Desktop URL for this special page or null if a 
standard one should be used
+*/
+   public function getDesktopUrl( $subPage ) {
+   return null;
+   }
 }
diff --git a/includes/specials/SpecialMobileDiff.php 
b/includes/specials/SpecialMobileDiff.php
index 88c91f7..4cf428b 100644
--- a/includes/specials/Speci

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

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

Change subject: Update MultimediaViewer for I595446dc5
..


Update MultimediaViewer for I595446dc5

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

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



diff --git a/extensions/MultimediaViewer b/extensions/MultimediaViewer
index cc7a023..7b20707 16
--- a/extensions/MultimediaViewer
+++ b/extensions/MultimediaViewer
-Subproject commit cc7a0235847e47a8c23a6a907297fac709312708
+Subproject commit 7b20707f00e03faddf1f43d7011807df3657432d

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iafc748c563c2ea6b50c57087be484063da4ce2dc
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.23wmf22
Gerrit-Owner: Ori.livneh 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Set line-height for code icon on schema pages - change (mediawiki...EventLogging)

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

Change subject: Set line-height for code icon on schema pages
..


Set line-height for code icon on schema pages

The Vector typography refresh caused the height of the code icon on schema
pages to bloat.

Bug: 64251
Change-Id: Iaa232298e0ed6689cee3ec987f7a127b7c33a577
(cherry picked from commit bc4c3d148e4670c558d3e63b69f8ef9d70789727)
---
M modules/ext.eventLogging.jsonSchema.css
1 file changed, 1 insertion(+), 0 deletions(-)

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



diff --git a/modules/ext.eventLogging.jsonSchema.css 
b/modules/ext.eventLogging.jsonSchema.css
index dbe3f35..f73a8c9 100644
--- a/modules/ext.eventLogging.jsonSchema.css
+++ b/modules/ext.eventLogging.jsonSchema.css
@@ -82,6 +82,7 @@
padding: 0.1em;
cursor: pointer;
transition: background-color .5s;
+   line-height: 0.46em;
 }
 
 .mw-json-schema-code-glyph:hover {

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Iaa232298e0ed6689cee3ec987f7a127b7c33a577
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/EventLogging
Gerrit-Branch: wmf/1.24wmf1
Gerrit-Owner: Ori.livneh 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

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


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

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

Change subject: Update MultimediaViewer for I595446dc5
..


Update MultimediaViewer for I595446dc5

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

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



diff --git a/extensions/MultimediaViewer b/extensions/MultimediaViewer
index 92777e3..e4e8a11 16
--- a/extensions/MultimediaViewer
+++ b/extensions/MultimediaViewer
-Subproject commit 92777e3d0d150cbd3db37a11e26e2ba05745fbae
+Subproject commit e4e8a111893028d63308529e69c01541a39b5289

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I1c5e8d6a596fde4f8411cb97c55fb88dd98c0427
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.24wmf1
Gerrit-Owner: Ori.livneh 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Add summarize/close/open topic to history/contribution - change (mediawiki...Flow)

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

Change subject: Add summarize/close/open topic to history/contribution
..


Add summarize/close/open topic to history/contribution

* board history
* topic history
* contribution
* watchlist
* recentchanges

Change-Id: Ia6c956db1c34f4160f31167068e27ebcbe89d472
---
M Flow.php
M FlowActions.php
M container.php
M includes/Block/Topic.php
M includes/Collection/PostSummaryCollection.php
M includes/Data/BoardHistoryIndex.php
M includes/Data/BoardHistoryStorage.php
A includes/Data/PostSummaryRecentChanges.php
M includes/Data/TopicHistoryIndex.php
A includes/Data/TopicHistoryStorage.php
M includes/Formatter/AbstractQuery.php
M includes/Formatter/BoardHistory.php
M includes/Formatter/ContributionsQuery.php
M includes/Formatter/RecentChangesQuery.php
M includes/Formatter/RevisionFormatter.php
15 files changed, 355 insertions(+), 44 deletions(-)

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



diff --git a/Flow.php b/Flow.php
index 68222ce..7758034 100755
--- a/Flow.php
+++ b/Flow.php
@@ -126,6 +126,7 @@
 $wgAutoloadClasses['Flow\Data\UniqueFeatureIndex'] = $dir . 
'includes/Data/UniqueFeatureIndex.php';
 $wgAutoloadClasses['Flow\Data\TopKIndex'] = $dir . 
'includes/Data/TopKIndex.php';
 $wgAutoloadClasses['Flow\Data\TopicHistoryIndex'] = $dir . 
'includes/Data/TopicHistoryIndex.php';
+$wgAutoloadClasses['Flow\Data\TopicHistoryStorage'] = $dir . 
'includes/Data/TopicHistoryStorage.php';
 $wgAutoloadClasses['Flow\Data\BoardHistoryStorage'] = $dir . 
'includes/Data/BoardHistoryStorage.php';
 $wgAutoloadClasses['Flow\Data\BoardHistoryIndex'] = $dir . 
'includes/Data/BoardHistoryIndex.php';
 $wgAutoloadClasses['Flow\Data\ObjectStorage'] = $dir . 
'includes/Data/ObjectStorage.php';
@@ -144,6 +145,7 @@
 $wgAutoloadClasses['Flow\Data\PagerPage'] = $dir . 
'includes/Data/PagerPage.php';
 $wgAutoloadClasses['Flow\Data\RecentChanges'] = $dir . 
'includes/Data/RecentChanges.php';
 $wgAutoloadClasses['Flow\Data\PostRevisionRecentChanges'] = $dir . 
'includes/Data/PostRevisionRecentChanges.php';
+$wgAutoloadClasses['Flow\Data\PostSummaryRecentChanges'] = $dir . 
'includes/Data/PostSummaryRecentChanges.php';
 $wgAutoloadClasses['Flow\Data\HeaderRecentChanges'] = $dir . 
'includes/Data/HeaderRecentChanges.php';
 $wgAutoloadClasses['Flow\Data\Compactor'] = $dir . 
'includes/Data/Compactor.php';
 $wgAutoloadClasses['Flow\Data\FeatureCompactor'] = $dir . 
'includes/Data/FeatureCompactor.php';
diff --git a/FlowActions.php b/FlowActions.php
index e10fe7c..3a80218 100644
--- a/FlowActions.php
+++ b/FlowActions.php
@@ -80,13 +80,13 @@
PostSummary::MODERATED_SUPPRESSED => array( 
'flow-suppress' ),
),
'button-method' => 'GET',
-   'links' => array(),
+   'links' => array( 'topic', 'topic-history' ),
'history' => array(
'i18n-message' => 
'flow-rev-message-create-topic-summary',
'i18n-params' => array(
'user-links',
'user-text',
-   'topic-of-post',
+   'post-of-summary',
),
'class' => 'flow-history-create-topic-summary',
),
@@ -104,13 +104,13 @@
PostSummary::MODERATED_SUPPRESSED => array( 
'flow-suppress' ),
),
'button-method' => 'GET',
-   'links' => array(),
+   'links' => array( 'topic', 'topic-history', 'diff-post-summary' 
),
'history' => array(
'i18n-message' => 'flow-rev-message-edit-topic-summary',
'i18n-params' => array(
'user-links',
'user-text',
-   'topic-of-post',
+   'post-of-summary',
),
'class' => 'flow-history-edit-topic-summary',
),
@@ -341,7 +341,7 @@
PostRevision::MODERATED_NONE => array( 'flow-hide', 
'flow-close', 'flow-delete', 'flow-suppress' ),
),
'button-method' => 'GET',
-   'links' => array(),
+   'links' => array( 'topic', 'topic-history' ),
'history' => array(
'i18n-message' => 'flow-rev-message-closed-topic',
'i18n-params' => array(
@@ -569,6 +569,7 @@
return '';
},
PostRevision::MODERATED_HIDDEN => '',
+   PostRevision::MODERATED_CLOSED => '',
PostRevision::MODERATED_DELETED => '',
PostRevision::MODERATED_SUPPRESSED => 'fl

[MediaWiki-commits] [Gerrit] Add topic/post summary diff view - change (mediawiki...Flow)

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

Change subject: Add topic/post summary diff view
..


Add topic/post summary diff view

Change-Id: I0bf26d798b1f5bebd391773fc3fd52a5ee95ecbd
---
M Flow.php
M i18n/en.json
M i18n/qqq.json
M includes/Block/TopicSummary.php
M includes/UrlGenerator.php
M includes/View/Revision.php
M modules/discussion/styles/post.less
A templates/postsummary.html.php
8 files changed, 261 insertions(+), 6 deletions(-)

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



diff --git a/Flow.php b/Flow.php
index 479b5e6..68222ce 100755
--- a/Flow.php
+++ b/Flow.php
@@ -112,6 +112,7 @@
 $wgAutoloadClasses['Flow\View\RevisionView'] = 
"$dir/includes/View/Revision.php";
 $wgAutoloadClasses['Flow\View\PostRevisionView'] = 
"$dir/includes/View/Revision.php";
 $wgAutoloadClasses['Flow\View\HeaderRevisionView'] = 
"$dir/includes/View/Revision.php";
+$wgAutoloadClasses['Flow\View\PostSummaryRevisionView'] = 
"$dir/includes/View/Revision.php";
 
 // Classes that deal with database interaction between database and the models
 $wgAutoloadClasses['Flow\Repository\TreeRepository'] = $dir . 
'includes/Repository/TreeRepository.php';
diff --git a/i18n/en.json b/i18n/en.json
index fe275fc..417079a 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -262,10 +262,13 @@
 "flow-topic-permalink-warning-user-board": "This topic was started on [$2 
{{GENDER:$1|$1}}'s board]",
 "flow-revision-permalink-warning-post": "This is a permanent link to a 
single version of this post.\nThis version is from $1.\nYou can see the [$5 
differences from the previous version], or view other versions on the [$4 post 
history page].",
 "flow-revision-permalink-warning-post-first": "This is a permanent link to 
the first version of this post.\nYou can view later versions on the [$4 post 
history page].",
+"flow-revision-permalink-warning-postsummary":  "This is a permanent link 
to a single version of the summary for this post. This version is from $1.\nYou 
can see the [$5 differences from the previous version], or view other versions 
on the [$4 post history page].",
+"flow-revision-permalink-warning-postsummary-first": "This is a permanent 
link to the first version of this post summary.\nYou can view later versions on 
the [$4 post history page].",
 "flow-revision-permalink-warning-header": "This is a permanent link to a 
single version of the header.\nThis version is from $1.  You can see the [$3 
differences from the previous version], or view other versions on the [$2 board 
history page].",
 "flow-revision-permalink-warning-header-first": "This is a permanent link 
to the first version of the header.\nYou can view later versions on the [$2 
board history page].",
 "flow-compare-revisions-revision-header": "Version by {{GENDER:$2|$2}} 
from $1",
 "flow-compare-revisions-header-post": "This page shows the 
{{GENDER:$3|changes}} between two versions of a post by $3 in the topic \"[$5 
$2]\" on [$4 $1].\nYou can see other versions of this post at its [$6 history 
page].",
+"flow-compare-revisions-header-postsummary": "This page shows the 
{{GENDER:$3|changes}} between two versions of a post summary in the post \"[$4 
$2]\" on [$3 $1].\nYou can see other versions of this post at its [$5 history 
page].",
 "flow-compare-revisions-header-header": "This page shows the 
{{GENDER:$2|changes}} between two versions of the header on [$3 $1].\nYou can 
see other versions of the header at its [$4 history page].",
 "flow-topic-collapsed-one-line": "Small view",
 "flow-topic-collapsed-full": "Collapsed view",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 66ef265..7bd1aaa 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -240,10 +240,13 @@
"flow-topic-permalink-warning-user-board": "Displayed at the top of a 
page when a person has clicked on a permanent link to a topic from a user's 
board.\n\nParameters:\n* $1 - the user's name. Supports GENDER.\n* $2 - URL for 
a link to the board that the topic comes from\nSee also:\n* 
{{msg-mw|Flow-topic-permalink-warning}}",
"flow-revision-permalink-warning-post": "Header displayed at the top of 
a page when somebody is viewing a single-revision permalink of a post.\n\nThis 
message will not appear for the first revision, which has its own message 
({{msg-mw|Flow-revision-permalink-warning-post-first}}).\n\nNote that the 
\"topic permalink warning\" (see {{msg-mw|Flow-topic-permalink-warning}}) will 
also be displayed.\n\nParameters:\n* $1 - date and timestamp, formatted as most 
are in Flow. That is, a human-readable timestamp that changes into an RFC2822 
timestamp when hovered over.\n* $2 - title of the Flow Board that the post 
appears on. Example: User talk:Andrew\n* $3 - title of the topic that this post 
appears in\n* $4 - URL to the history page\n* $5 - URL to the diff from the 
previous revision to this one\nSee al

[MediaWiki-commits] [Gerrit] Regression: Push history back to stable - change (mediawiki...MobileFrontend)

2014-04-22 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

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

Change subject: Regression: Push history back to stable
..

Regression: Push history back to stable

Bug introduced by If81fee954025b1ebc11d7d4a86eb70377b1f2233

Change-Id: I1eddf0fabdff92b8dde133fa75d2bc3065fca836
---
M includes/specials/SpecialMobileHistory.php
1 file changed, 0 insertions(+), 1 deletion(-)


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

diff --git a/includes/specials/SpecialMobileHistory.php 
b/includes/specials/SpecialMobileHistory.php
index f4b06b6..39c72b1 100644
--- a/includes/specials/SpecialMobileHistory.php
+++ b/includes/specials/SpecialMobileHistory.php
@@ -4,7 +4,6 @@
 class SpecialMobileHistory extends MobileSpecialPageFeed {
const LIMIT = 50;
const DB_REVISIONS_TABLE = 'revision';
-   protected $mode = 'beta';
/**  @var String|null timestamp to offset results from */
protected $offset;
 

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

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

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


[MediaWiki-commits] [Gerrit] Set line-height for code icon on schema pages - change (mediawiki...EventLogging)

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

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

Change subject: Set line-height for code icon on schema pages
..

Set line-height for code icon on schema pages

The Vector typography refresh caused the height of the code icon on schema
pages to bloat.

Bug: 64251
Change-Id: Iaa232298e0ed6689cee3ec987f7a127b7c33a577
(cherry picked from commit bc4c3d148e4670c558d3e63b69f8ef9d70789727)
---
M modules/ext.eventLogging.jsonSchema.css
1 file changed, 1 insertion(+), 0 deletions(-)


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

diff --git a/modules/ext.eventLogging.jsonSchema.css 
b/modules/ext.eventLogging.jsonSchema.css
index dbe3f35..f73a8c9 100644
--- a/modules/ext.eventLogging.jsonSchema.css
+++ b/modules/ext.eventLogging.jsonSchema.css
@@ -82,6 +82,7 @@
padding: 0.1em;
cursor: pointer;
transition: background-color .5s;
+   line-height: 0.46em;
 }
 
 .mw-json-schema-code-glyph:hover {

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iaa232298e0ed6689cee3ec987f7a127b7c33a577
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/EventLogging
Gerrit-Branch: wmf/1.24wmf1
Gerrit-Owner: Ori.livneh 

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


[MediaWiki-commits] [Gerrit] Improve diff detection - change (mediawiki...MobileFrontend)

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

Change subject: Improve diff detection
..


Improve diff detection

Bug: 63999
Change-Id: I02b18d43a6e5ffd1bdd5f78ef0ceb98d1c516103
---
M includes/specials/SpecialMobileDiff.php
M tests/specials/SpecialMobileDiffTest.php
2 files changed, 5 insertions(+), 0 deletions(-)

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



diff --git a/includes/specials/SpecialMobileDiff.php 
b/includes/specials/SpecialMobileDiff.php
index 88c91f7..f12665e 100644
--- a/includes/specials/SpecialMobileDiff.php
+++ b/includes/specials/SpecialMobileDiff.php
@@ -292,6 +292,9 @@
$req = MobileContext::singleton()->getRequest();
$rev2 = $req->getText( 'diff' );
$rev1 = $req->getText( 'oldid' );
+   if ( $rev1 == 'prev' || $rev1 == 'next' ) { // Actually, both 
do the same, WTF
+   $rev1 = '';
+   }
// redirect requests to the diff page to mobile view
if ( !$rev2 ) {
if ( $rev1 ) {
diff --git a/tests/specials/SpecialMobileDiffTest.php 
b/tests/specials/SpecialMobileDiffTest.php
index 8258a65..c17692a 100644
--- a/tests/specials/SpecialMobileDiffTest.php
+++ b/tests/specials/SpecialMobileDiffTest.php
@@ -77,6 +77,8 @@
array( array( 'diff' => 'prev', 'oldid' => 201 ), '' ),
// weird edge case comparing identical things
array( array( 'oldid' => 101, 'diff' => 101 ), 
'Special:MobileDiff/101...101' ),
+   // https://bugzilla.wikimedia.org/63999
+   array( array( 'oldid' => 'prev', 'diff' => 5 ), 
'Special:MobileDiff/5' ),
);
}
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I02b18d43a6e5ffd1bdd5f78ef0ceb98d1c516103
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: MaxSem 
Gerrit-Reviewer: Awjrichards 
Gerrit-Reviewer: JGonera 
Gerrit-Reviewer: Jdlrobson 
Gerrit-Reviewer: Kaldari 
Gerrit-Reviewer: jenkins-bot <>

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


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

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

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

Change subject: Update MultimediaViewer for I595446dc5
..

Update MultimediaViewer for I595446dc5

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


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

diff --git a/extensions/MultimediaViewer b/extensions/MultimediaViewer
index cc7a023..7b20707 16
--- a/extensions/MultimediaViewer
+++ b/extensions/MultimediaViewer
-Subproject commit cc7a0235847e47a8c23a6a907297fac709312708
+Subproject commit 7b20707f00e03faddf1f43d7011807df3657432d

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iafc748c563c2ea6b50c57087be484063da4ce2dc
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.23wmf22
Gerrit-Owner: Ori.livneh 

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


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

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

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

Change subject: Update MultimediaViewer for I595446dc5
..

Update MultimediaViewer for I595446dc5

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


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/66/129066/1

diff --git a/extensions/MultimediaViewer b/extensions/MultimediaViewer
index 92777e3..e4e8a11 16
--- a/extensions/MultimediaViewer
+++ b/extensions/MultimediaViewer
-Subproject commit 92777e3d0d150cbd3db37a11e26e2ba05745fbae
+Subproject commit e4e8a111893028d63308529e69c01541a39b5289

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1c5e8d6a596fde4f8411cb97c55fb88dd98c0427
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.24wmf1
Gerrit-Owner: Ori.livneh 

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


[MediaWiki-commits] [Gerrit] Basic VE code for changing displaytitle as wikitext in metad... - change (mediawiki...VisualEditor)

2014-04-22 Thread Alex Monk (Code Review)
Alex Monk has uploaded a new change for review.

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

Change subject: Basic VE code for changing displaytitle as wikitext in metadata 
panel
..

Basic VE code for changing displaytitle as wikitext in metadata panel

Some parts of this are heavily based on how the existing defaultsort stuff 
works.

DO NOT SUBMIT: Relies on Parsoid change that hasn't been written yet. See bug 
56870

(I started writing this before realising that Parsoid didn't support it yet. 
Oops.)

Bug: 56868
Change-Id: I5f0ce2ec36e82b04d9e1357b14046867c1dd3b60
---
M VisualEditor.php
A modules/ve-mw/dm/metaitems/ve.dm.MWDisplayTitleMetaItem.js
M modules/ve-mw/ui/pages/ve.ui.MWAdvancedSettingsPage.js
3 files changed, 141 insertions(+), 2 deletions(-)


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

diff --git a/VisualEditor.php b/VisualEditor.php
index f634176..b9d205a 100644
--- a/VisualEditor.php
+++ b/VisualEditor.php
@@ -837,6 +837,7 @@
'scripts' => array(

'modules/ve-mw/dm/metaitems/ve.dm.MWCategoryMetaItem.js',

'modules/ve-mw/dm/metaitems/ve.dm.MWDefaultSortMetaItem.js',
+   
'modules/ve-mw/dm/metaitems/ve.dm.MWDisplayTitleMetaItem.js',

'modules/ve-mw/dm/metaitems/ve.dm.MWHiddenCategoryMetaItem.js',

'modules/ve-mw/dm/metaitems/ve.dm.MWIndexDisableMetaItem.js',

'modules/ve-mw/dm/metaitems/ve.dm.MWIndexForceMetaItem.js',
diff --git a/modules/ve-mw/dm/metaitems/ve.dm.MWDisplayTitleMetaItem.js 
b/modules/ve-mw/dm/metaitems/ve.dm.MWDisplayTitleMetaItem.js
new file mode 100644
index 000..96315d9
--- /dev/null
+++ b/modules/ve-mw/dm/metaitems/ve.dm.MWDisplayTitleMetaItem.js
@@ -0,0 +1,54 @@
+/*!
+ * VisualEditor DataModel MWDisplayTitleMetaItem class.
+ *
+ * @copyright 2011-2014 VisualEditor Team and others; see AUTHORS.txt
+ * @license The MIT License (MIT); see LICENSE.txt
+ */
+
+/**
+ * DataModel display title meta item.
+ *
+ * @class
+ * @extends ve.dm.MetaItem
+ * @constructor
+ * @param {Object} element Reference to element in meta-linmod
+ */
+ve.dm.MWDisplayTitleMetaItem = function VeDmMWDisplayTitleMetaItem( element ) {
+   // Parent constructor
+   ve.dm.MetaItem.call( this, element );
+};
+
+/* Inheritance */
+
+OO.inheritClass( ve.dm.MWDisplayTitleMetaItem, ve.dm.MetaItem );
+
+/* Static Properties */
+
+ve.dm.MWDisplayTitleMetaItem.static.name = 'mwDisplayTitle';
+
+ve.dm.MWDisplayTitleMetaItem.static.group = 'mwDisplayTitle';
+
+ve.dm.MWDisplayTitleMetaItem.static.matchTagNames = [ 'meta' ];
+
+ve.dm.MWDisplayTitleMetaItem.static.matchRdfaTypes = [ 
'mw:PageProp/displaytitle' ];
+
+ve.dm.MWDisplayTitleMetaItem.static.toDataElement = function ( domElements ) {
+   var content = domElements[0].getAttribute( 'content' );
+   return {
+   'type': this.name,
+   'attributes': {
+   'content': content
+   }
+   };
+};
+
+ve.dm.MWDisplayTitleMetaItem.static.toDomElements = function ( dataElement, 
doc ) {
+   var meta = doc.createElement( 'meta' );
+   meta.setAttribute( 'property', 'mw:PageProp/displaytitle' );
+   meta.setAttribute( 'content', dataElement.attributes.content );
+   return [ meta ];
+};
+
+/* Registration */
+
+ve.dm.modelRegistry.register( ve.dm.MWDisplayTitleMetaItem );
diff --git a/modules/ve-mw/ui/pages/ve.ui.MWAdvancedSettingsPage.js 
b/modules/ve-mw/ui/pages/ve.ui.MWAdvancedSettingsPage.js
index 583156c..e657c79 100644
--- a/modules/ve-mw/ui/pages/ve.ui.MWAdvancedSettingsPage.js
+++ b/modules/ve-mw/ui/pages/ve.ui.MWAdvancedSettingsPage.js
@@ -84,6 +84,32 @@
}
);
 
+   this.displayTitleTouched = false;
+   this.enableDisplayTitleInput = new OO.ui.CheckboxInputWidget( { '$': 
this.$ } );
+   this.enableDisplayTitleInput.connect( this, { 'change': 
'onEnableDisplayTitleInputChange' } );
+   this.enableDisplayTitleField = new OO.ui.FieldLayout(
+   this.enableDisplayTitleInput,
+   {
+   '$': this.$,
+   'align': 'inline',
+   'label': 'Enable display title'
+   }
+   );
+   this.displayTitleInput = new OO.ui.TextInputWidget( {
+   '$': this.$,
+   'placeholder': 'Display title'
+   } );
+   this.displayTitleInput.connect( this, { 'change': 
'onDisplayTitleInputChange' } );
+   this.displayTitleField = new OO.ui.FieldLayout(
+   this.displayTitleInput,
+   {
+   '$': this.$,
+   'align': 'inline'
+   }
+   );
+
+   this.advancedSettingsFieldset.addItems( [ this.indexing, 
this.newEditSectionLink, this.enableDisplayTitleField, this.displayTit

[MediaWiki-commits] [Gerrit] Add more survey languages (fr, de, pt/pr-br) - change (mediawiki...MultimediaViewer)

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

Change subject: Add more survey languages (fr, de, pt/pr-br)
..


Add more survey languages (fr, de, pt/pr-br)

For pt speakers pt-br is shown until we get a pt translation

Related core commit: If2c57846f4dfb05ea58f36b25e3d8185d2a6e70e

Change-Id: I595446dc59c1bca2ea0b977be9d26f17192d3bc4
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/481
---
M resources/mmv/ui/mmv.ui.stripeButtons.js
M tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
2 files changed, 27 insertions(+), 5 deletions(-)

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



diff --git a/resources/mmv/ui/mmv.ui.stripeButtons.js 
b/resources/mmv/ui/mmv.ui.stripeButtons.js
index 6fafaee..5278970 100644
--- a/resources/mmv/ui/mmv.ui.stripeButtons.js
+++ b/resources/mmv/ui/mmv.ui.stripeButtons.js
@@ -192,14 +192,17 @@
 * @param {string|null} langcode
 */
SBP.getFeedbackSurveyBaseUrlForLanguage = function ( langcode ) {
-   var baseUrl = 'https://www.surveymonkey.com/s/media-viewer-1',
-   surveyTranslations = { ca: 1, hu: 1 };
+   var baseLangcode,
+   baseUrl = 
'https://www.surveymonkey.com/s/media-viewer-1',
+   surveyTranslations = { ca: 'ca', hu: 'hu', fr: 'fr', 
pt: 'pt-br', 'pt-br': 'pt-br', de: 'de' };
 
-   langcode = langcode.split( /[_-]/ )[0]; // get rid of variants
-   if ( langcode === 'en') {
+   baseLangcode = langcode.split( /[_-]/ )[0]; // get rid of 
variants
+   if ( baseLangcode === 'en') {
return baseUrl;
} else if ( surveyTranslations[langcode] ) {
-   return baseUrl + '-' + langcode;
+   return baseUrl + '-' + surveyTranslations[langcode];
+   } else if ( surveyTranslations[baseLangcode] ) {
+   return baseUrl + '-' + surveyTranslations[baseLangcode];
} else {
return null;
}
diff --git a/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js 
b/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
index 11ca67b..389f0c7 100644
--- a/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
+++ b/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
@@ -82,6 +82,25 @@
mw.config.set( 'wgUserLanguage', oldLanguage );
} );
 
+   QUnit.test( 'getFeedbackSurveyBaseUrlForLanguage()', 7, function ( 
assert ) {
+   var buttons = createStripeButtons();
+
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'en' ),
+   'https://www.surveymonkey.com/s/media-viewer-1', 'Base 
survey URL for english' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'hu' ),
+   'https://www.surveymonkey.com/s/media-viewer-1-hu', 
'Language code appended for supported languages' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'el' ),
+   null, 'Null for non-supported languages' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'en-gb' ),
+   'https://www.surveymonkey.com/s/media-viewer-1', 'Base 
survey URL for english variants' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'fr-xx' ),
+   'https://www.surveymonkey.com/s/media-viewer-1-fr', 
'Base code appended for other variants' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'pt-br' ),
+   'https://www.surveymonkey.com/s/media-viewer-1-pt-br', 
'Full code appended if the variant itself is supported' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'pt' ),
+   'https://www.surveymonkey.com/s/media-viewer-1-pt-br', 
'Temporary special case for pt' );
+   } );
+
QUnit.test( 'set()/empty() sanity test:', 1, function ( assert ) {
var buttons = createStripeButtons(),
fakeImageInfo = { descriptionUrl: 
'//commons.wikimedia.org/wiki/File:Foo.jpg' },

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I595446dc59c1bca2ea0b977be9d26f17192d3bc4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: wmf/1.24wmf1
Gerrit-Owner: Gergő Tisza 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Hygiene: Clean up profile page dead code - change (mediawiki...MobileFrontend)

2014-04-22 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

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

Change subject: Hygiene: Clean up profile page dead code
..

Hygiene: Clean up profile page dead code

Change-Id: I0d8d56a6ea5dbf308da6bd1de86d535d41fc5264
---
M includes/specials/SpecialUserProfile.php
M less/specials/userprofile.less
2 files changed, 0 insertions(+), 82 deletions(-)


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

diff --git a/includes/specials/SpecialUserProfile.php 
b/includes/specials/SpecialUserProfile.php
index 6bef211..713bb0b 100644
--- a/includes/specials/SpecialUserProfile.php
+++ b/includes/specials/SpecialUserProfile.php
@@ -16,16 +16,6 @@
 * @var MobileUserInfo
 */
private $userInfo;
-   /**
-* The user's description of himself or herself
-* @var String
-*/
-   public $userDescription;
-   /**
-* Whether or not the page is editable by the current user
-* @var Boolean
-*/
-   private $editable = false;
 
public function __construct() {
parent::__construct( 'UserProfile' );
@@ -71,35 +61,6 @@
Html::closeElement( 'div' );
wfProfileOut( __METHOD__ );
return $img;
-   }
-
-   /**
-* Returns HTML to show the user's description as well as a hidden form 
for editing
-* the description.
-*
-* @return String HTML
-*
-*/
-   protected function getUserSummary() {
-   $out = '';
-   if ( $this->editable || $this->userDescription ) {
-   $out = Html::openElement( 'div', array( 'class' => 
'user-description-container' ) );
-   if ( $this->userDescription ) {
-   $out .= Html::openElement( 'p', array( 
'class' => 'user-description' ) );
-   // FIXME: Use quotation-marks message
-   // NOTE: This outputs WikiText as raw 
text (not parsed). This is on
-   // purpose, but may be changed in the 
future.
-   $out .= htmlspecialchars( 
$this->userDescription );
-   $out .= Html::closeElement( 'p' );
-   } elseif ( $this->editable ) {
-   $out .= Html::openElement( 'p', array( 
'class' => 'user-description-placeholder' ) );
-   $out .= $this->msg( 
'mobile-frontend-profile-description-placeholder',
-   $this->targetUser );
-   $out .= Html::closeElement( 'p' );
-   }
-   $out .= Html::closeElement( 'div' );
-   }
-   return $out;
}
 
/**
diff --git a/less/specials/userprofile.less b/less/specials/userprofile.less
index 7c67c49..946d7aa 100644
--- a/less/specials/userprofile.less
+++ b/less/specials/userprofile.less
@@ -25,49 +25,6 @@
font-size: 0.9em;
}
 
-   .user-description-container {
-   padding: 0 (@contentMargin * 2) 1.5em;
-   position: relative;
-
-   .user-description-placeholder,
-   .user-description {
-   display: inline;
-   font-family: @fontFamilyHeading;
-   font-style: italic;
-   font-size: 1.2em;
-   line-height: @contentLineHeight;
-   }
-
-   .edit-button {
-   display: inline-block;
-   vertical-align: middle;
-   background: url(images/profile/edit.png) 50% 30% 
no-repeat;
-   .background-size( 16px, auto );
-   text-indent: px;
-   width: 32px;
-   height: 32px;
-   cursor: pointer;
-   }
-
-   .editor {
-   text-align: right;
-   }
-
-   textarea {
-   .box-sizing( border-box );
-   width: 100%;
-   height: 120px;
-   margin-bottom: 1em;
-   }
-
-   .character-counter {
-   margin-right: 1em;
-   &.warning {
-   color: @redBase;
-   }
-   }
-   }
-
h2 {
color: @grayLight;
text-transform: uppercase;

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

Gerrit

[MediaWiki-commits] [Gerrit] Add more survey languages (fr, de, pt/pr-br) - change (mediawiki...MultimediaViewer)

2014-04-22 Thread Ori.livneh (Code Review)
Ori.livneh has submitted this change and it was merged.

Change subject: Add more survey languages (fr, de, pt/pr-br)
..


Add more survey languages (fr, de, pt/pr-br)

For pt speakers pt-br is shown until we get a pt translation

Related core commit: If2c57846f4dfb05ea58f36b25e3d8185d2a6e70e

Change-Id: I595446dc59c1bca2ea0b977be9d26f17192d3bc4
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/481
(cherry picked from commit d1a6592185cddb38df14a03a3a69c44dda1c525a)
---
M resources/mmv/ui/mmv.ui.stripeButtons.js
M tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
2 files changed, 27 insertions(+), 5 deletions(-)

Approvals:
  Ori.livneh: Verified; Looks good to me, approved



diff --git a/resources/mmv/ui/mmv.ui.stripeButtons.js 
b/resources/mmv/ui/mmv.ui.stripeButtons.js
index 655e60c..f6434a9 100644
--- a/resources/mmv/ui/mmv.ui.stripeButtons.js
+++ b/resources/mmv/ui/mmv.ui.stripeButtons.js
@@ -192,14 +192,17 @@
 * @param {string|null} langcode
 */
SBP.getFeedbackSurveyBaseUrlForLanguage = function ( langcode ) {
-   var baseUrl = 'https://www.surveymonkey.com/s/media-viewer-1',
-   surveyTranslations = { ca: 1, hu: 1 };
+   var baseLangcode,
+   baseUrl = 
'https://www.surveymonkey.com/s/media-viewer-1',
+   surveyTranslations = { ca: 'ca', hu: 'hu', fr: 'fr', 
pt: 'pt-br', 'pt-br': 'pt-br', de: 'de' };
 
-   langcode = langcode.split( /[_-]/ )[0]; // get rid of variants
-   if ( langcode === 'en') {
+   baseLangcode = langcode.split( /[_-]/ )[0]; // get rid of 
variants
+   if ( baseLangcode === 'en') {
return baseUrl;
} else if ( surveyTranslations[langcode] ) {
-   return baseUrl + '-' + langcode;
+   return baseUrl + '-' + surveyTranslations[langcode];
+   } else if ( surveyTranslations[baseLangcode] ) {
+   return baseUrl + '-' + surveyTranslations[baseLangcode];
} else {
return null;
}
diff --git a/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js 
b/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
index 11ca67b..389f0c7 100644
--- a/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
+++ b/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
@@ -82,6 +82,25 @@
mw.config.set( 'wgUserLanguage', oldLanguage );
} );
 
+   QUnit.test( 'getFeedbackSurveyBaseUrlForLanguage()', 7, function ( 
assert ) {
+   var buttons = createStripeButtons();
+
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'en' ),
+   'https://www.surveymonkey.com/s/media-viewer-1', 'Base 
survey URL for english' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'hu' ),
+   'https://www.surveymonkey.com/s/media-viewer-1-hu', 
'Language code appended for supported languages' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'el' ),
+   null, 'Null for non-supported languages' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'en-gb' ),
+   'https://www.surveymonkey.com/s/media-viewer-1', 'Base 
survey URL for english variants' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'fr-xx' ),
+   'https://www.surveymonkey.com/s/media-viewer-1-fr', 
'Base code appended for other variants' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'pt-br' ),
+   'https://www.surveymonkey.com/s/media-viewer-1-pt-br', 
'Full code appended if the variant itself is supported' );
+   assert.strictEqual( 
buttons.getFeedbackSurveyBaseUrlForLanguage( 'pt' ),
+   'https://www.surveymonkey.com/s/media-viewer-1-pt-br', 
'Temporary special case for pt' );
+   } );
+
QUnit.test( 'set()/empty() sanity test:', 1, function ( assert ) {
var buttons = createStripeButtons(),
fakeImageInfo = { descriptionUrl: 
'//commons.wikimedia.org/wiki/File:Foo.jpg' },

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I595446dc59c1bca2ea0b977be9d26f17192d3bc4
Gerrit-PatchSet: 8
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: wmf/1.23wmf22
Gerrit-Owner: Gergő Tisza 
Gerrit-Reviewer: Ori.livneh 

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 9388480..c034e31 - change (mediawiki/extensions)

2014-04-22 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

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

Change subject: Syncronize VisualEditor: 9388480..c034e31
..

Syncronize VisualEditor: 9388480..c034e31

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


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

diff --git a/VisualEditor b/VisualEditor
index 9388480..c034e31 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 93884808bcf11ec3f7ae3fcfa79027da4301c4f5
+Subproject commit c034e31404226eee4d868f4e884d2b6399f37e4e

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

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

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


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 9388480..c034e31 - change (mediawiki/extensions)

2014-04-22 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: 9388480..c034e31
..


Syncronize VisualEditor: 9388480..c034e31

Change-Id: I92693ada8ecaa62c8563de04c7ca1decfbe30086
---
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 9388480..c034e31 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 93884808bcf11ec3f7ae3fcfa79027da4301c4f5
+Subproject commit c034e31404226eee4d868f4e884d2b6399f37e4e

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I92693ada8ecaa62c8563de04c7ca1decfbe30086
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] Show notice if user is globally blocked - change (mediawiki...VisualEditor)

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

Change subject: Show notice if user is globally blocked
..


Show notice if user is globally blocked

Bug: 53009
Change-Id: I5c8a31f40535e7495133738a03d83648d57fb526
---
M ApiVisualEditor.php
1 file changed, 13 insertions(+), 0 deletions(-)

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



diff --git a/ApiVisualEditor.php b/ApiVisualEditor.php
index e926597..dce6e15 100644
--- a/ApiVisualEditor.php
+++ b/ApiVisualEditor.php
@@ -391,6 +391,19 @@
)->parseAsBlock();
}
 
+   if ( class_exists( 'GlobalBlocking' ) ) {
+   $error = 
GlobalBlocking::getUserBlockErrors(
+   $user,
+   $this->getRequest()->getIP()
+   );
+   if ( count( $error ) ) {
+   $notices[] = 
call_user_func_array(
+   array( $this, 'msg' ),
+   $error
+   )->parseAsBlock();
+   }
+   }
+
// HACK: Build a fake EditPage so we can get 
checkboxes from it
$article = new Article( $page ); // 
Deliberately omitting ,0 so oldid comes from request
$ep = new EditPage( $article );

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

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

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


[MediaWiki-commits] [Gerrit] revive dump_tests, using new config and logging api - change (wikimedia...tools)

2014-04-22 Thread Adamw (Code Review)
Adamw has uploaded a new change for review.

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

Change subject: revive dump_tests, using new config and logging api
..

revive dump_tests, using new config and logging api

Change-Id: Ia0b563adce0b2d78d1845ab23560f9493dc63e71
---
M live_analysis/dump_tests.py
1 file changed, 6 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/tools 
refs/changes/62/129062/1

diff --git a/live_analysis/dump_tests.py b/live_analysis/dump_tests.py
index 6e42444..a3dab29 100755
--- a/live_analysis/dump_tests.py
+++ b/live_analysis/dump_tests.py
@@ -5,9 +5,13 @@
 
 import csv
 import sys
-import mediawiki.centralnotice.api
 
-import process.globals
+from process.logging import Logger as log
+from process.globals import load_config
+load_config("analysis")
+
+import mediawiki.centralnotice.api
+from process.globals import config
 
 def is_relevant(entry):
 '''
@@ -52,5 +56,4 @@
 cur = cur + pagesize
 
 if __name__ == "__main__":
-process.globals.load_config("analysis")
 fetch()

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia0b563adce0b2d78d1845ab23560f9493dc63e71
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/tools
Gerrit-Branch: master
Gerrit-Owner: Adamw 

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


[MediaWiki-commits] [Gerrit] Fix WikibaseLuaBindings after SiteLinkLookup change - change (mediawiki...Wikibase)

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

Change subject: Fix WikibaseLuaBindings after SiteLinkLookup change
..


Fix WikibaseLuaBindings after SiteLinkLookup change

After I67824712f SiteLinkLookup::getItemIdForLink no longer
returns int.

Change-Id: I67d78661de8469a9578420a8ab1421622197c5d3
---
M client/includes/scribunto/WikibaseLuaBindings.php
M client/tests/phpunit/includes/scribunto/WikibaseLuaBindingsTest.php
2 files changed, 3 insertions(+), 5 deletions(-)

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



diff --git a/client/includes/scribunto/WikibaseLuaBindings.php 
b/client/includes/scribunto/WikibaseLuaBindings.php
index 2c2d8a1..07261e3 100644
--- a/client/includes/scribunto/WikibaseLuaBindings.php
+++ b/client/includes/scribunto/WikibaseLuaBindings.php
@@ -179,13 +179,11 @@
 * @return string|null $id
 */
public function getEntityId( $pageTitle = null ) {
-   $numericId = $this->siteLinkTable->getItemIdForLink( 
$this->siteId, $pageTitle );
+   $id = $this->siteLinkTable->getItemIdForLink( $this->siteId, 
$pageTitle );
 
-   if ( ! is_int( $numericId ) ) {
+   if ( !$id ) {
return null;
}
-
-   $id = ItemId::newFromNumber( $numericId );
 
return $this->entityIdFormatter->format( $id );
}
diff --git 
a/client/tests/phpunit/includes/scribunto/WikibaseLuaBindingsTest.php 
b/client/tests/phpunit/includes/scribunto/WikibaseLuaBindingsTest.php
index 6665eee..8108431 100644
--- a/client/tests/phpunit/includes/scribunto/WikibaseLuaBindingsTest.php
+++ b/client/tests/phpunit/includes/scribunto/WikibaseLuaBindingsTest.php
@@ -46,7 +46,7 @@
$siteLinkTable->expects( $this->any() )
->method( 'getItemIdForLink' )
->will( $this->returnCallback( function( $siteId, $page 
) {
-   return ( $page === 'Rome' ) ? 33 : 
false;
+   return ( $page === 'Rome' ) ? new 
ItemId( 'Q33' ) : false;
} )
);
 

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I67d78661de8469a9578420a8ab1421622197c5d3
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Hoo man 
Gerrit-Reviewer: Aude 
Gerrit-Reviewer: WikidataJenkins 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Some cleanup + trace dom range identification - change (mediawiki...parsoid)

2014-04-22 Thread Subramanya Sastry (Code Review)
Subramanya Sastry has uploaded a new change for review.

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

Change subject: Some cleanup + trace dom range identification
..

Some cleanup + trace dom range identification

* Refactored some common code.

* After wasting an hour tracing a non-bug after being confused by
  different tables marked by identical about-ids, fixed trace
  output to prominently emit tag-ids for tables so it is clear
  that different table elements are being examines.

* Added tracing for finding DOM ranges and marked a potential
  bug with a FIXME.

Change-Id: I19ac27f57ccce31580069279df3fa835aa038d73
---
M lib/dom.wrapTemplates.js
1 file changed, 34 insertions(+), 24 deletions(-)


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

diff --git a/lib/dom.wrapTemplates.js b/lib/dom.wrapTemplates.js
index 874a773..1c989c2 100644
--- a/lib/dom.wrapTemplates.js
+++ b/lib/dom.wrapTemplates.js
@@ -47,32 +47,26 @@
// now find common ancestor
var elem = endElem;
var parentNode = endElem.parentNode;
-   var range = null;
+   var range = {
+   startElem: startElem,
+   endElem: endMeta,
+   id: env.stripIdPrefix(startElem.getAttribute("about")),
+   startOffset: DU.getDataParsoid( startElem ).tsr[0],
+   flipped: false
+   };
while (parentNode && parentNode.nodeType !== doc.DOCUMENT_NODE) {
var i = startAncestors.indexOf( parentNode );
-   var tsr0 = DU.getDataParsoid( startElem ).tsr[0];
if (i === 0) {
// widen the scope to include the full subtree
-   range = {
-   'root': startElem,
-   startElem: startElem,
-   endElem: endMeta,
-   start: startElem.firstChild,
-   end: startElem.lastChild,
-   id: 
env.stripIdPrefix(startElem.getAttribute("about")),
-   startOffset: tsr0
-   };
+   range.root = startElem;
+   range.start = startElem.firstChild;
+   // SSS FIXME: startElem.lastChild might not be an 
ELEMENT_NODE
+   range.end = startElem.lastChild;
break;
-   } else if ( i > 0) {
-   range = {
-   'root': parentNode,
-   startElem: startElem,
-   endElem: endMeta,
-   start: startAncestors[i - 1],
-   end: elem,
-   id: 
env.stripIdPrefix(startElem.getAttribute("about")),
-   startOffset: tsr0
-   };
+   } else if (i > 0) {
+   range.root = parentNode;
+   range.start = startAncestors[i - 1];
+   range.end = elem;
break;
}
elem = parentNode;
@@ -179,12 +173,26 @@
}
}
 
-   if (!DU.inSiblingOrder(range.start, range.end)) {
+   if (DU.inSiblingOrder(range.end, range.start)) {
// In foster-parenting situations, the end-meta tag (and hence 
r.end)
// can show up before the r.start which would be the table 
itself.
// So, we record this info for later analysis.
range.flipped = true;
}
+
+   env.log("trace/tplwrap/findranges", function() {
+   var msg = "";
+   var dp1 = DU.getDataParsoid(range.start);
+   var dp2 = DU.getDataParsoid(range.end);
+   msg += 
"\n--";
+   msg += "\nFound range : " + range.id + "; flipped? " + 
range.flipped + "; offset: " + range.startOffset;
+   msg += "\nstart-elem : " + range.startElem.outerHTML + 
"; DP: " + JSON.stringify(DU.getDataParsoid(range.startElem));
+   msg += "\nend-elem : " + range.endElem.outerHTML + "; 
DP: " + JSON.stringify(DU.getDataParsoid(range.endElem));
+   msg += "\nstart : [TAG_ID " + dp1.tagId + "]: " + 
range.start.outerHTML + "; DP: " + JSON.stringify(dp1);
+   msg += "\nend : [TAG_ID " + dp2.tagId + "]: " + 
range.end.outerHTML + "; DP: " + JSON.stringify(dp2);
+   msg += 
"\n--";
+   return msg;
+   });
 
return range;
 }
@@ -401,11 +409,13 @@
 
env.log("trace/tplwrap/merge", function() {

[MediaWiki-commits] [Gerrit] Fix Fatal error: Call to a member function doTransform() - change (mediawiki...TimedMediaHandler)

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

Change subject: Fix Fatal error: Call to a member function doTransform()
..


Fix Fatal error: Call to a member function doTransform()

Bug: 64152
Change-Id: I7483c8b7ec75f5149998da2b530ca0467ac70de7
---
M TimedMediaThumbnail.php
1 file changed, 10 insertions(+), 2 deletions(-)

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



diff --git a/TimedMediaThumbnail.php b/TimedMediaThumbnail.php
index 55f4290..7775744 100644
--- a/TimedMediaThumbnail.php
+++ b/TimedMediaThumbnail.php
@@ -198,8 +198,16 @@
"width" => $options['width'],
"height" => $options['height']
);
-   $scaledThumb = $thumbFile->getHandler()->doTransform( 
$thumbFile,
-   $options['dstPath'], $options['dstPath'], $thumbParams 
);
+   $handler = $thumbFile->getHandler();
+   if ( !$handler ) {
+   return false;
+   }
+   $scaledThumb = $handler->doTransform(
+   $thumbFile,
+   $options['dstPath'],
+   $options['dstPath'],
+   $thumbParams
+   );
 
if ( !$scaledThumb || $scaledThumb->isError() ) {
return $scaledThumb;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I7483c8b7ec75f5149998da2b530ca0467ac70de7
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/TimedMediaHandler
Gerrit-Branch: master
Gerrit-Owner: Reedy 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Test commit - change (mediawiki...Flow)

2014-04-22 Thread Violetto (Code Review)
Violetto has uploaded a new change for review.

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

Change subject: Test commit
..

Test commit

Change-Id: I42cccb6f6d2a6f84b7a2e101202c121083847ce3
---
M modules/discussion/styles/collapse.less
1 file changed, 0 insertions(+), 1 deletion(-)


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

diff --git a/modules/discussion/styles/collapse.less 
b/modules/discussion/styles/collapse.less
index 853775e..12687a0 100644
--- a/modules/discussion/styles/collapse.less
+++ b/modules/discussion/styles/collapse.less
@@ -31,7 +31,6 @@
margin-right: 6px;
}
}
-
.topic-one-line {
.collapseButtonIcon( '../../base/images/toggle_one_line' );
}

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I42cccb6f6d2a6f84b7a2e101202c121083847ce3
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Flow
Gerrit-Branch: master
Gerrit-Owner: Violetto 

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


[MediaWiki-commits] [Gerrit] Hide some tools when VE is open - change (mediawiki...VisualEditor)

2014-04-22 Thread Alex Monk (Code Review)
Alex Monk has uploaded a new change for review.

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

Change subject: Hide some tools when VE is open
..

Hide some tools when VE is open

Bug: 57940
Change-Id: I2f586e8c73affe1b7f14c40ba892774e784f09c8
---
M modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js
1 file changed, 2 insertions(+), 0 deletions(-)


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

diff --git a/modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js 
b/modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js
index 2728290..9fa4b8c 100644
--- a/modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js
+++ b/modules/ve-mw/init/targets/ve.init.mw.ViewPageTarget.js
@@ -1235,6 +1235,7 @@
.removeClass( 've-init-mw-viewPageTarget-content' )
.show()
.fadeTo( 0, 1 );
+   $( '#t-print, #t-permalink, #p-coll-print_export, #t-cite' ).show();
 };
 
 /**
@@ -1257,6 +1258,7 @@
$( '#bodyContent > :visible:not(#siteSub,.ve-ui-mwTocWidget)' )
.addClass( 've-init-mw-viewPageTarget-content' )
.hide();
+   $( '#t-print, #t-permalink, #p-coll-print_export, #t-cite' ).hide();
 };
 
 /**

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

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

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


[MediaWiki-commits] [Gerrit] Fix WikibaseLuaBindings after SiteLinkLookup change - change (mediawiki...Wikibase)

2014-04-22 Thread Hoo man (Code Review)
Hoo man has uploaded a new change for review.

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

Change subject: Fix WikibaseLuaBindings after SiteLinkLookup change
..

Fix WikibaseLuaBindings after SiteLinkLookup change

After I67824712f SiteLinkLookup::getItemIdForLink no longer
returns int.

Change-Id: I67d78661de8469a9578420a8ab1421622197c5d3
---
M client/includes/scribunto/WikibaseLuaBindings.php
1 file changed, 2 insertions(+), 4 deletions(-)


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

diff --git a/client/includes/scribunto/WikibaseLuaBindings.php 
b/client/includes/scribunto/WikibaseLuaBindings.php
index 2c2d8a1..07261e3 100644
--- a/client/includes/scribunto/WikibaseLuaBindings.php
+++ b/client/includes/scribunto/WikibaseLuaBindings.php
@@ -179,13 +179,11 @@
 * @return string|null $id
 */
public function getEntityId( $pageTitle = null ) {
-   $numericId = $this->siteLinkTable->getItemIdForLink( 
$this->siteId, $pageTitle );
+   $id = $this->siteLinkTable->getItemIdForLink( $this->siteId, 
$pageTitle );
 
-   if ( ! is_int( $numericId ) ) {
+   if ( !$id ) {
return null;
}
-
-   $id = ItemId::newFromNumber( $numericId );
 
return $this->entityIdFormatter->format( $id );
}

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

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

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


[MediaWiki-commits] [Gerrit] Clean up live-analysis code - change (wikimedia...tools)

2014-04-22 Thread Adamw (Code Review)
Adamw has uploaded a new change for review.

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

Change subject: Clean up live-analysis code
..

Clean up live-analysis code

* use yaml config and logging module

Also:
* log.error is duplicated to stderr

Change-Id: Ida829bf5f48c2c5b2373e82b2387fd8440f3ebed
---
M fundraising_ab_tests/__init__.py
M fundraising_ab_tests/results_gdoc.py
M fundraising_ab_tests/spec.py
M fundraising_ab_tests/spec_gdoc.py
D live_analysis/config.py.example
A live_analysis/config.yaml.example
M live_analysis/publish_results
M live_analysis/update_spec_sheet
M process/logging.py
9 files changed, 77 insertions(+), 59 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/tools 
refs/changes/56/129056/1

diff --git a/fundraising_ab_tests/__init__.py b/fundraising_ab_tests/__init__.py
index 01a2efe..6f8b05e 100644
--- a/fundraising_ab_tests/__init__.py
+++ b/fundraising_ab_tests/__init__.py
@@ -6,14 +6,15 @@
 
 import mediawiki.centralnotice.api
 from results import get_banner_results
+from process.logging import Logger as log
 
 class FrTest(object):
 def __init__(self, label=None, type="", campaign=None, banners=None, 
start=None, end=None, disabled=False, **ignore):
-print "Warning: ignoring columns: %s" % (", ".join(ignore.keys()), )
+log.warn("ignoring columns: {columns}".format(columns=", 
".join(ignore.keys(
 
 self.campaign = mediawiki.centralnotice.api.get_campaign(campaign)
 if not self.campaign:
-print "Warning: no such campaign '%s'" % campaign
+log.warn("no such campaign '{campaign}'".format(campaign=campaign))
 
 self.type = type.lower()
 
@@ -59,10 +60,10 @@
 if self.is_country_test:
 #results = [ calculate_result(country=code) for code in 
campaign['countries'] ]
 #self.results.extend(results)
-print "country test type not implemented"
+log.warn("country test type not implemented")
 
 if self.is_lp_test:
-print "LP test type not implemented"
+log.warn("LP test type not implemented")
 
 def get_case(self, **kw):
 conditions = {
diff --git a/fundraising_ab_tests/results_gdoc.py 
b/fundraising_ab_tests/results_gdoc.py
index c52b7d7..4c3c333 100644
--- a/fundraising_ab_tests/results_gdoc.py
+++ b/fundraising_ab_tests/results_gdoc.py
@@ -1,7 +1,8 @@
 from google.gdocs import Spreadsheet
+from process.logging import Logger as log
 
 def write_gdoc_results(doc=None, results=[]):
-print "Writing test results to %s" % doc
+log.info("Writing test results to {url}".format(url=doc))
 doc = Spreadsheet(doc=doc)
 for result in results:
 props = {}
@@ -10,7 +11,7 @@
 doc.append_row(props)
 
 def update_gdoc_results(doc=None, results=[]):
-print "Updating results in %s" % doc
+log.info("Updating results in {url}".format(url=doc))
 doc = Spreadsheet(doc=doc)
 existing = list(doc.get_all_rows())
 
@@ -43,7 +44,7 @@
 doc.append_row(props)
 else:
 if len(matching) > 1:
-print "WARNING: more than one result row %s matches criteria: 
%s" % (matching, result['criteria'], )
+log.warn("more than one result row {match} matches criteria: 
{criteria}".format(match=matching, criteria=result['criteria']))
 index = matching[-1]
-print "DEBUG: updating row %d with %s" % (index, 
result['criteria']['banner'])
+log.debug("updating row {rownum} with 
{banner}".format(rownum=index, banner=result['criteria']['banner']))
 doc.update_row(props, index=index)
diff --git a/fundraising_ab_tests/spec.py b/fundraising_ab_tests/spec.py
index 099ec3d..8f19ad4 100644
--- a/fundraising_ab_tests/spec.py
+++ b/fundraising_ab_tests/spec.py
@@ -7,6 +7,8 @@
 
 from fundraising_ab_tests import FrTest
 import campaign_log
+from process.globals import config
+from process.logging import Logger as log
 
 def parse_spec(spec):
 for row in spec:
@@ -18,7 +20,9 @@
 
 def is_fr_test(test):
 if test.label and test.banners and test.campaign:
-is_chapter = re.search(r'(_|\b)WM[A-Z]{2}(_|\b)', test.banners[0])
+is_chapter = re.search(config.fr_chapter_test, test.banners[0])
+if is_chapter:
+log.debug("Determined banner {banner} belongs to a 
chapter".format(banner=test.banners[0]))
 return not is_chapter
 
 
diff --git a/fundraising_ab_tests/spec_gdoc.py 
b/fundraising_ab_tests/spec_gdoc.py
index 3c56201..9af5012 100644
--- a/fundraising_ab_tests/spec_gdoc.py
+++ b/fundraising_ab_tests/spec_gdoc.py
@@ -1,11 +1,12 @@
 from spec import FrTestSpec, parse_spec
 from google.gdocs import Spreadsheet
+from process.logging import Logger as log
 
 def read_gdoc_spec(doc=None):
 return 
FrTestSpec(spec=list(parse_spec(Spreadsheet(doc=doc).get_all_rows(
 
 def update_gdoc_spec(do

[MediaWiki-commits] [Gerrit] Bump version for new alpha release - change (apps...wikipedia)

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

Change subject: Bump version for new alpha release
..


Bump version for new alpha release

Change-Id: I06e787fcc230b20e26969f32010bc0e6ab81cc9b
---
M wikipedia/AndroidManifest.xml
1 file changed, 3 insertions(+), 3 deletions(-)

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



diff --git a/wikipedia/AndroidManifest.xml b/wikipedia/AndroidManifest.xml
index 76a8c08..e1a2211 100644
--- a/wikipedia/AndroidManifest.xml
+++ b/wikipedia/AndroidManifest.xml
@@ -1,8 +1,8 @@
 
 http://schemas.android.com/apk/res/android";
 package="org.wikipedia"
-android:versionCode="37"
-android:versionName="2.0-alpha-2014-04-15" >
+android:versionCode="38"
+android:versionName="2.0-alpha-2014-04-22" >
 
 
 
-
\ No newline at end of file
+

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I06e787fcc230b20e26969f32010bc0e6ab81cc9b
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Yuvipanda 
Gerrit-Reviewer: Yuvipanda 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Massive update for SMW 1.9, extensions moved to GitHub, and ... - change (mediawiki...SemanticBundle)

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

Change subject: Massive update for SMW 1.9, extensions moved to GitHub, and 
Composer usage
..


Massive update for SMW 1.9, extensions moved to GitHub, and Composer usage

Also added Semantic Extra Special Properties extension

Change-Id: I7b614cafe356d3355a4f612f44d70833f66468a3
---
M Makefile
M SemanticBundleSettings.sample.php
M externals
3 files changed, 66 insertions(+), 30 deletions(-)

Approvals:
  Yaron Koren: Checked; Looks good to me, approved
  jenkins-bot: Verified



diff --git a/Makefile b/Makefile
index a927202..fb547c6 100644
--- a/Makefile
+++ b/Makefile
@@ -3,8 +3,17 @@
 all:
rm -rf release
mkdir release
-   awk '{ system("cd release && git clone 
https://gerrit.wikimedia.org/r/p/mediawiki/extensions/"$$1".git && cd "$$1" && 
git checkout "$$2" && git submodule init && git submodule update && rm -r .* && 
cd ../..") }' < externals
+   awk '{ system("cd release && git clone https://"$$2"/"$$1".git && cd 
"$$1" && git checkout "$$3" && git submodule init && git submodule update && rm 
-r .* && cd ../..") }' < externals
sed -i -r -e "s/'version'\s*=>\s*'(.*)'/'version' => '\1$(ver)'/" 
release/SemanticBundle/SemanticBundle.php
+   mkdir release/SemanticBundle/data-values
+   mv release/Interfaces release/SemanticBundle/data-values/interfaces
+   mv release/DataValues release/SemanticBundle/data-values/data-values
+   mv release/Common release/SemanticBundle/data-values/common
+   mv release/Validators release/SemanticBundle/data-values/validators
+   mv release/Time release/SemanticBundle/data-values/time
+   mv release/Geo release/SemanticBundle/data-values/geo
+   mkdir release/SemanticBundle/param-processor
+   mv release/ParamProcessor 
release/SemanticBundle/param-processor/param-processor
tar -C release -c ./ | gzip >SemanticBundle-${ver}.tgz
7z a SemanticBundle-${ver}.7z release
(cd release; zip -r ../SemanticBundle-${ver}.zip .)
@@ -12,8 +21,17 @@
 dev:
rm -rf dev 
mkdir dev
-   awk '{ system("cd dev && git clone 
https://gerrit.wikimedia.org/r/p/mediawiki/extensions/"$$1".git && cd "$$1" && 
git submodule init && git submodule update && rm -r .* && cd ../..") }' < 
externals
+   awk '{ system("cd dev && git clone https://"$$2"/"$$1".git && cd "$$1" 
&& git submodule init && git submodule update && rm -r .* && cd ../..") }' < 
externals
sed -i -r -e "s/'version'\s*=>\s*'(.*)'/'version' => '\1$(ver)-dev'/" 
dev/SemanticBundle/SemanticBundle.php
+   mkdir release/SemanticBundle/data-values
+   mv release/Interfaces release/SemanticBundle/data-values/interfaces
+   mv release/DataValues release/SemanticBundle/data-values/data-values
+   mv release/Common release/SemanticBundle/data-values/common
+   mv release/Validators release/SemanticBundle/data-values/validators
+   mv release/Time release/SemanticBundle/data-values/time
+   mv release/Geo release/SemanticBundle/data-values/geo
+   mkdir release/SemanticBundle/param-processor
+   mv release/ParamProcessor 
release/SemanticBundle/param-processor/param-processor
tar -C dev -c ./ | gzip >SemanticBundle-dev-$(ver).tgz
7z a SemanticBundle-dev-${ver}.7z dev
(cd dev; zip -r ../SemanticBundle-dev-$(ver).zip .)
diff --git a/SemanticBundleSettings.sample.php 
b/SemanticBundleSettings.sample.php
index d90d25d..834ae17 100644
--- a/SemanticBundleSettings.sample.php
+++ b/SemanticBundleSettings.sample.php
@@ -19,7 +19,18 @@
 
 # Semantic MediaWiki basic installation.
 # More info: http://semantic-mediawiki.org/wiki/Help:Installation
+
+# First, all of SMW's current dependencies.
+# This includes adding autoload calls for the classes that would normally
+# be autoloaded by Composer.
+$classMap = require_once( 
"$IP/extensions/SemanticBundle/SB_AutoloadClassmap.php" );
+foreach ( $classMap as $className => $fileName ) {
+$wgAutoloadClasses[$className] = $fileName;
+}
+include_once( 
"$IP/extensions/SemanticBundle/param-processor/param-processor/src/ParamProcessor/Processor.php"
 );
+include_once( 
"$IP/extensions/SemanticBundle/param-processor/param-processor/DefaultConfig.php"
 );
 include_once( "$IP/extensions/Validator/Validator.php" );
+
 include_once( "$IP/extensions/SemanticMediaWiki/SemanticMediaWiki.php" );
 enableSemantics( parse_url( $wgServer, PHP_URL_HOST ) );
 
@@ -44,14 +55,13 @@
 #include_once( "$IP/extensions/SemanticDrilldown/SemanticDrilldown.php" );
 
 # Maps and Semantic Maps 
-# If you're planning to use Google Maps or Yahoo! Maps, you should also set
-# $egGoogleMapsKey or $egYahooMapsKey (AFTER the include_once statements).
-# More info:
-# http://mapping.referata.com/wiki/Maps#Installation
-# http://mapping.referata.com/wiki/Semantic_Maps#Installation
 #include_once( "$IP/extensions/Maps/Maps.php" );
 #include_

[MediaWiki-commits] [Gerrit] Massive update for SMW 1.9, extensions moved to GitHub, and ... - change (mediawiki...SemanticBundle)

2014-04-22 Thread Yaron Koren (Code Review)
Yaron Koren has uploaded a new change for review.

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

Change subject: Massive update for SMW 1.9, extensions moved to GitHub, and 
Composer usage
..

Massive update for SMW 1.9, extensions moved to GitHub, and Composer usage

Also added Semantic Extra Special Properties extension

Change-Id: I7b614cafe356d3355a4f612f44d70833f66468a3
---
M Makefile
M SemanticBundleSettings.sample.php
M externals
3 files changed, 66 insertions(+), 30 deletions(-)


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

diff --git a/Makefile b/Makefile
index a927202..fb547c6 100644
--- a/Makefile
+++ b/Makefile
@@ -3,8 +3,17 @@
 all:
rm -rf release
mkdir release
-   awk '{ system("cd release && git clone 
https://gerrit.wikimedia.org/r/p/mediawiki/extensions/"$$1".git && cd "$$1" && 
git checkout "$$2" && git submodule init && git submodule update && rm -r .* && 
cd ../..") }' < externals
+   awk '{ system("cd release && git clone https://"$$2"/"$$1".git && cd 
"$$1" && git checkout "$$3" && git submodule init && git submodule update && rm 
-r .* && cd ../..") }' < externals
sed -i -r -e "s/'version'\s*=>\s*'(.*)'/'version' => '\1$(ver)'/" 
release/SemanticBundle/SemanticBundle.php
+   mkdir release/SemanticBundle/data-values
+   mv release/Interfaces release/SemanticBundle/data-values/interfaces
+   mv release/DataValues release/SemanticBundle/data-values/data-values
+   mv release/Common release/SemanticBundle/data-values/common
+   mv release/Validators release/SemanticBundle/data-values/validators
+   mv release/Time release/SemanticBundle/data-values/time
+   mv release/Geo release/SemanticBundle/data-values/geo
+   mkdir release/SemanticBundle/param-processor
+   mv release/ParamProcessor 
release/SemanticBundle/param-processor/param-processor
tar -C release -c ./ | gzip >SemanticBundle-${ver}.tgz
7z a SemanticBundle-${ver}.7z release
(cd release; zip -r ../SemanticBundle-${ver}.zip .)
@@ -12,8 +21,17 @@
 dev:
rm -rf dev 
mkdir dev
-   awk '{ system("cd dev && git clone 
https://gerrit.wikimedia.org/r/p/mediawiki/extensions/"$$1".git && cd "$$1" && 
git submodule init && git submodule update && rm -r .* && cd ../..") }' < 
externals
+   awk '{ system("cd dev && git clone https://"$$2"/"$$1".git && cd "$$1" 
&& git submodule init && git submodule update && rm -r .* && cd ../..") }' < 
externals
sed -i -r -e "s/'version'\s*=>\s*'(.*)'/'version' => '\1$(ver)-dev'/" 
dev/SemanticBundle/SemanticBundle.php
+   mkdir release/SemanticBundle/data-values
+   mv release/Interfaces release/SemanticBundle/data-values/interfaces
+   mv release/DataValues release/SemanticBundle/data-values/data-values
+   mv release/Common release/SemanticBundle/data-values/common
+   mv release/Validators release/SemanticBundle/data-values/validators
+   mv release/Time release/SemanticBundle/data-values/time
+   mv release/Geo release/SemanticBundle/data-values/geo
+   mkdir release/SemanticBundle/param-processor
+   mv release/ParamProcessor 
release/SemanticBundle/param-processor/param-processor
tar -C dev -c ./ | gzip >SemanticBundle-dev-$(ver).tgz
7z a SemanticBundle-dev-${ver}.7z dev
(cd dev; zip -r ../SemanticBundle-dev-$(ver).zip .)
diff --git a/SemanticBundleSettings.sample.php 
b/SemanticBundleSettings.sample.php
index d90d25d..834ae17 100644
--- a/SemanticBundleSettings.sample.php
+++ b/SemanticBundleSettings.sample.php
@@ -19,7 +19,18 @@
 
 # Semantic MediaWiki basic installation.
 # More info: http://semantic-mediawiki.org/wiki/Help:Installation
+
+# First, all of SMW's current dependencies.
+# This includes adding autoload calls for the classes that would normally
+# be autoloaded by Composer.
+$classMap = require_once( 
"$IP/extensions/SemanticBundle/SB_AutoloadClassmap.php" );
+foreach ( $classMap as $className => $fileName ) {
+$wgAutoloadClasses[$className] = $fileName;
+}
+include_once( 
"$IP/extensions/SemanticBundle/param-processor/param-processor/src/ParamProcessor/Processor.php"
 );
+include_once( 
"$IP/extensions/SemanticBundle/param-processor/param-processor/DefaultConfig.php"
 );
 include_once( "$IP/extensions/Validator/Validator.php" );
+
 include_once( "$IP/extensions/SemanticMediaWiki/SemanticMediaWiki.php" );
 enableSemantics( parse_url( $wgServer, PHP_URL_HOST ) );
 
@@ -44,14 +55,13 @@
 #include_once( "$IP/extensions/SemanticDrilldown/SemanticDrilldown.php" );
 
 # Maps and Semantic Maps 
-# If you're planning to use Google Maps or Yahoo! Maps, you should also set
-# $egGoogleMapsKey or $egYahooMapsKey (AFTER the include_once statements).
-# More info:
-# http://mapping.referata.com/wiki/Maps#Installation
-# http://mapping.referata.com/wiki/Semantic_Maps#Installation
 #includ

[MediaWiki-commits] [Gerrit] Provide appropriate padding for login benefits message - change (apps...wikipedia)

2014-04-22 Thread Dbrant (Code Review)
Dbrant has submitted this change and it was merged.

Change subject: Provide appropriate padding for login benefits message
..


Provide appropriate padding for login benefits message

Change-Id: Ifb4c073fea4e5f4a6fb721bcf2d0c7cfd34272db
---
M wikipedia/res/layout/fragment_navdrawer.xml
1 file changed, 2 insertions(+), 0 deletions(-)

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



diff --git a/wikipedia/res/layout/fragment_navdrawer.xml 
b/wikipedia/res/layout/fragment_navdrawer.xml
index 0f38cfd..bcdbc1e 100644
--- a/wikipedia/res/layout/fragment_navdrawer.xml
+++ b/wikipedia/res/layout/fragment_navdrawer.xml
@@ -17,6 +17,8 @@
   android:background="@drawable/item_background_holo_light"
   android:paddingTop="8dp"
   android:paddingBottom="8dp"
+  android:paddingEnd="8dp"
+  android:paddingRight="8dp"
 >
 https://gerrit.wikimedia.org/r/129053
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ifb4c073fea4e5f4a6fb721bcf2d0c7cfd34272db
Gerrit-PatchSet: 2
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Yuvipanda 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Make convert-icons.py script Python 3.0 compatible - change (apps...wikipedia)

2014-04-22 Thread Dbrant (Code Review)
Dbrant has submitted this change and it was merged.

Change subject: Make convert-icons.py script Python 3.0 compatible
..


Make convert-icons.py script Python 3.0 compatible

Change-Id: If2b1a15d7dbba4c1b9d08667d1f7cb228ec86ac9
---
M scripts/convert-icons.py
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Dbrant: Looks good to me, approved



diff --git a/scripts/convert-icons.py b/scripts/convert-icons.py
index 4eeffc7..a354260 100644
--- a/scripts/convert-icons.py
+++ b/scripts/convert-icons.py
@@ -37,7 +37,7 @@
 for svg in self.svgs:
 for density in DENSITIES.keys():
 self._do_flop(density, self._do_export(density, svg))
-print u"\u2713 %s" % os.path.basename(svg)
+print(u"\u2713 %s" % os.path.basename(svg))
 
 
 if __name__ == "__main__":

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

Gerrit-MessageType: merged
Gerrit-Change-Id: If2b1a15d7dbba4c1b9d08667d1f7cb228ec86ac9
Gerrit-PatchSet: 2
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Yuvipanda 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Bigger, badder, animated progress bar - change (mediawiki...MultimediaViewer)

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

Change subject: Bigger, badder, animated progress bar
..


Bigger, badder, animated progress bar

Nobody will be able to say it's not prominent enough anymore.

Change-Id: I060dcf2b8f244f7d59f4ed1ef6dfd85a08f3ef88
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/464
---
M resources/mmv/ui/mmv.ui.progressBar.less
1 file changed, 33 insertions(+), 3 deletions(-)

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



diff --git a/resources/mmv/ui/mmv.ui.progressBar.less 
b/resources/mmv/ui/mmv.ui.progressBar.less
index ef9b063..147c19d 100644
--- a/resources/mmv/ui/mmv.ui.progressBar.less
+++ b/resources/mmv/ui/mmv.ui.progressBar.less
@@ -1,9 +1,12 @@
-@progress-height: 3px;
+@import "mediawiki.mixins.animation";
+
+@progress-height: 14px;
 
 .mw-mmv-progress {
width: 100%;
height: @progress-height;
-   background-color: rgb( 204, 204, 204 );
+   background-color: #cc;
+   background-color: rgba( 221, 221, 221, 0.5 );
margin-top: -@progress-height;
 }
 
@@ -14,5 +17,32 @@
 .mw-mmv-progress-percent {
width: 0;
height: @progress-height;
-   background-color: rgb( 0, 113, 188 );
+   background: linear-gradient(-45deg, transparent 33%, rgba(0,0,0,0.1) 
33%,  rgba(0,0,0,0.1) 66%, transparent 66%), #347bff;
+   background-size: 35px 20px, 100% 100%, 100% 100%;
+   .animation( mw-mmv-progress-percent-animation 1.5s linear infinite );
 }
+
+.mw-mmv-progress-percent-animation() {
+   0% {
+   background-position: 0px 0px;
+   }
+   100% {
+   background-position: -70px 0px;
+   }
+}
+
+@-webkit-keyframes mw-mmv-progress-percent-animation {
+   .mw-mmv-progress-percent-animation;
+}
+
+@-moz-keyframes mw-mmv-progress-percent-animation {
+   .mw-mmv-progress-percent-animation;
+}
+
+@-o-keyframes mw-mmv-progress-percent-animation {
+   .mw-mmv-progress-percent-animation;
+}
+
+@keyframes mw-mmv-progress-percent-animation {
+   .mw-mmv-progress-percent-animation;
+}
\ No newline at end of file

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I060dcf2b8f244f7d59f4ed1ef6dfd85a08f3ef88
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: master
Gerrit-Owner: Gilles 
Gerrit-Reviewer: Gergő Tisza 
Gerrit-Reviewer: Gilles 
Gerrit-Reviewer: Pginer 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Bump version for new alpha release - change (apps...wikipedia)

2014-04-22 Thread Yuvipanda (Code Review)
Yuvipanda has uploaded a new change for review.

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

Change subject: Bump version for new alpha release
..

Bump version for new alpha release

Change-Id: I06e787fcc230b20e26969f32010bc0e6ab81cc9b
---
M wikipedia/AndroidManifest.xml
1 file changed, 3 insertions(+), 3 deletions(-)


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

diff --git a/wikipedia/AndroidManifest.xml b/wikipedia/AndroidManifest.xml
index 76a8c08..e1a2211 100644
--- a/wikipedia/AndroidManifest.xml
+++ b/wikipedia/AndroidManifest.xml
@@ -1,8 +1,8 @@
 
 http://schemas.android.com/apk/res/android";
 package="org.wikipedia"
-android:versionCode="37"
-android:versionName="2.0-alpha-2014-04-15" >
+android:versionCode="38"
+android:versionName="2.0-alpha-2014-04-22" >
 
 
 
-
\ No newline at end of file
+

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

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

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


[MediaWiki-commits] [Gerrit] Added --multiversiononly option to image SHA1 population script - change (mediawiki/core)

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

Change subject: Added --multiversiononly option to image SHA1 population script
..


Added --multiversiononly option to image SHA1 population script

* A portion of files have bad SHA1 values due to re-upload bugs.
  This adds an option to just force updates for files with re-uploads.

Change-Id: I24bd9a8f19bafc3e794cf32c78ce7f720f302627
(cherry picked from commit d35063273c264d9991e0cc47decf6976ca5f2844)
---
M maintenance/populateImageSha1.php
1 file changed, 10 insertions(+), 2 deletions(-)

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



diff --git a/maintenance/populateImageSha1.php 
b/maintenance/populateImageSha1.php
index 126d22d..4964bf1 100644
--- a/maintenance/populateImageSha1.php
+++ b/maintenance/populateImageSha1.php
@@ -33,6 +33,7 @@
parent::__construct();
$this->mDescription = "Populate the img_sha1 field";
$this->addOption( 'force', "Recalculate sha1 for rows that 
already have a value" );
+   $this->addOption( 'multiversiononly', "Calculate only for files 
with several versions" );
$this->addOption( 'method', "Use 'pipe' to pipe to mysql 
command line,\n" .
"\t\tdefault uses Database class", false, true );
$this->addOption( 'file', 'Fix for a specific file, without 
File: namespace prefixed', false, true );
@@ -47,7 +48,7 @@
}
 
public function execute() {
-   if ( $this->getOption( 'file' ) ) {
+   if ( $this->getOption( 'file' ) || $this->hasOption( 
'multiversiononly' ) ) {
$this->doDBUpdates(); // skip update log checks/saves
} else {
parent::execute();
@@ -82,7 +83,12 @@
$conds = array( 'img_sha1' => '' );
$this->output( "Populating img_sha1 field\n" );
}
-   $res = $dbw->select( 'image', array( 'img_name' ), 
$conds, __METHOD__ );
+   if ( $this->hasOption( 'multiversiononly' ) ) {
+   $res = $dbw->select( 'oldimage',
+   array( 'img_name' => 
'DISTINCT(oi_name)' ), $conds, __METHOD__ );
+   } else {
+   $res = $dbw->select( 'image', array( 'img_name' 
), $conds, __METHOD__ );
+   }
}
 
$imageTable = $dbw->tableName( 'image' );
@@ -109,10 +115,12 @@
"Done %d of %d, %5.3f%%  \r", $i, 
$numRows, $i / $numRows * 100 ) );
wfWaitForSlaves();
}
+
$file = wfLocalFile( $row->img_name );
if ( !$file ) {
continue;
}
+
// Upgrade the current file version...
$sha1 = $file->getRepo()->getFileSha1( $file->getPath() 
);
if ( strval( $sha1 ) !== '' ) { // file on disk and 
hashed properly

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I24bd9a8f19bafc3e794cf32c78ce7f720f302627
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.24wmf1
Gerrit-Owner: Aaron Schulz 
Gerrit-Reviewer: Aaron Schulz 
Gerrit-Reviewer: Parent5446 
Gerrit-Reviewer: jenkins-bot <>

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


[MediaWiki-commits] [Gerrit] Add new app icon - change (apps...wikipedia)

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

Change subject: Add new app icon
..


Add new app icon

Bug: 61259
Change-Id: Ie438b5f623078dfa1cff2bf350975ffa769c35dc
---
A icon-svgs/48/launcher.svg
M wikipedia/AndroidManifest.xml
D wikipedia/res/drawable-hdpi/ic_launcher.png
A wikipedia/res/drawable-hdpi/launcher.png
A wikipedia/res/drawable-ldpi/launcher.png
A wikipedia/res/drawable-ldrtl-hdpi/launcher.png
A wikipedia/res/drawable-ldrtl-ldpi/launcher.png
A wikipedia/res/drawable-ldrtl-mdpi/launcher.png
A wikipedia/res/drawable-ldrtl-xhdpi/launcher.png
A wikipedia/res/drawable-ldrtl-xxhdpi/launcher.png
D wikipedia/res/drawable-mdpi/ic_launcher.png
A wikipedia/res/drawable-mdpi/launcher.png
D wikipedia/res/drawable-xhdpi/ic_launcher.png
A wikipedia/res/drawable-xhdpi/launcher.png
D wikipedia/res/drawable-xxhdpi/ic_launcher.png
A wikipedia/res/drawable-xxhdpi/launcher.png
16 files changed, 30 insertions(+), 1 deletion(-)

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



diff --git a/icon-svgs/48/launcher.svg b/icon-svgs/48/launcher.svg
new file mode 100644
index 000..4e4966c
--- /dev/null
+++ b/icon-svgs/48/launcher.svg
@@ -0,0 +1,29 @@
+
+
+http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd";>
+http://www.w3.org/2000/svg"; 
xmlns:xlink="http://www.w3.org/1999/xlink"; x="0px" y="0px"
+viewBox="0 0 1024 1024" style="enable-background:new 0 0 1024 1024;" 
xml:space="preserve">
+
+   
+   
+   
+
+
+
+   
+   
+   
+
+
diff --git a/wikipedia/AndroidManifest.xml b/wikipedia/AndroidManifest.xml
index ec03e91..76a8c08 100644
--- a/wikipedia/AndroidManifest.xml
+++ b/wikipedia/AndroidManifest.xml
@@ -13,7 +13,7 @@
 
diff --git a/wikipedia/res/drawable-hdpi/ic_launcher.png 
b/wikipedia/res/drawable-hdpi/ic_launcher.png
deleted file mode 100644
index 288b665..000
--- a/wikipedia/res/drawable-hdpi/ic_launcher.png
+++ /dev/null
Binary files differ
diff --git a/wikipedia/res/drawable-hdpi/launcher.png 
b/wikipedia/res/drawable-hdpi/launcher.png
new file mode 100644
index 000..23a2ead
--- /dev/null
+++ b/wikipedia/res/drawable-hdpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-ldpi/launcher.png 
b/wikipedia/res/drawable-ldpi/launcher.png
new file mode 100644
index 000..0c92dc9
--- /dev/null
+++ b/wikipedia/res/drawable-ldpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-ldrtl-hdpi/launcher.png 
b/wikipedia/res/drawable-ldrtl-hdpi/launcher.png
new file mode 100644
index 000..482c4e4
--- /dev/null
+++ b/wikipedia/res/drawable-ldrtl-hdpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-ldrtl-ldpi/launcher.png 
b/wikipedia/res/drawable-ldrtl-ldpi/launcher.png
new file mode 100644
index 000..6d57749
--- /dev/null
+++ b/wikipedia/res/drawable-ldrtl-ldpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-ldrtl-mdpi/launcher.png 
b/wikipedia/res/drawable-ldrtl-mdpi/launcher.png
new file mode 100644
index 000..0b5506b
--- /dev/null
+++ b/wikipedia/res/drawable-ldrtl-mdpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-ldrtl-xhdpi/launcher.png 
b/wikipedia/res/drawable-ldrtl-xhdpi/launcher.png
new file mode 100644
index 000..4eeba91
--- /dev/null
+++ b/wikipedia/res/drawable-ldrtl-xhdpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-ldrtl-xxhdpi/launcher.png 
b/wikipedia/res/drawable-ldrtl-xxhdpi/launcher.png
new file mode 100644
index 000..b20b80e
--- /dev/null
+++ b/wikipedia/res/drawable-ldrtl-xxhdpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-mdpi/ic_launcher.png 
b/wikipedia/res/drawable-mdpi/ic_launcher.png
deleted file mode 100644
index 6ae570b..000
--- a/wikipedia/res/drawable-mdpi/ic_launcher.png
+++ /dev/null
Binary files differ
diff --git a/wikipedia/res/drawable-mdpi/launcher.png 
b/wikipedia/res/drawable-mdpi/launcher.png
new file mode 100644
index 000..dc302c5
--- /dev/null
+++ b/wikipedia/res/drawable-mdpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-xhdpi/ic_launcher.png 
b/wikipedia/res/drawable-xhdpi/ic_launcher.png
deleted file mode 100644
index d4fb7cd..000
--- a/wikipedia/res/drawable-xhdpi/ic_launcher.png
+++ /dev/null
Binary files differ
diff --git a/wikipedia/res/drawable-xhdpi/launcher.png 
b/wikipedia/res/drawable-xhdpi/launcher.png
new file mode 100644
index 000..111c4f4
--- /dev/null
+++ b/wikipedia/res/drawable-xhdpi/launcher.png
Binary files differ
diff --git a/wikipedia/res/drawable-xxhdpi/ic_launcher.png 
b/wikipedia/res/drawable-xxhdpi/ic_launcher.png
deleted file mode 100644
index 85a6081..000
--- a/wikipedia/res/drawable-xxhdpi/ic_launcher.png
+++ /dev/null
Binary files differ
diff --git a/wikipedia/res/drawable-xxhdpi/launcher.png 
b/wikipedia/res/drawable-xxhdpi/launcher.png
new file mode 100644
index 000..d7009e9
-

[MediaWiki-commits] [Gerrit] Provide appropriate padding for login benefits message - change (apps...wikipedia)

2014-04-22 Thread Yuvipanda (Code Review)
Yuvipanda has uploaded a new change for review.

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

Change subject: Provide appropriate padding for login benefits message
..

Provide appropriate padding for login benefits message

Change-Id: Ifb4c073fea4e5f4a6fb721bcf2d0c7cfd34272db
---
M wikipedia/res/layout/fragment_navdrawer.xml
1 file changed, 2 insertions(+), 0 deletions(-)


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

diff --git a/wikipedia/res/layout/fragment_navdrawer.xml 
b/wikipedia/res/layout/fragment_navdrawer.xml
index 0f38cfd..bcdbc1e 100644
--- a/wikipedia/res/layout/fragment_navdrawer.xml
+++ b/wikipedia/res/layout/fragment_navdrawer.xml
@@ -17,6 +17,8 @@
   android:background="@drawable/item_background_holo_light"
   android:paddingTop="8dp"
   android:paddingBottom="8dp"
+  android:paddingEnd="8dp"
+  android:paddingRight="8dp"
 >
 https://gerrit.wikimedia.org/r/129053
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

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

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


[MediaWiki-commits] [Gerrit] Make convert-icons.py script Python 3.0 compatible - change (apps...wikipedia)

2014-04-22 Thread Yuvipanda (Code Review)
Yuvipanda has uploaded a new change for review.

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

Change subject: Make convert-icons.py script Python 3.0 compatible
..

Make convert-icons.py script Python 3.0 compatible

Change-Id: If2b1a15d7dbba4c1b9d08667d1f7cb228ec86ac9
---
M scripts/convert-icons.py
1 file changed, 1 insertion(+), 1 deletion(-)


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

diff --git a/scripts/convert-icons.py b/scripts/convert-icons.py
index 4eeffc7..a354260 100644
--- a/scripts/convert-icons.py
+++ b/scripts/convert-icons.py
@@ -37,7 +37,7 @@
 for svg in self.svgs:
 for density in DENSITIES.keys():
 self._do_flop(density, self._do_export(density, svg))
-print u"\u2713 %s" % os.path.basename(svg)
+print(u"\u2713 %s" % os.path.basename(svg))
 
 
 if __name__ == "__main__":

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

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

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


[MediaWiki-commits] [Gerrit] Include Scribunto on travis - change (mediawiki...Wikibase)

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

Change subject: Include Scribunto on travis
..


Include Scribunto on travis

Change-Id: Ie4a1df5c6af5cf43ccffc73b3407e434dbb1680f
---
M build/travis/mw-apply-wb-settings.sh
1 file changed, 1 insertion(+), 0 deletions(-)

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



diff --git a/build/travis/mw-apply-wb-settings.sh 
b/build/travis/mw-apply-wb-settings.sh
index 33727dd..1274a4f 100644
--- a/build/travis/mw-apply-wb-settings.sh
+++ b/build/travis/mw-apply-wb-settings.sh
@@ -27,6 +27,7 @@
   echo '$wgLanguageCode = "'$LANG'";' >> LocalSettings.php
   echo '$wgDebugLogFile = "mw-debug.log";' >> LocalSettings.php
   echo "define( 'WB_EXPERIMENTAL_FEATURES', 1 );" >> LocalSettings.php
+  echo 'require_once __DIR__ . "/extensions/Scribunto/Scribunto.php";' >> 
LocalSettings.php
 }
 
 apply_common_settings

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie4a1df5c6af5cf43ccffc73b3407e434dbb1680f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Hoo man 
Gerrit-Reviewer: Aude 
Gerrit-Reviewer: jenkins-bot <>

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


  1   2   3   4   >