[MediaWiki-commits] [Gerrit] Yuri's vanity + missing qqq for a rights msg - change (mediawiki...Gather)
jenkins-bot has submitted this change and it was merged. Change subject: Yuri's vanity + missing qqq for a rights msg .. Yuri's vanity + missing qqq for a rights msg * Added myself * right-gather-hidelist was not listed in QQQ i18n Change-Id: Ie4245f0d5775720c50c60db74e16db2108c7d4f3 --- M Gather.php M i18n/en.json M i18n/qqq.json 3 files changed, 7 insertions(+), 3 deletions(-) Approvals: Jdlrobson: Looks good to me, approved jenkins-bot: Verified diff --git a/Gather.php b/Gather.php index 29c3143..98397ea 100644 --- a/Gather.php +++ b/Gather.php @@ -7,6 +7,7 @@ * @author Jon Robson * @author Joaquin Hernandez * @author Rob Moen + * @author Yuri Astrakhan * @licence GNU General Public Licence 2.0 or later */ @@ -20,7 +21,7 @@ $wgExtensionCredits['other'][] = array( 'path' = __FILE__, 'name' = 'Gather', - 'author' = array( 'Jon Robson', 'Joaquin Hernandez', 'Rob Moen' ), + 'author' = array( 'Jon Robson', 'Joaquin Hernandez', 'Rob Moen', 'Yuri Astrakhan' ), 'descriptionmsg' = 'gather-desc', 'url' = 'https://www.mediawiki.org/wiki/Gather', 'license-name' = 'GPL-2.0+', diff --git a/i18n/en.json b/i18n/en.json index 8e4e831..1bcb2bf 100644 --- a/i18n/en.json +++ b/i18n/en.json @@ -3,7 +3,8 @@ authors: [ Joaquin Hernandez, Jon Robson, - Rob Moen + Rob Moen, + Yuri Astrakhan ] }, gather-lists-collection-owner: Owner, diff --git a/i18n/qqq.json b/i18n/qqq.json index 1747ac3..c2965ed 100644 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -7,7 +7,8 @@ Rob Moen, Liuxinyu970226, Robby, - Amire80 + Amire80, + Yuri Astrakhan ] }, gather-lists-collection-owner: Label for owner of collection on list of all collections\n{{Identical|Owner}}, @@ -63,6 +64,7 @@ gather-empty-footer: Footnote shown on an empty rendered collection on [[Special:Gather]]., gather-edit-button: Label for a button that enables editing a collection.\n{{Identical|Edit}}, gather-delete-button: Label for a button that enables deleting a collection.\n{{Identical|Delete}}, + right-gather-hidelist: Description of right to hide or restore public lists.\n\n{{Doc-right|gather-hidelist}}, apihelp-gather-description: {{doc-apihelp-description|gather}}, apihelp-gather-param-gather: {{doc-apihelp-param|gather|gather}}, apihelp-gather-param-owner: {{doc-apihelp-param|gather|owner}}, -- To view, visit https://gerrit.wikimedia.org/r/199558 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ie4245f0d5775720c50c60db74e16db2108c7d4f3 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Gather Gerrit-Branch: master Gerrit-Owner: Yurik yu...@wikimedia.org Gerrit-Reviewer: Jdlrobson jrob...@wikimedia.org Gerrit-Reviewer: Jhernandez jhernan...@wikimedia.org Gerrit-Reviewer: Robmoen rm...@wikimedia.org Gerrit-Reviewer: Siebrand siebr...@kitano.nl Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Disable TCP slow-start restart on caches - change (operations/puppet)
BBlack has submitted this change and it was merged. Change subject: Disable TCP slow-start restart on caches .. Disable TCP slow-start restart on caches TCP SSR resets the congestion window of connections that have gone idle, which means it has a tendency to reset the congestion window of HTTP keepalive and SPDY connections, which are characterized by short bursts of activity separated by long idle times. References: * https://www.belshe.com/2011/12/03/spdy-configuration-tcp_slow_start_after_idle/ * http://chimera.labs.oreilly.com/books/123000545/ch02.html#SLOW_START Change-Id: I368d74cae73e010a503cd3144663651e07229cf2 --- M manifests/role/cache.pp 1 file changed, 9 insertions(+), 0 deletions(-) Approvals: BBlack: Looks good to me, approved jenkins-bot: Verified diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp index 6633c1d..b7a1f91 100644 --- a/manifests/role/cache.pp +++ b/manifests/role/cache.pp @@ -812,6 +812,15 @@ 'vm.dirty_expire_centisecs' = 500, # default 3000 }, } + +# Disable TCP SSR (slow-start restart). SSR resets the congestion +# window of connections that have gone idle, which means it has a +# tendency to reset the congestion window of HTTP keepalive and SPDY +# connections, which are characterized by short bursts of activity +# separated by long idle times. +sysctl::parameters { 'disable_ssr': +values = { 'net.ipv4.tcp_slow_start_after_idle' = 0 }, +} } # mma: mmap addrseses for fixed persistent storage on x86_64 Linux: -- To view, visit https://gerrit.wikimedia.org/r/199556 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I368d74cae73e010a503cd3144663651e07229cf2 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Ori.livneh o...@wikimedia.org Gerrit-Reviewer: BBlack bbl...@wikimedia.org Gerrit-Reviewer: Mark Bergsma m...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Preserve array keys in array_slice - change (mediawiki...UserOptionStats)
Nikerabbit has uploaded a new change for review. https://gerrit.wikimedia.org/r/199583 Change subject: Preserve array keys in array_slice .. Preserve array keys in array_slice Enabled could show as disabled when keys were renumbered. Change-Id: I56dd242c10dc2df11e1c2d2462fc539914ce7e47 --- M SpecialUserOptionStats.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/UserOptionStats refs/changes/83/199583/1 diff --git a/SpecialUserOptionStats.php b/SpecialUserOptionStats.php index c6fe292..ad592ff 100644 --- a/SpecialUserOptionStats.php +++ b/SpecialUserOptionStats.php @@ -80,7 +80,7 @@ // So use the last free color for other which includes the rest $max = 7; $rest = array_slice( $data, $max ); - $data = array_slice( $data, 0, $max ); + $data = array_slice( $data, 0, $max, true ); foreach ( $data as $k = $d ) { $labels[] = $k ($d); $realdata[] = array( $k, $d ); -- To view, visit https://gerrit.wikimedia.org/r/199583 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I56dd242c10dc2df11e1c2d2462fc539914ce7e47 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/UserOptionStats Gerrit-Branch: master Gerrit-Owner: Nikerabbit niklas.laxst...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Revert Use EntityIdFormatter in MessageParameterFormatter - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/199587 Change subject: Revert Use EntityIdFormatter in MessageParameterFormatter .. Revert Use EntityIdFormatter in MessageParameterFormatter will be just for the branch for now, since it causes T93804. we can investigate more proper fix for master, as using EntityIdFormatter here is a good idea. This reverts commit fb60de9acf5ffa5347fc0f57656073154e170c97. Bug: T93804 Change-Id: I330d4761a47bb244f4fde4d7b549e24aa4410c79 --- M lib/includes/formatters/EntityIdLinkFormatter.php M lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php M repo/includes/Localizer/MessageParameterFormatter.php M repo/includes/WikibaseRepo.php M repo/tests/phpunit/includes/Localizer/MessageParameterFormatterTest.php 5 files changed, 32 insertions(+), 22 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/87/199587/1 diff --git a/lib/includes/formatters/EntityIdLinkFormatter.php b/lib/includes/formatters/EntityIdLinkFormatter.php index 9a520aa..60567f4 100644 --- a/lib/includes/formatters/EntityIdLinkFormatter.php +++ b/lib/includes/formatters/EntityIdLinkFormatter.php @@ -24,7 +24,7 @@ public function formatEntityId( EntityId $entityId ) { $title = parent::formatEntityId( $entityId ); - return [[$title| . wfEscapeWikiText( $entityId-getSerialization() ) . ]]; + return [[$title]]; } } diff --git a/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php b/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php index d7084b9..035a916 100644 --- a/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php +++ b/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php @@ -5,6 +5,7 @@ use LogicException; use PHPUnit_Framework_TestCase; use Title; +use ValueFormatters\FormatterOptions; use Wikibase\DataModel\Entity\EntityId; use Wikibase\DataModel\Entity\Item; use Wikibase\DataModel\Entity\ItemId; @@ -16,6 +17,8 @@ * @covers Wikibase\Lib\EntityIdLinkFormatter * * @group Wikibase + * @group ValueFormatters + * @group DataValueExtensions * @group WikibaseLib * @group EntityIdFormatterTest * @@ -28,11 +31,11 @@ return array( 'ItemId' = array( new ItemId( 'Q23' ), - '[[ITEM-TEST--Q23|Q23]]' + '[[ITEM-TEST--Q23]]' ), 'PropertyId' = array( new PropertyId( 'P23' ), - '[[PROPERTY-TEST--P23|P23]]' + '[[PROPERTY-TEST--P23]]' ), ); } @@ -58,7 +61,8 @@ } } - private function newEntityIdLinkFormatter() { + protected function newEntityIdLinkFormatter() { + $options = new FormatterOptions(); $titleLookup = $this-getMock( 'Wikibase\Lib\Store\EntityTitleLookup' ); $titleLookup-expects( $this-any() )-method( 'getTitleForId' ) -will( $this-returnCallback( array( $this, 'getTitleForId' ) ) ); diff --git a/repo/includes/Localizer/MessageParameterFormatter.php b/repo/includes/Localizer/MessageParameterFormatter.php index 6cd3c75..7d54deb 100644 --- a/repo/includes/Localizer/MessageParameterFormatter.php +++ b/repo/includes/Localizer/MessageParameterFormatter.php @@ -10,8 +10,8 @@ use ValueFormatters\ValueFormatter; use Wikibase\DataModel\Entity\EntityId; use Wikibase\DataModel\SiteLink; -use Wikibase\Lib\EntityIdFormatter; use Wikibase\Lib\MediaWikiNumberLocalizer; +use Wikibase\Lib\Store\EntityTitleLookup; /** * ValueFormatter for formatting objects that may be encountered in @@ -28,9 +28,9 @@ private $dataValueFormatter; /** -* @var EntityIdFormatter +* @var EntityTitleLookup */ - private $entityIdFormatter; + private $entityTitleLookup; /** * @var SiteStore @@ -49,18 +49,18 @@ /** * @param ValueFormatter $dataValueFormatter A formatter for turning DataValues into wikitext. -* @param EntityIdFormatter $entityIdFormatter An entity id formatter returning wikitext. +* @param EntityTitleLookup $entityTitleLookup * @param SiteStore $sites * @param Language $language */ public function __construct( ValueFormatter $dataValueFormatter, - EntityIdFormatter $entityIdFormatter, + EntityTitleLookup $entityTitleLookup, SiteStore $sites, Language $language ) { $this-dataValueFormatter = $dataValueFormatter; - $this-entityIdFormatter = $entityIdFormatter; +
[MediaWiki-commits] [Gerrit] Performance improvements for RdfWriter - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Performance improvements for RdfWriter .. Performance improvements for RdfWriter Change-Id: I20df20124a3db2404a3a99421373128332d9fd4b --- M repo/includes/rdf/N3Quoter.php M repo/includes/rdf/N3RdfWriterBase.php M repo/includes/rdf/RdfWriterBase.php 3 files changed, 75 insertions(+), 85 deletions(-) Approvals: Thiemo Mättig (WMDE): Looks good to me, approved jenkins-bot: Verified diff --git a/repo/includes/rdf/N3Quoter.php b/repo/includes/rdf/N3Quoter.php index f2084f7..407beb9 100644 --- a/repo/includes/rdf/N3Quoter.php +++ b/repo/includes/rdf/N3Quoter.php @@ -11,67 +11,31 @@ */ class N3Quoter { - private $badChars = array( - \, - \\, - \0, - \n, - \r, - \t, - ); - - private $badCharEscapes = array( - '\', - '', - '\0', - '\n', - '\r', - '\t', - ); - - private $badUriChars = array( - , - , - \, -, - \n, - \r, - \t, - ); - - private $badUriCharEscapes = array( - '%3C', - '%3E', - '%22', - '%20', - '%0D', - '%0A', - '%09', - ); - /** * @var UnicodeEscaper */ private $escaper = null; /** -* @param $escapeUnicode +* @param bool $escapeUnicode */ public function setEscapeUnicode( $escapeUnicode ) { $this-escaper = $escapeUnicode ? new UnicodeEscaper() : null; } - public function escapeIRI( $uri ) { - //FIXME: more robust escaping; - //FIXME: apply unicode escaping?! - $quoted = str_replace( $this-badUriChars, $this-badUriCharEscapes, $uri ); + public function escapeIRI( $iri ) { + $quoted = strtr( $iri, array( + ' ' = '%20', + '' = '%22', + '' = '%3C', + '' = '%3E', + ) ); return $quoted; } public function escapeLiteral( $s ) { - //FIXME: more robust escaping - $escaped = str_replace( $this-badChars, $this-badCharEscapes, $s ); + $escaped = addcslashes( $s, \r\n\t\0\\\ ); if ( $this-escaper !== null ) { $escaped = $this-escaper-escapeString( $escaped ); diff --git a/repo/includes/rdf/N3RdfWriterBase.php b/repo/includes/rdf/N3RdfWriterBase.php index 8eebea1..25059f7 100644 --- a/repo/includes/rdf/N3RdfWriterBase.php +++ b/repo/includes/rdf/N3RdfWriterBase.php @@ -16,10 +16,29 @@ */ protected $quoter; + /** +* @var bool +*/ + private $trustIRIs = true; + public function __construct( $role = parent::DOCUMENT_ROLE, BNodeLabeler $labeler = null, N3Quoter $quoter = null ) { parent::__construct( $role, $labeler ); $this-quoter = $quoter ?: new N3Quoter(); + } + + /** +* @return boolean +*/ + public function getTrustIRIs() { + return $this-trustIRIs; + } + + /** +* @param boolean $trustIRIs +*/ + public function setTrustIRIs( $trustIRIs ) { + $this-trustIRIs = $trustIRIs; } protected function writeRef( $base, $local = null ) { @@ -51,7 +70,10 @@ throw new InvalidArgumentException( '$iri must be an absolute iri: ' . $iri ); } - $iri = $this-quoter-escapeIRI( $iri ); + if ( !$this-trustIRIs ) { + $iri = $this-quoter-escapeIRI( $iri ); + } + $this-write( '', $iri, '' ); } diff --git a/repo/includes/rdf/RdfWriterBase.php b/repo/includes/rdf/RdfWriterBase.php index 0239d1d..a42e610 100644 --- a/repo/includes/rdf/RdfWriterBase.php +++ b/repo/includes/rdf/RdfWriterBase.php @@ -22,10 +22,17 @@ */ private $buffer = array(); + const STATE_START = 0; + const STATE_DOCUMENT = 5; + const STATE_SUBJECT = 10; + const STATE_PREDICATE = 11; + const STATE_OBJECT = 12; + const STATE_DRAIN = 100; + /** * @var string the current state */ - private $state = 'start'; + private $state = self::STATE_START; /** * Shorthands that can be used in place of IRIs, e.g. (a to mean rdf:type). @@ -161,10 +168,10 @@ final public function sub() { //FIXME: don't mess with the state, enqueue the writer to be placed in the buffer
[MediaWiki-commits] [Gerrit] update cassandra submodule - change (operations/puppet)
Filippo Giunchedi has uploaded a new change for review. https://gerrit.wikimedia.org/r/199585 Change subject: update cassandra submodule .. update cassandra submodule Change-Id: I15964f034a5c727827f5e3d6bbef2f5422b3c86b --- M modules/cassandra 1 file changed, 0 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/85/199585/1 diff --git a/modules/cassandra b/modules/cassandra index 65fde18..fe345a7 16 --- a/modules/cassandra +++ b/modules/cassandra -Subproject commit 65fde188705cb1f3306777a93047723042386690 +Subproject commit fe345a76ed988c6dbf2d4f54baa4f17d03d5e6cc -- To view, visit https://gerrit.wikimedia.org/r/199585 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I15964f034a5c727827f5e3d6bbef2f5422b3c86b Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Filippo Giunchedi fgiunch...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] remove CAMELLIA from ciphersuites - change (operations/puppet)
BBlack has uploaded a new change for review. https://gerrit.wikimedia.org/r/199582 Change subject: remove CAMELLIA from ciphersuites .. remove CAMELLIA from ciphersuites Change-Id: I4fddffe03933836627dd426d0f41a9e49dbde2f2 --- M modules/wmflib/lib/puppet/parser/functions/ssl_ciphersuite.rb 1 file changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/82/199582/1 diff --git a/modules/wmflib/lib/puppet/parser/functions/ssl_ciphersuite.rb b/modules/wmflib/lib/puppet/parser/functions/ssl_ciphersuite.rb index 3a7ca11..f91cd6a 100644 --- a/modules/wmflib/lib/puppet/parser/functions/ssl_ciphersuite.rb +++ b/modules/wmflib/lib/puppet/parser/functions/ssl_ciphersuite.rb @@ -47,8 +47,8 @@ module Puppet::Parser::Functions ciphersuites = { -'compat' = 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128:AES256:HIGH:!aNULL:!eNULL:!EXPORT:!DES:!MD5:!PSK:!DH', -'strong' = 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:HIGH:!aNULL:!eNULL:!EXPORT:!DES:!3DES:!MD5:!PSK:!DH' +'compat' = 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128:AES256:HIGH:!aNULL:!eNULL:!EXPORT:!DES:!MD5:!PSK:!DH:!CAMELLIA', +'strong' = 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:HIGH:!aNULL:!eNULL:!EXPORT:!DES:!3DES:!MD5:!PSK:!DH:!CAMELLIA' } newfunction( :ssl_ciphersuite, -- To view, visit https://gerrit.wikimedia.org/r/199582 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I4fddffe03933836627dd426d0f41a9e49dbde2f2 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: BBlack bbl...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Replace mb_strtolower with strtolower - change (mediawiki/core)
Nikerabbit has uploaded a new change for review. https://gerrit.wikimedia.org/r/199584 Change subject: Replace mb_strtolower with strtolower .. Replace mb_strtolower with strtolower Function mb_strtolower is not guaranteed to be present. In this case we are dealing with language codes, which are ASCII, for which there is no need to use multibyte version in the first place. Bug: T55912 Change-Id: I009bab2ff03b22142d35c8be60711266ca3683c1 --- M includes/media/SVG.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/84/199584/1 diff --git a/includes/media/SVG.php b/includes/media/SVG.php index 0618f7e..8fdfa47 100644 --- a/includes/media/SVG.php +++ b/includes/media/SVG.php @@ -487,7 +487,7 @@ function makeParamString( $params ) { $lang = ''; if ( isset( $params['lang'] ) $params['lang'] !== 'en' ) { - $params['lang'] = mb_strtolower( $params['lang'] ); + $params['lang'] = strtolower( $params['lang'] ); $lang = lang{$params['lang']}-; } if ( !isset( $params['width'] ) ) { -- To view, visit https://gerrit.wikimedia.org/r/199584 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I009bab2ff03b22142d35c8be60711266ca3683c1 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Nikerabbit niklas.laxst...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] send additional metrics to graphite - change (operations...cassandra)
Filippo Giunchedi has submitted this change and it was merged. Change subject: send additional metrics to graphite .. send additional metrics to graphite There are a number of additional metrics available, beyond what is contained in the sample configuration. Some of these (column family-specific metrics for example), will be particularly valuable. Bug: T78514 Change-Id: I71c7b3c0c9a9d2b64a9386ec087b32d9bf6bca91 --- M templates/metrics.yaml.erb 1 file changed, 6 insertions(+), 0 deletions(-) Approvals: Filippo Giunchedi: Verified; Looks good to me, approved Mobrovac: Looks good to me, but someone else must approve GWicke: Looks good to me, but someone else must approve diff --git a/templates/metrics.yaml.erb b/templates/metrics.yaml.erb index 8c4f323..ded831d 100644 --- a/templates/metrics.yaml.erb +++ b/templates/metrics.yaml.erb @@ -12,6 +12,12 @@ patterns: - ^org.apache.cassandra.metrics.Cache.+ - ^org.apache.cassandra.metrics.ClientRequest.+ +- ^org.apache.cassandra.metrics.ColumnFamily.+ +- ^org.apache.cassandra.metrics.Connection.+ +- ^org.apache.cassandra.metrics.CQL.+ +- ^org.apache.cassandra.metrics.DroppedMessage.+ +- ^org.apache.cassandra.metrics.FileCache.+ +- ^org.apache.cassandra.metrics.IndexColumnFamily.+ - ^org.apache.cassandra.metrics.Storage.+ - ^org.apache.cassandra.metrics.ThreadPools.+ - ^org.apache.cassandra.metrics.Compaction.+ -- To view, visit https://gerrit.wikimedia.org/r/199264 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I71c7b3c0c9a9d2b64a9386ec087b32d9bf6bca91 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet/cassandra Gerrit-Branch: master Gerrit-Owner: Eevans eev...@wikimedia.org Gerrit-Reviewer: Alexandros Kosiaris akosia...@wikimedia.org Gerrit-Reviewer: Filippo Giunchedi fgiunch...@wikimedia.org Gerrit-Reviewer: GWicke gwi...@wikimedia.org Gerrit-Reviewer: Giuseppe Lavagetto glavage...@wikimedia.org Gerrit-Reviewer: Mobrovac mobro...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Revert Use EntityIdFormatter in MessageParameterFormatter - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/199586 Change subject: Revert Use EntityIdFormatter in MessageParameterFormatter .. Revert Use EntityIdFormatter in MessageParameterFormatter will be just for the branch for now, since it causes T93804. we can investigate more proper fix for master, as using EntityIdFormatter here is a good idea. This reverts commit fb60de9acf5ffa5347fc0f57656073154e170c97. Bug: T93804 Change-Id: I330d4761a47bb244f4fde4d7b549e24aa4410c79 --- M lib/includes/formatters/EntityIdLinkFormatter.php M lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php M repo/includes/Localizer/MessageParameterFormatter.php M repo/includes/WikibaseRepo.php M repo/tests/phpunit/includes/Localizer/MessageParameterFormatterTest.php 5 files changed, 32 insertions(+), 22 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/86/199586/1 diff --git a/lib/includes/formatters/EntityIdLinkFormatter.php b/lib/includes/formatters/EntityIdLinkFormatter.php index 9a520aa..60567f4 100644 --- a/lib/includes/formatters/EntityIdLinkFormatter.php +++ b/lib/includes/formatters/EntityIdLinkFormatter.php @@ -24,7 +24,7 @@ public function formatEntityId( EntityId $entityId ) { $title = parent::formatEntityId( $entityId ); - return [[$title| . wfEscapeWikiText( $entityId-getSerialization() ) . ]]; + return [[$title]]; } } diff --git a/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php b/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php index d7084b9..035a916 100644 --- a/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php +++ b/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php @@ -5,6 +5,7 @@ use LogicException; use PHPUnit_Framework_TestCase; use Title; +use ValueFormatters\FormatterOptions; use Wikibase\DataModel\Entity\EntityId; use Wikibase\DataModel\Entity\Item; use Wikibase\DataModel\Entity\ItemId; @@ -16,6 +17,8 @@ * @covers Wikibase\Lib\EntityIdLinkFormatter * * @group Wikibase + * @group ValueFormatters + * @group DataValueExtensions * @group WikibaseLib * @group EntityIdFormatterTest * @@ -28,11 +31,11 @@ return array( 'ItemId' = array( new ItemId( 'Q23' ), - '[[ITEM-TEST--Q23|Q23]]' + '[[ITEM-TEST--Q23]]' ), 'PropertyId' = array( new PropertyId( 'P23' ), - '[[PROPERTY-TEST--P23|P23]]' + '[[PROPERTY-TEST--P23]]' ), ); } @@ -58,7 +61,8 @@ } } - private function newEntityIdLinkFormatter() { + protected function newEntityIdLinkFormatter() { + $options = new FormatterOptions(); $titleLookup = $this-getMock( 'Wikibase\Lib\Store\EntityTitleLookup' ); $titleLookup-expects( $this-any() )-method( 'getTitleForId' ) -will( $this-returnCallback( array( $this, 'getTitleForId' ) ) ); diff --git a/repo/includes/Localizer/MessageParameterFormatter.php b/repo/includes/Localizer/MessageParameterFormatter.php index 6cd3c75..7d54deb 100644 --- a/repo/includes/Localizer/MessageParameterFormatter.php +++ b/repo/includes/Localizer/MessageParameterFormatter.php @@ -10,8 +10,8 @@ use ValueFormatters\ValueFormatter; use Wikibase\DataModel\Entity\EntityId; use Wikibase\DataModel\SiteLink; -use Wikibase\Lib\EntityIdFormatter; use Wikibase\Lib\MediaWikiNumberLocalizer; +use Wikibase\Lib\Store\EntityTitleLookup; /** * ValueFormatter for formatting objects that may be encountered in @@ -28,9 +28,9 @@ private $dataValueFormatter; /** -* @var EntityIdFormatter +* @var EntityTitleLookup */ - private $entityIdFormatter; + private $entityTitleLookup; /** * @var SiteStore @@ -49,18 +49,18 @@ /** * @param ValueFormatter $dataValueFormatter A formatter for turning DataValues into wikitext. -* @param EntityIdFormatter $entityIdFormatter An entity id formatter returning wikitext. +* @param EntityTitleLookup $entityTitleLookup * @param SiteStore $sites * @param Language $language */ public function __construct( ValueFormatter $dataValueFormatter, - EntityIdFormatter $entityIdFormatter, + EntityTitleLookup $entityTitleLookup, SiteStore $sites, Language $language ) { $this-dataValueFormatter = $dataValueFormatter; - $this-entityIdFormatter = $entityIdFormatter; +
[MediaWiki-commits] [Gerrit] update cassandra submodule - change (operations/puppet)
Filippo Giunchedi has submitted this change and it was merged. Change subject: update cassandra submodule .. update cassandra submodule Change-Id: I15964f034a5c727827f5e3d6bbef2f5422b3c86b --- M modules/cassandra 1 file changed, 0 insertions(+), 0 deletions(-) Approvals: Filippo Giunchedi: Verified; Looks good to me, approved jenkins-bot: Verified diff --git a/modules/cassandra b/modules/cassandra index 65fde18..fe345a7 16 --- a/modules/cassandra +++ b/modules/cassandra -Subproject commit 65fde188705cb1f3306777a93047723042386690 +Subproject commit fe345a76ed988c6dbf2d4f54baa4f17d03d5e6cc -- To view, visit https://gerrit.wikimedia.org/r/199585 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I15964f034a5c727827f5e3d6bbef2f5422b3c86b Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Filippo Giunchedi fgiunch...@wikimedia.org Gerrit-Reviewer: Filippo Giunchedi fgiunch...@wikimedia.org Gerrit-Reviewer: Mobrovac mobro...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Split individual tests in UsageAccumulatorContractTester - change (mediawiki...Wikibase)
Thiemo Mättig (WMDE) has uploaded a new change for review. https://gerrit.wikimedia.org/r/199588 Change subject: Split individual tests in UsageAccumulatorContractTester .. Split individual tests in UsageAccumulatorContractTester This doesn#t change semantics, all it does is splitting the code in individual private methods. And I'm adding a contains check for each. Change-Id: Ib957f55231572b328c187d74c177d8388ec64fb8 --- M client/tests/phpunit/includes/Usage/HashUsageAccumulatorTest.php M client/tests/phpunit/includes/Usage/ParserOutputUsageAccumulatorTest.php M client/tests/phpunit/includes/Usage/UsageAccumulatorContractTester.php 3 files changed, 94 insertions(+), 23 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/88/199588/1 diff --git a/client/tests/phpunit/includes/Usage/HashUsageAccumulatorTest.php b/client/tests/phpunit/includes/Usage/HashUsageAccumulatorTest.php index 32ccfd1..ea88c02 100644 --- a/client/tests/phpunit/includes/Usage/HashUsageAccumulatorTest.php +++ b/client/tests/phpunit/includes/Usage/HashUsageAccumulatorTest.php @@ -20,7 +20,7 @@ $acc = new HashUsageAccumulator(); $tester = new UsageAccumulatorContractTester( $acc ); - $tester-testAddGetUsage(); + $tester-testAddAndGetUsages(); } } diff --git a/client/tests/phpunit/includes/Usage/ParserOutputUsageAccumulatorTest.php b/client/tests/phpunit/includes/Usage/ParserOutputUsageAccumulatorTest.php index 1ac9a44..35db7c6 100644 --- a/client/tests/phpunit/includes/Usage/ParserOutputUsageAccumulatorTest.php +++ b/client/tests/phpunit/includes/Usage/ParserOutputUsageAccumulatorTest.php @@ -22,7 +22,7 @@ $acc = new ParserOutputUsageAccumulator( $parserOutput ); $tester = new UsageAccumulatorContractTester( $acc ); - $tester-testAddGetUsage(); + $tester-testAddAndGetUsages(); $this-assertNotNull( $parserOutput-getExtensionData( 'wikibase-entity-usage' ) ); } diff --git a/client/tests/phpunit/includes/Usage/UsageAccumulatorContractTester.php b/client/tests/phpunit/includes/Usage/UsageAccumulatorContractTester.php index e528d39..070b28d 100644 --- a/client/tests/phpunit/includes/Usage/UsageAccumulatorContractTester.php +++ b/client/tests/phpunit/includes/Usage/UsageAccumulatorContractTester.php @@ -11,7 +11,10 @@ use Wikibase\DataModel\Snak\PropertyValueSnak; /** - * Contract tester for implementations of the UsageAccumulator interface + * Contract tester for implementations of the UsageAccumulator interface. + * + * @covers Wikibase\Client\Usage\UsageAccumulator + * @uses Wikibase\Client\Usage\EntityUsage * * @group Wikibase * @group WikibaseClient @@ -31,34 +34,102 @@ $this-usageAccumulator = $usageAccumulator; } - public function testAddGetUsage() { + public function testAddAndGetUsages() { + $this-testAddAndGetLabelUsageForSnaks(); + $this-testAddAndGetLabelUsage(); + $this-testAddAndGetTitleUsage(); + $this-testAddAndGetSiteLinksUsage(); + $this-testAddAndGetOtherUsage(); + $this-testAddAndGetAllUsage(); + $q2 = new ItemId( 'Q2' ); $q3 = new ItemId( 'Q3' ); $q4 = new ItemId( 'Q4' ); + $expected = array( + new EntityUsage( $q4, EntityUsage::LABEL_USAGE ), + new EntityUsage( $q2, EntityUsage::LABEL_USAGE ), + new EntityUsage( $q2, EntityUsage::TITLE_USAGE ), + new EntityUsage( $q2, EntityUsage::SITELINK_USAGE ), + new EntityUsage( $q2, EntityUsage::OTHER_USAGE ), + new EntityUsage( $q3, EntityUsage::ALL_USAGE ), + ); - // FIXME: Split into separate tests. - // FIXME: Why is OTHER_USAGE missing? - $this-usageAccumulator-addSiteLinksUsage( $q2 ); - $this-usageAccumulator-addLabelUsage( $q2 ); - $this-usageAccumulator-addTitleUsage( $q2 ); - $this-usageAccumulator-addAllUsage( $q3 ); + $usages = $this-usageAccumulator-getUsages(); + $this-assertSameUsages( $expected, $usages ); + } - // Testing convenience methods + private function testAddAndGetLabelUsageForSnaks() { + $q4 = new ItemId( 'Q4' ); $this-usageAccumulator-addLabelUsageForSnaks( array( new PropertyValueSnak( new PropertyId( 'P4' ), new EntityIdValue( $q4 ) ), ) ); - $usage = $this-usageAccumulator-getUsages(); + $expected = new EntityUsage( $q4, EntityUsage::LABEL_USAGE ); - $expected = array( -
[MediaWiki-commits] [Gerrit] Make Parsoid work with multiwiki. - change (mediawiki/vagrant)
Werdna has uploaded a new change for review. https://gerrit.wikimedia.org/r/199591 Change subject: Make Parsoid work with multiwiki. .. Make Parsoid work with multiwiki. The implementation is not ideal: I could not figure out how to loop over defined wikis. But at least VisualEditor now works on multiwiki setups Change-Id: Ia553d4f8d7aa3cab53656755d119bd5d9d989295 --- M puppet/modules/mediawiki/templates/parsoid.localsettings.js.erb M puppet/modules/role/templates/ve-config.php.erb 2 files changed, 18 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/vagrant refs/changes/91/199591/1 diff --git a/puppet/modules/mediawiki/templates/parsoid.localsettings.js.erb b/puppet/modules/mediawiki/templates/parsoid.localsettings.js.erb index ec668d2..a9f626d 100644 --- a/puppet/modules/mediawiki/templates/parsoid.localsettings.js.erb +++ b/puppet/modules/mediawiki/templates/parsoid.localsettings.js.erb @@ -3,7 +3,23 @@ * This file is managed by Puppet. */ exports.setup = function( parsoidConfig ) { -parsoidConfig.setInterwiki( 'localhost', '%= scope[mediawiki::server_url] %/w/api.php' ); +%- + # XXX: I wish I could think of a better way to do this + `alldbs`.split(\n).each do |db| +wikiname = db[0..-5] +if wikiname != '' then + # XXX I should be reading the resource config but I can't + # figure out how + server_url = 'http://' + +wikiname + +scope[mediawiki::multiwiki::base_domain] + +scope[port_fragment] +else + server_url = scope[mediawiki::server_url] +end +-% +parsoidConfig.setInterwiki( '%=db%', '%=server_url%/w/api.php' ); +%- end % parsoidConfig.usePHPPreProcessor = %= @use_php_preprocessor %; parsoidConfig.useSelser = %= @use_selser %; %- if @allow_cors -% diff --git a/puppet/modules/role/templates/ve-config.php.erb b/puppet/modules/role/templates/ve-config.php.erb index dac002b..74b6f6b 100644 --- a/puppet/modules/role/templates/ve-config.php.erb +++ b/puppet/modules/role/templates/ve-config.php.erb @@ -2,3 +2,4 @@ $wgVisualEditorNamespaces = array( NS_MAIN, NS_USER ); $wgDefaultUserOptions['visualeditor-enable'] = 1; $wgVisualEditorParsoidURL = 'http://localhost:%= scope['mediawiki::parsoid::port'] %'; +$wgVisualEditorParsoidPrefix = $wgDBname; -- To view, visit https://gerrit.wikimedia.org/r/199591 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia553d4f8d7aa3cab53656755d119bd5d9d989295 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/vagrant Gerrit-Branch: master Gerrit-Owner: Werdna agarr...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] dispatchChanges: Don't use FOR UPDATE for selecting a client - change (mediawiki...Wikibase)
Hoo man has uploaded a new change for review. https://gerrit.wikimedia.org/r/199592 Change subject: dispatchChanges: Don't use FOR UPDATE for selecting a client .. dispatchChanges: Don't use FOR UPDATE for selecting a client Also make the randomness parameter actually work and increase the default value. In production the value should be even higher. Change-Id: Ie7d68953be5c680c964d12a4943d72886407d9ad --- M lib/maintenance/dispatchChanges.php 1 file changed, 3 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/92/199592/1 diff --git a/lib/maintenance/dispatchChanges.php b/lib/maintenance/dispatchChanges.php index 8b99b38..42ebf79 100644 --- a/lib/maintenance/dispatchChanges.php +++ b/lib/maintenance/dispatchChanges.php @@ -98,7 +98,7 @@ * causes a completely random selection of the target, regardless of when it * was last selected for dispatch. */ - protected $randomness = 5; + protected $randomness = 10; /** * @var bool: whether output should be version. @@ -119,7 +119,7 @@ $this-addOption( 'lock-grace-interval', Seconds after wich to probe for orphaned locks. . Default: 60, false, true ); $this-addOption( 'randomness', Number of least current target wikis to pick from at random. - . Default: 5., false, true ); + . Default: 10., false, true ); $this-addOption( 'max-passes', The number of passes to perform. . Default: 1 if --max-time is not set, infinite if it is., false, true ); $this-addOption( 'max-time', The number of seconds to run before exiting, @@ -146,6 +146,7 @@ $this-delay = intval( $this-getOption( 'idle-delay', 10 ) ); $this-dispatchInterval = intval( $this-getOption( 'dispatch-interval', 60 ) ); $this-lockGraceInterval = intval( $this-getOption( 'lock-grace-interval', 60 ) ); + $this-randomness = intval( $this-getOption( 'lock-grace-interval', $this-randomness ) ); $this-verbose = $this-getOption( 'verbose', false ); @@ -419,7 +420,6 @@ __METHOD__, array( 'ORDER BY' = 'chd_seen ASC', - 'FOR UPDATE', 'LIMIT' = (int)$this-randomness ) ); -- To view, visit https://gerrit.wikimedia.org/r/199592 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie7d68953be5c680c964d12a4943d72886407d9ad Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Hoo man h...@online.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] New Wikidata Build - 2015-03-25T10:00:01+0000 - change (mediawiki...Wikidata)
WikidataBuilder has uploaded a new change for review. https://gerrit.wikimedia.org/r/199595 Change subject: New Wikidata Build - 2015-03-25T10:00:01+ .. New Wikidata Build - 2015-03-25T10:00:01+ Change-Id: I5938d4eb0347939aa854352ecec50e6b99d306a1 --- M WikibaseClient.settings.php M WikibaseRepo.settings.php M composer.lock M extensions/PropertySuggester/build/travis/after_script.sh M extensions/PropertySuggester/build/travis/before_script.sh M extensions/PropertySuggester/build/travis/script.sh M extensions/ValueView/README.md M extensions/ValueView/ValueView.php M extensions/ValueView/tests/lib/jquery.ui/jquery.ui.inputextender.tests.js M extensions/ValueView/tests/lib/jquery/jquery.focusAt.tests.js M extensions/ValueView/tests/src/ExpertExtender/ExpertExtender.tests.js M extensions/Wikibase/.jscsrc M extensions/Wikibase/README.md M extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh M extensions/Wikibase/build/travis/install.sh M extensions/Wikibase/build/travis/mw-apply-wb-settings.sh M extensions/Wikibase/build/travis/script.sh M extensions/Wikibase/build/travis/update-db.sh M extensions/Wikibase/client/WikibaseClient.hooks.php M extensions/Wikibase/client/WikibaseClient.php M extensions/Wikibase/client/config/WikibaseClient.default.php A extensions/Wikibase/client/i18n/ang.json M extensions/Wikibase/client/i18n/arq.json M extensions/Wikibase/client/i18n/as.json M extensions/Wikibase/client/i18n/az.json M extensions/Wikibase/client/i18n/be-tarask.json A extensions/Wikibase/client/i18n/bho.json M extensions/Wikibase/client/i18n/da.json M extensions/Wikibase/client/i18n/de.json A extensions/Wikibase/client/i18n/gom-deva.json M extensions/Wikibase/client/i18n/kk-cyrl.json M extensions/Wikibase/client/i18n/lt.json M extensions/Wikibase/client/i18n/lzh.json M extensions/Wikibase/client/i18n/oc.json M extensions/Wikibase/client/i18n/ps.json M extensions/Wikibase/client/i18n/qqq.json M extensions/Wikibase/client/i18n/ru.json M extensions/Wikibase/client/i18n/sr-el.json A extensions/Wikibase/client/i18n/tcy.json M extensions/Wikibase/client/i18n/tt-cyrl.json M extensions/Wikibase/client/i18n/uk.json M extensions/Wikibase/client/i18n/zh-hant.json M extensions/Wikibase/client/includes/Changes/ChangeHandler.php M extensions/Wikibase/client/includes/RepoItemLinkGenerator.php M extensions/Wikibase/client/includes/UpdateRepo/UpdateRepo.php M extensions/Wikibase/client/includes/scribunto/EntityAccessor.php A extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php A extensions/Wikibase/client/maintenance/updateSubscriptions.php A extensions/Wikibase/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php M extensions/Wikibase/composer.json M extensions/Wikibase/docs/json.wiki A extensions/Wikibase/lib/i18n/arq.json M extensions/Wikibase/lib/i18n/as.json M extensions/Wikibase/lib/i18n/az.json A extensions/Wikibase/lib/i18n/gom-deva.json M extensions/Wikibase/lib/i18n/hr.json M extensions/Wikibase/lib/i18n/lt.json A extensions/Wikibase/lib/i18n/ne.json M extensions/Wikibase/lib/i18n/oc.json M extensions/Wikibase/lib/i18n/ps.json M extensions/Wikibase/lib/i18n/qqq.json M extensions/Wikibase/lib/i18n/qu.json M extensions/Wikibase/lib/i18n/sr-ec.json M extensions/Wikibase/lib/i18n/sr-el.json M extensions/Wikibase/lib/i18n/sv.json A extensions/Wikibase/lib/i18n/sw.json M extensions/Wikibase/lib/i18n/uk.json M extensions/Wikibase/lib/includes/Summary.php M extensions/Wikibase/lib/includes/changes/EntityChange.php M extensions/Wikibase/lib/includes/formatters/CommonsLinkFormatter.php M extensions/Wikibase/lib/includes/formatters/EntityIdHtmlLinkFormatterFactory.php M extensions/Wikibase/lib/includes/formatters/EntityIdLinkFormatter.php M extensions/Wikibase/lib/includes/formatters/GlobeCoordinateDetailsFormatter.php M extensions/Wikibase/lib/includes/formatters/HtmlTimeFormatter.php M extensions/Wikibase/lib/includes/formatters/HtmlUrlFormatter.php M extensions/Wikibase/lib/includes/formatters/MonolingualHtmlFormatter.php M extensions/Wikibase/lib/includes/formatters/MwTimeIsoFormatter.php M extensions/Wikibase/lib/includes/formatters/PropertyValueSnakFormatter.php M extensions/Wikibase/lib/includes/formatters/QuantityDetailsFormatter.php M extensions/Wikibase/lib/includes/formatters/TimeDetailsFormatter.php M extensions/Wikibase/lib/includes/formatters/UnDeserializableValueFormatter.php D extensions/Wikibase/lib/includes/parsers/DateTimeParser.php M extensions/Wikibase/lib/includes/parsers/EntityIdValueParser.php M extensions/Wikibase/lib/includes/parsers/MWTimeIsoParser.php M extensions/Wikibase/lib/includes/parsers/MonolingualTextParser.php A extensions/Wikibase/lib/includes/parsers/PhpDateTimeParser.php M extensions/Wikibase/lib/includes/parsers/TimeParser.php M extensions/Wikibase/lib/includes/parsers/YearMonthTimeParser.php M extensions/Wikibase/lib/includes/parsers/YearTimeParser.php M
[MediaWiki-commits] [Gerrit] Revert Fix filtering in change dispatcher. - change (mediawiki...Wikibase)
Hoo man has uploaded a new change for review. https://gerrit.wikimedia.org/r/199589 Change subject: Revert Fix filtering in change dispatcher. .. Revert Fix filtering in change dispatcher. DispatchChanges::isRelevantChange returns true or false, but never null. This reverts commit 4d98bc2bc33bf20be2edb69d7e9502aa4047b5ee. Change-Id: I5248d05a04abe2230c4ff4eca15563b5631201e6 --- M lib/maintenance/dispatchChanges.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/89/199589/1 diff --git a/lib/maintenance/dispatchChanges.php b/lib/maintenance/dispatchChanges.php index 96ae2cf..f2131d8 100644 --- a/lib/maintenance/dispatchChanges.php +++ b/lib/maintenance/dispatchChanges.php @@ -860,7 +860,7 @@ // The change is relevant if it alters any sitelinks referring to $siteID, // or the item currently links to $siteID. if ( isset( $linkedItems[$itemId] ) - || $this-isRelevantChange( $change, $siteID ) ) { + || $this-isRelevantChange( $change, $siteID ) !== null ) { $filteredChanges[] = $change; $numberOfChangesFound++; -- To view, visit https://gerrit.wikimedia.org/r/199589 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I5248d05a04abe2230c4ff4eca15563b5631201e6 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Hoo man h...@online.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Concatenate strings in JavaScriptFFS - change (mediawiki...Translate)
Ayushimrigen has uploaded a new change for review. https://gerrit.wikimedia.org/r/199590 Change subject: Concatenate strings in JavaScriptFFS .. Concatenate strings in JavaScriptFFS The strings were getting divided only when they contained '+ ' or '+'. But they may contain more spaces between + and . This has been solved here. Bug: T1 Change-Id: I9f489682baa1540fc0e6715febcaf6ae2807e053 --- M ffs/JavaScriptFFS.php 1 file changed, 3 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate refs/changes/90/199590/1 diff --git a/ffs/JavaScriptFFS.php b/ffs/JavaScriptFFS.php index ecbec78..f963ead 100644 --- a/ffs/JavaScriptFFS.php +++ b/ffs/JavaScriptFFS.php @@ -96,14 +96,13 @@ /** * Concatenate separated strings. */ - $segment = str_replace( '+', ' +', $segment ); - $segment = explode( ' +', $segment ); + $segment = explode( '+', $segment ); $count = count( $segment ); for ( $i = 0; $i $count; $i++ ) { - $segment[$i] = ltrim( ltrim( $segment[$i] ), '' ); + $segment[$i] = trim( trim( $segment[$i] ), '' ); } $segment = implode( $segment ); - + $segment[$i] = trim( trim( $segment[$i] ), '' ); /** * Remove line breaks between message keys and messages. */ -- To view, visit https://gerrit.wikimedia.org/r/199590 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I9f489682baa1540fc0e6715febcaf6ae2807e053 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Ayushimrigen ayushimrige...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] dhcp: swap mac addresses for mw2178 and mw2179 - change (operations/puppet)
Giuseppe Lavagetto has uploaded a new change for review. https://gerrit.wikimedia.org/r/199594 Change subject: dhcp: swap mac addresses for mw2178 and mw2179 .. dhcp: swap mac addresses for mw2178 and mw2179 In I2b79b1 I should have corrected the entry for mw2179, but I changed mw2178 instead. Swapping them now. Change-Id: If5049371afd3f336b210cac06cb4177bae107412 --- M modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 1 file changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/94/199594/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 6263ea6..8ef5ebc 100644 --- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 +++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 @@ -5002,12 +5002,12 @@ } host mw2178 { - hardware ethernet B0:83:FE:DF:26:F7; + hardware ethernet B0:83:FE:DA:7A:BE; fixed-address mw2178.codfw.wmnet; } host mw2179 { - hardware ethernet B0:83:FE:DA:7A:BE; + hardware ethernet B0:83:FE:DF:26:F7; fixed-address mw2179.codfw.wmnet; } -- To view, visit https://gerrit.wikimedia.org/r/199594 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: If5049371afd3f336b210cac06cb4177bae107412 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Giuseppe Lavagetto glavage...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Use specific summary lines in SpecialSetLabelDescriptionAliases - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Use specific summary lines in SpecialSetLabelDescriptionAliases .. Use specific summary lines in SpecialSetLabelDescriptionAliases This simply uses the old messages if only 1 field was changed. The actual change detection is the most simple possible. I think this is enough. Bug: T93853 Change-Id: I6cdbd3e3dd7b1a5b9c4710d544a993b3341d1849 --- M repo/includes/specials/SpecialSetLabelDescriptionAliases.php 1 file changed, 24 insertions(+), 13 deletions(-) Approvals: Tobias Gritschacher: Looks good to me, approved Hoo man: Looks good to me, approved jenkins-bot: Verified Objections: Daniel Kinzler: There's a problem with this change, please improve diff --git a/repo/includes/specials/SpecialSetLabelDescriptionAliases.php b/repo/includes/specials/SpecialSetLabelDescriptionAliases.php index 73bff9b..db2bd58 100644 --- a/repo/includes/specials/SpecialSetLabelDescriptionAliases.php +++ b/repo/includes/specials/SpecialSetLabelDescriptionAliases.php @@ -334,10 +334,14 @@ $changeOps = array(); if ( $this-label !== '' ) { - $changeOps['wbsetlabel'] = $changeOpFactory-newSetLabelOp( - $this-languageCode, - $this-label - ); + if ( !$fingerprint-hasLabel( $this-languageCode ) + || $fingerprint-getLabel( $this-languageCode )-getText() !== $this-label + ) { + $changeOps['wbsetlabel'] = $changeOpFactory-newSetLabelOp( + $this-languageCode, + $this-label + ); + } } elseif ( $fingerprint-hasLabel( $this-languageCode ) ) { $changeOps['wbsetlabel'] = $changeOpFactory-newRemoveLabelOp( $this-languageCode @@ -345,10 +349,14 @@ } if ( $this-description !== '' ) { - $changeOps['wbsetdescription'] = $changeOpFactory-newSetDescriptionOp( - $this-languageCode, - $this-description - ); + if ( !$fingerprint-hasDescription( $this-languageCode ) + || $fingerprint-getDescription( $this-languageCode )-getText() !== $this-description + ) { + $changeOps['wbsetdescription'] = $changeOpFactory-newSetDescriptionOp( + $this-languageCode, + $this-description + ); + } } elseif ( $fingerprint-hasDescription( $this-languageCode ) ) { $changeOps['wbsetdescription'] = $changeOpFactory-newRemoveDescriptionOp( $this-languageCode @@ -356,10 +364,14 @@ } if ( !empty( $this-aliases ) ) { - $changeOps['wbsetaliases'] = $changeOpFactory-newSetAliasesOp( - $this-languageCode, - $this-aliases - ); + if ( !$fingerprint-hasAliasGroup( $this-languageCode ) + || $fingerprint-getAliasGroup( $this-languageCode )-getAliases() !== $this-aliases + ) { + $changeOps['wbsetaliases'] = $changeOpFactory-newSetAliasesOp( + $this-languageCode, + $this-aliases + ); + } } elseif ( $fingerprint-hasAliasGroup( $this-languageCode ) ) { $changeOps['wbsetaliases'] = $changeOpFactory-newRemoveAliasesOp( $this-languageCode, @@ -374,7 +386,6 @@ * @return Summary */ private function getSummaryForLabelDescriptionAliases() { - // FIXME: Use the existing messages if only 1 of the 3 fields changed. // FIXME: Introduce more specific messages if only 2 of the 3 fields changed. $summary = new Summary( 'wbsetlabeldescriptionaliases' ); $summary-addAutoSummaryArgs( $this-label, $this-description, $this-aliases ); -- To view, visit https://gerrit.wikimedia.org/r/194107 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I6cdbd3e3dd7b1a5b9c4710d544a993b3341d1849 Gerrit-PatchSet: 4 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Thiemo Mättig
[MediaWiki-commits] [Gerrit] Use tox for running flake8 - change (mediawiki...UploadWizard)
jenkins-bot has submitted this change and it was merged. Change subject: Use tox for running flake8 .. Use tox for running flake8 Also instead of totally ignoring line length, set a max of 120 The [pep8] section is left in since jenkins is still running pep8, and should be removed once jenkins is updated to use tox instead. Change-Id: Id18ae52a5db4d1d7cb112fde895dde94217d38da --- M .gitignore M tox.ini 2 files changed, 18 insertions(+), 2 deletions(-) Approvals: Hashar: Looks good to me, approved jenkins-bot: Verified diff --git a/.gitignore b/.gitignore index 6625c5d..19649be 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,4 @@ tests/browser/.gem tests/browser/.bundle node_modules +.tox diff --git a/tox.ini b/tox.ini index 555e4de..d432c1b 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,21 @@ +[tox] + +# Ensure 1.6+ is used to support 'skipsdist' +minversion = 1.6 + +# Do not run install command +skipsdist = True + +# Environements to execute when invoking 'tox' +envlist = flake8 + +[testenv:flake8] +commands = flake8 +deps = flake8 + [flake8] -; E501 line too long -ignore = E501 +exclude = .tox +max_line_length = 120 [pep8] ; E501 line too long -- To view, visit https://gerrit.wikimedia.org/r/196744 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Id18ae52a5db4d1d7cb112fde895dde94217d38da Gerrit-PatchSet: 3 Gerrit-Project: mediawiki/extensions/UploadWizard Gerrit-Branch: master Gerrit-Owner: Legoktm legoktm.wikipe...@gmail.com Gerrit-Reviewer: Gergő Tisza gti...@wikimedia.org Gerrit-Reviewer: Gilles gdu...@wikimedia.org Gerrit-Reviewer: Hashar has...@free.fr Gerrit-Reviewer: Legoktm legoktm.wikipe...@gmail.com Gerrit-Reviewer: MarkTraceur mtrac...@member.fsf.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Position the group selector to appear at the bottom of the t... - change (mediawiki...Translate)
Nikerabbit has submitted this change and it was merged. Change subject: Position the group selector to appear at the bottom of the trigger. .. Position the group selector to appear at the bottom of the trigger. The group selector hide the trigger when opened due to its height growth at the bottom when the data is loaded. Added collision:none so that group selector is opened to the bottom side of the trigger and height change would not cause a problem. Change-Id: I6e08fcb635ddc8170383d91927d1a2d6eb4be8bf --- M resources/js/ext.translate.special.searchtranslations.js M resources/js/ext.translate.special.translate.js 2 files changed, 26 insertions(+), 7 deletions(-) Approvals: Nikerabbit: Looks good to me, approved jenkins-bot: Verified diff --git a/resources/js/ext.translate.special.searchtranslations.js b/resources/js/ext.translate.special.searchtranslations.js index 7c37e60..85fe97e 100644 --- a/resources/js/ext.translate.special.searchtranslations.js +++ b/resources/js/ext.translate.special.searchtranslations.js @@ -182,7 +182,8 @@ uri, maxListSize = 10, currentGroup = $( '.facet.groups' ).data( 'group' ), - resultCount = groupList.length; + resultCount = groupList.length, + position; level = level || 0; groupList = groupList.splice( 0, maxListSize ); @@ -240,12 +241,23 @@ ); $parent.append( $grouSelectorTrigger ); + if ( $( 'body' ).hasClass( 'rtl' ) ) { + position = { + my: 'right top', + at: 'right+90 top+40', + collision: 'none' + }; + } else { + position = { + my: 'left top', + at: 'left-90 top+40', + collision: 'none' + }; + } + $grouSelectorTrigger.msggroupselector( { language: mw.config.get( 'wgUserLanguage' ), - position: { - my: 'left top', - at: 'left top' - }, + position: position, onSelect: function ( group ) { var uri = new mw.Uri( window.location.href ); uri.extend( { 'group': group.id } ); diff --git a/resources/js/ext.translate.special.translate.js b/resources/js/ext.translate.special.translate.js index 940fd3a..870bd99 100644 --- a/resources/js/ext.translate.special.translate.js +++ b/resources/js/ext.translate.special.translate.js @@ -262,7 +262,7 @@ $( document ).ready( function () { var $translateContainer, $hideTranslatedButton, $controlOwnButton, $messageList, - targetLanguage, docLanguageAutonym, docLanguageCode, ulsOptions, filter, uri; + targetLanguage, docLanguageAutonym, docLanguageCode, ulsOptions, filter, uri, position; $messageList = $( '.tux-messagelist' ); if ( $messageList.length ) { @@ -288,9 +288,16 @@ // This is the selector for non-TUX mode prepareWorkflowSelector(); + if ( $( 'body' ).hasClass( 'rtl' ) ) { + position = { + my: 'right top', + at: 'right+80 bottom+5' + }; + } $( '.tux-breadcrumb .grouplink' ).msggroupselector( { onSelect: mw.translate.changeGroup, - language: targetLanguage + language: targetLanguage, + position: position } ); updateGroupWarning(); -- To view, visit https://gerrit.wikimedia.org/r/195854 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I6e08fcb635ddc8170383d91927d1a2d6eb4be8bf Gerrit-PatchSet: 4 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Phoenix303 divyalife...@gmail.com Gerrit-Reviewer: KartikMistry kartik.mis...@gmail.com Gerrit-Reviewer: Nemo bis federicol...@tiscali.it Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com Gerrit-Reviewer: Phoenix303 divyalife...@gmail.com Gerrit-Reviewer: Siebrand siebr...@kitano.nl Gerrit-Reviewer: jenkins-bot
[MediaWiki-commits] [Gerrit] dhcp: swap mac addresses for mw2178 and mw2179 - change (operations/puppet)
Giuseppe Lavagetto has submitted this change and it was merged. Change subject: dhcp: swap mac addresses for mw2178 and mw2179 .. dhcp: swap mac addresses for mw2178 and mw2179 In I2b79b1 I should have corrected the entry for mw2179, but I changed mw2178 instead. Swapping them now. Change-Id: If5049371afd3f336b210cac06cb4177bae107412 --- M modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 1 file changed, 2 insertions(+), 2 deletions(-) Approvals: Giuseppe Lavagetto: Verified; 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 6263ea6..8ef5ebc 100644 --- a/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 +++ b/modules/install-server/files/dhcpd/linux-host-entries.ttyS1-115200 @@ -5002,12 +5002,12 @@ } host mw2178 { - hardware ethernet B0:83:FE:DF:26:F7; + hardware ethernet B0:83:FE:DA:7A:BE; fixed-address mw2178.codfw.wmnet; } host mw2179 { - hardware ethernet B0:83:FE:DA:7A:BE; + hardware ethernet B0:83:FE:DF:26:F7; fixed-address mw2179.codfw.wmnet; } -- To view, visit https://gerrit.wikimedia.org/r/199594 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: If5049371afd3f336b210cac06cb4177bae107412 Gerrit-PatchSet: 2 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Giuseppe Lavagetto glavage...@wikimedia.org Gerrit-Reviewer: Giuseppe Lavagetto glavage...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] New auto-summary message for SpecialSetLabelDescriptionAliases - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: New auto-summary message for SpecialSetLabelDescriptionAliases .. New auto-summary message for SpecialSetLabelDescriptionAliases Again, this is only one step, more patches are coming. There are a lot of FIXMEs in here, but I would love to fix them in later patches. Please review and merge so we can move forward. If you find actual issues introduced by this patch I will fix them. If you find issues *not* introduced here I will mark them as FIXME if not already done. Ok? Bug: T93853 Change-Id: I66f06792386adddf48e342a7a623e38033bc28ae --- M repo/i18n/en.json M repo/i18n/qqq.json M repo/includes/specials/SpecialSetLabelDescriptionAliases.php 3 files changed, 76 insertions(+), 42 deletions(-) Approvals: Tobias Gritschacher: Looks good to me, approved jenkins-bot: Verified diff --git a/repo/i18n/en.json b/repo/i18n/en.json index 416d3d3..2ef6536 100644 --- a/repo/i18n/en.json +++ b/repo/i18n/en.json @@ -341,6 +341,7 @@ wikibase-item-summary-wbsetaliases-add-remove: Added and removed [$2] {{PLURAL:$1|alias|aliases}}, wikibase-item-summary-wbsetaliases-add: Added [$2] {{PLURAL:$1|alias|aliases}}, wikibase-item-summary-wbsetaliases-remove: Removed [$2] {{PLURAL:$1|alias|aliases}}, + wikibase-item-summary-wbsetlabeldescriptionaliases: Changed [$2] label, description and aliases, wikibase-item-summary-wbsetsitelink-add: Added link to [$2], wikibase-item-summary-wbsetsitelink-add-both: Added link with badges to [$2], wikibase-item-summary-wbsetsitelink-set: Changed link to [$2], @@ -393,6 +394,7 @@ wikibase-property-summary-wbsetaliases-add-remove: Added and removed [$2] {{PLURAL:$1|alias|aliases}}, wikibase-property-summary-wbsetaliases-add: Added [$2] {{PLURAL:$1|alias|aliases}}, wikibase-property-summary-wbsetaliases-remove: Removed [$2] {{PLURAL:$1|alias|aliases}}, + wikibase-property-summary-wbsetlabeldescriptionaliases: Changed [$2] label, description and aliases, wikibase-property-summary-wbsetclaim-update: Changed {{PLURAL:$3|claim|claims}}, wikibase-property-summary-wbsetclaim-create: Created {{PLURAL:$3|claim|claims}}, wikibase-property-summary-wbsetclaim-update-qualifiers: Changed {{PLURAL:$4|one qualifier|$4 qualifiers}} of {{PLURAL:$3|claim|claims}}, diff --git a/repo/i18n/qqq.json b/repo/i18n/qqq.json index 9afa0fb..a777010 100644 --- a/repo/i18n/qqq.json +++ b/repo/i18n/qqq.json @@ -368,6 +368,7 @@ wikibase-item-summary-wbsetaliases-add-remove: {{wikibase summary messages|item|Automatic edit summary when adding and removing item aliases. A user can be in edit mode for aliases and can remove one or more aliases, while adding others in the same edit.}}, wikibase-item-summary-wbsetaliases-add: {{wikibase summary messages|item|Automatic edit summary when adding one or more aliases.}}, wikibase-item-summary-wbsetaliases-remove: {{wikibase summary messages|item|Automatic edit summary when a user removes one or more aliases.}}, + wikibase-item-summary-wbsetlabeldescriptionaliases: {{wikibase summary messages|item|Automatic edit summary generated when editing an item label, description and aliases. Example of a full edit summary is \Changed [en] label, description and aliases: Label, Description, Alias 1, Alias 2\.}}, wikibase-item-summary-wbsetsitelink-add: {{wikibase summary messages|sitelinks|Automatic edit summary (autocomment) when adding a language link. Such a summary could appear in English as \Added link to [itwiki]: Italia\.}}, wikibase-item-summary-wbsetsitelink-add-both: {{wikibase summary messages|sitelinks|Automatic edit summary (autocomment) when adding a language link with badges. Such a summary could appear in English as \Added link to [itwiki]: Italia, Q2, Q3\.}}, wikibase-item-summary-wbsetsitelink-set: {{doc-important|Translate this as \Changed link which points to nowiki[$2]/nowiki\.}}\n{{wikibase summary messages|sitelinks|Automatic edit summary (autocomment) when editing a language link. Such a summary could appear in English as \Changed link to [itwiki]: Italia\.}}, @@ -420,6 +421,7 @@ wikibase-property-summary-wbsetaliases-add-remove: Automatic edit summary when adding and removing property aliases. A user can be in edit mode for aliases and can remove one or more aliases, while adding others in the same edit.\n\nParameters:\n* $1 - the number of aliases added/removed\n* $2 - the language code of the item page, wikibase-property-summary-wbsetaliases-add: Automatic edit summary when adding an alias(es) for a property. Parameters:\n* $1 - the number of aliases that were added\n* $2 - the language code for the item page, wikibase-property-summary-wbsetaliases-remove: Automatic edit summary when a user removes one
[MediaWiki-commits] [Gerrit] Add debug logging to client UpdateRepo code - change (mediawiki...Wikibase)
Hoo man has uploaded a new change for review. https://gerrit.wikimedia.org/r/199596 Change subject: Add debug logging to client UpdateRepo code .. Add debug logging to client UpdateRepo code In order to find the root cause behind T92789 Bug: T92789 Change-Id: Ic1945d49510f2f9a61423e337a66e1e2391ea3e2 --- M client/includes/Hooks/UpdateRepoHookHandlers.php M client/includes/UpdateRepo/UpdateRepo.php 2 files changed, 17 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/96/199596/1 diff --git a/client/includes/Hooks/UpdateRepoHookHandlers.php b/client/includes/Hooks/UpdateRepoHookHandlers.php index ec41526..53dcc5c 100644 --- a/client/includes/Hooks/UpdateRepoHookHandlers.php +++ b/client/includes/Hooks/UpdateRepoHookHandlers.php @@ -230,6 +230,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnDelete: Failed to inject job: . $e-getMessage() ); } return true; @@ -274,6 +275,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnMove: Failed to inject job: . $e-getMessage() ); } return true; diff --git a/client/includes/UpdateRepo/UpdateRepo.php b/client/includes/UpdateRepo/UpdateRepo.php index 89f158b..0ec0d67 100644 --- a/client/includes/UpdateRepo/UpdateRepo.php +++ b/client/includes/UpdateRepo/UpdateRepo.php @@ -106,18 +106,33 @@ if ( !class_exists( 'CentralAuthUser' ) ) { // We can't do anything without CentralAuth as there's no way to verify that // the local user equals the repo one with the same name + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : class CentralAuthUser doesn't exist + ); + return false; } $caUser = CentralAuthUser::getInstance( $this-user ); if ( !$caUser || !$caUser-exists() ) { // The current user doesn't have a central account + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : User doesn't have a global account + ); + return false; } if ( !$caUser-isAttached() || !$caUser-attachedOn( $this-repoDB ) ) { // Either the user account on this wiki or the one on the repo do not exist // or they aren't connected + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : User is not attached locally or on {$this-repoDB} + ); + return false; } -- To view, visit https://gerrit.wikimedia.org/r/199596 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic1945d49510f2f9a61423e337a66e1e2391ea3e2 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Hoo man h...@online.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] ldap: selector outside a resource - change (operations/puppet)
Andrew Bogott has submitted this change and it was merged. Change subject: ldap: selector outside a resource .. ldap: selector outside a resource Change-Id: I9ef949976fda74977b46b106d411c05f436f9ce7 --- M modules/ldap/manifests/client.pp 1 file changed, 6 insertions(+), 4 deletions(-) Approvals: Andrew Bogott: Looks good to me, approved jenkins-bot: Verified Dzahn: Looks good to me, but someone else must approve diff --git a/modules/ldap/manifests/client.pp b/modules/ldap/manifests/client.pp index 7f57c8c..6069033 100644 --- a/modules/ldap/manifests/client.pp +++ b/modules/ldap/manifests/client.pp @@ -60,12 +60,14 @@ mode = '0444', } +$nscd_conf = $::realm ? { +'labs' = 'puppet:///modules/ldap/nscd-labs.conf', +default = 'puppet:///modules/ldap/nscd.conf', +} + file { '/etc/nscd.conf': notify = Service['nscd'], -source = $::realm ? { -'labs' = 'puppet:///modules/ldap/nscd-labs.conf', -default = 'puppet:///modules/ldap/nscd.conf', -} +source = $nscd_conf, } file { '/etc/nsswitch.conf': -- To view, visit https://gerrit.wikimedia.org/r/195524 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I9ef949976fda74977b46b106d411c05f436f9ce7 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Matanya mata...@foss.co.il Gerrit-Reviewer: Alexandros Kosiaris akosia...@wikimedia.org Gerrit-Reviewer: Andrew Bogott abog...@wikimedia.org Gerrit-Reviewer: Dzahn dz...@wikimedia.org Gerrit-Reviewer: Giuseppe Lavagetto glavage...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update url schemas on Special:Gather - change (mediawiki...Gather)
Jhernandez has uploaded a new change for review. https://gerrit.wikimedia.org/r/199610 Change subject: Update url schemas on Special:Gather .. Update url schemas on Special:Gather Mainly, user lists and a user list now are prefixed, so that we can have other prefixes, like /all * Introduce regex based routing * Modify /User/Id to be /by/User/Id * Add /all /all/public /all/hidden as a redirect to Special:GatherLists as a first step to merging the two special pages. * Fix No public list found error shown on GatherLists. In follow up patches I'll convert Special:GatherLists to a view that will be rendered by Special:Gather, like the views\Collection or the views\CollectionsList. Bug: T93774 Change-Id: I963de47101313ac6e73ec84b687b5d4ad90c5788 --- M includes/models/CollectionBase.php M includes/specials/SpecialGather.php M includes/specials/SpecialGatherLists.php M tests/browser/features/support/pages/watchlist_collection_page.rb 4 files changed, 47 insertions(+), 24 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather refs/changes/10/199610/1 diff --git a/includes/models/CollectionBase.php b/includes/models/CollectionBase.php index 61fefe0..1dac331 100644 --- a/includes/models/CollectionBase.php +++ b/includes/models/CollectionBase.php @@ -118,12 +118,13 @@ /** * Return local url for collection -* Example: /wiki/Special:Gather/user/id +* Example: /wiki/Special:Gather/by/user/id * * @return string localized url for collection */ public function getUrl() { return SpecialPage::getTitleFor( 'Gather' ) + -getSubpage( 'by' ) -getSubpage( $this-getOwner() ) -getSubpage( $this-getId() ) -getLocalURL(); diff --git a/includes/specials/SpecialGather.php b/includes/specials/SpecialGather.php index 32648d7..3dd38d8 100644 --- a/includes/specials/SpecialGather.php +++ b/includes/specials/SpecialGather.php @@ -32,39 +32,61 @@ } /** -* Render the special page and redirect the user to the editor (if page exists) +* Render the special page * -* @param string $subpage The name of the page to edit +* @param string $subpage */ public function execute( $subpage ) { - if ( $subpage ) { - $args = explode( '/', $subpage ); - // If there is a user argument, that's what we want to use - if ( isset( $args[0] ) ) { - // Show specified user's collections - $user = User::newFromName( $args[0] ); - } else { - // Otherwise use current user - $user = $this-getUser(); - } - } else { + if ( preg_match( '/^$/', $subpage ) ) { + // Root subpage. User owned collections. // For listing own lists, you need to be logged in $this-requireLogin( 'gather-anon-view-lists' ); $user = $this-getUser(); - } + $this-renderUserCollectionsList( $user ); - if ( !( $user $user-getId() ) ) { - // Invalid user - $this-renderError( new views\NotFound() ); - } else { - if ( isset( $args ) isset( $args[1] ) ) { - $id = intval( $args[1] ); - $this-renderUserCollection( $user, $id ); + } elseif ( preg_match( '/^by\/(?user\w+)\/?$/', $subpage, $matches ) ) { + // User's collections + // /by/:user = /by/:user/ + $user = User::newFromName( $matches['user'] ); + + if ( !( $user $user-getId() ) ) { + // Invalid user + $this-renderError( new views\NotFound() ); } else { $this-renderUserCollectionsList( $user ); } + + } elseif ( preg_match( '/^by\/(?user\w+)\/(?id\d+)$/', $subpage, $matches ) ) { + // Collection page + // /by/:user/:id + $id = $matches['id']; + $user = User::newFromName( $matches['user'] ); + + if ( !( $user $user-getId() ) ) { + // Invalid user + $this-renderError( new views\NotFound() ); + } else { + $this-renderUserCollection( $user, $id ); + }
[MediaWiki-commits] [Gerrit] Add debug logging to client UpdateRepo code - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Add debug logging to client UpdateRepo code .. Add debug logging to client UpdateRepo code In order to find the root cause behind T92789 Bug: T92789 Change-Id: Ic1945d49510f2f9a61423e337a66e1e2391ea3e2 --- M client/includes/Hooks/UpdateRepoHookHandlers.php M client/includes/UpdateRepo/UpdateRepo.php 2 files changed, 24 insertions(+), 0 deletions(-) Approvals: Aude: Looks good to me, approved Thiemo Mättig (WMDE): Looks good to me, but someone else must approve jenkins-bot: Verified diff --git a/client/includes/Hooks/UpdateRepoHookHandlers.php b/client/includes/Hooks/UpdateRepoHookHandlers.php index ec41526..53dcc5c 100644 --- a/client/includes/Hooks/UpdateRepoHookHandlers.php +++ b/client/includes/Hooks/UpdateRepoHookHandlers.php @@ -230,6 +230,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnDelete: Failed to inject job: . $e-getMessage() ); } return true; @@ -274,6 +275,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnMove: Failed to inject job: . $e-getMessage() ); } return true; diff --git a/client/includes/UpdateRepo/UpdateRepo.php b/client/includes/UpdateRepo/UpdateRepo.php index 89f158b..ea21694 100644 --- a/client/includes/UpdateRepo/UpdateRepo.php +++ b/client/includes/UpdateRepo/UpdateRepo.php @@ -91,6 +91,13 @@ $this-title-getFullText() ) ); + + if ( $this-entityId === null ) { + wfDebugLog( + 'UpdateRepo', + Couldn't find an item for {$this-title-getFullText()} + ); + } } return $this-entityId; @@ -106,18 +113,33 @@ if ( !class_exists( 'CentralAuthUser' ) ) { // We can't do anything without CentralAuth as there's no way to verify that // the local user equals the repo one with the same name + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : class CentralAuthUser doesn't exist + ); + return false; } $caUser = CentralAuthUser::getInstance( $this-user ); if ( !$caUser || !$caUser-exists() ) { // The current user doesn't have a central account + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : User doesn't have a global account + ); + return false; } if ( !$caUser-isAttached() || !$caUser-attachedOn( $this-repoDB ) ) { // Either the user account on this wiki or the one on the repo do not exist // or they aren't connected + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : User is not attached locally or on {$this-repoDB} + ); + return false; } -- To view, visit https://gerrit.wikimedia.org/r/199596 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic1945d49510f2f9a61423e337a66e1e2391ea3e2 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Hoo man h...@online.de Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: JanZerebecki jan.wikime...@zerebecki.de Gerrit-Reviewer: Thiemo Mättig (WMDE) thiemo.maet...@wikimedia.de Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] labs_vmbuilder: resource attributes quoting - change (operations/puppet)
Andrew Bogott has submitted this change and it was merged. Change subject: labs_vmbuilder: resource attributes quoting .. labs_vmbuilder: resource attributes quoting bug: T91908 Change-Id: Icab204a958f12acb8974e57ec37eb1cd0c58d004 --- M modules/labs_vmbuilder/manifests/init.pp 1 file changed, 8 insertions(+), 8 deletions(-) Approvals: Andrew Bogott: Looks good to me, approved jenkins-bot: Verified diff --git a/modules/labs_vmbuilder/manifests/init.pp b/modules/labs_vmbuilder/manifests/init.pp index d656945..2d6a778 100644 --- a/modules/labs_vmbuilder/manifests/init.pp +++ b/modules/labs_vmbuilder/manifests/init.pp @@ -1,6 +1,6 @@ class labs_vmbuilder($vmbuilder_version) { package { 'python-vm-builder': -ensure = present, +ensure = 'present', } $vmbuilder_filepath = '/etc/vmbuilder/files' @@ -30,7 +30,7 @@ } file { $vmbuilder_filepath: -ensure = directory, +ensure = 'directory', mode = '0555', } @@ -60,34 +60,34 @@ } $projectregex = s/${instanceproject}/_PROJECT_/g -$fqdnregex = s/${::ec2id}.${::domain}/_FQDN_/g -$masterregex = s/${servername}/_MASTER_/g +$fqdnregex= s/${::ec2id}.${::domain}/_FQDN_/g +$masterregex = s/${servername}/_MASTER_/g Exec { path = '/bin' } exec { cp /etc/security/access.conf ${vmbuilder_filepath}/access.conf: -subscribe = File['vmbuilder_version'], +subscribe = File['vmbuilder_version'], } ~ exec { sed -i '${projectregex}' ${vmbuilder_filepath}/access.conf: } exec { cp /etc/nslcd.conf ${vmbuilder_filepath}/nslcd.conf: -subscribe = File['vmbuilder_version'], +subscribe = File['vmbuilder_version'], } ~ exec { sed -i '${projectregex}' ${vmbuilder_filepath}/nslcd.conf: } exec { cp /etc/ldap/ldap.conf ${vmbuilder_filepath}/nss_ldap.conf: -subscribe = File['vmbuilder_version'], +subscribe = File['vmbuilder_version'], } ~ exec { sed -i '${projectregex}' ${vmbuilder_filepath}/nss_ldap.conf: } exec { cp /etc/puppet/puppet.conf ${vmbuilder_filepath}/puppet.conf: -subscribe = File['vmbuilder_version'], +subscribe = File['vmbuilder_version'], } ~ exec { sed -i '${projectregex}' ${vmbuilder_filepath}/puppet.conf: -- To view, visit https://gerrit.wikimedia.org/r/195764 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Icab204a958f12acb8974e57ec37eb1cd0c58d004 Gerrit-PatchSet: 2 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Matanya mata...@foss.co.il Gerrit-Reviewer: Alexandros Kosiaris akosia...@wikimedia.org Gerrit-Reviewer: Andrew Bogott abog...@wikimedia.org Gerrit-Reviewer: Dzahn dz...@wikimedia.org Gerrit-Reviewer: coren mpellet...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] labs_vmbuilder: unquote ensure - change (operations/puppet)
Matanya has uploaded a new change for review. https://gerrit.wikimedia.org/r/199614 Change subject: labs_vmbuilder: unquote ensure .. labs_vmbuilder: unquote ensure Change-Id: Iee2b35eeb47cc041799d0fdbc35c0ee3e6c73049 --- M modules/labs_vmbuilder/manifests/init.pp 1 file changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/14/199614/1 diff --git a/modules/labs_vmbuilder/manifests/init.pp b/modules/labs_vmbuilder/manifests/init.pp index 2d6a778..37f0345 100644 --- a/modules/labs_vmbuilder/manifests/init.pp +++ b/modules/labs_vmbuilder/manifests/init.pp @@ -1,6 +1,6 @@ class labs_vmbuilder($vmbuilder_version) { package { 'python-vm-builder': -ensure = 'present', +ensure = present, } $vmbuilder_filepath = '/etc/vmbuilder/files' @@ -30,7 +30,7 @@ } file { $vmbuilder_filepath: -ensure = 'directory', +ensure = directory, mode = '0555', } -- To view, visit https://gerrit.wikimedia.org/r/199614 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iee2b35eeb47cc041799d0fdbc35c0ee3e6c73049 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Matanya mata...@foss.co.il ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] New model for indentation - change (mediawiki...Flow)
Matthias Mullie has submitted this change and it was merged. Change subject: New model for indentation .. New model for indentation Bug: T88501 Change-Id: I998ffb4f718cfb5ae092378bd032157846773d5d --- M Flow.php M includes/Formatter/AbstractQuery.php M includes/Formatter/RevisionFormatter.php M includes/Repository/MultiGetList.php M includes/Repository/TreeRepository.php M modules/engine/components/board/base/flow-board-interactive-events.js M modules/styles/common.less 7 files changed, 75 insertions(+), 17 deletions(-) Approvals: Mattflaschen: Looks good to me, approved jenkins-bot: Verified diff --git a/Flow.php b/Flow.php index fdc1f25..e57f586 100644 --- a/Flow.php +++ b/Flow.php @@ -227,7 +227,7 @@ $wgFlowOccupyNamespaces = array(); // Max threading depth -$wgFlowMaxThreadingDepth = 3; +$wgFlowMaxThreadingDepth = 8; // A list of editors to use, in priority order $wgFlowEditorList = array( 'none' ); // EXPERIMENTAL prepend 'visualeditor' diff --git a/includes/Formatter/AbstractQuery.php b/includes/Formatter/AbstractQuery.php index ee01887..155d7f2 100644 --- a/includes/Formatter/AbstractQuery.php +++ b/includes/Formatter/AbstractQuery.php @@ -57,6 +57,8 @@ */ protected $currentRevisionsCache = array(); + protected $identityMap = array(); + /** * @param ManagerGroup $storage * @param TreeRepository $treeRepository @@ -110,11 +112,17 @@ // map from post Id to the related root post id $rootPostIds = array_filter( $this-treeRepository-findRoots( $postIds ) ); - $rootPostRequests = array(); foreach( $rootPostIds as $postId ) { $rootPostRequests[] = array( 'rev_type_id' = $postId ); } + + // these tree identity maps are required for determining where a reply goes when + // + // replying to a specific post. + $identityMap = $this-treeRepository-fetchSubtreeIdentityMap( + array_unique( $rootPostIds, SORT_REGULAR ) + ); $rootPostResult = $this-storage-findMulti( 'PostRevision', @@ -175,6 +183,7 @@ $this-postCache = array_merge( $this-postCache, $rootPosts ); $this-rootPostIdCache = array_merge( $this-rootPostIdCache, $rootPostIds ); $this-workflowCache = array_merge( $this-workflowCache, $workflows ); + $this-identityMap = array_merge( $this-identityMap, $identityMap ); } /** @@ -213,9 +222,24 @@ if ( $revision instanceof PostRevision ) { $row-rootPost = $this-getRootPost( $revision ); $revision-setRootPost( $row-rootPost ); + $row-isLastReply = $this-isLastReply( $revision ); } return $row; + } + + protected function isLastReply( PostRevision $revision ) { + if ( $revision-isTopicTitle() ) { + return false; + } + $reply = $revision-getReplyToId()-getAlphadecimal(); + if ( !isset( $this-identityMap[$reply] ) ) { + wfDebugLog( 'Flow', __METHOD__ . : Missing $reply in identity map ); + return false; + } + $parent = $this-identityMap[$revision-getReplyToId()-getAlphadecimal()]; + $keys = array_keys( $parent['children'] ); + return end( $keys ) === $revision-getPostId()-getAlphadecimal(); } /** @@ -364,6 +388,8 @@ public $indexFieldValue; /** @var PostRevision|null */ public $rootPost; + /** @var bool */ + public $isLastReply = false; // protect against typos public function __get( $attribute ) { @@ -375,3 +401,4 @@ throw new \MWException( Accessing non-existent parameter: $attribute ); } } + diff --git a/includes/Formatter/RevisionFormatter.php b/includes/Formatter/RevisionFormatter.php index e64d083..c3861c9 100644 --- a/includes/Formatter/RevisionFormatter.php +++ b/includes/Formatter/RevisionFormatter.php @@ -480,11 +480,20 @@ } /* -* If the post being replied to is at or exceeds the max -* threading depth, the reply link should point to parent. +* If the post being replied to is the most recent post +* of its depth, the reply link should point to parent */ $replyToId = $postId; $replyToRevision = $revision; + if (
[MediaWiki-commits] [Gerrit] Add RDF Munger - change (wikidata...rdf)
jenkins-bot has submitted this change and it was merged. Change subject: Add RDF Munger .. Add RDF Munger Munges RDF - probably not what we need in the end but a good example. Change-Id: I7787a9692e65c727214bf15971f1d4add51bad04 --- M README.md M common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java A common/src/main/java/org/wikidata/query/rdf/common/uri/Ontology.java A tools/src/main/java/org/wikidata/query/rdf/tool/rdf/Munger.java D tools/src/test/java/org/wikidata/query/rdf/tool/DummyUnitTest.java R tools/src/test/java/org/wikidata/query/rdf/tool/rdf/BlazegraphCanaryIntegrationTest.java A tools/src/test/java/org/wikidata/query/rdf/tool/rdf/MungerUnitTest.java 7 files changed, 178 insertions(+), 25 deletions(-) Approvals: Manybubbles: Looks good to me, approved jenkins-bot: Verified diff --git a/README.md b/README.md index f1e042b..6eae4ac 100644 --- a/README.md +++ b/README.md @@ -2,11 +2,39 @@ == Tools for Querying Wikibase instances with RDF. Two modules: -* tools - Tools for syncing a Wikibase instance with an SPARQL 1.1 complian triple store -** Apache Licensed +* tools - Tools for syncing a Wikibase instance with an SPARQL 1.1 compliant triple store + * Apache Licensed * blazegraph - Blazegraph extension to make querying Wikibase instances more efficient -** GPLv2 Licensed + * GPLv2 Licensed +* common - Code shared between tools and blazegraph + * Apache Licensed Development Notes - -* Eclipse - Works well with m2e. +### Eclipse +Works well with m2e. + +### Randomized Testing +Some tests use RandomizedRunner. If they fail you'll get a stack trace containing a seed that looks like this: +``` + at __randomizedtesting.SeedInfo.seed([A4D62887A701F9F1:1BF047C091E0A9C2]:0) +``` +You can reuse that see by adding @Seed to the test class like this: +```java + @RunWith(RandomizedRunner.class) + @Seed(A4D62887A701F9F1:1BF047C091E0A9C2) + public class MungerUnitTest extends RandomizedTest { +``` +Just remember to remove the @Seed annotation before committing the code. + +We use RandomizedRunner because its a good way to cover a ton of testing ground with relatively little code. Its how Lucene consistently finds bugs in the JVM before they're hit in production. + +### Unit and Integration Testing +All tests either end in UnitTest or IntegrationTest. UnitTests are so named because they don't need any external services. IntegrationTests either need to spin up some service like Blazegraph or they need an Internet connection to wikidata.org or test.wikidata.org. + +### Blazegraph +We use Blazegraph for testing SPARQL. You can start it from the command line by running +```bash + cd tools runBlazegraph.sh +``` +It is started automatically during integration testing. diff --git a/common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java b/common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java index 49fcd0a..8ef1cb8 100644 --- a/common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java +++ b/common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java @@ -7,7 +7,7 @@ /** * An EntityData instance for wikidata.org. */ -public static Entity WIKIDATA = new Entity(wikidata.org); +public static EntityData WIKIDATA = new EntityData(wikidata.org); private final String namespace; diff --git a/common/src/main/java/org/wikidata/query/rdf/common/uri/Ontology.java b/common/src/main/java/org/wikidata/query/rdf/common/uri/Ontology.java new file mode 100644 index 000..c681853 --- /dev/null +++ b/common/src/main/java/org/wikidata/query/rdf/common/uri/Ontology.java @@ -0,0 +1,9 @@ +package org.wikidata.query.rdf.common.uri; + +/** + * Marks the kinds of things (items or properties). + */ +public class Ontology { +public static final String NAMESPACE = http://www.wikidata.org/ontology#;; +public static final String ITEM = NAMESPACE + Item; +} diff --git a/tools/src/main/java/org/wikidata/query/rdf/tool/rdf/Munger.java b/tools/src/main/java/org/wikidata/query/rdf/tool/rdf/Munger.java new file mode 100644 index 000..1df7175 --- /dev/null +++ b/tools/src/main/java/org/wikidata/query/rdf/tool/rdf/Munger.java @@ -0,0 +1,83 @@ +package org.wikidata.query.rdf.tool.rdf; + +import java.util.Collection; +import java.util.Iterator; + +import org.openrdf.model.Resource; +import org.openrdf.model.Statement; +import org.openrdf.model.Value; +import org.openrdf.model.impl.StatementImpl; +import org.openrdf.model.impl.URIImpl; +import org.openrdf.model.vocabulary.RDF; +import org.wikidata.query.rdf.common.uri.Entity; +import org.wikidata.query.rdf.common.uri.EntityData; +import org.wikidata.query.rdf.common.uri.Ontology; +import org.wikidata.query.rdf.common.uri.SchemaDotOrg; + +/** + * Munges RDF from Wikibase into a more queryable format. Note that this is + *
[MediaWiki-commits] [Gerrit] swift_new: lint and resource quoting - change (operations/puppet)
Filippo Giunchedi has submitted this change and it was merged. Change subject: swift_new: lint and resource quoting .. swift_new: lint and resource quoting bug: T91908 Change-Id: Icd9b640f98cb4a71d85344ac0ef2586b5eac8904 --- M modules/swift_new/manifests/container_sync.pp M modules/swift_new/manifests/init.pp M modules/swift_new/manifests/monitoring/graphite.pp M modules/swift_new/manifests/mount_filesystem.pp M modules/swift_new/manifests/params.pp M modules/swift_new/manifests/proxy.pp M modules/swift_new/manifests/ring.pp M modules/swift_new/manifests/stats/accounts.pp M modules/swift_new/manifests/storage.pp 9 files changed, 36 insertions(+), 35 deletions(-) Approvals: Andrew Bogott: Looks good to me, but someone else must approve Filippo Giunchedi: Verified; Looks good to me, approved diff --git a/modules/swift_new/manifests/container_sync.pp b/modules/swift_new/manifests/container_sync.pp index f9622f6..e090099 100644 --- a/modules/swift_new/manifests/container_sync.pp +++ b/modules/swift_new/manifests/container_sync.pp @@ -1,6 +1,6 @@ class swift_new::container_sync ( - $replication_accounts = $::swift_new::params::replication_accounts, - $replication_keys = $::swift_new::params::replication_keys, +$replication_accounts = $::swift_new::params::replication_accounts, +$replication_keys = $::swift_new::params::replication_keys, ) { file { '/etc/swift/container-sync-realms.conf': ensure = present, diff --git a/modules/swift_new/manifests/init.pp b/modules/swift_new/manifests/init.pp index 121dbe3..19ba756 100644 --- a/modules/swift_new/manifests/init.pp +++ b/modules/swift_new/manifests/init.pp @@ -39,7 +39,7 @@ 'python-swiftclient', 'parted', ]: -ensure = 'present', +ensure = present, } require_package('python-statsd') @@ -51,7 +51,7 @@ } file { '/etc/swift': -ensure = 'directory', +ensure = directory, require = Package['swift'], recurse = true, } @@ -63,7 +63,7 @@ } file { '/var/cache/swift': -ensure = 'directory', +ensure = directory, require = Package['swift'], mode= '0755', } diff --git a/modules/swift_new/manifests/monitoring/graphite.pp b/modules/swift_new/manifests/monitoring/graphite.pp index 1c875c8..2b7460c 100644 --- a/modules/swift_new/manifests/monitoring/graphite.pp +++ b/modules/swift_new/manifests/monitoring/graphite.pp @@ -8,7 +8,7 @@ warning = 95, critical= 90, under = true, -nagios_critical = false +nagios_critical = false, } monitoring::graphite_threshold { swift_${swift_cluster_dispersion_container}: @@ -18,6 +18,6 @@ warning = 92, critical= 88, under = true, -nagios_critical = false +nagios_critical = false, } } diff --git a/modules/swift_new/manifests/mount_filesystem.pp b/modules/swift_new/manifests/mount_filesystem.pp index 66235f0..c169e35 100644 --- a/modules/swift_new/manifests/mount_filesystem.pp +++ b/modules/swift_new/manifests/mount_filesystem.pp @@ -6,7 +6,7 @@ $mount_point = ${mount_base}/${dev_suffix} file { mountpoint-${mount_point}: -ensure = 'directory', +ensure = directory, path = $mount_point, owner = 'swift', group = 'swift', @@ -19,7 +19,7 @@ # We don't want puppet to keep the FS mounted, otherwise # it would conflict with swift-drive-auditor trying to keep FS # unmounted. -ensure = 'present', +ensure = present, device = LABEL=swift-${dev_suffix}, name = $mount_point, fstype = 'xfs', diff --git a/modules/swift_new/manifests/params.pp b/modules/swift_new/manifests/params.pp index c41c6f7..e8f1ef5 100644 --- a/modules/swift_new/manifests/params.pp +++ b/modules/swift_new/manifests/params.pp @@ -1,10 +1,10 @@ class swift_new::params ( - $swift_cluster = undef, - $accounts = {}, - $account_keys = {}, - $replication_accounts = {}, - $replication_keys = {}, - $graphite_host = 'graphite-in.eqiad.wmnet', +$swift_cluster= undef, +$accounts = {}, +$account_keys = {}, +$replication_accounts = {}, +$replication_keys = {}, +$graphite_host= 'graphite-in.eqiad.wmnet', ) { # Noop class } diff --git a/modules/swift_new/manifests/proxy.pp b/modules/swift_new/manifests/proxy.pp index ff91efe..eee4136 100644 --- a/modules/swift_new/manifests/proxy.pp +++ b/modules/swift_new/manifests/proxy.pp @@ -18,7 +18,7 @@ 'swift-proxy', 'python-swauth', ]: -ensure = 'present', +ensure = present, } file { '/etc/swift/proxy-server.conf': diff --git a/modules/swift_new/manifests/ring.pp
[MediaWiki-commits] [Gerrit] mysql: selector outside a resource + 4 spaces - change (operations/puppet)
Andrew Bogott has submitted this change and it was merged. Change subject: mysql: selector outside a resource + 4 spaces .. mysql: selector outside a resource + 4 spaces Change-Id: I448387252f4650dbb48f1a803bf6498132c18d24 --- M modules/mysql/manifests/server/package.pp 1 file changed, 16 insertions(+), 14 deletions(-) Approvals: Andrew Bogott: Looks good to me, approved Springle: Looks good to me, but someone else must approve jenkins-bot: Verified diff --git a/modules/mysql/manifests/server/package.pp b/modules/mysql/manifests/server/package.pp index 32303cf..253d373 100644 --- a/modules/mysql/manifests/server/package.pp +++ b/modules/mysql/manifests/server/package.pp @@ -1,22 +1,24 @@ # This is handled by a separate class in case we want to just # install the package and configure elsewhere. class mysql::server::package ( - $package_name = $mysql::params::server_package_name, +$package_name = $mysql::params::server_package_name, ) { - if $package_name =~ /mariadb/ { -apt::repository { 'wikimedia-mariadb': - uri= 'http://apt.wikimedia.org/wikimedia', - dist = 'precise-wikimedia', - components = 'mariadb', +if $package_name =~ /mariadb/ { +apt::repository { 'wikimedia-mariadb': +uri= 'http://apt.wikimedia.org/wikimedia', +dist = 'precise-wikimedia', +components = 'mariadb', +} } - } - package { 'mysql-server': -ensure= $package_ensure, -name = $package_name, -require = $package_name ? { - 'mariadb-server-5.5' = Apt::Repository['wikimedia-mariadb'], - default = undef +$package_source = $package_name ? { +'mariadb-server-5.5' = Apt::Repository['wikimedia-mariadb'], +default = undef } - } + +package { 'mysql-server': +ensure= $package_ensure, +name = $package_name, +require = $package_source, +} } -- To view, visit https://gerrit.wikimedia.org/r/195518 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I448387252f4650dbb48f1a803bf6498132c18d24 Gerrit-PatchSet: 2 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Matanya mata...@foss.co.il Gerrit-Reviewer: Alexandros Kosiaris akosia...@wikimedia.org Gerrit-Reviewer: Andrew Bogott abog...@wikimedia.org Gerrit-Reviewer: Dzahn dz...@wikimedia.org Gerrit-Reviewer: Giuseppe Lavagetto glavage...@wikimedia.org Gerrit-Reviewer: Springle sprin...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] BsVisualEditor: Fixed error handling for save button - change (mediawiki...BlueSpiceExtensions)
Pwirth has uploaded a new change for review. https://gerrit.wikimedia.org/r/199611 Change subject: BsVisualEditor: Fixed error handling for save button .. BsVisualEditor: Fixed error handling for save button * Fixed return value and improved processing * Fixed plugin error handling for fail return * Added TODO's - This shloud be an API call anyway Change-Id: Ia6335ae0a3faee3fcaca9a8c6e7633a6daa48023 --- M VisualEditor/VisualEditor.class.php M VisualEditor/resources/tiny_mce_plugins/bsactions/plugin.js 2 files changed, 43 insertions(+), 24 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceExtensions refs/changes/11/199611/1 diff --git a/VisualEditor/VisualEditor.class.php b/VisualEditor/VisualEditor.class.php index 792ff58..7fcc8aa 100644 --- a/VisualEditor/VisualEditor.class.php +++ b/VisualEditor/VisualEditor.class.php @@ -438,14 +438,24 @@ } /** -* +* PW(25.03.2015) TODO: Use API * @global User $wgUser * @global Language $wgLang * @return string */ public static function doSaveArticle() { - if (BsCore::checkAccessAdmission('read') === false) - return true; + $aResult = $aOutput = array( + 'saveresult' = 'fail', + 'message' = '', + 'edittime' = '', + 'summary' = '', + 'starttime' = wfTimestamp(TS_MW, time() + 2), + ); + if (BsCore::checkAccessAdmission('read') === false) { + $aResult['message'] = wfMessage( 'bs-permissionerror' )-plain(); + return FormatJson::encode( $aResult ); + } + global $wgLang, $wgRequest; $sArticleId = $wgRequest-getInt('articleId', 0); $sText = $wgRequest-getVal('text', ''); @@ -458,37 +468,36 @@ $sSummary = '/* '.wfMessage( 'bs-visualeditor-no-summary' )-plain().' */'; } - $oArticle = Article::newFromID($sArticleId); - if ( $oArticle === null ) { - $oArticle = new Article(Title::newFromText($sPageName)); + //PW(25.03.2015) TODO: Use Wikipage + $oArticle = Article::newFromID( $sArticleId ); + if( is_null($oArticle) ) { + $oTitle = Title::newFromText( $sPageName ); + if( is_null($oTitle) || !$oTitle-exists() ) { + $aResult['message'] = wfMessage( 'badtitle' )-plain(); + return FormatJson::encode( $aResult ); + } + $oArticle = new Article( $oTitle ); } if ($iSection) { $sText = $oArticle-replaceSection($iSection, $sText); } + //PW(25.03.2015) TODO: Deprecated since MW 1.21 use + //Wikipage::doEditContent instead $oSaveResult = $oArticle-doEdit($sText, $sSummary); - $sTime = $wgLang-timeanddate($sReturnEditTime, true); - $sMessage = ''; - $sResult = ''; - if (empty($oSaveResult-errors)) { - $sResult = 'ok'; - $sMessage = wfMessage( 'bs-visualeditor-save-message', $sTime, $sSummary )-plain(); + if( $oSaveResult-isGood() ) { + $sTime = $wgLang-timeanddate($sReturnEditTime, true); + $aResult['edittime'] = $sReturnEditTime; + $aResult['saveresult'] = 'ok'; + $aResult['message'] = wfMessage( 'bs-visualeditor-save-message', $sTime, $sSummary )-plain(); + $aResult['summary'] = $sSummary; } else { - $sResult = 'fail'; - $sMessage = $oSaveResult-getMessage(); + $aResult['message'] = $oSaveResult-getMessage()-plain(); } - $aOutput = array( - 'saveresult' = $sResult, //$oSaveResult-getMessage(),//$sSaveResultCode, - 'message' = $sMessage, //wfMessage( 'bs-visualeditor-save-message', $sTime, $sSummary )-plain(), - 'edittime' = $sReturnEditTime, - 'summary' = $sSummary, - 'starttime' = wfTimestamp(TS_MW, time() + 2) - ); - - return FormatJson::encode($aOutput); + return FormatJson::encode( $aResult ); } public static function checkLinks($links) { diff --git a/VisualEditor/resources/tiny_mce_plugins/bsactions/plugin.js b/VisualEditor/resources/tiny_mce_plugins/bsactions/plugin.js index ebdd429..9f6a1c7 100644 ---
[MediaWiki-commits] [Gerrit] Fix isset() check in PhpDateTimeParser - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Fix isset() check in PhpDateTimeParser .. Fix isset() check in PhpDateTimeParser Bug: T93836 Change-Id: Ibe203d0b584ec43a79525db5f5c11448351a62dd (cherry picked from commit 13ecc63c3feae2708a758a9464dd87431a591809) --- M lib/includes/parsers/PhpDateTimeParser.php M lib/tests/phpunit/parsers/PhpDateTimeParserTest.php 2 files changed, 4 insertions(+), 1 deletion(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/lib/includes/parsers/PhpDateTimeParser.php b/lib/includes/parsers/PhpDateTimeParser.php index 986da80..3c02785 100644 --- a/lib/includes/parsers/PhpDateTimeParser.php +++ b/lib/includes/parsers/PhpDateTimeParser.php @@ -172,7 +172,7 @@ } } - if ( !isset( $matches ) ) { + if ( !isset( $matches[1] ) ) { return null; } diff --git a/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php b/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php index ad63be6..0f9f825 100644 --- a/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php +++ b/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php @@ -137,6 +137,8 @@ array( '+0111-07-04T00:00:00Z' ), '4th July 1' = array( '+0001-07-04T00:00:00Z' ), + '12.Jun.10x' = + array( '+0010-06-12T00:00:00Z' ), // More than 4 digit years '4th July 1' = @@ -265,6 +267,7 @@ '1980+3', '1980+x', 'x', + 'x x x', 'zz', 'America/New_York' ); -- To view, visit https://gerrit.wikimedia.org/r/199612 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ibe203d0b584ec43a79525db5f5c11448351a62dd Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Aude aude.w...@gmail.com Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: Thiemo Mättig (WMDE) thiemo.maet...@wikimedia.de Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix isset() check in PhpDateTimeParser - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/199612 Change subject: Fix isset() check in PhpDateTimeParser .. Fix isset() check in PhpDateTimeParser Bug: T93836 Change-Id: Ibe203d0b584ec43a79525db5f5c11448351a62dd (cherry picked from commit 13ecc63c3feae2708a758a9464dd87431a591809) --- M lib/includes/parsers/PhpDateTimeParser.php M lib/tests/phpunit/parsers/PhpDateTimeParserTest.php 2 files changed, 4 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/12/199612/1 diff --git a/lib/includes/parsers/PhpDateTimeParser.php b/lib/includes/parsers/PhpDateTimeParser.php index 986da80..3c02785 100644 --- a/lib/includes/parsers/PhpDateTimeParser.php +++ b/lib/includes/parsers/PhpDateTimeParser.php @@ -172,7 +172,7 @@ } } - if ( !isset( $matches ) ) { + if ( !isset( $matches[1] ) ) { return null; } diff --git a/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php b/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php index ad63be6..0f9f825 100644 --- a/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php +++ b/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php @@ -137,6 +137,8 @@ array( '+0111-07-04T00:00:00Z' ), '4th July 1' = array( '+0001-07-04T00:00:00Z' ), + '12.Jun.10x' = + array( '+0010-06-12T00:00:00Z' ), // More than 4 digit years '4th July 1' = @@ -265,6 +267,7 @@ '1980+3', '1980+x', 'x', + 'x x x', 'zz', 'America/New_York' ); -- To view, visit https://gerrit.wikimedia.org/r/199612 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ibe203d0b584ec43a79525db5f5c11448351a62dd Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Aude aude.w...@gmail.com Gerrit-Reviewer: Thiemo Mättig (WMDE) thiemo.maet...@wikimedia.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Increase length of *_wiki fields to 64 - change (mediawiki...Flow)
jenkins-bot has submitted this change and it was merged. Change subject: Increase length of *_wiki fields to 64 .. Increase length of *_wiki fields to 64 This fixes a Jenkins failure. Also, until this is deployed to WMF production, we can't deploy to any wikis with a DB name longer than 16 characters. Bug: T93463 Change-Id: I5e30d72dcade9e13703bab06e3756944c5314b56 --- M Hooks.php A db_patches/patch-increase_width_wiki_fields.sql M flow.sql 3 files changed, 20 insertions(+), 6 deletions(-) Approvals: Matthias Mullie: Looks good to me, approved jenkins-bot: Verified diff --git a/Hooks.php b/Hooks.php index 43080da..de4af73 100644 --- a/Hooks.php +++ b/Hooks.php @@ -134,6 +134,9 @@ $updater-modifyExtensionField( 'flow_workflow', 'workflow_id', $dir/db_patches/patch-88bit_uuids.sql ); $updater-addExtensionField( 'flow_workflow', 'workflow_type', $dir/db_patches/patch-add_workflow_type.sql ); $updater-modifyExtensionField( 'flow_workflow', 'workflow_user_id', $dir/db_patches/patch-default_null_workflow_user.sql ); + + // Doesn't need SQLite support, since SQLite doesn't care about text widths. + $updater-modifyExtensionField( 'flow_workflow', 'workflow_wiki', $dir/db_patches/patch-increase_width_wiki_fields.sql ); } $updater-addExtensionIndex( 'flow_workflow', 'flow_workflow_lookup', $dir/db_patches/patch-workflow_lookup_idx.sql ); diff --git a/db_patches/patch-increase_width_wiki_fields.sql b/db_patches/patch-increase_width_wiki_fields.sql new file mode 100644 index 000..9b0d499 --- /dev/null +++ b/db_patches/patch-increase_width_wiki_fields.sql @@ -0,0 +1,11 @@ +-- This patch doesn't need to be SQLite compatible (or re-implemented +-- for SQLite) since SQLite doesn't care about column widths anyway. +ALTER TABLE /*_*/flow_workflow MODIFY workflow_wiki varchar(64) binary not null; + +ALTER TABLE /*_*/flow_subscription MODIFY subscription_user_wiki varchar(64) binary not null; + +ALTER TABLE /*_*/flow_tree_revision MODIFY tree_orig_user_wiki varchar(64) binary not null; + +ALTER TABLE /*_*/flow_revision MODIFY rev_user_wiki varchar(64) binary not null, + MODIFY rev_mod_user_wiki varchar(64) binary default null, + MODIFY rev_edit_user_wiki varchar(64) binary default null; diff --git a/flow.sql b/flow.sql index f6e32cc..2ba529e 100644 --- a/flow.sql +++ b/flow.sql @@ -3,7 +3,7 @@ CREATE TABLE /*_*/flow_workflow ( workflow_id binary(11) not null, - workflow_wiki varchar(16) binary not null, + workflow_wiki varchar(64) binary not null, workflow_namespace int not null, workflow_page_id int unsigned not null, workflow_title_text varchar(255) binary not null, @@ -21,7 +21,7 @@ CREATE TABLE /*_*/flow_subscription ( subscription_workflow_id int unsigned not null, subscription_user_id bigint unsigned not null, - subscription_user_wiki varchar(32) binary not null, + subscription_user_wiki varchar(64) binary not null, subscription_create_timestamp varchar(14) binary not null, subscription_last_updated varchar(14) binary not null ) /*$wgDBTableOptions*/; @@ -48,7 +48,7 @@ -- denormalized so we don't need to keep finding the first revision of a post tree_orig_user_id bigint unsigned not null, tree_orig_user_ip varbinary(39) default null, - tree_orig_user_wiki varchar(32) binary not null, + tree_orig_user_wiki varchar(64) binary not null, -- denormalize post parent as well? Prevents an extra query when building -- tree from closure table. unnecessary? tree_parent_id binary(11), @@ -84,7 +84,7 @@ -- user id creating the revision rev_user_id bigint unsigned not null, rev_user_ip varbinary(39) default null, - rev_user_wiki varchar(32) binary not null, + rev_user_wiki varchar(64) binary not null, -- rev_id of parent or null if no previous revision rev_parent_id binary(11) null, -- comma separated set of ascii flags. @@ -99,7 +99,7 @@ -- moderated by who? rev_mod_user_id bigint unsigned, rev_mod_user_ip varbinary(39) default null, - rev_mod_user_wiki varchar(32) binary default null, + rev_mod_user_wiki varchar(64) binary default null, rev_mod_timestamp varchar(14) binary, -- moderated why? (coming soon: how?, where? and what?) rev_mod_reason varchar(255) binary, @@ -108,7 +108,7 @@ rev_last_edit_id binary(11) null, rev_edit_user_id bigint unsigned, rev_edit_user_ip varbinary(39) default null, - rev_edit_user_wiki varchar(32) binary default null, + rev_edit_user_wiki varchar(64) binary default null, rev_content_length int not null default
[MediaWiki-commits] [Gerrit] dispatchChanges: Don't use FOR UPDATE for selecting a client - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: dispatchChanges: Don't use FOR UPDATE for selecting a client .. dispatchChanges: Don't use FOR UPDATE for selecting a client Also make the randomness parameter actually work and increase the default value. In production the value should be even higher. Change-Id: Ie7d68953be5c680c964d12a4943d72886407d9ad --- M lib/maintenance/dispatchChanges.php 1 file changed, 3 insertions(+), 3 deletions(-) Approvals: Thiemo Mättig (WMDE): Looks good to me, approved jenkins-bot: Verified diff --git a/lib/maintenance/dispatchChanges.php b/lib/maintenance/dispatchChanges.php index 8b99b38..794e2b2 100644 --- a/lib/maintenance/dispatchChanges.php +++ b/lib/maintenance/dispatchChanges.php @@ -98,7 +98,7 @@ * causes a completely random selection of the target, regardless of when it * was last selected for dispatch. */ - protected $randomness = 5; + protected $randomness = 10; /** * @var bool: whether output should be version. @@ -119,7 +119,7 @@ $this-addOption( 'lock-grace-interval', Seconds after wich to probe for orphaned locks. . Default: 60, false, true ); $this-addOption( 'randomness', Number of least current target wikis to pick from at random. - . Default: 5., false, true ); + . Default: 10., false, true ); $this-addOption( 'max-passes', The number of passes to perform. . Default: 1 if --max-time is not set, infinite if it is., false, true ); $this-addOption( 'max-time', The number of seconds to run before exiting, @@ -146,6 +146,7 @@ $this-delay = intval( $this-getOption( 'idle-delay', 10 ) ); $this-dispatchInterval = intval( $this-getOption( 'dispatch-interval', 60 ) ); $this-lockGraceInterval = intval( $this-getOption( 'lock-grace-interval', 60 ) ); + $this-randomness = intval( $this-getOption( 'randomness', $this-randomness ) ); $this-verbose = $this-getOption( 'verbose', false ); @@ -419,7 +420,6 @@ __METHOD__, array( 'ORDER BY' = 'chd_seen ASC', - 'FOR UPDATE', 'LIMIT' = (int)$this-randomness ) ); -- To view, visit https://gerrit.wikimedia.org/r/199592 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ie7d68953be5c680c964d12a4943d72886407d9ad Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Hoo man h...@online.de Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: Daniel Kinzler daniel.kinz...@wikimedia.de Gerrit-Reviewer: Thiemo Mättig (WMDE) thiemo.maet...@wikimedia.de Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] labs_vmbuilder: unquote ensure - change (operations/puppet)
Andrew Bogott has submitted this change and it was merged. Change subject: labs_vmbuilder: unquote ensure .. labs_vmbuilder: unquote ensure Change-Id: Iee2b35eeb47cc041799d0fdbc35c0ee3e6c73049 --- M modules/labs_vmbuilder/manifests/init.pp 1 file changed, 2 insertions(+), 2 deletions(-) Approvals: Andrew Bogott: Looks good to me, approved jenkins-bot: Verified diff --git a/modules/labs_vmbuilder/manifests/init.pp b/modules/labs_vmbuilder/manifests/init.pp index 2d6a778..37f0345 100644 --- a/modules/labs_vmbuilder/manifests/init.pp +++ b/modules/labs_vmbuilder/manifests/init.pp @@ -1,6 +1,6 @@ class labs_vmbuilder($vmbuilder_version) { package { 'python-vm-builder': -ensure = 'present', +ensure = present, } $vmbuilder_filepath = '/etc/vmbuilder/files' @@ -30,7 +30,7 @@ } file { $vmbuilder_filepath: -ensure = 'directory', +ensure = directory, mode = '0555', } -- To view, visit https://gerrit.wikimedia.org/r/199614 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Iee2b35eeb47cc041799d0fdbc35c0ee3e6c73049 Gerrit-PatchSet: 2 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Matanya mata...@foss.co.il Gerrit-Reviewer: Andrew Bogott abog...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] zuul: lint - change (operations/puppet)
Andrew Bogott has submitted this change and it was merged. Change subject: zuul: lint .. zuul: lint Change-Id: I1d90efb518ecb250304cb77bba9ad706a5d7c1a0 --- M modules/zuul/manifests/init.pp M modules/zuul/manifests/merger.pp M modules/zuul/manifests/server.pp 3 files changed, 72 insertions(+), 81 deletions(-) Approvals: Andrew Bogott: Looks good to me, approved Hashar: Checked; Looks good to me, but someone else must approve jenkins-bot: Verified Dzahn: Looks good to me, but someone else must approve diff --git a/modules/zuul/manifests/init.pp b/modules/zuul/manifests/init.pp index ef13ecc..3e3de0d 100644 --- a/modules/zuul/manifests/init.pp +++ b/modules/zuul/manifests/init.pp @@ -17,82 +17,80 @@ # class zuul ( $git_source_repo = 'https://gerrit.wikimedia.org/r/p/integration/zuul.git', -) { +){ - include zuul::user +include zuul::user - # Dependencies as mentionned in zuul:tools/pip-requires - $packages = [ -'python-yaml', -'python-webob', -'python-daemon', -'python-lockfile', -'python-paramiko', -'python-jenkins', -'python-paste', +# Dependencies as mentionned in zuul:tools/pip-requires +$packages = [ +'python-yaml', +'python-webob', +'python-daemon', +'python-lockfile', +'python-paramiko', +'python-jenkins', +'python-paste', -# GitPython at least 0.3.2RC1 which is neither in Lucid nor in Precise -# We had to backport it and its dependencies from Quantal: -'python-git', -'python-gitdb', -'python-async', -'python-smmap', +# GitPython at least 0.3.2RC1 which is neither in Lucid nor in Precise +# We had to backport it and its dependencies from Quantal: +'python-git', +'python-gitdb', +'python-async', +'python-smmap', -'python-extras', # backported in Precise (bug 47122) +'python-extras', # backported in Precise (bug 47122) -'python-pip', -'python-setuptools', -'python-voluptuous', +'python-pip', +'python-setuptools', +'python-voluptuous', -# For Zuul post v1.3.0 -'python-pbr', -'python-gear', -'python-apscheduler', +# For Zuul post v1.3.0 +'python-pbr', +'python-gear', +'python-apscheduler', -'python-babel', -'python-prettytable', - ] +'python-babel', +'python-prettytable', +] - require_package('python-statsd') - ensure_packages($packages) +require_package('python-statsd') +ensure_packages($packages) - # Used to be in /var/lib/git/zuul but /var/lib/git can be used - # to replicate git bare repositories. - $zuul_source_dir = '/usr/local/src/zuul' +# Used to be in /var/lib/git/zuul but /var/lib/git can be used +# to replicate git bare repositories. +$zuul_source_dir = '/usr/local/src/zuul' - git::clone { 'integration/zuul': -ensure= present, -directory = $zuul_source_dir, -origin= $git_source_repo, -branch= 'master', - } +git::clone { 'integration/zuul': +ensure= present, +directory = $zuul_source_dir, +origin= $git_source_repo, +branch= 'master', +} - exec { 'install_zuul': -# Make sure to install without downloading from pypi -command = 'python setup.py install', -environment = 'HTTP_PROXY=. HTTPS_PROXY=.', -cwd = $zuul_source_dir, -path= '/bin:/usr/bin', -umask = 022, -refreshonly = true, -subscribe = Git::Clone['integration/zuul'], -require = [ - Package[$packages], -], - } +exec { 'install_zuul': +# Make sure to install without downloading from pypi +command = 'python setup.py install', +environment = 'HTTP_PROXY=. HTTPS_PROXY=.', +cwd = $zuul_source_dir, +path= '/bin:/usr/bin', +umask = '022', +refreshonly = true, +subscribe = Git::Clone['integration/zuul'], +require = Package[$packages], +} - file { '/etc/zuul': -ensure = directory, - } +file { '/etc/zuul': +ensure = directory, +} - file { '/var/log/zuul': -ensure = directory, -owner = 'zuul', - } +file { '/var/log/zuul': +ensure = directory, +owner = 'zuul', +} - file { '/var/lib/zuul': -ensure = directory, -owner = 'zuul', - } +file { '/var/lib/zuul': +ensure = directory, +owner = 'zuul', +} } diff --git a/modules/zuul/manifests/merger.pp b/modules/zuul/manifests/merger.pp index 14dd490..7d2b565 100644 --- a/modules/zuul/manifests/merger.pp +++ b/modules/zuul/manifests/merger.pp @@ -21,11 +21,11 @@ $gerrit_user, $url_pattern, $gerrit_baseurl = 'https://gerrit.wikimedia.org/r', -$git_dir = '/var/lib/zuul/git', -$git_email =
[MediaWiki-commits] [Gerrit] backup: resource attributes quoting - change (operations/puppet)
Andrew Bogott has submitted this change and it was merged. Change subject: backup: resource attributes quoting .. backup: resource attributes quoting bug: T91908 Change-Id: I0729bcceb71322b99e33b7ed4af2af9d7c10a46f --- M modules/backup/manifests/mysqlset.pp M modules/backup/manifests/set.pp 2 files changed, 13 insertions(+), 12 deletions(-) Approvals: Andrew Bogott: Looks good to me, approved jenkins-bot: Verified Dzahn: Looks good to me, but someone else must approve diff --git a/modules/backup/manifests/mysqlset.pp b/modules/backup/manifests/mysqlset.pp index 8f412e8..2b8f02a 100644 --- a/modules/backup/manifests/mysqlset.pp +++ b/modules/backup/manifests/mysqlset.pp @@ -1,12 +1,13 @@ -define backup::mysqlset($method='bpipe', -$xtrabackup=true, -$per_db=false, -$innodb_only=false, -$local_dump_dir=undef, -$password_file=undef, -$mysql_binary=undef, -$mysqldump_binary=undef, -$jobdefaults=$role::backup::host::jobdefaults, +define backup::mysqlset( +$method = 'bpipe', +$xtrabackup = true, +$per_db = false, +$innodb_only = false, +$local_dump_dir = undef, +$password_file= undef, +$mysql_binary = undef, +$mysqldump_binary = undef, +$jobdefaults = $role::backup::host::jobdefaults, ) { $allowed_methods = [ 'bpipe', 'predump' ] @@ -27,7 +28,7 @@ $fileset = mysql-${basefileset} file { '/etc/bacula/scripts/predump': -ensure = 'present', +ensure = present, owner = 'root', group = 'root', mode= '0500', @@ -44,7 +45,7 @@ mysql_binary = $mysql_binary, mysqldump_binary = $mysqldump_binary, } -$extras = undef +$extras = undef $fileset = mysql-${method}-x${xtrabackup}-p${per_db}-i${innodb_only} } diff --git a/modules/backup/manifests/set.pp b/modules/backup/manifests/set.pp index 727bcc7..7a226f9 100644 --- a/modules/backup/manifests/set.pp +++ b/modules/backup/manifests/set.pp @@ -8,7 +8,7 @@ $motd_content = #!/bin/sh\necho \Backed up on this host: ${name}\ @motd::script { backups-${name}: -ensure = 'present', +ensure = present, priority = 06, content = $motd_content, tag = 'backup-motd', -- To view, visit https://gerrit.wikimedia.org/r/195661 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I0729bcceb71322b99e33b7ed4af2af9d7c10a46f Gerrit-PatchSet: 2 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Matanya mata...@foss.co.il Gerrit-Reviewer: Alexandros Kosiaris akosia...@wikimedia.org Gerrit-Reviewer: Andrew Bogott abog...@wikimedia.org Gerrit-Reviewer: ArielGlenn ar...@wikimedia.org Gerrit-Reviewer: Dzahn dz...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] New auto-summary message for SpecialSetLabelDescriptionAliases - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: New auto-summary message for SpecialSetLabelDescriptionAliases .. New auto-summary message for SpecialSetLabelDescriptionAliases Again, this is only one step, more patches are coming. There are a lot of FIXMEs in here, but I would love to fix them in later patches. Please review and merge so we can move forward. If you find actual issues introduced by this patch I will fix them. If you find issues *not* introduced here I will mark them as FIXME if not already done. Ok? Bug: T93853 Change-Id: I66f06792386adddf48e342a7a623e38033bc28ae --- M repo/i18n/en.json M repo/i18n/qqq.json M repo/includes/specials/SpecialSetLabelDescriptionAliases.php 3 files changed, 76 insertions(+), 42 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/repo/i18n/en.json b/repo/i18n/en.json index 416d3d3..2ef6536 100644 --- a/repo/i18n/en.json +++ b/repo/i18n/en.json @@ -341,6 +341,7 @@ wikibase-item-summary-wbsetaliases-add-remove: Added and removed [$2] {{PLURAL:$1|alias|aliases}}, wikibase-item-summary-wbsetaliases-add: Added [$2] {{PLURAL:$1|alias|aliases}}, wikibase-item-summary-wbsetaliases-remove: Removed [$2] {{PLURAL:$1|alias|aliases}}, + wikibase-item-summary-wbsetlabeldescriptionaliases: Changed [$2] label, description and aliases, wikibase-item-summary-wbsetsitelink-add: Added link to [$2], wikibase-item-summary-wbsetsitelink-add-both: Added link with badges to [$2], wikibase-item-summary-wbsetsitelink-set: Changed link to [$2], @@ -393,6 +394,7 @@ wikibase-property-summary-wbsetaliases-add-remove: Added and removed [$2] {{PLURAL:$1|alias|aliases}}, wikibase-property-summary-wbsetaliases-add: Added [$2] {{PLURAL:$1|alias|aliases}}, wikibase-property-summary-wbsetaliases-remove: Removed [$2] {{PLURAL:$1|alias|aliases}}, + wikibase-property-summary-wbsetlabeldescriptionaliases: Changed [$2] label, description and aliases, wikibase-property-summary-wbsetclaim-update: Changed {{PLURAL:$3|claim|claims}}, wikibase-property-summary-wbsetclaim-create: Created {{PLURAL:$3|claim|claims}}, wikibase-property-summary-wbsetclaim-update-qualifiers: Changed {{PLURAL:$4|one qualifier|$4 qualifiers}} of {{PLURAL:$3|claim|claims}}, diff --git a/repo/i18n/qqq.json b/repo/i18n/qqq.json index 8f1178e..248f76d 100644 --- a/repo/i18n/qqq.json +++ b/repo/i18n/qqq.json @@ -363,6 +363,7 @@ wikibase-item-summary-wbsetaliases-add-remove: {{wikibase summary messages|item|Automatic edit summary when adding and removing item aliases. A user can be in edit mode for aliases and can remove one or more aliases, while adding others in the same edit.}}, wikibase-item-summary-wbsetaliases-add: {{wikibase summary messages|item|Automatic edit summary when adding one or more aliases.}}, wikibase-item-summary-wbsetaliases-remove: {{wikibase summary messages|item|Automatic edit summary when a user removes one or more aliases.}}, + wikibase-item-summary-wbsetlabeldescriptionaliases: {{wikibase summary messages|item|Automatic edit summary generated when editing an item label, description and aliases. Example of a full edit summary is \Changed [en] label, description and aliases: Label, Description, Alias 1, Alias 2\.}}, wikibase-item-summary-wbsetsitelink-add: {{wikibase summary messages|sitelinks|Automatic edit summary (autocomment) when adding a language link. Such a summary could appear in English as \Added link to [itwiki]: Italia\.}}, wikibase-item-summary-wbsetsitelink-add-both: {{wikibase summary messages|sitelinks|Automatic edit summary (autocomment) when adding a language link with badges. Such a summary could appear in English as \Added link to [itwiki]: Italia, Q2, Q3\.}}, wikibase-item-summary-wbsetsitelink-set: {{doc-important|Translate this as \Changed link which points to nowiki[$2]/nowiki\.}}\n{{wikibase summary messages|sitelinks|Automatic edit summary (autocomment) when editing a language link. Such a summary could appear in English as \Changed link to [itwiki]: Italia\.}}, @@ -415,6 +416,7 @@ wikibase-property-summary-wbsetaliases-add-remove: Automatic edit summary when adding and removing property aliases. A user can be in edit mode for aliases and can remove one or more aliases, while adding others in the same edit.\n\nParameters:\n* $1 - the number of aliases added/removed\n* $2 - the language code of the item page, wikibase-property-summary-wbsetaliases-add: Automatic edit summary when adding an alias(es) for a property. Parameters:\n* $1 - the number of aliases that were added\n* $2 - the language code for the item page, wikibase-property-summary-wbsetaliases-remove: Automatic edit summary when a user removes one or more aliases
[MediaWiki-commits] [Gerrit] Use specific summary lines in SpecialSetLabelDescriptionAliases - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Use specific summary lines in SpecialSetLabelDescriptionAliases .. Use specific summary lines in SpecialSetLabelDescriptionAliases This simply uses the old messages if only 1 field was changed. The actual change detection is the most simple possible. I think this is enough. Bug: T93853 Change-Id: I6cdbd3e3dd7b1a5b9c4710d544a993b3341d1849 --- M repo/includes/specials/SpecialSetLabelDescriptionAliases.php 1 file changed, 24 insertions(+), 13 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/repo/includes/specials/SpecialSetLabelDescriptionAliases.php b/repo/includes/specials/SpecialSetLabelDescriptionAliases.php index 7936811..d7d2d51 100644 --- a/repo/includes/specials/SpecialSetLabelDescriptionAliases.php +++ b/repo/includes/specials/SpecialSetLabelDescriptionAliases.php @@ -292,10 +292,14 @@ $changeOps = array(); if ( $this-label !== '' ) { - $changeOps['wbsetlabel'] = $changeOpFactory-newSetLabelOp( - $this-languageCode, - $this-label - ); + if ( !$fingerprint-hasLabel( $this-languageCode ) + || $fingerprint-getLabel( $this-languageCode )-getText() !== $this-label + ) { + $changeOps['wbsetlabel'] = $changeOpFactory-newSetLabelOp( + $this-languageCode, + $this-label + ); + } } elseif ( $fingerprint-hasLabel( $this-languageCode ) ) { $changeOps['wbsetlabel'] = $changeOpFactory-newRemoveLabelOp( $this-languageCode @@ -303,10 +307,14 @@ } if ( $this-description !== '' ) { - $changeOps['wbsetdescription'] = $changeOpFactory-newSetDescriptionOp( - $this-languageCode, - $this-description - ); + if ( !$fingerprint-hasDescription( $this-languageCode ) + || $fingerprint-getDescription( $this-languageCode )-getText() !== $this-description + ) { + $changeOps['wbsetdescription'] = $changeOpFactory-newSetDescriptionOp( + $this-languageCode, + $this-description + ); + } } elseif ( $fingerprint-hasDescription( $this-languageCode ) ) { $changeOps['wbsetdescription'] = $changeOpFactory-newRemoveDescriptionOp( $this-languageCode @@ -314,10 +322,14 @@ } if ( !empty( $this-aliases ) ) { - $changeOps['wbsetaliases'] = $changeOpFactory-newSetAliasesOp( - $this-languageCode, - $this-aliases - ); + if ( !$fingerprint-hasAliasGroup( $this-languageCode ) + || $fingerprint-getAliasGroup( $this-languageCode )-getAliases() !== $this-aliases + ) { + $changeOps['wbsetaliases'] = $changeOpFactory-newSetAliasesOp( + $this-languageCode, + $this-aliases + ); + } } elseif ( $fingerprint-hasAliasGroup( $this-languageCode ) ) { $changeOps['wbsetaliases'] = $changeOpFactory-newRemoveAliasesOp( $this-languageCode, @@ -332,7 +344,6 @@ * @return Summary */ private function getSummaryForLabelDescriptionAliases() { - // FIXME: Use the existing messages if only 1 of the 3 fields changed. // FIXME: Introduce more specific messages if only 2 of the 3 fields changed. $summary = new Summary( 'wbsetlabeldescriptionaliases' ); $summary-addAutoSummaryArgs( $this-label, $this-description, $this-aliases ); -- To view, visit https://gerrit.wikimedia.org/r/199608 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I6cdbd3e3dd7b1a5b9c4710d544a993b3341d1849 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Aude aude.w...@gmail.com Gerrit-Reviewer: Addshore addshorew...@gmail.com Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: Thiemo Mättig
[MediaWiki-commits] [Gerrit] Add RdfRepository - change (wikidata...rdf)
jenkins-bot has submitted this change and it was merged. Change subject: Add RdfRepository .. Add RdfRepository Its supports updates. There is an integration test that validates it is sane based on the current data layout. Change-Id: I8392895a3992fa6ae0da04fd0dc104d030e90c4f --- M blazegraph/pom.xml A common/pom.xml A common/src/main/java/org/wikidata/query/rdf/common/uri/Entity.java A common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java A common/src/main/java/org/wikidata/query/rdf/common/uri/RDFS.java A common/src/main/java/org/wikidata/query/rdf/common/uri/SchemaDotOrg.java C common/src/test/java/org/wikidata/query/rdf/common/DummyUnitTest.java M pom.xml M tools/pom.xml A tools/runBlazegraph.sh D tools/src/main/java/org/wikidata/query/rdf/tool/Dummy.java A tools/src/main/java/org/wikidata/query/rdf/tool/rdf/RdfRepository.java A tools/src/main/java/org/wikidata/query/rdf/tool/rdf/UpdateBuilder.java A tools/src/main/resources/logback.xml R tools/src/test/java/org/wikidata/query/rdf/tool/BlazegraphCanaryIntegrationTest.java R tools/src/test/java/org/wikidata/query/rdf/tool/DummyUnitTest.java A tools/src/test/java/org/wikidata/query/rdf/tool/Matchers.java A tools/src/test/java/org/wikidata/query/rdf/tool/StatementHelper.java A tools/src/test/java/org/wikidata/query/rdf/tool/rdf/RdfRepositoryIntegrationTest.java 19 files changed, 670 insertions(+), 38 deletions(-) Approvals: Manybubbles: Looks good to me, approved jenkins-bot: Verified diff --git a/blazegraph/pom.xml b/blazegraph/pom.xml index ac7e688..116a910 100644 --- a/blazegraph/pom.xml +++ b/blazegraph/pom.xml @@ -29,13 +29,6 @@ plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-jar-plugin/artifactId -executions - execution -goals - goaltest-jar/goal -/goals - /execution -/executions /plugin plugin groupIdcom.carrotsearch.randomizedtesting/groupId diff --git a/common/pom.xml b/common/pom.xml new file mode 100644 index 000..1406621 --- /dev/null +++ b/common/pom.xml @@ -0,0 +1,41 @@ +project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; + xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; + modelVersion4.0.0/modelVersion + parent +groupIdorg.wikidata.query.rdf/groupId +artifactIdparent/artifactId +version0.0.1-SNAPSHOT/version + /parent + artifactIdcommon/artifactId + packagingjar/packaging + + nameShared code/name + licenses +license + nameThe Apache Software License, Version 2.0/name + urlhttp://www.apache.org/licenses/LICENSE-2.0.txt/url + distributionrepo/distribution +/license + /licenses + + build +plugins + plugin +groupIdorg.apache.maven.plugins/groupId +artifactIdmaven-jar-plugin/artifactId + /plugin + plugin +groupIdcom.carrotsearch.randomizedtesting/groupId +artifactIdjunit4-maven-plugin/artifactId + /plugin + plugin +groupIdorg.apache.maven.plugins/groupId +artifactIdmaven-source-plugin/artifactId + /plugin + plugin +groupIdorg.apache.maven.plugins/groupId +artifactIdmaven-javadoc-plugin/artifactId + /plugin +/plugins + /build +/project diff --git a/common/src/main/java/org/wikidata/query/rdf/common/uri/Entity.java b/common/src/main/java/org/wikidata/query/rdf/common/uri/Entity.java new file mode 100644 index 000..745751e --- /dev/null +++ b/common/src/main/java/org/wikidata/query/rdf/common/uri/Entity.java @@ -0,0 +1,21 @@ +package org.wikidata.query.rdf.common.uri; + +/** + * Used to prefix entities in Wikibase. + */ +public class Entity { +/** + * An Entity instance for wikidata.org. + */ +public static Entity WIKIDATA = new Entity(wikidata.org); + +private final String namespace; + +public Entity(String host) { +this.namespace = http://www.; + host + /entity/; +} + +public String namespace() { +return namespace; +} +} diff --git a/common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java b/common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java new file mode 100644 index 000..49fcd0a --- /dev/null +++ b/common/src/main/java/org/wikidata/query/rdf/common/uri/EntityData.java @@ -0,0 +1,21 @@ +package org.wikidata.query.rdf.common.uri; + +/** + * Used by Wikibase RDF export to refer to information about the export itself. + */ +public class EntityData { +/** + * An EntityData instance for wikidata.org. + */ +public static Entity WIKIDATA = new Entity(wikidata.org); + +private final String namespace; + +public EntityData(String host) { +this.namespace = http://www.; + host + /wiki/Special:EntityData/; +} + +public String namespace()
[MediaWiki-commits] [Gerrit] nova: lint compute.pp - change (operations/puppet)
Andrew Bogott has submitted this change and it was merged. Change subject: nova: lint compute.pp .. nova: lint compute.pp Change-Id: I217c7bbe3a277a2422966bfd3313990511153730 --- M modules/openstack/manifests/nova/compute.pp 1 file changed, 89 insertions(+), 75 deletions(-) Approvals: Andrew Bogott: Looks good to me, approved jenkins-bot: Verified diff --git a/modules/openstack/manifests/nova/compute.pp b/modules/openstack/manifests/nova/compute.pp index 02b2656..f2e687b 100644 --- a/modules/openstack/manifests/nova/compute.pp +++ b/modules/openstack/manifests/nova/compute.pp @@ -1,117 +1,131 @@ -class openstack::nova::compute($openstack_version=$::openstack::version, $novaconfig) { +class openstack::nova::compute( +$openstack_version=$::openstack::version, +$novaconfig +){ include openstack::repo -if ( $::realm == production ) { +if ( $::realm == 'production' ) { $certname = virt-star.${site}.wmnet install_certificate{ ${certname}: } -file { -/var/lib/nova/${certname}.key: -owner = 'nova', -group = 'libvirtd', -mode= '0440', -source = puppet:///private/ssl/${certname}.key, -require = Package['nova-common']; -/var/lib/nova/clientkey.pem: -ensure = link, -target = /var/lib/nova/${certname}.key; -/var/lib/nova/clientcert.pem: -ensure = link, -target = /etc/ssl/localcerts/${certname}.crt, -require = Install_certificate[${certname}]; -/var/lib/nova/cacert.pem: -ensure = link, -target = /etc/ssl/certs/wmf-ca.pem, -require = Install_certificate[${certname}]; -/var/lib/nova/.ssh: -ensure = directory, -owner = 'nova', -group = 'nova', -mode= '0700', -require = Package[nova-common]; -/var/lib/nova/.ssh/id_rsa: -source = puppet:///private/ssh/nova/nova.key, -owner = 'nova', -group = 'nova', -mode= '0600', -require = File[/var/lib/nova/.ssh]; -/var/lib/nova/.ssh/id_rsa.pub: -source = puppet:///private/ssh/nova/nova.pub, -owner = 'nova', -group = 'nova', -mode= '0600', -require = File[/var/lib/nova/.ssh]; -/etc/libvirt/libvirtd.conf: -notify = Service[libvirt-bin], -owner = 'root', -group = 'root', -mode= '0444', -content = template(openstack/common/nova/libvirtd.conf.erb), -require = Package[nova-common]; -/etc/default/libvirt-bin: -notify = Service[libvirt-bin], -owner = 'root', -group = 'root', -mode= '0444', -content = template(openstack/common/nova/libvirt-bin.default.erb), -require = Package[nova-common]; -/etc/nova/nova-compute.conf: -notify = Service['nova-compute'], -owner = 'root', -group = 'root', -mode= '0444', -content = template(openstack/common/nova/nova-compute.conf.erb), -require = Package[nova-common]; +file { /var/lib/nova/${certname}.key: +owner = 'nova', +group = 'libvirtd', +mode= '0440', +source = puppet:///private/ssl/${certname}.key, +require = Package['nova-common'], +} +file { '/var/lib/nova/clientkey.pem': +ensure = link, +target = /var/lib/nova/${certname}.key, +} +file { '/var/lib/nova/clientcert.pem': +ensure = link, +target = /etc/ssl/localcerts/${certname}.crt, +require = Install_certificate[${certname}], +} +file { '/var/lib/nova/cacert.pem': +ensure = link, +target = '/etc/ssl/certs/wmf-ca.pem', +require = Install_certificate[${certname}], +} +file { '/var/lib/nova/.ssh': +ensure = directory, +owner = 'nova', +group = 'nova', +mode= '0700', +require = Package['nova-common'], +} +file { '/var/lib/nova/.ssh/id_rsa': +source = 'puppet:///private/ssh/nova/nova.key', +owner = 'nova', +group = 'nova', +mode= '0600', +require = File['/var/lib/nova/.ssh'], +} +file { '/var/lib/nova/.ssh/id_rsa.pub': +source =
[MediaWiki-commits] [Gerrit] Remove the User namespace vs Main namespace publishing summary - change (mediawiki...ContentTranslation)
jenkins-bot has submitted this change and it was merged. Change subject: Remove the User namespace vs Main namespace publishing summary .. Remove the User namespace vs Main namespace publishing summary All publishing is at Main namespace now Change-Id: Icbf858b92d0aaa267d5990f7f1f408cc564e4106 --- M i18n/en.json M specials/SpecialContentTranslationStats.php 2 files changed, 0 insertions(+), 27 deletions(-) Approvals: KartikMistry: Looks good to me, approved jenkins-bot: Verified diff --git a/i18n/en.json b/i18n/en.json index 07f0c7e..f799d4e 100644 --- a/i18n/en.json +++ b/i18n/en.json @@ -70,7 +70,6 @@ cx-tools-categories-count-message: {{PLURAL:$1|$1 category|$1 categories|0=No categories}}, cx-stats-title: Content Translation statistics, cx-stats-unknown: unknown, - cx-stats-summary: $1/$2 {{PLURAL:$1|page|pages}} ($3%) in the main namespace in this wiki., cx-tools-reference-title: Reference, cx-tools-reference-remove: Remove reference, cx-tools-link-instruction-shortcut: Shift + click any link to open, diff --git a/specials/SpecialContentTranslationStats.php b/specials/SpecialContentTranslationStats.php index 33f9274..1a91115 100644 --- a/specials/SpecialContentTranslationStats.php +++ b/specials/SpecialContentTranslationStats.php @@ -28,32 +28,6 @@ // @TODO better to return title = stats iterator $stats = ContentTranslation\Stats::getStats(); - $out-addHtml( $this-getPagesSummary( $stats ) ); $out-addModules( 'ext.cx.stats' ); - } - - private function getPagesSummary( $pages ) { - $total = $main = 0; - - foreach ( $pages as $row ) { - $title = Title::newFromRow( $row ); - - $total++; - if ( $title-inNamespace( NS_MAIN ) ) { - $main++; - } - } - - if ( $total 0 ) { - $percentage = round( $main / $total * 100 ); - } else { - $percentage = 0; - } - - $summary = wfMessage( 'cx-stats-summary' ) - -numParams( $main, $total, $percentage ) - -parse(); - - return $summary; } } -- To view, visit https://gerrit.wikimedia.org/r/199603 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Icbf858b92d0aaa267d5990f7f1f408cc564e4106 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/ContentTranslation Gerrit-Branch: master Gerrit-Owner: Santhosh santhosh.thottin...@gmail.com Gerrit-Reviewer: Amire80 amir.ahar...@mail.huji.ac.il Gerrit-Reviewer: KartikMistry kartik.mis...@gmail.com Gerrit-Reviewer: Siebrand siebr...@kitano.nl 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 debug logging to client UpdateRepo code - change (mediawiki...Wikibase)
Hoo man has uploaded a new change for review. https://gerrit.wikimedia.org/r/199613 Change subject: Add debug logging to client UpdateRepo code .. Add debug logging to client UpdateRepo code In order to find the root cause behind T92789 Bug: T92789 Change-Id: Ic1945d49510f2f9a61423e337a66e1e2391ea3e2 --- M client/includes/Hooks/UpdateRepoHookHandlers.php M client/includes/UpdateRepo/UpdateRepo.php 2 files changed, 24 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/13/199613/1 diff --git a/client/includes/Hooks/UpdateRepoHookHandlers.php b/client/includes/Hooks/UpdateRepoHookHandlers.php index ec41526..53dcc5c 100644 --- a/client/includes/Hooks/UpdateRepoHookHandlers.php +++ b/client/includes/Hooks/UpdateRepoHookHandlers.php @@ -230,6 +230,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnDelete: Failed to inject job: . $e-getMessage() ); } return true; @@ -274,6 +275,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnMove: Failed to inject job: . $e-getMessage() ); } return true; diff --git a/client/includes/UpdateRepo/UpdateRepo.php b/client/includes/UpdateRepo/UpdateRepo.php index 89f158b..ea21694 100644 --- a/client/includes/UpdateRepo/UpdateRepo.php +++ b/client/includes/UpdateRepo/UpdateRepo.php @@ -91,6 +91,13 @@ $this-title-getFullText() ) ); + + if ( $this-entityId === null ) { + wfDebugLog( + 'UpdateRepo', + Couldn't find an item for {$this-title-getFullText()} + ); + } } return $this-entityId; @@ -106,18 +113,33 @@ if ( !class_exists( 'CentralAuthUser' ) ) { // We can't do anything without CentralAuth as there's no way to verify that // the local user equals the repo one with the same name + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : class CentralAuthUser doesn't exist + ); + return false; } $caUser = CentralAuthUser::getInstance( $this-user ); if ( !$caUser || !$caUser-exists() ) { // The current user doesn't have a central account + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : User doesn't have a global account + ); + return false; } if ( !$caUser-isAttached() || !$caUser-attachedOn( $this-repoDB ) ) { // Either the user account on this wiki or the one on the repo do not exist // or they aren't connected + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : User is not attached locally or on {$this-repoDB} + ); + return false; } -- To view, visit https://gerrit.wikimedia.org/r/199613 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic1945d49510f2f9a61423e337a66e1e2391ea3e2 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Hoo man h...@online.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] enable OCSP Stapling everywhere - change (operations/puppet)
BBlack has uploaded a new change for review. https://gerrit.wikimedia.org/r/199624 Change subject: enable OCSP Stapling everywhere .. enable OCSP Stapling everywhere Change-Id: Ic2c4c6844cd64f0159e306c2ace89ca0b24dd7bf --- M manifests/role/cache.pp 1 file changed, 2 insertions(+), 18 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/24/199624/1 diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp index b7a1f91..bcc0385 100644 --- a/manifests/role/cache.pp +++ b/manifests/role/cache.pp @@ -654,34 +654,18 @@ include certificates::wmf_ca_2014_2017 include role::protoproxy::ssl::common -# Test OCSP on cp1008 only initially -if $::hostname == 'cp1008' { -$ocsp_test = true -} -else { -$ocsp_test = false -} - localssl { 'unified': certname = 'uni.wikimedia.org', default_server = true, -do_ocsp = $ocsp_test, +do_ocsp = true, } define sni_cert() { -# Test OCSP on cp1008 only initially -if $::hostname == 'cp1008' { -$ocsp_test = true -} -else { -$ocsp_test = false -} - localssl { $name: certname = sni.${name}, server_name = $name, server_aliases = [*.${name}], -do_ocsp = $ocsp_test, +do_ocsp = true, } } -- To view, visit https://gerrit.wikimedia.org/r/199624 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic2c4c6844cd64f0159e306c2ace89ca0b24dd7bf Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: BBlack bbl...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] mediawiki: re-enable monitoring in codfw - change (operations/puppet)
Giuseppe Lavagetto has submitted this change and it was merged. Change subject: mediawiki: re-enable monitoring in codfw .. mediawiki: re-enable monitoring in codfw Change-Id: Ib1dce402e54f1f3e791c9760766048b822c9636a --- M manifests/role/mediawiki.pp 1 file changed, 14 insertions(+), 14 deletions(-) Approvals: Giuseppe Lavagetto: Looks good to me, approved jenkins-bot: Verified diff --git a/manifests/role/mediawiki.pp b/manifests/role/mediawiki.pp index 4bd89e2..8267c7e 100644 --- a/manifests/role/mediawiki.pp +++ b/manifests/role/mediawiki.pp @@ -91,24 +91,24 @@ ensure = present, rule = 'proto tcp dport ssh saddr $DEPLOYMENT_HOSTS ACCEPT;', } -if $::site == 'eqiad' { -monitoring::service { 'appserver http': -description = 'Apache HTTP', -check_command = 'check_http_wikipedia', + +monitoring::service { 'appserver http': +description = 'Apache HTTP', +check_command = 'check_http_wikipedia', +} + +if os_version('ubuntu = trusty') { +monitoring::service { 'appserver_http_hhvm': +description = 'HHVM rendering', +check_command = 'check_http_wikipedia_main', } -if os_version('ubuntu = trusty') { -monitoring::service { 'appserver_http_hhvm': -description = 'HHVM rendering', -check_command = 'check_http_wikipedia_main', -} - -nrpe::monitor_service { 'hhvm': -description = 'HHVM processes', -nrpe_command = '/usr/lib/nagios/plugins/check_procs -c 1: -C hhvm', -} +nrpe::monitor_service { 'hhvm': +description = 'HHVM processes', +nrpe_command = '/usr/lib/nagios/plugins/check_procs -c 1: -C hhvm', } } + } class role::mediawiki::appserver { -- To view, visit https://gerrit.wikimedia.org/r/199606 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ib1dce402e54f1f3e791c9760766048b822c9636a Gerrit-PatchSet: 2 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Giuseppe Lavagetto glavage...@wikimedia.org Gerrit-Reviewer: Giuseppe Lavagetto glavage...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update Wikidata - Bug fixes including for recent changes for... - change (mediawiki/core)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/199619 Change subject: Update Wikidata - Bug fixes including for recent changes formatting .. Update Wikidata - Bug fixes including for recent changes formatting see I6d8e001 for actual changes and details Change-Id: I88d713d58fb658fd17f770a7189260c182ab37d8 --- M extensions/Wikidata 1 file changed, 0 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/19/199619/1 diff --git a/extensions/Wikidata b/extensions/Wikidata index 8a6e0b1..b300848 16 --- a/extensions/Wikidata +++ b/extensions/Wikidata -Subproject commit 8a6e0b11fb4b477336227f60bfbd09d18fb6821a +Subproject commit b3008486ac3c76d9cc3f5fb89c09a8fc92f05da6 -- To view, visit https://gerrit.wikimedia.org/r/199619 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I88d713d58fb658fd17f770a7189260c182ab37d8 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Aude aude.w...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] [WIP] Add test for exporting bibtex - change (mediawiki...citoid)
Mvolz has uploaded a new change for review. https://gerrit.wikimedia.org/r/199623 Change subject: [WIP] Add test for exporting bibtex .. [WIP] Add test for exporting bibtex Change-Id: Ie27289f2cb578e6d7b9e6f3c93d416e9c3c7cbe2 --- A test/features/scraping/export.js M test/utils/assert.js 2 files changed, 36 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/citoid refs/changes/23/199623/1 diff --git a/test/features/scraping/export.js b/test/features/scraping/export.js new file mode 100644 index 000..c467e87 --- /dev/null +++ b/test/features/scraping/export.js @@ -0,0 +1,23 @@ +'use strict'; + + +var preq = require('preq'); +var assert = require('../../utils/assert.js'); +var server = require('../../utils/server.js'); + + +describe('export', function() { + + this.timeout(2); + + before(function () { return server.start(); }); + + it('bibtex', function() { + return server.query('http://example.com', 'bibtex').then(function(res) { + assert.status(res, 200); + assert.checkBibtex(res, '\n@misc{_example_???'); + }); + }); + +}); + diff --git a/test/utils/assert.js b/test/utils/assert.js index a2e7db0..32a218b 100644 --- a/test/utils/assert.js +++ b/test/utils/assert.js @@ -109,6 +109,19 @@ } +function checkSubstring(res, beginning, length) { +var sub, +cit = res.body; + +if (cit instanceof String) { +throw new Error('Expected String, got: ' + JSON.stringify(cit)); +} + +sub = res.body.substring(0, length); + +assert.deepEqual(sub, beginning, Beginning of citation does not match); +} + module.exports.ok = assert.ok; module.exports.fails = fails; -- To view, visit https://gerrit.wikimedia.org/r/199623 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie27289f2cb578e6d7b9e6f3c93d416e9c3c7cbe2 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/services/citoid Gerrit-Branch: master Gerrit-Owner: Mvolz mv...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix transform of video links in pages. - change (apps...wikipedia)
jenkins-bot has submitted this change and it was merged. Change subject: Fix transform of video links in pages. .. Fix transform of video links in pages. The transformation of video links contained a bug that could potentially throw an exception within JS that would stop the page from loading. Example: [[Bill Clinton]] Change-Id: Ic9f617518bbb62e0e28a57bfd210b963cca1a237 --- M wikipedia/assets/bundle.js M wikipedia/assets/preview.js M www/js/transforms.js 3 files changed, 4 insertions(+), 4 deletions(-) Approvals: BearND: Looks good to me, approved jenkins-bot: Verified diff --git a/wikipedia/assets/bundle.js b/wikipedia/assets/bundle.js index 8b85e48..518d05a 100644 --- a/wikipedia/assets/bundle.js +++ b/wikipedia/assets/bundle.js @@ -955,7 +955,7 @@ // since we don't need it. var aTags = mediaDiv.querySelectorAll( 'a' ); if (aTags.length 0) { - aTags[i].parentNode.removeChild(aTags[i]); + aTags[0].parentNode.removeChild(aTags[0]); } var containerLink = document.createElement( 'a' ); containerLink.setAttribute( 'href', imgTags[0].getAttribute( 'alt' ) ); @@ -1280,4 +1280,4 @@ try { module.exports = parseCSSColor } catch(e) { } -},{}]},{},[6,15,7,8,11,12,2,1,4,5,3,10,9,13,14]) +},{}]},{},[6,15,7,8,11,12,2,1,4,5,3,10,9,13,14]) \ No newline at end of file diff --git a/wikipedia/assets/preview.js b/wikipedia/assets/preview.js index c26d9eb..c466d77 100644 --- a/wikipedia/assets/preview.js +++ b/wikipedia/assets/preview.js @@ -594,4 +594,4 @@ try { module.exports = parseCSSColor } catch(e) { } -},{}]},{},[3,2,4,1,5,6,7,8]) +},{}]},{},[3,2,4,1,5,6,7,8]) \ No newline at end of file diff --git a/www/js/transforms.js b/www/js/transforms.js index 01379ba..50b069f 100644 --- a/www/js/transforms.js +++ b/www/js/transforms.js @@ -345,7 +345,7 @@ // since we don't need it. var aTags = mediaDiv.querySelectorAll( 'a' ); if (aTags.length 0) { - aTags[i].parentNode.removeChild(aTags[i]); + aTags[0].parentNode.removeChild(aTags[0]); } var containerLink = document.createElement( 'a' ); containerLink.setAttribute( 'href', imgTags[0].getAttribute( 'alt' ) ); -- To view, visit https://gerrit.wikimedia.org/r/199274 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic9f617518bbb62e0e28a57bfd210b963cca1a237 Gerrit-PatchSet: 2 Gerrit-Project: apps/android/wikipedia Gerrit-Branch: master Gerrit-Owner: Dbrant dbr...@wikimedia.org Gerrit-Reviewer: BearND bsitzm...@wikimedia.org Gerrit-Reviewer: Brion VIBBER br...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 55b23ec..80d8312 - change (mediawiki/extensions)
Jenkins-mwext-sync has uploaded a new change for review. https://gerrit.wikimedia.org/r/199616 Change subject: Syncronize VisualEditor: 55b23ec..80d8312 .. Syncronize VisualEditor: 55b23ec..80d8312 Change-Id: I30cf7e6724a96e237715581c144ff22800695dae --- M VisualEditor 1 file changed, 0 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions refs/changes/16/199616/1 diff --git a/VisualEditor b/VisualEditor index 55b23ec..80d8312 16 --- a/VisualEditor +++ b/VisualEditor -Subproject commit 55b23ec255acc7d50a3b095d19399a97ce1023ab +Subproject commit 80d8312c2841496134e9564f8c1a9a5ec482aedd -- To view, visit https://gerrit.wikimedia.org/r/199616 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I30cf7e6724a96e237715581c144ff22800695dae Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions Gerrit-Branch: master Gerrit-Owner: Jenkins-mwext-sync jenkins-...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update Wikidata - Fix recent changes formatting on wikidata - change (mediawiki...Wikidata)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/199617 Change subject: Update Wikidata - Fix recent changes formatting on wikidata .. Update Wikidata - Fix recent changes formatting on wikidata * also fixes edit summary on SpecialSetLabelDescriptionAliases page * add debug logging to UpdateRepo code * fix php notice in PhpDateTimeParser Change-Id: I6d8e0019e11674ffbe1ca62b337c5f41b61b4e6b --- M composer.json M composer.lock M extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php M extensions/Wikibase/client/includes/UpdateRepo/UpdateRepo.php M extensions/Wikibase/lib/includes/formatters/EntityIdLinkFormatter.php M extensions/Wikibase/lib/includes/parsers/PhpDateTimeParser.php M extensions/Wikibase/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php M extensions/Wikibase/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php M extensions/Wikibase/repo/i18n/en.json M extensions/Wikibase/repo/i18n/qqq.json M extensions/Wikibase/repo/includes/Localizer/MessageParameterFormatter.php M extensions/Wikibase/repo/includes/WikibaseRepo.php M extensions/Wikibase/repo/includes/specials/SpecialSetLabelDescriptionAliases.php M extensions/Wikibase/repo/tests/phpunit/includes/Localizer/MessageParameterFormatterTest.php M vendor/composer/installed.json 15 files changed, 169 insertions(+), 89 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikidata refs/changes/17/199617/1 diff --git a/composer.json b/composer.json index 1c414a4..227596d 100644 --- a/composer.json +++ b/composer.json @@ -5,6 +5,10 @@ repositories: [ { type: vcs, +url: https://git.wikimedia.org/git/mediawiki/extensions/Wikibase.git; + }, + { +type: vcs, url: https://github.com/wmde/Wikidata.org.git; }, { @@ -33,4 +37,4 @@ preferred-install: dist, autoloader-suffix: wikidata_1_25wmf22 } -} \ No newline at end of file +} diff --git a/composer.lock b/composer.lock index 2ab3e90..a0e9c21 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file;, This file is @generated automatically ], -hash: 2c17a6721641ee4dfc829a9a94dc98f5, +hash: 99b3db77c3640ec4fa944bb1517f39d7, packages: [ { name: composer/installers, @@ -1236,14 +1236,8 @@ version: dev-wmf/1.25wmf22, source: { type: git, -url: https://github.com/wikimedia/mediawiki-extensions-Wikibase.git;, -reference: 7d3a0b11d0321ff09fde1b5692599860fea6496c -}, -dist: { -type: zip, -url: https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/7d3a0b11d0321ff09fde1b5692599860fea6496c;, -reference: 7d3a0b11d0321ff09fde1b5692599860fea6496c, -shasum: +url: https://git.wikimedia.org/git/mediawiki/extensions/Wikibase.git;, +reference: c42291f422f391dd14388859caf39857e80a4959 }, require: { data-values/common: ~0.2.0, @@ -1291,7 +1285,6 @@ Wikibase\\Repo\\View\\: repo/includes/View } }, -notification-url: https://packagist.org/downloads/;, license: [ GPL-2.0+ ], @@ -1309,7 +1302,11 @@ wikibaserepo, wikidata ], -time: 2015-03-25 00:03:14 +support: { +issues: https://bugzilla.wikimedia.org/;, +irc: irc://irc.freenode.net/wikidata +}, +time: 2015-03-25 14:50:27 }, { name: wikibase/wikimedia-badges, diff --git a/extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php b/extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php index ec41526..53dcc5c 100644 --- a/extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php +++ b/extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php @@ -230,6 +230,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnDelete: Failed to inject job: . $e-getMessage() ); } return true; @@ -274,6 +275,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnMove: Failed to inject job: .
[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 55b23ec..80d8312 - change (mediawiki/extensions)
Jenkins-mwext-sync has submitted this change and it was merged. Change subject: Syncronize VisualEditor: 55b23ec..80d8312 .. Syncronize VisualEditor: 55b23ec..80d8312 Change-Id: I30cf7e6724a96e237715581c144ff22800695dae --- 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 55b23ec..80d8312 16 --- a/VisualEditor +++ b/VisualEditor -Subproject commit 55b23ec255acc7d50a3b095d19399a97ce1023ab +Subproject commit 80d8312c2841496134e9564f8c1a9a5ec482aedd -- To view, visit https://gerrit.wikimedia.org/r/199616 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I30cf7e6724a96e237715581c144ff22800695dae Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions Gerrit-Branch: master Gerrit-Owner: Jenkins-mwext-sync jenkins-...@wikimedia.org Gerrit-Reviewer: Jenkins-mwext-sync jenkins-...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add unit test for mwAlienExtension node - change (mediawiki...VisualEditor)
jenkins-bot has submitted this change and it was merged. Change subject: Add unit test for mwAlienExtension node .. Add unit test for mwAlienExtension node Change-Id: I0323cf16f103ad801127568afe75e03d90e62c37 --- M modules/ve-mw/tests/dm/ve.dm.mwExample.js 1 file changed, 40 insertions(+), 0 deletions(-) Approvals: Jforrester: Looks good to me, approved jenkins-bot: Verified diff --git a/modules/ve-mw/tests/dm/ve.dm.mwExample.js b/modules/ve-mw/tests/dm/ve.dm.mwExample.js index 190e0de..59b7c1b 100644 --- a/modules/ve-mw/tests/dm/ve.dm.mwExample.js +++ b/modules/ve-mw/tests/dm/ve.dm.mwExample.js @@ -1051,6 +1051,46 @@ { type: '/internalList' } ] }, + 'mw:AlienExtension': { + body: + 'div about=#mwt1 typeof=mw:Extension/syntaxhighlight' + + ' data-mw={quot;namequot;:quot;syntaxhighlightquot;,quot;attrsquot;:{quot;langquot;:quot;phpquot;},quot;bodyquot;:{quot;extsrcquot;:quot;\\n$foo = bar;\\nquot;}}' + + ' data-parsoid=1' + + '' + + 'divspanRendering/span/div' + + '/div', + normalizedBody: + 'div typeof=mw:Extension/syntaxhighlight' + + ' data-mw={quot;namequot;:quot;syntaxhighlightquot;,quot;attrsquot;:{quot;langquot;:quot;php5quot;},quot;bodyquot;:{quot;extsrcquot;:quot;\\n$foo = bar;\\nquot;}}' + + ' about=#mwt1 data-parsoid=1' + + '' + + '/div', + data: [ + { + type: 'mwAlienExtension', + attributes: { + mw: { + name: 'syntaxhighlight', + attrs: { + lang: 'php' + }, + body: { + extsrc: '\n$foo = bar;\n' + } + }, + originalIndex: 0, + originalMw: '{name:syntaxhighlight,attrs:{lang:php},body:{extsrc:\\n$foo = bar;\\n}}' + }, + originalDomElements: $( 'div about=#mwt1 data-parsoid=1/div' ).toArray() + }, + { type: '/mwAlienExtension' }, + { type: 'internalList' }, + { type: '/internalList' } + ], + modify: function ( model ) { + model.data.data[0].attributes.mw.attrs.lang = 'php5'; + } + }, 'mw:Reference': { // Wikitext: // Fooref name=bar / Bazref group=g1 name=:0Quux/ref Wheeref name=bar[[Bar]]/ref Yayref group=g1No name/ref Quuxref name=barDifferent content/ref Fooref group=g1 name=foo / -- To view, visit https://gerrit.wikimedia.org/r/198712 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I0323cf16f103ad801127568afe75e03d90e62c37 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/VisualEditor Gerrit-Branch: master Gerrit-Owner: Esanders esand...@wikimedia.org Gerrit-Reviewer: Catrope roan.katt...@gmail.com Gerrit-Reviewer: Jforrester jforres...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Kill esams dead/non-existent hosts - change (operations/dns)
Faidon Liambotis has submitted this change and it was merged. Change subject: Kill esams dead/non-existent hosts .. Kill esams dead/non-existent hosts A bunch of old hosts do not exist anymore, so kill them from DNS. Change-Id: Ia797e8e003832673172464ff33e65b1482c761fb --- M templates/10.in-addr.arpa M templates/174.198.91.in-addr.arpa M templates/wikimedia.org 3 files changed, 3 insertions(+), 33 deletions(-) Approvals: Faidon Liambotis: Looks good to me, approved jenkins-bot: Verified diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa index 59e7155..4e151d0 100644 --- a/templates/10.in-addr.arpa +++ b/templates/10.in-addr.arpa @@ -211,7 +211,6 @@ 86 1H IN PTR amssq61.mgmt.esams.wmnet. 87 1H IN PTR amssq62.mgmt.esams.wmnet. -100 1H IN PTR yarrow.ipmi.knams.wikimedia.org. 101 1H IN PTR br1-knams.ipmi.knams.wikimedia.org. 102 1H IN PTR csw1-esams.mgmt.esams.wmnet. 104 1H IN PTR asw-esams.mgmt.esams.wmnet. @@ -283,7 +282,6 @@ 213 1H IN PTR ae1-200.cr2-knams.wikimedia.org. 249 1H IN PTR msw-oe12-esams.mgmt.esams.wmnet. -250 1H IN PTR eth1.mint.esams.wikimedia.org. 253 1H IN PTR schleifenbauer.mgmt.esams.wmnet. $ORIGIN {{ zonename }}. diff --git a/templates/174.198.91.in-addr.arpa b/templates/174.198.91.in-addr.arpa index 96ce607..21d7737 100644 --- a/templates/174.198.91.in-addr.arpa +++ b/templates/174.198.91.in-addr.arpa @@ -33,7 +33,6 @@ 107 1H IN PTR slauerhoff-array.esams.wikimedia.org. 108 1H IN PTR slauerhoff.esams.wikimedia.org. 113 1H IN PTR hooft.esams.wikimedia.org. - 121 1H IN PTR eeden.esams.wikimedia.org. 122 1H IN PTR maerlant.esams.wikimedia.org. diff --git a/templates/wikimedia.org b/templates/wikimedia.org index 22abc23..e578852 100644 --- a/templates/wikimedia.org +++ b/templates/wikimedia.org @@ -720,48 +720,21 @@ ; Service aliases puppet 1H IN CNAMEpalladium.eqiad.wmnet. -recursor0 1H IN A91.198.174.6 ; nescio -ntp 1H IN CNAME nescio +recursor0 1H IN A91.198.174.6 ; nescio +ntp 1H IN CNAMEnescio ; Servers maerlant1H IN A91.198.174.122 slauerhoff 1H IN A91.198.174.108 slauerhoff-array1H IN A91.198.174.107 - -; Maps (OSM and others) -tiles 1H IN A91.198.174.8 - -; Servers - -fuchsia 1H IN A91.198.174.120 -hawthorn1H IN A91.198.174.122 hooft 1H IN A91.198.174.113 -1H IN 2620:0:862:1:91:198:174:113 -iris1H IN A91.198.174.124 +1H IN 2620:0:862:1:91:198:174:113 eeden 1H IN A91.198.174.121 - -mint1H IN A91.198.174.119 - nescio 1H IN A91.198.174.106 -ragweed 1H IN A91.198.174.126 -sage1H IN A145.97.39.130 ; Management -fuchsia.ipmi1H IN A10.21.0.4 -hawthorn.ipmi 1H IN A10.21.0.6 -iris.ipmi 1H IN A10.21.0.8 -mint.ipmi 1H IN A10.21.0.3 -ragweed.ipmi1H IN A10.21.0.11 -sage.ipmi 1H IN A10.21.0.10 -vandale.ipmi1H IN A10.21.0.12 -zedler.ipmi 1H IN A10.21.0.13 -zedler-array.ipmi 1H IN A10.21.0.14 -hemlock.ipmi1H IN A10.21.0.15 -nightshade.ipmi 1H IN A10.21.0.46 -willow.ipmi 1H IN A10.21.0.47 -yarrow.ipmi 1H IN A10.21.0.100 br1-knams.ipmi 1H IN A10.21.0.101 scs-oe11-esams 1H IN A10.21.0.102 -- To view, visit https://gerrit.wikimedia.org/r/199287 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ia797e8e003832673172464ff33e65b1482c761fb Gerrit-PatchSet: 3 Gerrit-Project: operations/dns Gerrit-Branch: master Gerrit-Owner: Faidon Liambotis fai...@wikimedia.org Gerrit-Reviewer: Faidon Liambotis fai...@wikimedia.org Gerrit-Reviewer: Mark Bergsma m...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update Wikidata - Bug fixes including for recent changes for... - change (mediawiki/core)
jenkins-bot has submitted this change and it was merged. Change subject: Update Wikidata - Bug fixes including for recent changes formatting .. Update Wikidata - Bug fixes including for recent changes formatting see I6d8e001 for actual changes and details Change-Id: I88d713d58fb658fd17f770a7189260c182ab37d8 --- M extensions/Wikidata 1 file changed, 0 insertions(+), 0 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/extensions/Wikidata b/extensions/Wikidata index 8a6e0b1..b300848 16 --- a/extensions/Wikidata +++ b/extensions/Wikidata -Subproject commit 8a6e0b11fb4b477336227f60bfbd09d18fb6821a +Subproject commit b3008486ac3c76d9cc3f5fb89c09a8fc92f05da6 -- To view, visit https://gerrit.wikimedia.org/r/199619 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I88d713d58fb658fd17f770a7189260c182ab37d8 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Aude aude.w...@gmail.com Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Clean up RDF and Dumpers related code - change (mediawiki...Wikibase)
Thiemo Mättig (WMDE) has uploaded a new change for review. https://gerrit.wikimedia.org/r/199622 Change subject: Clean up RDF and Dumpers related code .. Clean up RDF and Dumpers related code Nothing here should change semantics. This is a pure clean up patch. * Fix some wrong type hints * More specific type hints * Drop some none-descriptive method descriptions * Optimize imports * Split long lines * Code formatting according to style guide Change-Id: If782b9e1e17973f31c5b25f73cb07f59109b042b --- M repo/includes/Dumpers/DumpGenerator.php M repo/includes/Dumpers/JsonDumpGenerator.php M repo/includes/Dumpers/RdfDumpGenerator.php M repo/includes/rdf/BNodeLabeler.php M repo/includes/rdf/N3RdfWriterBase.php M repo/includes/rdf/NTriplesRdfWriter.php M repo/includes/rdf/RdfBuilder.php M repo/includes/rdf/RdfProducer.php M repo/includes/rdf/RdfSerializer.php M repo/includes/rdf/RdfWriterBase.php M repo/includes/rdf/TurtleRdfWriter.php M repo/includes/rdf/UnicodeEscaper.php M repo/includes/rdf/XmlRdfWriter.php M repo/maintenance/dumpRdf.php M repo/tests/phpunit/includes/Dumpers/RdfDumpGeneratorTest.php 15 files changed, 273 insertions(+), 221 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/22/199622/1 diff --git a/repo/includes/Dumpers/DumpGenerator.php b/repo/includes/Dumpers/DumpGenerator.php index 7b75da1..771f58b 100644 --- a/repo/includes/Dumpers/DumpGenerator.php +++ b/repo/includes/Dumpers/DumpGenerator.php @@ -3,8 +3,6 @@ namespace Wikibase\Dumpers; use InvalidArgumentException; -use MWContentSerializationException; -use MWException; use Wikibase\DataModel\Entity\EntityId; use Wikibase\Lib\Reporting\ExceptionHandler; use Wikibase\Lib\Reporting\MessageReporter; @@ -61,6 +59,7 @@ /** * Entity count limit - dump will generate this many +* * @var int */ protected $limit = 0; @@ -83,6 +82,7 @@ /** * Set maximum number of entities produced +* * @param int $limit */ public function setLimit( $limit ) { @@ -174,14 +174,17 @@ * Set the entity type to be included in the output. * * @param string|null $type The desired type (use null for any type). +* * @throws InvalidArgumentException */ public function setEntityTypeFilter( $type ) { $this-entityType = $type; } + private function idMatchesFilters( EntityId $entityId ) { return $this-idMatchesShard( $entityId ) $this-idMatchesType( $entityId ); } + private function idMatchesShard( EntityId $entityId ) { // Shorten out if ( $this-shardingFactor === 1 ) { @@ -258,7 +261,7 @@ $this-progressReporter-reportMessage( 'Processed ' . $dumpCount . ' entities.' ); - if( $this-limit $dumpCount = $this-limit ) { + if ( $this-limit $dumpCount = $this-limit ) { break; } } @@ -268,6 +271,7 @@ /** * Dump list of entities +* * @param EntityId[] $entityIds * @param int $dumpCount The number of entities already dumped (will be updated). */ @@ -288,7 +292,7 @@ $this-postEntityDump( $dumpCount ); $dumpCount ++; - if( $this-limit $dumpCount = $this-limit ) { + if ( $this-limit $dumpCount = $this-limit ) { break; } } catch ( StorageException $ex ) { @@ -303,8 +307,8 @@ * @param EntityId $entityId * * @throws StorageException -* * @return string|null */ abstract protected function generateDumpForEntityId( EntityId $entityId ); + } diff --git a/repo/includes/Dumpers/JsonDumpGenerator.php b/repo/includes/Dumpers/JsonDumpGenerator.php index dd8a3c5..2a35aa7 100644 --- a/repo/includes/Dumpers/JsonDumpGenerator.php +++ b/repo/includes/Dumpers/JsonDumpGenerator.php @@ -157,4 +157,5 @@ public function getJsonFlags() { return $this-jsonFlags; } + } diff --git a/repo/includes/Dumpers/RdfDumpGenerator.php b/repo/includes/Dumpers/RdfDumpGenerator.php index 212a362..28976ca 100644 --- a/repo/includes/Dumpers/RdfDumpGenerator.php +++ b/repo/includes/Dumpers/RdfDumpGenerator.php @@ -2,20 +2,20 @@ namespace Wikibase\Dumpers; +use HashBagOStuff; use InvalidArgumentException; use MWContentSerializationException; use MWException; use SiteList; use Wikibase\DataModel\Entity\EntityId; -use Wikibase\Lib\Serializers\Serializer; +use Wikibase\DataModel\Entity\PropertyDataTypeLookup; use
[MediaWiki-commits] [Gerrit] Resolve redirects when doing prefixsearch. - change (apps...wikipedia)
jenkins-bot has submitted this change and it was merged. Change subject: Resolve redirects when doing prefixsearch. .. Resolve redirects when doing prefixsearch. Our search experience provides the user with prefix-search and full-text search results. However, in the case of prefix-search results, if the result is a Redirect page, it may be more useful to the user to see the *target* of the redirect, rather than the redirect name itself. In addition, the redirect (source) page doesn't come with a thumbnail or pageterms, which is even less useful to the user. This patch enables automatic resolving of redirects for prefix-search, whereby the target of the redirect will be shown, complete with thumbnail and description. This is accomplished in a slightly roundabout way: - The search API allows us to specify redirects=true to automatically resolve redirects. Simple enough... - However, when we receive the results, any result that is a redirect target will no longer have the index property, which we use to sort the results in our list. - However, the query response also contains a separate redirects array that contains a list of all the redirected results, apparently in the correct order. - So first, I take all the results that have an index property, and make a list of the holes in the indices. I then fill the holes with the results that don't have an index property, in the order that they appear in the redirects list! This can be vastly simplified, of course, if the API includes the index property with the redirected results. However, this may be difficult to do on the API side, so this will have to be the solution for now. Change-Id: I65e281fa83071a4dbf288ecdd7d3bf5ee39a0aee --- M wikipedia/src/main/java/org/wikipedia/search/TitleSearchTask.java 1 file changed, 37 insertions(+), 1 deletion(-) Approvals: BearND: Looks good to me, approved Deskana: Looks good to me, but someone else must approve jenkins-bot: Verified diff --git a/wikipedia/src/main/java/org/wikipedia/search/TitleSearchTask.java b/wikipedia/src/main/java/org/wikipedia/search/TitleSearchTask.java index 31f22f2..0bdb3bc 100644 --- a/wikipedia/src/main/java/org/wikipedia/search/TitleSearchTask.java +++ b/wikipedia/src/main/java/org/wikipedia/search/TitleSearchTask.java @@ -33,6 +33,7 @@ public RequestBuilder buildRequest(Api api) { return api.action(query) .param(generator, prefixsearch) +.param(redirects, true) .param(gpssearch, prefix) .param(gpsnamespace, 0) .param(gpslimit, NUM_RESULTS_PER_QUERY) @@ -88,13 +89,48 @@ return new SearchResults(pageTitles, null, suggestion); } +// Collect a list of redirect targets, if available. +// This provides us with the order in which the redirects are listed in the results, +// since the redirected results don't come with an index property. +ArrayListString redirectTargetList = new ArrayList(); +if (queryResult.has(redirects)) { +JSONArray redirs = queryResult.getJSONArray(redirects); +for (int i = 0; i redirs.length(); i++) { +redirectTargetList.add(((JSONObject) redirs.get(i)).getString(to)); +} +} + +// Create a list of indices, which will be claimed by results that have an index. +// Results that are redirects will not have an index, so we will manually place them +// into any indices that are left over. +ArrayListInteger pageIndices = new ArrayList(); +for (int i = 0; i pages.length(); i++) { +pageIndices.add(i + 1); +} + // First, put all the page objects into an array JSONObject[] pageArray = new JSONObject[pages.length()]; int pageIndex = 0; IteratorString pageIter = pages.keys(); while (pageIter.hasNext()) { -pageArray[pageIndex++] = (JSONObject)pages.get(pageIter.next()); +JSONObject page = (JSONObject)pages.get(pageIter.next()); +pageArray[pageIndex++] = page; +if (page.has(index)) { +pageIndices.remove((Integer) page.getInt(index)); +} } +// add an index to any results that didn't have one, in the order that they appear +// in the redirect map. +for (String redirTo : redirectTargetList) { +for (JSONObject page : pageArray) { +if (page.getString(title).equals(redirTo) + !page.has(index) pageIndices.size() 0) { +page.put(index, pageIndices.get(0)); +pageIndices.remove(0); +} +} +} + // now sort the array based on the index property Arrays.sort(pageArray, new ComparatorJSONObject() { @Override -- To view,
[MediaWiki-commits] [Gerrit] Add debug logging to client UpdateRepo code - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Add debug logging to client UpdateRepo code .. Add debug logging to client UpdateRepo code In order to find the root cause behind T92789 Bug: T92789 Change-Id: Ic1945d49510f2f9a61423e337a66e1e2391ea3e2 --- M client/includes/Hooks/UpdateRepoHookHandlers.php M client/includes/UpdateRepo/UpdateRepo.php 2 files changed, 24 insertions(+), 0 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/client/includes/Hooks/UpdateRepoHookHandlers.php b/client/includes/Hooks/UpdateRepoHookHandlers.php index ec41526..53dcc5c 100644 --- a/client/includes/Hooks/UpdateRepoHookHandlers.php +++ b/client/includes/Hooks/UpdateRepoHookHandlers.php @@ -230,6 +230,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnDelete: Failed to inject job: . $e-getMessage() ); } return true; @@ -274,6 +275,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnMove: Failed to inject job: . $e-getMessage() ); } return true; diff --git a/client/includes/UpdateRepo/UpdateRepo.php b/client/includes/UpdateRepo/UpdateRepo.php index 89f158b..ea21694 100644 --- a/client/includes/UpdateRepo/UpdateRepo.php +++ b/client/includes/UpdateRepo/UpdateRepo.php @@ -91,6 +91,13 @@ $this-title-getFullText() ) ); + + if ( $this-entityId === null ) { + wfDebugLog( + 'UpdateRepo', + Couldn't find an item for {$this-title-getFullText()} + ); + } } return $this-entityId; @@ -106,18 +113,33 @@ if ( !class_exists( 'CentralAuthUser' ) ) { // We can't do anything without CentralAuth as there's no way to verify that // the local user equals the repo one with the same name + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : class CentralAuthUser doesn't exist + ); + return false; } $caUser = CentralAuthUser::getInstance( $this-user ); if ( !$caUser || !$caUser-exists() ) { // The current user doesn't have a central account + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : User doesn't have a global account + ); + return false; } if ( !$caUser-isAttached() || !$caUser-attachedOn( $this-repoDB ) ) { // Either the user account on this wiki or the one on the repo do not exist // or they aren't connected + wfDebugLog( + 'UpdateRepo', + Can't validate user . $this-user-getName() . : User is not attached locally or on {$this-repoDB} + ); + return false; } -- To view, visit https://gerrit.wikimedia.org/r/199613 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic1945d49510f2f9a61423e337a66e1e2391ea3e2 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Hoo man h...@online.de Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fallback to read from master in DifferenceEngine::loadRevisi... - change (mediawiki/core)
Hoo man has uploaded a new change for review. https://gerrit.wikimedia.org/r/199620 Change subject: Fallback to read from master in DifferenceEngine::loadRevisionData .. Fallback to read from master in DifferenceEngine::loadRevisionData In DifferenceEngine we need to show a diff immediately after an edit happened if someone did a rollback. To make that work again, try loading a revision from master if we have more than one database servers and we failed loading the revision from a slave. Change-Id: I08a16faa9e637c614c6d2fc9a10536c7b41685a8 Follows: 3c2bc32ae1775f5e875958b62d7181b4b5cfe24e Bug: T93866 --- M includes/diff/DifferenceEngine.php 1 file changed, 6 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/20/199620/1 diff --git a/includes/diff/DifferenceEngine.php b/includes/diff/DifferenceEngine.php index 77bbd36..de8dd43 100644 --- a/includes/diff/DifferenceEngine.php +++ b/includes/diff/DifferenceEngine.php @@ -1233,6 +1233,12 @@ // Load the new revision object if ( $this-mNewid ) { $this-mNewRev = Revision::newFromId( $this-mNewid ); + + if ( !$this-mNewRev wfGetLB()-getServerCount() 1 ) { + // Try harder… This is being hit after a rollback where we show the + // diff immediately after the edit happened. T93866 + $this-mNewRev = Revision::newFromId( $this-mNewid, Revision::READ_LATEST ); + } } else { $this-mNewRev = Revision::newFromTitle( $this-getTitle(), -- To view, visit https://gerrit.wikimedia.org/r/199620 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I08a16faa9e637c614c6d2fc9a10536c7b41685a8 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Hoo man h...@online.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Move duplicate code to UsageAccumulator classes - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Move duplicate code to UsageAccumulator classes .. Move duplicate code to UsageAccumulator classes This patch does not finally solve the problem of duplicate code. It moves the code to a place where it fits better, in my opinion. There will be an othe rpatchj on top of this. Change-Id: I9107b2701a958c89b46005f63caf19e0bd7e4a24 --- M client/includes/DataAccess/StatementTransclusionInteractor.php M client/includes/Usage/HashUsageAccumulator.php M client/includes/Usage/ParserOutputUsageAccumulator.php M client/includes/Usage/UsageAccumulator.php M client/includes/scribunto/SnakSerializationRenderer.php M client/tests/phpunit/includes/DataAccess/PropertyParserFunction/LanguageAwareRendererTest.php M client/tests/phpunit/includes/DataAccess/StatementTransclusionInteractorTest.php M client/tests/phpunit/includes/Usage/HashUsageAccumulatorTest.php M client/tests/phpunit/includes/Usage/UsageAccumulatorContractTester.php 9 files changed, 121 insertions(+), 134 deletions(-) Approvals: Hoo man: Looks good to me, approved jenkins-bot: Verified Objections: Daniel Kinzler: There's a problem with this change, please improve diff --git a/client/includes/DataAccess/StatementTransclusionInteractor.php b/client/includes/DataAccess/StatementTransclusionInteractor.php index ab134f4..0008c07 100644 --- a/client/includes/DataAccess/StatementTransclusionInteractor.php +++ b/client/includes/DataAccess/StatementTransclusionInteractor.php @@ -4,11 +4,7 @@ use Language; use Wikibase\Client\Usage\UsageAccumulator; -use Wikibase\DataAccess\PropertyIdResolver; -use Wikibase\DataAccess\SnaksFinder; use Wikibase\DataModel\Entity\EntityId; -use Wikibase\DataModel\Entity\EntityIdValue; -use Wikibase\DataModel\Snak\PropertyValueSnak; use Wikibase\DataModel\Snak\Snak; use Wikibase\DataModel\StatementListProvider; use Wikibase\Lib\PropertyLabelNotResolvedException; @@ -81,7 +77,12 @@ * @throws PropertyLabelNotResolvedException * @return string */ - public function render( EntityId $entityId, UsageAccumulator $usageAccumulator, $propertyLabelOrId, $acceptableRanks = null ) { + public function render( + EntityId $entityId, + UsageAccumulator $usageAccumulator, + $propertyLabelOrId, + $acceptableRanks = null + ) { $entity = $this-entityLookup-getEntity( $entityId ); if ( !$entity instanceof StatementListProvider ) { @@ -98,7 +99,8 @@ $propertyId, $acceptableRanks ); - $this-trackUsage( $snaks, $usageAccumulator ); + + $usageAccumulator-addLabelUsageForSnaks( $snaks ); return $this-formatSnaks( $snaks ); } @@ -116,28 +118,6 @@ } return $this-language-commaList( $formattedValues ); - } - - /** -* @param Snak[] $snaks -* @param UsageAccumulator $usageAccumulator -*/ - private function trackUsage( array $snaks, UsageAccumulator $usageAccumulator ) { - // Note: we track any EntityIdValue as a label usage. - // This is making assumptions about what the respective formatter actually does. - // Ideally, the formatter itself would perform the tracking, but that seems nasty to model. - - foreach ( $snaks as $snak ) { - if ( !( $snak instanceof PropertyValueSnak) ) { - continue; - } - - $value = $snak-getDataValue(); - - if ( $value instanceof EntityIdValue ) { - $usageAccumulator-addLabelUsage( $value-getEntityId() ); - } - } } } diff --git a/client/includes/Usage/HashUsageAccumulator.php b/client/includes/Usage/HashUsageAccumulator.php index 7bc0637..e819b92 100644 --- a/client/includes/Usage/HashUsageAccumulator.php +++ b/client/includes/Usage/HashUsageAccumulator.php @@ -3,6 +3,9 @@ namespace Wikibase\Client\Usage; use Wikibase\DataModel\Entity\EntityId; +use Wikibase\DataModel\Entity\EntityIdValue; +use Wikibase\DataModel\Snak\PropertyValueSnak; +use Wikibase\DataModel\Snak\Snak; /** * This implementation of the UsageAccumulator interface simply wraps @@ -41,6 +44,23 @@ } /** +* @see UsageAccumulator::addLabelUsageForSnaks +* +* @param Snak[] $snaks +*/ + public function addLabelUsageForSnaks( array $snaks ) { + foreach ( $snaks as $snak ) { + if ( $snak instanceof PropertyValueSnak ) { + $value = $snak-getDataValue(); + + if ( $value instanceof
[MediaWiki-commits] [Gerrit] Fixed lspnamespace param bug for list=listpages - change (mediawiki...Gather)
Yurik has uploaded a new change for review. https://gerrit.wikimedia.org/r/199615 Change subject: Fixed lspnamespace param bug for list=listpages .. Fixed lspnamespace param bug for list=listpages Thanks Anomie for catching that Change-Id: I422a147501f2410f2f217b783c91031476bda330 --- M includes/api/ApiQueryListPages.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather refs/changes/15/199615/1 diff --git a/includes/api/ApiQueryListPages.php b/includes/api/ApiQueryListPages.php index ad12fc0..767c031 100644 --- a/includes/api/ApiQueryListPages.php +++ b/includes/api/ApiQueryListPages.php @@ -131,7 +131,7 @@ $this-addTables( 'gather_list_item' ); $this-addFields( array( 'gli_namespace', 'gli_title', 'gli_order' ) ); $this-addWhereFld( 'gli_gl_id', $params['id'] ); - $this-addWhereFld( 'wl_namespace', $params['namespace'] ); + $this-addWhereFld( 'gli_namespace', $params['namespace'] ); if ( isset( $params['continue'] ) ) { $cont = $params['continue']; -- To view, visit https://gerrit.wikimedia.org/r/199615 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I422a147501f2410f2f217b783c91031476bda330 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Gather Gerrit-Branch: master Gerrit-Owner: Yurik yu...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update VE core submodule to master (cb06317) - change (mediawiki...VisualEditor)
Jforrester has uploaded a new change for review. https://gerrit.wikimedia.org/r/199618 Change subject: Update VE core submodule to master (cb06317) .. Update VE core submodule to master (cb06317) New changes: 5197b2d Rangestate optimization 80a07cf Unmix GeneratedContentNode from AlienNodes f510e9c Make (Node/Annotation/MetaItem)Factory inherit from ModelFactory b625ff0 Localisation updates from https://translatewiki.net. 5c4653c ve.qunit: Use 'jscs:disable' comment rather than hacks 90e9480 Remove registration of abstract AlienNode classes d325674 i18n/en.json: Convert from spaces to tabs, like all other files f40fc15 Add 'classes' config option to focusable nodes to simplify AlienNode f7c8999 Document config options as @cfg ad3aa0b ve.ce.Surface.test: Groundwork for testing non-linear selections cd1a992 Localisation updates from https://translatewiki.net. c92471e Move drop marker to highlights layer and position absolutely Change-Id: I437663d93a346a06c6a5137cce5149c7a6fcbb7f --- M .jsduck/categories.json M .jsduck/eg-iframe.html M VisualEditor.php M extension.json M lib/ve 5 files changed, 6 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/VisualEditor refs/changes/18/199618/1 diff --git a/.jsduck/categories.json b/.jsduck/categories.json index 9f28c13..8a6ab84 100644 --- a/.jsduck/categories.json +++ b/.jsduck/categories.json @@ -66,9 +66,11 @@ classes: [ ve.dm, ve.dm.Model, + ve.dm.ModelRegistry, + ve.dm.ModelFactory, ve.dm.AnnotationFactory, ve.dm.MetaItemFactory, - ve.dm.ModelRegistry, + ve.dm.NodeFactory, ve.dm.Converter, ve.dm.DataString, ve.dm.DocumentSynchronizer, @@ -76,7 +78,6 @@ ve.dm.Scalable, ve.dm.APIResultsProvider, ve.dm.APIResultsQueue, - ve.dm.NodeFactory, ve.dm.Surface, ve.dm.SurfaceFragment, ve.dm.*Selection, diff --git a/.jsduck/eg-iframe.html b/.jsduck/eg-iframe.html index 21a2cc6..6787e42 100644 --- a/.jsduck/eg-iframe.html +++ b/.jsduck/eg-iframe.html @@ -141,6 +141,7 @@ script src=lib/ve/src/ve.EventSequencer.js/script script src=lib/ve/src/dm/ve.dm.js/script script src=lib/ve/src/dm/ve.dm.Model.js/script + script src=lib/ve/src/dm/ve.dm.ModelFactory.js/script script src=lib/ve/src/dm/ve.dm.ModelRegistry.js/script script src=lib/ve/src/dm/ve.dm.NodeFactory.js/script script src=lib/ve/src/dm/ve.dm.AnnotationFactory.js/script diff --git a/VisualEditor.php b/VisualEditor.php index f23170d..39c77b1 100644 --- a/VisualEditor.php +++ b/VisualEditor.php @@ -378,6 +378,7 @@ 'lib/ve/src/dm/ve.dm.js', 'lib/ve/src/dm/ve.dm.Model.js', 'lib/ve/src/dm/ve.dm.ModelRegistry.js', + 'lib/ve/src/dm/ve.dm.ModelFactory.js', 'lib/ve/src/dm/ve.dm.NodeFactory.js', 'lib/ve/src/dm/ve.dm.AnnotationFactory.js', 'lib/ve/src/dm/ve.dm.AnnotationSet.js', diff --git a/extension.json b/extension.json index 68af33f..79ab02f 100644 --- a/extension.json +++ b/extension.json @@ -456,6 +456,7 @@ lib/ve/src/dm/ve.dm.js, lib/ve/src/dm/ve.dm.Model.js, lib/ve/src/dm/ve.dm.ModelRegistry.js, + lib/ve/src/dm/ve.dm.ModelFactory.js, lib/ve/src/dm/ve.dm.NodeFactory.js, lib/ve/src/dm/ve.dm.AnnotationFactory.js, lib/ve/src/dm/ve.dm.AnnotationSet.js, diff --git a/lib/ve b/lib/ve index 715750b..cb06317 16 --- a/lib/ve +++ b/lib/ve -Subproject commit 715750bd8c23984f6ae458025a39b179cd8593fa +Subproject commit cb06317a7be0c6b1b3d624abbc5e5b737e9fbccf -- To view, visit https://gerrit.wikimedia.org/r/199618 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I437663d93a346a06c6a5137cce5149c7a6fcbb7f Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/VisualEditor Gerrit-Branch: master Gerrit-Owner: Jforrester
[MediaWiki-commits] [Gerrit] Kill toolserver IPv4/IPv6 subnets - change (operations/dns)
Faidon Liambotis has submitted this change and it was merged. Change subject: Kill toolserver IPv4/IPv6 subnets .. Kill toolserver IPv4/IPv6 subnets Change-Id: I2edcb8355413f19cd631594212cff0c2d675408f --- M templates/0.8.c.e.2.0.a.2.ip6.arpa M templates/10.in-addr.arpa M templates/2.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa M templates/59.15.185.in-addr.arpa 4 files changed, 0 insertions(+), 43 deletions(-) Approvals: Mark Bergsma: Looks good to me, but someone else must approve Faidon Liambotis: Looks good to me, approved jenkins-bot: Verified diff --git a/templates/0.8.c.e.2.0.a.2.ip6.arpa b/templates/0.8.c.e.2.0.a.2.ip6.arpa index 7d5db5e..ccdb3f1 100644 --- a/templates/0.8.c.e.2.0.a.2.ip6.arpa +++ b/templates/0.8.c.e.2.0.a.2.ip6.arpa @@ -15,14 +15,6 @@ 1D IN NS ns1.wikimedia.org. 1D IN NS ns2.wikimedia.org. -; Toolserver (2a02:ec80:101::/48) - -$ORIGIN 1.0.1.0.{{ zonename }}. - -@ 1H IN NSa.ns.toolserver.org. -@ 1H IN NSb.ns.toolserver.org. -@ 1H IN NSc.ns.toolserver.org. - ; OOB Tilaa transit subnet (2a02:ec80:500:1::/64) $ORIGIN 1.0.0.0.0.0.5.0.{{ zonename }}. diff --git a/templates/10.in-addr.arpa b/templates/10.in-addr.arpa index 4e151d0..14dc242 100644 --- a/templates/10.in-addr.arpa +++ b/templates/10.in-addr.arpa @@ -284,17 +284,6 @@ 249 1H IN PTR msw-oe12-esams.mgmt.esams.wmnet. 253 1H IN PTR schleifenbauer.mgmt.esams.wmnet. -$ORIGIN {{ zonename }}. -; Toolserver management -0.231H IN NS a.ns.toolserver.org. -1H IN NS b.ns.toolserver.org. -1H IN NS c.ns.toolserver.org. - -; Toolserver internal -1.241H IN NS a.ns.toolserver.org. -1H IN NS b.ns.toolserver.org. -1H IN NS c.ns.toolserver.org. - ; ; EQIAD (10.64.0.0/12) ; diff --git a/templates/2.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa b/templates/2.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa index a8252cb..d480a4e 100644 --- a/templates/2.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa +++ b/templates/2.6.8.0.0.0.0.0.0.2.6.2.ip6.arpa @@ -122,21 +122,6 @@ 3.8.1.0.0.0.0.0.0.2.0.0.0.1.0.0 1H IN PTR cp3048.esams.wmnet. 4.8.1.0.0.0.0.0.0.2.0.0.0.1.0.0 1H IN PTR cp3049.esams.wmnet. -; Toolserver external subnet 2620:0:862:101::/64 - -$ORIGIN 1.0.1.0.{{ zonename }}. - -@ 1H IN NSa.ns.toolserver.org. -@ 1H IN NSb.ns.toolserver.org. -@ 1H IN NSc.ns.toolserver.org. - -; Toolserver internal subnet 2620:0:862:301::/64 - -$ORIGIN 1.0.3.0.{{ zonename }}. - -@ 1H IN NSa.ns.toolserver.org. -@ 1H IN NSb.ns.toolserver.org. -@ 1H IN NSc.ns.toolserver.org. ; LVS Service IPs, 2620:0:862:ed1a::/64 diff --git a/templates/59.15.185.in-addr.arpa b/templates/59.15.185.in-addr.arpa index 3e5c4a5..c86aa34 100644 --- a/templates/59.15.185.in-addr.arpa +++ b/templates/59.15.185.in-addr.arpa @@ -15,15 +15,6 @@ 1D IN NS ns1.wikimedia.org. 1D IN NS ns2.wikimedia.org. -; Toolserver subnet: 185.15.59.192/27 (185.15.59.192 - 185.15.59.223) - -192-223 1H IN NSa.ns.toolserver.org. -1H IN NSb.ns.toolserver.org. -1H IN NSc.ns.toolserver.org. -{% for i in range(192, 224) %} -{{ i }} 1H IN CNAME {{ i }}.192-223.59.15.185.in-addr.arpa. -{%- endfor %} - ; Neighbor blocks: 185.15.59.244/29 ; cr1-esams -- mr1-esams: 185.15.59.244/31 -- To view, visit https://gerrit.wikimedia.org/r/199288 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I2edcb8355413f19cd631594212cff0c2d675408f Gerrit-PatchSet: 3 Gerrit-Project: operations/dns Gerrit-Branch: master Gerrit-Owner: Faidon Liambotis fai...@wikimedia.org Gerrit-Reviewer: Faidon Liambotis fai...@wikimedia.org Gerrit-Reviewer: Mark Bergsma m...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fallback to read from master in DifferenceEngine::loadRevisi... - change (mediawiki/core)
jenkins-bot has submitted this change and it was merged. Change subject: Fallback to read from master in DifferenceEngine::loadRevisionData .. Fallback to read from master in DifferenceEngine::loadRevisionData In DifferenceEngine we need to show a diff immediately after an edit happened if someone did a rollback. To make that work again, try loading a revision from master if we have more than one database servers and we failed loading the revision from a slave. Change-Id: I08a16faa9e637c614c6d2fc9a10536c7b41685a8 Follows: 3c2bc32ae1775f5e875958b62d7181b4b5cfe24e Bug: T93866 --- M includes/diff/DifferenceEngine.php 1 file changed, 6 insertions(+), 0 deletions(-) Approvals: Aaron Schulz: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/diff/DifferenceEngine.php b/includes/diff/DifferenceEngine.php index 77bbd36..de8dd43 100644 --- a/includes/diff/DifferenceEngine.php +++ b/includes/diff/DifferenceEngine.php @@ -1233,6 +1233,12 @@ // Load the new revision object if ( $this-mNewid ) { $this-mNewRev = Revision::newFromId( $this-mNewid ); + + if ( !$this-mNewRev wfGetLB()-getServerCount() 1 ) { + // Try harder… This is being hit after a rollback where we show the + // diff immediately after the edit happened. T93866 + $this-mNewRev = Revision::newFromId( $this-mNewid, Revision::READ_LATEST ); + } } else { $this-mNewRev = Revision::newFromTitle( $this-getTitle(), -- To view, visit https://gerrit.wikimedia.org/r/199609 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I08a16faa9e637c614c6d2fc9a10536c7b41685a8 Gerrit-PatchSet: 3 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Hoo man h...@online.de Gerrit-Reviewer: Aaron Schulz asch...@wikimedia.org Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: Daniel Kinzler daniel.kinz...@wikimedia.de Gerrit-Reviewer: Legoktm legoktm.wikipe...@gmail.com Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] whitespace and quotes fixup - change (integration/config)
jenkins-bot has submitted this change and it was merged. Change subject: whitespace and quotes fixup .. whitespace and quotes fixup Change-Id: Ifc38d3f84984b6ad70659fc097401be9fd499c8d --- M jjb/wm-fundraising.yaml 1 file changed, 8 insertions(+), 8 deletions(-) Approvals: Hashar: Looks good to me, approved jenkins-bot: Verified diff --git a/jjb/wm-fundraising.yaml b/jjb/wm-fundraising.yaml index e9cc8ea..af88a48 100644 --- a/jjb/wm-fundraising.yaml +++ b/jjb/wm-fundraising.yaml @@ -1,23 +1,23 @@ - project: -name: 'wikimedia-fundraising-tools' +name: wikimedia-fundraising-tools jobs: - - python-jobs + - python-jobs - project: -name: 'wikimedia-fundraising-crm' +name: wikimedia-fundraising-crm jobs: - - '{name}-jslint' + - '{name}-jslint' - project: -name: 'wikimedia-fundraising-SmashPig' +name: wikimedia-fundraising-SmashPig jobs: - - python-jobs + - python-jobs - project: -name: 'wikimedia-fundraising-slander' +name: wikimedia-fundraising-slander jobs: - - python-jobs + - python-jobs -- To view, visit https://gerrit.wikimedia.org/r/195061 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ifc38d3f84984b6ad70659fc097401be9fd499c8d Gerrit-PatchSet: 2 Gerrit-Project: integration/config Gerrit-Branch: master Gerrit-Owner: Awight awi...@wikimedia.org Gerrit-Reviewer: Hashar has...@free.fr Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Revert Use EntityIdFormatter in MessageParameterFormatter - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Revert Use EntityIdFormatter in MessageParameterFormatter .. Revert Use EntityIdFormatter in MessageParameterFormatter will be just for the branch for now, since it causes T93804. we can investigate more proper fix for master, as using EntityIdFormatter here is a good idea. This reverts commit fb60de9acf5ffa5347fc0f57656073154e170c97. Bug: T93804 Change-Id: I330d4761a47bb244f4fde4d7b549e24aa4410c79 --- M lib/includes/formatters/EntityIdLinkFormatter.php M lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php M repo/includes/Localizer/MessageParameterFormatter.php M repo/includes/WikibaseRepo.php M repo/tests/phpunit/includes/Localizer/MessageParameterFormatterTest.php 5 files changed, 32 insertions(+), 22 deletions(-) Approvals: Hoo man: Looks good to me, approved JanZerebecki: Looks good to me, but someone else must approve jenkins-bot: Verified diff --git a/lib/includes/formatters/EntityIdLinkFormatter.php b/lib/includes/formatters/EntityIdLinkFormatter.php index 9a520aa..60567f4 100644 --- a/lib/includes/formatters/EntityIdLinkFormatter.php +++ b/lib/includes/formatters/EntityIdLinkFormatter.php @@ -24,7 +24,7 @@ public function formatEntityId( EntityId $entityId ) { $title = parent::formatEntityId( $entityId ); - return [[$title| . wfEscapeWikiText( $entityId-getSerialization() ) . ]]; + return [[$title]]; } } diff --git a/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php b/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php index d7084b9..035a916 100644 --- a/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php +++ b/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php @@ -5,6 +5,7 @@ use LogicException; use PHPUnit_Framework_TestCase; use Title; +use ValueFormatters\FormatterOptions; use Wikibase\DataModel\Entity\EntityId; use Wikibase\DataModel\Entity\Item; use Wikibase\DataModel\Entity\ItemId; @@ -16,6 +17,8 @@ * @covers Wikibase\Lib\EntityIdLinkFormatter * * @group Wikibase + * @group ValueFormatters + * @group DataValueExtensions * @group WikibaseLib * @group EntityIdFormatterTest * @@ -28,11 +31,11 @@ return array( 'ItemId' = array( new ItemId( 'Q23' ), - '[[ITEM-TEST--Q23|Q23]]' + '[[ITEM-TEST--Q23]]' ), 'PropertyId' = array( new PropertyId( 'P23' ), - '[[PROPERTY-TEST--P23|P23]]' + '[[PROPERTY-TEST--P23]]' ), ); } @@ -58,7 +61,8 @@ } } - private function newEntityIdLinkFormatter() { + protected function newEntityIdLinkFormatter() { + $options = new FormatterOptions(); $titleLookup = $this-getMock( 'Wikibase\Lib\Store\EntityTitleLookup' ); $titleLookup-expects( $this-any() )-method( 'getTitleForId' ) -will( $this-returnCallback( array( $this, 'getTitleForId' ) ) ); diff --git a/repo/includes/Localizer/MessageParameterFormatter.php b/repo/includes/Localizer/MessageParameterFormatter.php index 6cd3c75..7d54deb 100644 --- a/repo/includes/Localizer/MessageParameterFormatter.php +++ b/repo/includes/Localizer/MessageParameterFormatter.php @@ -10,8 +10,8 @@ use ValueFormatters\ValueFormatter; use Wikibase\DataModel\Entity\EntityId; use Wikibase\DataModel\SiteLink; -use Wikibase\Lib\EntityIdFormatter; use Wikibase\Lib\MediaWikiNumberLocalizer; +use Wikibase\Lib\Store\EntityTitleLookup; /** * ValueFormatter for formatting objects that may be encountered in @@ -28,9 +28,9 @@ private $dataValueFormatter; /** -* @var EntityIdFormatter +* @var EntityTitleLookup */ - private $entityIdFormatter; + private $entityTitleLookup; /** * @var SiteStore @@ -49,18 +49,18 @@ /** * @param ValueFormatter $dataValueFormatter A formatter for turning DataValues into wikitext. -* @param EntityIdFormatter $entityIdFormatter An entity id formatter returning wikitext. +* @param EntityTitleLookup $entityTitleLookup * @param SiteStore $sites * @param Language $language */ public function __construct( ValueFormatter $dataValueFormatter, - EntityIdFormatter $entityIdFormatter, + EntityTitleLookup $entityTitleLookup, SiteStore $sites, Language $language ) { $this-dataValueFormatter = $dataValueFormatter; - $this-entityIdFormatter = $entityIdFormatter; +
[MediaWiki-commits] [Gerrit] remap CN - ulsfo - change (operations/dns)
BBlack has uploaded a new change for review. https://gerrit.wikimedia.org/r/199621 Change subject: remap CN - ulsfo .. remap CN - ulsfo Change-Id: I1382489f586fb6abb4c7bf7f0e4a60c6b2938059 --- M config-geo 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/operations/dns refs/changes/21/199621/1 diff --git a/config-geo b/config-geo index bf51cea..a4e601d 100644 --- a/config-geo +++ b/config-geo @@ -18,7 +18,7 @@ BN = [ulsfo, eqiad], # Brunei Darussalam BT = [ulsfo, eqiad], # Bhutan CC = [ulsfo, eqiad], # Cocos (Keeling) Islands -CN = [eqiad ], # China +CN = [ulsfo, eqiad], # China CX = [ulsfo, eqiad], # Christmas Island CY = [esams, ulsfo], # ESAMS-ULSFO # Cyprus GE = [esams, ulsfo], # ESAMS-ULSFO # Georgia -- To view, visit https://gerrit.wikimedia.org/r/199621 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I1382489f586fb6abb4c7bf7f0e4a60c6b2938059 Gerrit-PatchSet: 1 Gerrit-Project: operations/dns Gerrit-Branch: master Gerrit-Owner: BBlack bbl...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fallback to read from master in DifferenceEngine::loadRevisi... - change (mediawiki/core)
jenkins-bot has submitted this change and it was merged. Change subject: Fallback to read from master in DifferenceEngine::loadRevisionData .. Fallback to read from master in DifferenceEngine::loadRevisionData In DifferenceEngine we need to show a diff immediately after an edit happened if someone did a rollback. To make that work again, try loading a revision from master if we have more than one database servers and we failed loading the revision from a slave. Change-Id: I08a16faa9e637c614c6d2fc9a10536c7b41685a8 Follows: 3c2bc32ae1775f5e875958b62d7181b4b5cfe24e Bug: T93866 --- M includes/diff/DifferenceEngine.php 1 file changed, 6 insertions(+), 0 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/diff/DifferenceEngine.php b/includes/diff/DifferenceEngine.php index 77bbd36..de8dd43 100644 --- a/includes/diff/DifferenceEngine.php +++ b/includes/diff/DifferenceEngine.php @@ -1233,6 +1233,12 @@ // Load the new revision object if ( $this-mNewid ) { $this-mNewRev = Revision::newFromId( $this-mNewid ); + + if ( !$this-mNewRev wfGetLB()-getServerCount() 1 ) { + // Try harder… This is being hit after a rollback where we show the + // diff immediately after the edit happened. T93866 + $this-mNewRev = Revision::newFromId( $this-mNewid, Revision::READ_LATEST ); + } } else { $this-mNewRev = Revision::newFromTitle( $this-getTitle(), -- To view, visit https://gerrit.wikimedia.org/r/199620 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I08a16faa9e637c614c6d2fc9a10536c7b41685a8 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/core Gerrit-Branch: wmf/1.25wmf22 Gerrit-Owner: Hoo man h...@online.de Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fixed lspnamespace param bug for list=listpages - change (mediawiki...Gather)
jenkins-bot has submitted this change and it was merged. Change subject: Fixed lspnamespace param bug for list=listpages .. Fixed lspnamespace param bug for list=listpages Thanks Anomie for catching that Change-Id: I422a147501f2410f2f217b783c91031476bda330 --- M includes/api/ApiQueryListPages.php 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Jdlrobson: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/api/ApiQueryListPages.php b/includes/api/ApiQueryListPages.php index ad12fc0..767c031 100644 --- a/includes/api/ApiQueryListPages.php +++ b/includes/api/ApiQueryListPages.php @@ -131,7 +131,7 @@ $this-addTables( 'gather_list_item' ); $this-addFields( array( 'gli_namespace', 'gli_title', 'gli_order' ) ); $this-addWhereFld( 'gli_gl_id', $params['id'] ); - $this-addWhereFld( 'wl_namespace', $params['namespace'] ); + $this-addWhereFld( 'gli_namespace', $params['namespace'] ); if ( isset( $params['continue'] ) ) { $cont = $params['continue']; -- To view, visit https://gerrit.wikimedia.org/r/199615 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I422a147501f2410f2f217b783c91031476bda330 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Gather Gerrit-Branch: master Gerrit-Owner: Yurik yu...@wikimedia.org Gerrit-Reviewer: Jdlrobson jrob...@wikimedia.org Gerrit-Reviewer: Jhernandez jhernan...@wikimedia.org Gerrit-Reviewer: Robmoen rm...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update Wikidata - Fix recent changes formatting on wikidata - change (mediawiki...Wikidata)
jenkins-bot has submitted this change and it was merged. Change subject: Update Wikidata - Fix recent changes formatting on wikidata .. Update Wikidata - Fix recent changes formatting on wikidata * also fixes edit summary on SpecialSetLabelDescriptionAliases page * add debug logging to UpdateRepo code * fix php notice in PhpDateTimeParser Change-Id: I6d8e0019e11674ffbe1ca62b337c5f41b61b4e6b --- M composer.json M composer.lock M extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php M extensions/Wikibase/client/includes/UpdateRepo/UpdateRepo.php M extensions/Wikibase/lib/includes/formatters/EntityIdLinkFormatter.php M extensions/Wikibase/lib/includes/parsers/PhpDateTimeParser.php M extensions/Wikibase/lib/tests/phpunit/formatters/EntityIdLinkFormatterTest.php M extensions/Wikibase/lib/tests/phpunit/parsers/PhpDateTimeParserTest.php M extensions/Wikibase/repo/i18n/en.json M extensions/Wikibase/repo/i18n/qqq.json M extensions/Wikibase/repo/includes/Localizer/MessageParameterFormatter.php M extensions/Wikibase/repo/includes/WikibaseRepo.php M extensions/Wikibase/repo/includes/specials/SpecialSetLabelDescriptionAliases.php M extensions/Wikibase/repo/tests/phpunit/includes/Localizer/MessageParameterFormatterTest.php M vendor/composer/installed.json 15 files changed, 169 insertions(+), 89 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/composer.json b/composer.json index 1c414a4..227596d 100644 --- a/composer.json +++ b/composer.json @@ -5,6 +5,10 @@ repositories: [ { type: vcs, +url: https://git.wikimedia.org/git/mediawiki/extensions/Wikibase.git; + }, + { +type: vcs, url: https://github.com/wmde/Wikidata.org.git; }, { @@ -33,4 +37,4 @@ preferred-install: dist, autoloader-suffix: wikidata_1_25wmf22 } -} \ No newline at end of file +} diff --git a/composer.lock b/composer.lock index 2ab3e90..a0e9c21 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file;, This file is @generated automatically ], -hash: 2c17a6721641ee4dfc829a9a94dc98f5, +hash: 99b3db77c3640ec4fa944bb1517f39d7, packages: [ { name: composer/installers, @@ -1236,14 +1236,8 @@ version: dev-wmf/1.25wmf22, source: { type: git, -url: https://github.com/wikimedia/mediawiki-extensions-Wikibase.git;, -reference: 7d3a0b11d0321ff09fde1b5692599860fea6496c -}, -dist: { -type: zip, -url: https://api.github.com/repos/wikimedia/mediawiki-extensions-Wikibase/zipball/7d3a0b11d0321ff09fde1b5692599860fea6496c;, -reference: 7d3a0b11d0321ff09fde1b5692599860fea6496c, -shasum: +url: https://git.wikimedia.org/git/mediawiki/extensions/Wikibase.git;, +reference: c42291f422f391dd14388859caf39857e80a4959 }, require: { data-values/common: ~0.2.0, @@ -1291,7 +1285,6 @@ Wikibase\\Repo\\View\\: repo/includes/View } }, -notification-url: https://packagist.org/downloads/;, license: [ GPL-2.0+ ], @@ -1309,7 +1302,11 @@ wikibaserepo, wikidata ], -time: 2015-03-25 00:03:14 +support: { +issues: https://bugzilla.wikimedia.org/;, +irc: irc://irc.freenode.net/wikidata +}, +time: 2015-03-25 14:50:27 }, { name: wikibase/wikimedia-badges, diff --git a/extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php b/extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php index ec41526..53dcc5c 100644 --- a/extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php +++ b/extensions/Wikibase/client/includes/Hooks/UpdateRepoHookHandlers.php @@ -230,6 +230,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnDelete: Failed to inject job: . $e-getMessage() ); } return true; @@ -274,6 +275,7 @@ // show a message to the user that the Wikibase item needs to be // manually updated. wfLogWarning( $e-getMessage() ); + wfDebugLog( 'UpdateRepo', OnMove: Failed to inject job: . $e-getMessage() ); } return true;
[MediaWiki-commits] [Gerrit] Copy l10n CDB files to rebuildLocalisationCache.php tmp dir - change (mediawiki...scap)
jenkins-bot has submitted this change and it was merged. Change subject: Copy l10n CDB files to rebuildLocalisationCache.php tmp dir .. Copy l10n CDB files to rebuildLocalisationCache.php tmp dir Seed the localization cache for each rebuildLocalisationCache.php build with the current CDB files from the associated MediaWiki release branch. Bug: T93737 Change-Id: I01b24765ce26cf48d9b9381a476c3bcf39db7ab8 --- M scap/tasks.py 1 file changed, 11 insertions(+), 1 deletion(-) Approvals: Chad: Looks good to me, approved jenkins-bot: Verified diff --git a/scap/tasks.py b/scap/tasks.py index c23d4ce..ce19fcd 100644 --- a/scap/tasks.py +++ b/scap/tasks.py @@ -404,9 +404,19 @@ temp_dir = '/tmp/scap_l10n_' + str( random.SystemRandom().randint(0, 0x)) +# Create a temporary directory for l10n CDB files +utils.sudo_check_call('www-data', 'mkdir %s' % (temp_dir), logger) + +# Seed the temporary directory with the current CDB files +utils.sudo_check_call('www-data', +cp '%(out_dir)s/'*.cdb '%(temp_dir)s' % { +'temp_dir': temp_dir, +'out_dir': out_dir +}, +logger) + # Generate the files into a temporary directory as www-data utils.sudo_check_call('www-data', -'mkdir %(temp_dir)s ' '/usr/local/bin/mwscript rebuildLocalisationCache.php ' '--wiki=%(wikidb)s --outdir=%(temp_dir)s ' '--threads=%(use_cores)s %(lang)s %(force)s %(quiet)s' % { -- To view, visit https://gerrit.wikimedia.org/r/199318 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I01b24765ce26cf48d9b9381a476c3bcf39db7ab8 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/tools/scap Gerrit-Branch: master Gerrit-Owner: BryanDavis bda...@wikimedia.org Gerrit-Reviewer: 20after4 mmod...@wikimedia.org Gerrit-Reviewer: BryanDavis bda...@wikimedia.org Gerrit-Reviewer: Chad ch...@wikimedia.org Gerrit-Reviewer: Ori.livneh o...@wikimedia.org Gerrit-Reviewer: Thcipriani tcipri...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Do not pass objects to Summary::addAutoCommentArgs - change (mediawiki...Wikibase)
Thiemo Mättig (WMDE) has uploaded a new change for review. https://gerrit.wikimedia.org/r/199625 Change subject: Do not pass objects to Summary::addAutoCommentArgs .. Do not pass objects to Summary::addAutoCommentArgs This will probably not fix T93896, but it's just odd to stuff objects in here. This gets rendered as a string anyway. Bug: T93804 Bug: T93896 Change-Id: I5e30d9b9df53964587971a1649bf88deeedd8cbe --- M repo/includes/Interactors/RedirectCreationInteractor.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/25/199625/1 diff --git a/repo/includes/Interactors/RedirectCreationInteractor.php b/repo/includes/Interactors/RedirectCreationInteractor.php index 7cf5fa9..517dadc 100644 --- a/repo/includes/Interactors/RedirectCreationInteractor.php +++ b/repo/includes/Interactors/RedirectCreationInteractor.php @@ -92,7 +92,7 @@ $this-checkEmpty( $fromId ); $summary = new Summary( 'wbcreateredirect' ); - $summary-addAutoCommentArgs( $fromId, $toId ); + $summary-addAutoCommentArgs( $fromId-getSerialization(), $toId-getSerialization() ); $redirect = new EntityRedirect( $fromId, $toId ); $this-saveRedirect( $redirect, $summary, $bot ); -- To view, visit https://gerrit.wikimedia.org/r/199625 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I5e30d9b9df53964587971a1649bf88deeedd8cbe Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Thiemo Mättig (WMDE) thiemo.maet...@wikimedia.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] add sockets directory - change (labs...WMT)
John F. Lewis has uploaded a new change for review. https://gerrit.wikimedia.org/r/199626 Change subject: add sockets directory .. add sockets directory Change-Id: I747e3e74bc4971a38e6d8e2e4a802b955db1ab26 --- A bots/tmp/sockets/.gitkeep 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/labs/tools/WMT refs/changes/26/199626/1 diff --git a/bots/tmp/sockets/.gitkeep b/bots/tmp/sockets/.gitkeep new file mode 100644 index 000..8b13789 --- /dev/null +++ b/bots/tmp/sockets/.gitkeep @@ -0,0 +1 @@ + -- To view, visit https://gerrit.wikimedia.org/r/199626 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I747e3e74bc4971a38e6d8e2e4a802b955db1ab26 Gerrit-PatchSet: 1 Gerrit-Project: labs/tools/WMT Gerrit-Branch: master Gerrit-Owner: John F. Lewis johnflewi...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] DO NOT SUBMIT: try CI with MySQL ENGINE=MEMORY - change (mediawiki/core)
Hashar has uploaded a new change for review. https://gerrit.wikimedia.org/r/199633 Change subject: DO NOT SUBMIT: try CI with MySQL ENGINE=MEMORY .. DO NOT SUBMIT: try CI with MySQL ENGINE=MEMORY That is merely a lame test to figure out how WMF CI behave when the MySQL engine is changed from InnoDB to MEMORY. It lacks transactions so I expect a bunch of failures. Change-Id: I7faa63bdfb2b7bf1ac8ebfb2f13ac14a11c2bad6 --- M includes/DefaultSettings.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/33/199633/1 diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index fdb05fe..6510ce4 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -1670,7 +1670,7 @@ /** * MySQL table options to use during installation or update */ -$wgDBTableOptions = 'ENGINE=InnoDB'; +$wgDBTableOptions = 'ENGINE=MEMORY'; /** * SQL Mode - default is turning off all modes, including strict, if set. -- To view, visit https://gerrit.wikimedia.org/r/199633 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I7faa63bdfb2b7bf1ac8ebfb2f13ac14a11c2bad6 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Hashar has...@free.fr ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Illustrate collections (suboptimal but good enough approach) - change (mediawiki...Gather)
jenkins-bot has submitted this change and it was merged. Change subject: Illustrate collections (suboptimal but good enough approach) .. Illustrate collections (suboptimal but good enough approach) This sets a page image when absent when the user views a collection This is not perfect (if a user shares a URL before visiting that collection it will not be illustrated) but it seems the safest way to do this efficiently for the time being. Ideally this should be run on every insert/remove operation but that would mean iterating through all items in a collection and 3 saves to the database (we have to check the list exists first before adding the item and then we have to access all the items in that collection to access the page imageS) Changes: * add isWatchlist method * Correctly pass file rather than string as image when creating collection from api Bug: T91675 Change-Id: I026b8fe21626d76825e617b753c6d4c6f1769907 --- M includes/models/Collection.php M includes/models/CollectionBase.php M includes/models/CollectionsList.php M includes/specials/SpecialGather.php 4 files changed, 59 insertions(+), 3 deletions(-) Approvals: Jhernandez: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/models/Collection.php b/includes/models/Collection.php index 942d326..361fbf8 100644 --- a/includes/models/Collection.php +++ b/includes/models/Collection.php @@ -28,11 +28,30 @@ protected $items = array(); /** +* Image that could be used to illustrate collection. +* +* @var string +*/ + protected $imageSuggestion = ''; + + /** +* Obtain a suggested image from the created collection; +* +* @return string a suggested illustration based on members of collection. +*/ + public function getSuggestedImage() { + return $this-imageSuggestion; + } + + /** * Adds a item to the collection. * * @param CollectionItem $item */ public function add( CollectionItem $item ) { + if ( $item-hasImage() !$this-hasImage() ) { + $this-imageSuggestion = $item-getFile()-getTitle()-getText(); + } $this-items[] = $item; } diff --git a/includes/models/CollectionBase.php b/includes/models/CollectionBase.php index 61fefe0..561590d 100644 --- a/includes/models/CollectionBase.php +++ b/includes/models/CollectionBase.php @@ -59,10 +59,10 @@ * @param string $title Title of the collection * @param string $description Description of the collection * @param boolean $public Whether the collection is public or private -* @param File Image that represents the collection +* @param File $image Image that represents the collection */ public function __construct( $id = null, User $user, $title = '', $description = '', - $public = true, $image = null) { + $public = true, $image = null ) { $this-id = $id; $this-owner = $user; $this-title = $title; @@ -80,6 +80,13 @@ } /** +* @return boolean whether the collection is a watchlist. +*/ + public function isWatchlist() { + return $this-isWatchlist; + } + + /** * @return User */ public function getOwner() { diff --git a/includes/models/CollectionsList.php b/includes/models/CollectionsList.php index 2f5b8f6..4f736a4 100644 --- a/includes/models/CollectionsList.php +++ b/includes/models/CollectionsList.php @@ -106,8 +106,9 @@ $lists = $data['query']['lists']; foreach ( $lists as $list ) { if ( $list['public'] || $includePrivate ) { + $image = $list['image'] ? wfFindFile( $list['image'] ) : false; $info = new models\CollectionInfo( $list['id'], $user, - $list['label'], $list['description'], $list['public'], wfFindFile( $list['image'] ) ); + $list['label'], $list['description'], $list['public'], $image ); $info-setCount( $list['count'] ); if ( $memberTitle ) { $info-setMember( $memberTitle, $list['title'] ); diff --git a/includes/specials/SpecialGather.php b/includes/specials/SpecialGather.php index 32648d7..bc854e4 100644 --- a/includes/specials/SpecialGather.php +++ b/includes/specials/SpecialGather.php @@ -9,6 +9,9 @@ use Gather\views; use \User; use \SpecialPage; +use \UsageException; +use \DerivativeRequest; +use \ApiMain; /** * Render a collection of articles. @@ -92,6
[MediaWiki-commits] [Gerrit] Refactored abuse string testing code - change (mediawiki...Gather)
jenkins-bot has submitted this change and it was merged. Change subject: Refactored abuse string testing code .. Refactored abuse string testing code * Validation should happen in one designated spot * Input strings should never be replied back to the user (API security policy) Bug: T93385 Change-Id: Ib4fa22a7c92e27245cb2cc4c9d26b2a038271a0e --- M includes/api/ApiEditList.php 1 file changed, 36 insertions(+), 29 deletions(-) Approvals: Jdlrobson: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/api/ApiEditList.php b/includes/api/ApiEditList.php index 0e266ac..3f81563 100644 --- a/includes/api/ApiEditList.php +++ b/includes/api/ApiEditList.php @@ -26,6 +26,8 @@ namespace Gather\api; +use AbuseFilter; +use AbuseFilterVariableHolder; use ApiBase; use AppendIterator; use ArrayIterator; @@ -61,9 +63,6 @@ if ( $params['label'] !== null ) { $label = trim( $params['label'] ); $params['label'] = $label; - if ( $this-isDisallowedString( $label ) ) { - $this-dieUsage( Label `{$label}` denied by abuse filter, 'badlabel' ); - } } $this-checkPermissions( $params ); @@ -120,26 +119,28 @@ $this-processTitles( $params, $user, $listId, $dbw, $isWatchlist ); } } + /** * Checks whether the collection description or title is disallowed according to AbuseFilter * if available. If no abuse filters in place returns false. * @param string $string -* @return boolean +* @return bool */ private function isDisallowedString( $string ) { if ( class_exists( 'AbuseFilterVariableHolder' ) ) { - $vars = new \AbuseFilterVariableHolder(); - $vars-addHolders( \AbuseFilter::generateUserVars( $this-getUser() ) ); - $vars-setVar( 'action', 'gatheredit' ); // I think having your own action would be best + $vars = new AbuseFilterVariableHolder(); + $vars-addHolders( AbuseFilter::generateUserVars( $this-getUser() ) ); + $vars-setVar( 'action', 'gatheredit' ); $vars-setVar( 'old_wikitext', '' ); $vars-setVar( 'new_wikitext', $string ); $vars-setVar( 'added_lines', $string ); - $result = \AbuseFilter::filterAction( $vars, Title::newFromText( 'Gather' ) ); + $result = AbuseFilter::filterAction( $vars, Title::newFromText( 'Gather' ) ); return !$result-isGood(); } else { return false; } } + /** * This method should be called twice - once before accessing DB, and once when db row is found * @param array $params @@ -159,6 +160,7 @@ $user = $this-getUser(); // TBD: We might want to allow other users with getWatchlistUser() $p = $this-getModulePrefix(); $mode = $params['mode']; + $label = $params['label']; // These modes cannot change list items or change other params like label/description/... // Incidentally, these are also modes that cannot be applied to the watchlist $isNoUpdatesMode = in_array( $mode, array( 'showlist', 'hidelist', 'deletelist' ) ); @@ -167,12 +169,12 @@ $this-dieUsage( 'You must be logged-in to edit a list', 'notloggedin' ); } elseif ( !$user-isAllowed( 'editmywatchlist' ) ) { $this-dieUsage( 'You don\'t have permission to edit your list', 'permissiondenied' ); - } elseif ( $params['label'] === '' ) { + } elseif ( $label === '' ) { $this-dieUsage( 'If given, label must not be empty', 'badlabel' ); } if ( $isWatchlist ) { - if ( $params['label'] !== null ) { + if ( $label !== null ) { $this-dieUsage( {$p}label cannot be set for a watchlist, 'invalidparammix' ); } elseif ( $mode === 'deletelist' ) { $this-dieUsage( Watchlist may not be deleted, 'invalidparammix' ); @@ -197,7 +199,7 @@ } elseif ( $mode === 'remove' ) { $this-dieUsage( List must be identified with {$p}id when {$p}mode=remove is used, 'invalidparammix' ); - } elseif ( $params['label'] === null ) { + } elseif ( $label === null ) {
[MediaWiki-commits] [Gerrit] Do not pass objects to Summary::addAutoCommentArgs - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Do not pass objects to Summary::addAutoCommentArgs .. Do not pass objects to Summary::addAutoCommentArgs This will probably not fix T93896, but it's just odd to stuff objects in here. This gets rendered as a string anyway. Bug: T93804 Bug: T93896 Change-Id: I5e30d9b9df53964587971a1649bf88deeedd8cbe --- M repo/includes/Interactors/RedirectCreationInteractor.php 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Hoo man: Looks good to me, approved jenkins-bot: Verified diff --git a/repo/includes/Interactors/RedirectCreationInteractor.php b/repo/includes/Interactors/RedirectCreationInteractor.php index 7cf5fa9..517dadc 100644 --- a/repo/includes/Interactors/RedirectCreationInteractor.php +++ b/repo/includes/Interactors/RedirectCreationInteractor.php @@ -92,7 +92,7 @@ $this-checkEmpty( $fromId ); $summary = new Summary( 'wbcreateredirect' ); - $summary-addAutoCommentArgs( $fromId, $toId ); + $summary-addAutoCommentArgs( $fromId-getSerialization(), $toId-getSerialization() ); $redirect = new EntityRedirect( $fromId, $toId ); $this-saveRedirect( $redirect, $summary, $bot ); -- To view, visit https://gerrit.wikimedia.org/r/199625 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I5e30d9b9df53964587971a1649bf88deeedd8cbe Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Thiemo Mättig (WMDE) thiemo.maet...@wikimedia.de Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: Hoo man h...@online.de Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Revert exim4.conf.SMTP_IMAP_MM.erb local mail can cause loops - change (operations/puppet)
Rush has submitted this change and it was merged. Change subject: Revert exim4.conf.SMTP_IMAP_MM.erb local mail can cause loops .. Revert exim4.conf.SMTP_IMAP_MM.erb local mail can cause loops This reverts commit c104dd8f3da7519109cf9f55db650424936e7ffc. Change-Id: Icdbeed96dccdac87a9e965fa766672baa89abc32 --- M manifests/role/phabricator.pp M templates/exim/exim4.conf.SMTP_IMAP_MM.erb 2 files changed, 2 insertions(+), 6 deletions(-) Approvals: Rush: Looks good to me, approved jenkins-bot: Verified diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp index 059f9a0..f10a6c0 100644 --- a/manifests/role/phabricator.pp +++ b/manifests/role/phabricator.pp @@ -25,10 +25,6 @@ description = 'Phabricator (Main)' } -mailalias { 'root': -recipient = 'r...@wikimedia.org', -} - include passwords::phabricator include role::phabricator::config include phabricator::monitoring diff --git a/templates/exim/exim4.conf.SMTP_IMAP_MM.erb b/templates/exim/exim4.conf.SMTP_IMAP_MM.erb index 83c6074..3e37f04 100644 --- a/templates/exim/exim4.conf.SMTP_IMAP_MM.erb +++ b/templates/exim/exim4.conf.SMTP_IMAP_MM.erb @@ -554,12 +554,12 @@ % end % % if !@smart_route_list.empty? then -% -# Send all mail //not destined for the local machine// via a set of +# Send all mail not destined for the local machine via a set of # mail relays (smart hosts) smart_route: driver = manualroute transport = remote_smtp - route_list = !+local_domains %= @smart_route_list.join(:) % + route_list = * %= @smart_route_list.join(:) % % end % ## -- To view, visit https://gerrit.wikimedia.org/r/199634 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Icdbeed96dccdac87a9e965fa766672baa89abc32 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Rush r...@wikimedia.org Gerrit-Reviewer: Rush r...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] planet: use https instead of http - change (operations/puppet)
Gage has submitted this change and it was merged. Change subject: planet: use https instead of http .. planet: use https instead of http Since planets was moved to behind misc, the https stanza (443) was no longer needed. This removed the https redirects. As these are no longer needed as http, move them to https. Bug: T70554 Change-Id: Ic374c679c887f1f719d1a985c8fa7004b74b7d55 --- M modules/planet/templates/apache/planet.erb 1 file changed, 4 insertions(+), 4 deletions(-) Approvals: Gage: Looks good to me, approved jenkins-bot: Verified Dzahn: Looks good to me, but someone else must approve diff --git a/modules/planet/templates/apache/planet.erb b/modules/planet/templates/apache/planet.erb index a273f86..b892f75 100644 --- a/modules/planet/templates/apache/planet.erb +++ b/modules/planet/templates/apache/planet.erb @@ -7,9 +7,9 @@ DocumentRoot /var/www/planet -Redirect /atom.xml http://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/atom.xml -Redirect /rss10.xml http://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/rss10.xml -Redirect /rss20.xml http://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/rss20.xml +Redirect /atom.xml https://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/atom.xml +Redirect /rss10.xml https://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/rss10.xml +Redirect /rss20.xml https://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/rss20.xml -RedirectTemp / http://%= scope.lookupvar('planet::planet_meta_link') % +RedirectTemp / https://%= scope.lookupvar('planet::planet_meta_link') % /VirtualHost -- To view, visit https://gerrit.wikimedia.org/r/199638 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic374c679c887f1f719d1a985c8fa7004b74b7d55 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: John F. Lewis johnflewi...@gmail.com Gerrit-Reviewer: Dzahn dz...@wikimedia.org Gerrit-Reviewer: Gage jger...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] planet: use standard for http-https redirects - change (operations/puppet)
Dzahn has uploaded a new change for review. https://gerrit.wikimedia.org/r/199641 Change subject: planet: use standard for http-https redirects .. planet: use standard for http-https redirects Just adjust this to be the same as the standard snippet we use in several other places. Maybe this should be a parser function like ssl_ciphersuite. - do not redirect server status page - set env=ProtoRedirect Change-Id: I48546007610213f553234ee7938615a682a97a40 --- M modules/planet/templates/apache/planet-language.erb 1 file changed, 2 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/41/199641/1 diff --git a/modules/planet/templates/apache/planet-language.erb b/modules/planet/templates/apache/planet-language.erb index 3728330..f605f64 100644 --- a/modules/planet/templates/apache/planet-language.erb +++ b/modules/planet/templates/apache/planet-language.erb @@ -7,8 +7,9 @@ RewriteEngine On RewriteCond %{HTTP:X-Forwarded-Proto} !https +RewriteCond %{REQUEST_URI} !^/status$ RewriteRule ^/(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,E=ProtoRedirect] -Header always merge Vary X-Forwarded-Proto +Header always merge Vary X-Forwarded-Proto env=ProtoRedirect Directory /var/www/planet/%= @name % Allow from all -- To view, visit https://gerrit.wikimedia.org/r/199641 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I48546007610213f553234ee7938615a682a97a40 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Dzahn dz...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Title can only be plaintext - change (mediawiki...Flow)
jenkins-bot has submitted this change and it was merged. Change subject: Title can only be plaintext .. Title can only be plaintext It makes no sense to specify a format here! Change-Id: Ifc18373b5f34a2c732797842655296363acb8bc0 --- M i18n/en.json M i18n/qqq.json M includes/api/ApiFlowEditTitle.php 3 files changed, 2 insertions(+), 10 deletions(-) Approvals: Mattflaschen: Looks good to me, approved jenkins-bot: Verified diff --git a/i18n/en.json b/i18n/en.json index 41f14bb..40c905d 100644 --- a/i18n/en.json +++ b/i18n/en.json @@ -433,7 +433,6 @@ apihelp-flow+edit-title-description: Edits a topic's title., apihelp-flow+edit-title-param-prev_revision: Revision ID of the current title revision, to check for edit conflicts., apihelp-flow+edit-title-param-content: Content for title., - apihelp-flow+edit-title-param-format: Format of the summary (wikitext|html), apihelp-flow+edit-title-example-1: Edit the title of [[Topic:S2tycnas4hcucw8w]], apihelp-flow+edit-title-param-metadataonly: Whether to include only metadata about the new content, excluding everything else, apihelp-flow+edit-topic-summary-description: Edits a topic summary's content., diff --git a/i18n/qqq.json b/i18n/qqq.json index a21d048..7dfb98f 100644 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -435,7 +435,6 @@ apihelp-flow+edit-title-description: {{doc-apihelp-description|flow+edit-title}}, apihelp-flow+edit-title-param-prev_revision: {{doc-apihelp-param|flow+edit-title|prev_revision}}, apihelp-flow+edit-title-param-content: {{doc-apihelp-param|flow+edit-title|content}}, - apihelp-flow+edit-title-param-format: {{doc-apihelp-param|flow+edit-title|format}}, apihelp-flow+edit-title-example-1: {{doc-apihelp-example|flow+edit-title}}, apihelp-flow+edit-title-param-metadataonly: {{doc-apihelp-param|flow+edit-title|metadataonly}}, apihelp-flow+edit-topic-summary-description: {{doc-apihelp-description|flow+edit-topic-summary}}, diff --git a/includes/api/ApiFlowEditTitle.php b/includes/api/ApiFlowEditTitle.php index 279616b..d641144 100644 --- a/includes/api/ApiFlowEditTitle.php +++ b/includes/api/ApiFlowEditTitle.php @@ -26,11 +26,6 @@ 'content' = array( ApiBase::PARAM_REQUIRED = true, ), - 'format' = array( - ApiBase::PARAM_REQUIRED = true, - ApiBase::PARAM_DFLT = 'wikitext', - ApiBase::PARAM_TYPE = array( 'html', 'wikitext' ), - ), ) + parent::getAllowedParams(); } @@ -41,7 +36,6 @@ return array( 'prev_revision' = 'Revision id of the current title revision to check for edit conflicts', 'content' = 'Content for title', - 'format' = 'Format of the content (wikitext|html)', ); } @@ -57,7 +51,7 @@ */ public function getExamples() { return array( - 'api.php?action=flowsubmodule=edit-titlepage=Topic:S2tycnas4hcucw8wehprev_revision=???ehtcontent=Nice%20to20meet%20youehtformat=wikitext', + 'api.php?action=flowsubmodule=edit-titlepage=Topic:S2tycnas4hcucw8wetprev_revision=???etcontent=Nice%20to20meet%20you', ); } @@ -66,7 +60,7 @@ */ protected function getExamplesMessages() { return array( - 'action=flowsubmodule=edit-titlepage=Topic:S2tycnas4hcucw8wehprev_revision=???ehtcontent=Nice%20to20meet%20youehtformat=wikitext' + 'action=flowsubmodule=edit-titlepage=Topic:S2tycnas4hcucw8wetprev_revision=???ehtcontent=Nice%20to20meet%20you' = 'apihelp-flow+edit-title-example-1', ); } -- To view, visit https://gerrit.wikimedia.org/r/196567 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ifc18373b5f34a2c732797842655296363acb8bc0 Gerrit-PatchSet: 4 Gerrit-Project: mediawiki/extensions/Flow Gerrit-Branch: master Gerrit-Owner: Matthias Mullie mmul...@wikimedia.org Gerrit-Reviewer: Krinkle krinklem...@gmail.com Gerrit-Reviewer: Legoktm legoktm.wikipe...@gmail.com Gerrit-Reviewer: Mattflaschen mflasc...@wikimedia.org Gerrit-Reviewer: SG shah...@gmail.com Gerrit-Reviewer: Siebrand siebr...@kitano.nl 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 OCSP Stapling everywhere - change (operations/puppet)
BBlack has submitted this change and it was merged. Change subject: enable OCSP Stapling everywhere .. enable OCSP Stapling everywhere Change-Id: Ic2c4c6844cd64f0159e306c2ace89ca0b24dd7bf --- M manifests/role/cache.pp 1 file changed, 2 insertions(+), 18 deletions(-) Approvals: BBlack: Looks good to me, approved jenkins-bot: Verified diff --git a/manifests/role/cache.pp b/manifests/role/cache.pp index b7a1f91..bcc0385 100644 --- a/manifests/role/cache.pp +++ b/manifests/role/cache.pp @@ -654,34 +654,18 @@ include certificates::wmf_ca_2014_2017 include role::protoproxy::ssl::common -# Test OCSP on cp1008 only initially -if $::hostname == 'cp1008' { -$ocsp_test = true -} -else { -$ocsp_test = false -} - localssl { 'unified': certname = 'uni.wikimedia.org', default_server = true, -do_ocsp = $ocsp_test, +do_ocsp = true, } define sni_cert() { -# Test OCSP on cp1008 only initially -if $::hostname == 'cp1008' { -$ocsp_test = true -} -else { -$ocsp_test = false -} - localssl { $name: certname = sni.${name}, server_name = $name, server_aliases = [*.${name}], -do_ocsp = $ocsp_test, +do_ocsp = true, } } -- To view, visit https://gerrit.wikimedia.org/r/199624 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic2c4c6844cd64f0159e306c2ace89ca0b24dd7bf Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: BBlack bbl...@wikimedia.org Gerrit-Reviewer: BBlack bbl...@wikimedia.org Gerrit-Reviewer: Faidon Liambotis fai...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update url schemas on Special:Gather - change (mediawiki...Gather)
jenkins-bot has submitted this change and it was merged. Change subject: Update url schemas on Special:Gather .. Update url schemas on Special:Gather Mainly, user lists and a user list now are prefixed, so that we can have other prefixes, like /all * Introduce regex based routing * Modify /User/Id to be /by/User/Id * Add /all /all/public /all/hidden as a redirect to Special:GatherLists as a first step to merging the two special pages. * Fix No public list found error shown on GatherLists. In follow up patches I'll convert Special:GatherLists to a view that will be rendered by Special:Gather, like the views\Collection or the views\CollectionsList. Bug: T93774 Change-Id: I963de47101313ac6e73ec84b687b5d4ad90c5788 --- M includes/models/CollectionBase.php M includes/specials/SpecialGather.php M includes/specials/SpecialGatherLists.php M tests/browser/features/support/pages/watchlist_collection_page.rb 4 files changed, 47 insertions(+), 24 deletions(-) Approvals: Jdlrobson: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/models/CollectionBase.php b/includes/models/CollectionBase.php index 61fefe0..1dac331 100644 --- a/includes/models/CollectionBase.php +++ b/includes/models/CollectionBase.php @@ -118,12 +118,13 @@ /** * Return local url for collection -* Example: /wiki/Special:Gather/user/id +* Example: /wiki/Special:Gather/by/user/id * * @return string localized url for collection */ public function getUrl() { return SpecialPage::getTitleFor( 'Gather' ) + -getSubpage( 'by' ) -getSubpage( $this-getOwner() ) -getSubpage( $this-getId() ) -getLocalURL(); diff --git a/includes/specials/SpecialGather.php b/includes/specials/SpecialGather.php index 32648d7..3dd38d8 100644 --- a/includes/specials/SpecialGather.php +++ b/includes/specials/SpecialGather.php @@ -32,39 +32,61 @@ } /** -* Render the special page and redirect the user to the editor (if page exists) +* Render the special page * -* @param string $subpage The name of the page to edit +* @param string $subpage */ public function execute( $subpage ) { - if ( $subpage ) { - $args = explode( '/', $subpage ); - // If there is a user argument, that's what we want to use - if ( isset( $args[0] ) ) { - // Show specified user's collections - $user = User::newFromName( $args[0] ); - } else { - // Otherwise use current user - $user = $this-getUser(); - } - } else { + if ( preg_match( '/^$/', $subpage ) ) { + // Root subpage. User owned collections. // For listing own lists, you need to be logged in $this-requireLogin( 'gather-anon-view-lists' ); $user = $this-getUser(); - } + $this-renderUserCollectionsList( $user ); - if ( !( $user $user-getId() ) ) { - // Invalid user - $this-renderError( new views\NotFound() ); - } else { - if ( isset( $args ) isset( $args[1] ) ) { - $id = intval( $args[1] ); - $this-renderUserCollection( $user, $id ); + } elseif ( preg_match( '/^by\/(?user\w+)\/?$/', $subpage, $matches ) ) { + // User's collections + // /by/:user = /by/:user/ + $user = User::newFromName( $matches['user'] ); + + if ( !( $user $user-getId() ) ) { + // Invalid user + $this-renderError( new views\NotFound() ); } else { $this-renderUserCollectionsList( $user ); } + + } elseif ( preg_match( '/^by\/(?user\w+)\/(?id\d+)$/', $subpage, $matches ) ) { + // Collection page + // /by/:user/:id + $id = $matches['id']; + $user = User::newFromName( $matches['user'] ); + + if ( !( $user $user-getId() ) ) { + // Invalid user + $this-renderError( new views\NotFound() ); + } else { + $this-renderUserCollection( $user, $id ); + } + + } elseif ( preg_match(
[MediaWiki-commits] [Gerrit] Avoid fatal error when a collection has an image associated ... - change (mediawiki...Gather)
Jdlrobson has uploaded a new change for review. https://gerrit.wikimedia.org/r/199628 Change subject: Avoid fatal error when a collection has an image associated with it .. Avoid fatal error when a collection has an image associated with it Visiting http://localhost:/w/index.php/Special:Gather/Jdlrobson/4 where collection 4 has an image throws a fatal. Change-Id: Ie33247644ee21e42658e4a4983f6dadeae423fbf --- M includes/models/Collection.php 1 file changed, 2 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather refs/changes/28/199628/1 diff --git a/includes/models/Collection.php b/includes/models/Collection.php index 6e62858..942d326 100644 --- a/includes/models/Collection.php +++ b/includes/models/Collection.php @@ -131,8 +131,9 @@ $lists = $data['query']['lists']; if ( count( $lists ) === 1 ) { $list = $lists[0]; + $image = $list['image'] ? wfFindFile( $list['image'] ) : null; $collection = new Collection( $id, $user, $list['label'], $list['description'], - $list['public'], $list['image'] ); + $list['public'], $image ); } } -- To view, visit https://gerrit.wikimedia.org/r/199628 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie33247644ee21e42658e4a4983f6dadeae423fbf Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Gather Gerrit-Branch: master Gerrit-Owner: Jdlrobson jrob...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] [IMPROV] Site: Return preloads in requested order - change (pywikibot/core)
XZise has uploaded a new change for review. https://gerrit.wikimedia.org/r/199631 Change subject: [IMPROV] Site: Return preloads in requested order .. [IMPROV] Site: Return preloads in requested order Instead of returning the preloaded page in the order returned by the API it caches the pages and returns them in the same order as requested. Change-Id: Ia554e81881e12e0c4d00f45d19b484baccd5e447 --- M pywikibot/site.py 1 file changed, 15 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core refs/changes/31/199631/1 diff --git a/pywikibot/site.py b/pywikibot/site.py index 457a917..70cdc3c 100644 --- a/pywikibot/site.py +++ b/pywikibot/site.py @@ -2535,9 +2535,6 @@ langlinks=False): Return a generator to a list of preloaded pages. -Note that [at least in current implementation] pages may be iterated -in a different order than in the underlying pagelist. - @param pagelist: an iterable that returns Page objects @param groupsize: how many Pages to query at a time @type groupsize: int @@ -2549,6 +2546,12 @@ pageids = [str(p._pageid) for p in sublist if hasattr(p, _pageid) and p._pageid 0] cache = dict((p.title(withSection=False), p) for p in sublist) +# Contains the page if with the same position as in the sublist if +# it has been cached +ordered_cache = [None] * len(cache) +# The position of a title in the ordered_cache +cache_index = dict((p.title(withSection=False), index) + for index, p in enumerate(sublist)) props = revisions|info|categoryinfo if templates: @@ -2565,6 +2568,7 @@ rvgen.request[urvprop] = uids|flags|timestamp|user|comment|content pywikibot.output(uRetrieving %s pages from %s. % (len(cache), self)) +yield_position = 0 for pagedata in rvgen: pywikibot.debug(uPreloading %s % pagedata, _logger) try: @@ -2592,7 +2596,14 @@ continue page = cache[pagedata['title']] api.update_page(page, pagedata, rvgen.props) -yield page +# cache it in the ordered cache +index = cache_index[pagedata['title']] +assert(ordered_cache[index] is None) +ordered_cache[index] = page +# yield any cached pages +while ordered_cache[yield_position] is not None: +yield ordered_cache[yield_position] +yield_position += 1 def validate_tokens(self, types): Validate if requested tokens are acceptable. -- To view, visit https://gerrit.wikimedia.org/r/199631 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia554e81881e12e0c4d00f45d19b484baccd5e447 Gerrit-PatchSet: 1 Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Owner: XZise commodorefabia...@gmx.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] graphite: enable locking writes - change (operations/puppet)
Filippo Giunchedi has uploaded a new change for review. https://gerrit.wikimedia.org/r/199636 Change subject: graphite: enable locking writes .. graphite: enable locking writes our graphite clustering plan involves using carbonate while carbon-cache is running, this can potentially lead to corrupted whisper files if locking isn't used, see also https://github.com/jssjr/carbonate/issues/19 Bug: T86316 Change-Id: I76b064acf3b7ccad17313a4f05c3b72b3b01b798 --- M manifests/role/graphite.pp M modules/graphite/manifests/init.pp 2 files changed, 3 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/36/199636/1 diff --git a/manifests/role/graphite.pp b/manifests/role/graphite.pp index 315539f..cc8fd96 100644 --- a/manifests/role/graphite.pp +++ b/manifests/role/graphite.pp @@ -161,6 +161,7 @@ }, storage_dir = $carbon_storage_dir, +whisper_lock_writes = true, } class { '::graphite::web': diff --git a/modules/graphite/manifests/init.pp b/modules/graphite/manifests/init.pp index f60fbb1..ad00d1f 100644 --- a/modules/graphite/manifests/init.pp +++ b/modules/graphite/manifests/init.pp @@ -13,6 +13,7 @@ $storage_schemas, $storage_aggregation = {}, $storage_dir = '/var/lib/carbon', +$whisper_lock_writes = false, ) { package { ['graphite-carbon', 'python-whisper']: } @@ -30,6 +31,7 @@ log_cache_hits = false, log_cache_queue_sorts= false, log_listener_connections = false, +whisper_lock_writes = $whisper_lock_writes, user = undef, # Don't suid; Upstart will do it for us. conf_dir = '/etc/carbon', log_dir = '/var/log/carbon', -- To view, visit https://gerrit.wikimedia.org/r/199636 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I76b064acf3b7ccad17313a4f05c3b72b3b01b798 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Filippo Giunchedi fgiunch...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] connect to metawiki.labsdb not ruwiki.labsdb - change (labs...WMT)
John F. Lewis has submitted this change and it was merged. Change subject: connect to metawiki.labsdb not ruwiki.labsdb .. connect to metawiki.labsdb not ruwiki.labsdb Change-Id: I46f015870a7d4587dd850167df23003a69d30d65 --- M bots/masters/rcreader.php 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: John F. Lewis: Verified; Looks good to me, approved diff --git a/bots/masters/rcreader.php b/bots/masters/rcreader.php index f0b28f0..5d1b5e1 100644 --- a/bots/masters/rcreader.php +++ b/bots/masters/rcreader.php @@ -14,7 +14,7 @@ // Getting the list of the wiki channels (wmirc) $replica_mycnf = parse_ini_file( __DIR__ . /../../replica.my.cnf ); -$mysql = new MySQLi ( 'ruwiki.labsdb', $replica_mycnf['user'], $replica_mycnf['password'], 'meta_p' ); +$mysql = new MySQLi ( 'metawiki.labsdb', $replica_mycnf['user'], $replica_mycnf['password'], 'meta_p' ); unset( $replica_mycnf ); $query = SELECT `dbname`,`slice`,`url` FROM `wiki` WHERE `is_closed`=0 ORDER BY `slice`; -- To view, visit https://gerrit.wikimedia.org/r/199635 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I46f015870a7d4587dd850167df23003a69d30d65 Gerrit-PatchSet: 1 Gerrit-Project: labs/tools/WMT Gerrit-Branch: master Gerrit-Owner: John F. Lewis johnflewi...@gmail.com Gerrit-Reviewer: John F. Lewis johnflewi...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Avoid fatal error when a collection has an image associated ... - change (mediawiki...Gather)
jenkins-bot has submitted this change and it was merged. Change subject: Avoid fatal error when a collection has an image associated with it .. Avoid fatal error when a collection has an image associated with it Visiting http://localhost:/w/index.php/Special:Gather/Jdlrobson/4 where collection 4 has an image throws a fatal. Change-Id: Ie33247644ee21e42658e4a4983f6dadeae423fbf --- M includes/models/Collection.php 1 file changed, 2 insertions(+), 1 deletion(-) Approvals: Jhernandez: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/models/Collection.php b/includes/models/Collection.php index 6e62858..942d326 100644 --- a/includes/models/Collection.php +++ b/includes/models/Collection.php @@ -131,8 +131,9 @@ $lists = $data['query']['lists']; if ( count( $lists ) === 1 ) { $list = $lists[0]; + $image = $list['image'] ? wfFindFile( $list['image'] ) : null; $collection = new Collection( $id, $user, $list['label'], $list['description'], - $list['public'], $list['image'] ); + $list['public'], $image ); } } -- To view, visit https://gerrit.wikimedia.org/r/199628 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ie33247644ee21e42658e4a4983f6dadeae423fbf Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Gather Gerrit-Branch: master Gerrit-Owner: Jdlrobson jrob...@wikimedia.org Gerrit-Reviewer: Jhernandez jhernan...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] planet: use https instead of http - change (operations/puppet)
John F. Lewis has uploaded a new change for review. https://gerrit.wikimedia.org/r/199638 Change subject: planet: use https instead of http .. planet: use https instead of http Since planets was moved to behind misc, the https stanza (443) was no longer needed. This removed the https redirects. As these are no longer needed as http, move them to https. Bug: T70554 Change-Id: Ic374c679c887f1f719d1a985c8fa7004b74b7d55 --- M modules/planet/templates/apache/planet.erb 1 file changed, 4 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/38/199638/1 diff --git a/modules/planet/templates/apache/planet.erb b/modules/planet/templates/apache/planet.erb index a273f86..b892f75 100644 --- a/modules/planet/templates/apache/planet.erb +++ b/modules/planet/templates/apache/planet.erb @@ -7,9 +7,9 @@ DocumentRoot /var/www/planet -Redirect /atom.xml http://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/atom.xml -Redirect /rss10.xml http://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/rss10.xml -Redirect /rss20.xml http://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/rss20.xml +Redirect /atom.xml https://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/atom.xml +Redirect /rss10.xml https://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/rss10.xml +Redirect /rss20.xml https://en.planet.%= scope.lookupvar('planet::planet_domain_name') %/rss20.xml -RedirectTemp / http://%= scope.lookupvar('planet::planet_meta_link') % +RedirectTemp / https://%= scope.lookupvar('planet::planet_meta_link') % /VirtualHost -- To view, visit https://gerrit.wikimedia.org/r/199638 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic374c679c887f1f719d1a985c8fa7004b74b7d55 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: John F. Lewis johnflewi...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Labs: Split out labstores substance into roles - change (operations/puppet)
coren has uploaded a new change for review. https://gerrit.wikimedia.org/r/199639 Change subject: Labs: Split out labstores substance into roles .. Labs: Split out labstores substance into roles Rather than make site.pp uglier Change-Id: I07e756311c44978dc39ff91d50d07cd6630b4061 --- M manifests/role/labsnfs.pp M manifests/site.pp 2 files changed, 41 insertions(+), 34 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/39/199639/1 diff --git a/manifests/role/labsnfs.pp b/manifests/role/labsnfs.pp index c0ce9ec..2135b2c 100644 --- a/manifests/role/labsnfs.pp +++ b/manifests/role/labsnfs.pp @@ -5,11 +5,14 @@ # while being populated from the actual dumps server in prod. # # The IPs of the servers allowed to populate it ($dump_servers_ips) -# must be set at the node level or via hiera +# must be set at the node level or via hiera. # class role::labs::nfs::dumps($dump_servers_ips) { +$gangla_aggregator = true; + include standard +include rsync::server package { 'nfs-kernel-server': ensure = present, @@ -23,4 +26,38 @@ mode= '0444', } +rsync::server::module { +'pagecounts': +path= '/srv/dumps/pagecounts', +read_only = 'no', +hosts_allow = $dump_servers_ips, +} + } + +# Class: role::labs::nfs::fileserver +# +# The role class for the NFS servers that provide general filesystem +# services to Labs. +# +class role::labs::nfs::fileserver { + +$gangla_aggregator = true; + +include standard + +# eqiad still uses LDAP for now +# T87870 +if $::site == 'eqiad' { +class { 'ldap::role::client::labs': +ldapincludes = ['openldap', 'nss', 'utils'], +} +} else { +include admin +} + +include openstack::project-nfs-storage-service +include openstack::replica_management_service + +} + diff --git a/manifests/site.pp b/manifests/site.pp index aed8805..c5a91f8 100644 --- a/manifests/site.pp +++ b/manifests/site.pp @@ -1336,39 +1336,14 @@ $site = 'eqiad' $cluster = 'labsnfs' -$ldapincludes = ['openldap', 'nss', 'utils'] -$ganglia_aggregator = true - -# Commented out pending some troubleshooting -# interface::aggregate { 'bond0': -# orig_interface = 'eth0', -# members= [ 'eth0', 'eth1' ], -# } - -# need to solve using admin on ldap boxes -# RT 7732 -# include admin -include standard -include openstack::project-nfs-storage-service -include openstack::replica_management_service -include rsync::server - -rsync::server::module { -'pagecounts': -path= '/srv/dumps/pagecounts', -read_only = 'no', -hosts_allow = ['208.80.154.11', '208.80.152.185']; -} - -class { 'ldap::role::client::labs': ldapincludes = $ldapincludes } - +role labs::nfs::fileserver } node 'labstore1003.eqiad.wmnet' { + $site = 'eqiad' $cluster = 'labsnfs' -$ganglia_aggregator = true role labs::nfs::dumps } @@ -1378,13 +1353,8 @@ $site = 'codfw' $cluster = 'labsnfs' -$ganglia_aggregator = true +role labs::nfs::fileserver -include admin -include standard - -# Won't configure beyond that point until labs_storage module -# (No services running on this server for now) } node 'lanthanum.eqiad.wmnet' { -- To view, visit https://gerrit.wikimedia.org/r/199639 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I07e756311c44978dc39ff91d50d07cd6630b4061 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: coren mpellet...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Bump src to 0313fcc7 for deploy - change (mediawiki...deploy)
Subramanya Sastry has uploaded a new change for review. https://gerrit.wikimedia.org/r/199644 Change subject: Bump src to 0313fcc7 for deploy .. Bump src to 0313fcc7 for deploy Change-Id: I48540d9112638e98fe27ff426f05ad153bd66631 --- M src 1 file changed, 0 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid/deploy refs/changes/44/199644/1 diff --git a/src b/src index a5d7483..0313fcc 16 --- a/src +++ b/src -Subproject commit a5d7483f4e5347d5e1fd3b48aea4084a14336f40 +Subproject commit 0313fcc74a8a012a6028a688ef6cb74a7a563017 -- To view, visit https://gerrit.wikimedia.org/r/199644 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I48540d9112638e98fe27ff426f05ad153bd66631 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/services/parsoid/deploy Gerrit-Branch: master Gerrit-Owner: Subramanya Sastry ssas...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] add sockets directory - change (labs...WMT)
John F. Lewis has submitted this change and it was merged. Change subject: add sockets directory .. add sockets directory Change-Id: I747e3e74bc4971a38e6d8e2e4a802b955db1ab26 --- A bots/tmp/sockets/.gitkeep 1 file changed, 1 insertion(+), 0 deletions(-) Approvals: John F. Lewis: Verified; Looks good to me, approved diff --git a/bots/tmp/sockets/.gitkeep b/bots/tmp/sockets/.gitkeep new file mode 100644 index 000..8b13789 --- /dev/null +++ b/bots/tmp/sockets/.gitkeep @@ -0,0 +1 @@ + -- To view, visit https://gerrit.wikimedia.org/r/199626 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I747e3e74bc4971a38e6d8e2e4a802b955db1ab26 Gerrit-PatchSet: 1 Gerrit-Project: labs/tools/WMT Gerrit-Branch: master Gerrit-Owner: John F. Lewis johnflewi...@gmail.com Gerrit-Reviewer: John F. Lewis johnflewi...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Correct typo in i18n message key - change (mediawiki...Flow)
EBernhardson has uploaded a new change for review. https://gerrit.wikimedia.org/r/199627 Change subject: Correct typo in i18n message key .. Correct typo in i18n message key Bug: T93905 Change-Id: I3554cd58def1efa84d4468ca2463d4c77ff88e9c --- M includes/Block/Topic.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Flow refs/changes/27/199627/1 diff --git a/includes/Block/Topic.php b/includes/Block/Topic.php index 719b274..0c02290 100644 --- a/includes/Block/Topic.php +++ b/includes/Block/Topic.php @@ -846,7 +846,7 @@ // flow-error-not-allowed-suppress-extract // flow-error-not-allowed-reply-to-suppress-topic-extract 'msgKey' = array( - flow-error-not-allowed-{$this-action}-to-$start-$type, + flow-error-not-allowed-{$this-action}-to-$state-$type, flow-error-not-allowed-$state-extract, ) ) -- To view, visit https://gerrit.wikimedia.org/r/199627 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3554cd58def1efa84d4468ca2463d4c77ff88e9c Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Flow Gerrit-Branch: master Gerrit-Owner: EBernhardson ebernhard...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] i18n: Remove ur and mzn from line underline supression - change (mediawiki/core)
Ebrahim has uploaded a new change for review. https://gerrit.wikimedia.org/r/199629 Change subject: i18n: Remove ur and mzn from line underline supression .. i18n: Remove ur and mzn from line underline supression Follow up to I8168baff and If55b6ea7, they applied local workaround on their Wikipedia for reverting this, lets simplify things and remove them here also. Also it seem kk-arab is not used widely but anyway I don't think they choosed to use this feature. Change-Id: Ib9ea5b9c7f034b11f7e57cf7242003e133f49930 --- M includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php 1 file changed, 1 insertion(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/29/199629/1 diff --git a/includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php b/includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php index 472ceb2..e7eda19 100644 --- a/includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php +++ b/includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php @@ -68,8 +68,7 @@ ( $options['underline'] ? 'underline' : 'none' ) . ; }; } else { # The scripts of these languages are very hard to read with underlines - $rules[] = 'a:lang(ar), a:lang(kk-arab), a:lang(mzn), ' . - 'a:lang(ps), a:lang(ur) { text-decoration: none; }'; + $rules[] = 'a:lang(ar), a:lang(ps) { text-decoration: none; }'; } if ( $options['editfont'] !== 'default' ) { // Double-check that $options['editfont'] consists of safe characters only -- To view, visit https://gerrit.wikimedia.org/r/199629 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ib9ea5b9c7f034b11f7e57cf7242003e133f49930 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Ebrahim ebra...@gnu.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add labstore200[12] minimal configuration - change (operations/puppet)
coren has submitted this change and it was merged. Change subject: Add labstore200[12] minimal configuration .. Add labstore200[12] minimal configuration No roles included for now; waiting for the proper labs_storage module this week. Change-Id: I4a0424830e5b0e011ed6fa0af536df851e80af8a --- M manifests/site.pp 1 file changed, 14 insertions(+), 0 deletions(-) Approvals: coren: Looks good to me, approved jenkins-bot: Verified diff --git a/manifests/site.pp b/manifests/site.pp index 548b9bd..aed8805 100644 --- a/manifests/site.pp +++ b/manifests/site.pp @@ -1373,6 +1373,20 @@ role labs::nfs::dumps } +node /labstore200[12]\.codfw\.wmnet/ { + +$site = 'codfw' +$cluster = 'labsnfs' + +$ganglia_aggregator = true + +include admin +include standard + +# Won't configure beyond that point until labs_storage module +# (No services running on this server for now) +} + node 'lanthanum.eqiad.wmnet' { include standard -- To view, visit https://gerrit.wikimedia.org/r/199542 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I4a0424830e5b0e011ed6fa0af536df851e80af8a Gerrit-PatchSet: 2 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: coren mpellet...@wikimedia.org Gerrit-Reviewer: RobH r...@wikimedia.org Gerrit-Reviewer: coren mpellet...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Require gather-hidelist right for mode=allhidden - change (mediawiki...Gather)
Yurik has uploaded a new change for review. https://gerrit.wikimedia.org/r/199630 Change subject: Require gather-hidelist right for mode=allhidden .. Require gather-hidelist right for mode=allhidden Bug: T93793 Change-Id: I8bdf8ce11eed6bfbd2e40d5ec3887f105e04210b --- M includes/api/ApiQueryLists.php 1 file changed, 4 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather refs/changes/30/199630/1 diff --git a/includes/api/ApiQueryLists.php b/includes/api/ApiQueryLists.php index 21d3b78..cb18e16 100644 --- a/includes/api/ApiQueryLists.php +++ b/includes/api/ApiQueryLists.php @@ -71,6 +71,10 @@ not allowed with mode=allpublic, 'invalidparammix' ); } + if ( $mode === 'allhidden' !$this-getUser()-isAllowed( 'gather-hidelist' ) ) { + $this-dieUsage( 'You don\'t have permission to view hidden lists', + 'permissiondenied' ); + } $injectWatchlist = false; $findWatchlist = false; $owner = false; -- To view, visit https://gerrit.wikimedia.org/r/199630 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8bdf8ce11eed6bfbd2e40d5ec3887f105e04210b Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Gather Gerrit-Branch: master Gerrit-Owner: Yurik yu...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Revert exim4.conf.SMTP_IMAP_MM.erb local mail can cause loops - change (operations/puppet)
Rush has uploaded a new change for review. https://gerrit.wikimedia.org/r/199634 Change subject: Revert exim4.conf.SMTP_IMAP_MM.erb local mail can cause loops .. Revert exim4.conf.SMTP_IMAP_MM.erb local mail can cause loops This reverts commit c104dd8f3da7519109cf9f55db650424936e7ffc. Change-Id: Icdbeed96dccdac87a9e965fa766672baa89abc32 --- M manifests/role/phabricator.pp M templates/exim/exim4.conf.SMTP_IMAP_MM.erb 2 files changed, 2 insertions(+), 6 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/34/199634/1 diff --git a/manifests/role/phabricator.pp b/manifests/role/phabricator.pp index 059f9a0..f10a6c0 100644 --- a/manifests/role/phabricator.pp +++ b/manifests/role/phabricator.pp @@ -25,10 +25,6 @@ description = 'Phabricator (Main)' } -mailalias { 'root': -recipient = 'r...@wikimedia.org', -} - include passwords::phabricator include role::phabricator::config include phabricator::monitoring diff --git a/templates/exim/exim4.conf.SMTP_IMAP_MM.erb b/templates/exim/exim4.conf.SMTP_IMAP_MM.erb index 83c6074..3e37f04 100644 --- a/templates/exim/exim4.conf.SMTP_IMAP_MM.erb +++ b/templates/exim/exim4.conf.SMTP_IMAP_MM.erb @@ -554,12 +554,12 @@ % end % % if !@smart_route_list.empty? then -% -# Send all mail //not destined for the local machine// via a set of +# Send all mail not destined for the local machine via a set of # mail relays (smart hosts) smart_route: driver = manualroute transport = remote_smtp - route_list = !+local_domains %= @smart_route_list.join(:) % + route_list = * %= @smart_route_list.join(:) % % end % ## -- To view, visit https://gerrit.wikimedia.org/r/199634 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Icdbeed96dccdac87a9e965fa766672baa89abc32 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Rush r...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits