[MediaWiki-commits] [Gerrit] Corrected css classes and i18n messages. - change (mediawiki...WikidataQualityConstraints)
Dominic.sauer has submitted this change and it was merged. Change subject: Corrected css classes and i18n messages. .. Corrected css classes and i18n messages. Change-Id: I7247f39382990781aa5e199c4455775f71a30db1 --- M i18n/en.json M i18n/qqq.json M modules/SpecialConstraintReportPage.css M specials/SpecialConstraintReport.php 4 files changed, 9 insertions(+), 7 deletions(-) Approvals: Dominic.sauer: Verified; Looks good to me, approved diff --git a/i18n/en.json b/i18n/en.json index 1fe6074..ed01e9f 100755 --- a/i18n/en.json +++ b/i18n/en.json @@ -7,6 +7,7 @@ wbqc-constraintreport-explanation-part-two: The constraints are parsed from the property talk pages once a week, so if you add/delete/modify a constraint it might take up to a week until this gets taken into account by this constraint report. There is currently work in progress to migrate the constraints to statements on properties, enabling this special page to do live-checks., wbqc-constraintreport-form-submit-label: Check, wbqc-constraintreport-form-entityid-placeholder: Qxx/Pxx, + wbqc-constraintreport-result-headline: Result for $1, wbqc-constraintreport-empty-result: There are no constraint defined on this entity., wbqc-constraintreport-status-violation: Violation, wbqc-constraintreport-status-compliance: Compliance, diff --git a/i18n/qqq.json b/i18n/qqq.json index f1521c7..94dd9ab 100755 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -12,7 +12,8 @@ wbqc-constraintreport-explanation-part-two: Explanation (part two), what this special page does and how it gets its data., wbqc-constraintreport-form-submit-label: Label of the button, that starts the check.\n{{Identical|Check}}, wbqc-constraintreport-form-entityid-placeholder: Entity id placeholder for the input field., - wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., +wbqc-constraintreport-result-headline: Result headline, +wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., wbqc-constraintreport-status-violation: Status for claims that are violated against a constraint., wbqc-constraintreport-status-compliance: Status for claims that comply with a constraint, wbqc-constraintreport-status-todo: Status for constraints which cannot be checked yet., diff --git a/modules/SpecialConstraintReportPage.css b/modules/SpecialConstraintReportPage.css index 5f601d8..de89095 100755 --- a/modules/SpecialConstraintReportPage.css +++ b/modules/SpecialConstraintReportPage.css @@ -1,23 +1,23 @@ /* Entity id form */ -.wbqc-checkresult-form { +.wbqc-constraintreport-form { margin-top: 10px; margin-bottom: 20px; } -.wbqc-checkresult-form-entity-id { +.wbqc-constraintreport-form-entity-id { width: 120px; } -.wbqc-checkresult-form-submit { +.wbqc-constraintreport-form-submit { margin-left: 5px; } /* Notices */ -.wbqc-checkresult-notice { +.wbqc-constraintreport-notice { font-style: italic; } -.wbqc-checkresult-notice-error { +.wbqc-constraintreport-notice-error { font-weight: bold; color: #BA; } diff --git a/specials/SpecialConstraintReport.php b/specials/SpecialConstraintReport.php index 9888255..38d436e 100755 --- a/specials/SpecialConstraintReport.php +++ b/specials/SpecialConstraintReport.php @@ -441,7 +441,7 @@ $entityId-getSerialization() ); return - Html::openElement( 'h3', array( 'class' = 'wbqc-clear' ) ) //TODO delete if not wished + Html::openElement( 'h3' ) . $this-msg( 'wbqc-constraintreport-result-headline', $entityLink )-text() . Html::closeElement( 'h3' ); } -- To view, visit https://gerrit.wikimedia.org/r/210658 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I7247f39382990781aa5e199c4455775f71a30db1 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/WikidataQualityConstraints Gerrit-Branch: master Gerrit-Owner: Soeren.oldag soeren_ol...@freenet.de Gerrit-Reviewer: Dominic.sauer dominic.sa...@yahoo.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fixed UpdateTable script. External data can now be deleted i... - change (mediawiki...WikidataQualityExternalValidation)
Dominic.sauer has submitted this change and it was merged. Change subject: Fixed UpdateTable script. External data can now be deleted in batches. .. Fixed UpdateTable script. External data can now be deleted in batches. Change-Id: Ia2a9b32770973e52a84c2d031d751182ce307a61 --- M includes/ExternalDataRepo.php M includes/UpdateTable/ImportContext.php M includes/UpdateTable/Importer.php M maintenance/UpdateTable.php 4 files changed, 26 insertions(+), 69 deletions(-) Approvals: Dominic.sauer: Verified; Looks good to me, approved diff --git a/includes/ExternalDataRepo.php b/includes/ExternalDataRepo.php index 1cc6068..6bc9fd1 100644 --- a/includes/ExternalDataRepo.php +++ b/includes/ExternalDataRepo.php @@ -130,26 +130,40 @@ * Deletes all external data of dump with given id. * * @param string $dumpId + * @param int $batchSize * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ -public function deleteOfDump( $dumpId ) { +public function deleteOfDump( $dumpId, $batchSize = 1000 ) { $this-assertIsString( $dumpId, '$dumpId' ); -return $this-deleteOfDumps( array( $dumpId ) ); +return $this-deleteOfDumps( array( $dumpId ), $batchSize ); } /** * Deletes all external data of multiple dumps with given ids. * * @param array $dumpIds + * @param int $batchSize * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ -public function deleteOfDumps( array $dumpIds ) { +public function deleteOfDumps( array $dumpIds, $batchSize = 1000 ) { $this-assertIsArrayOfStrings( $dumpIds, '$dumpIds' ); $db = wfGetDB( DB_MASTER ); +$condition = $this-buildSqlInCondition( 'dump_id', $dumpIds ); +if ( $db-getType() === 'sqlite' ) { +$db-delete( DUMP_DATA_TABLE, $condition ); +} else { +do { +$db-commit( __METHOD__, 'flush' ); +wfWaitForSlaves(); +$table = $db-tableName( DUMP_DATA_TABLE ); +$db-query( sprintf('DELETE FROM %s WHERE %s LIMIT %s', $table, $condition, $batchSize ) ); +} while ( $db-affectedRows() 0 ); +} + return $db-delete( $this-tableName, array( $this-buildSqlInCondition( 'dump_id', $dumpIds ) ) diff --git a/includes/UpdateTable/ImportContext.php b/includes/UpdateTable/ImportContext.php index b674877..12c3945 100644 --- a/includes/UpdateTable/ImportContext.php +++ b/includes/UpdateTable/ImportContext.php @@ -3,7 +3,6 @@ namespace WikidataQuality\ExternalValidation\UpdateTable; use Doctrine\Instantiator\Exception\InvalidArgumentException; -use LoadBalancer; /** @@ -25,11 +24,6 @@ private $tarFilePath; /** -* @var LoadBalancer -*/ - private $loadBalancer; - - /** * @var int */ private $batchSize; @@ -40,30 +34,14 @@ private $quiet; /** -* @param LoadBalancer $loadBalancer * @param int $batchSize * @param bool $quiet * @param string $tarFilePath */ - public function __construct( LoadBalancer $loadBalancer, $batchSize, $quiet, $tarFilePath ) { - $this-setLoadBalancer( $loadBalancer ); + public function __construct( $batchSize, $quiet, $tarFilePath ) { $this-setBatchSize( $batchSize ); $this-setQuiet( $quiet ); $this-setTarFilePath( $tarFilePath ); - } - - /** -* @return LoadBalancer -*/ - public function getLoadBalancer() { - return $this-loadBalancer; - } - - /** -* @param LoadBalancer $loadBalancer -*/ - public function setLoadBalancer( LoadBalancer $loadBalancer ) { - $this-loadBalancer = $loadBalancer; } /** diff --git a/includes/UpdateTable/Importer.php b/includes/UpdateTable/Importer.php index cc7f4c2..1506a43 100755 --- a/includes/UpdateTable/Importer.php +++ b/includes/UpdateTable/Importer.php @@ -73,9 +73,10 @@ if ( !$this-importContext-isQuiet() ) { print \n; +print Delete old database entries...\n; } -$this-externalDataRepo-deleteOfDumps( $dumpIds ); +$this-externalDataRepo-deleteOfDumps( $dumpIds, $this-importContext-getBatchSize() ); if ( !$this-importContext-isQuiet() ) { print \n; @@ -111,29 +112,6 @@ unlink( $this-dumpInformationFilePath ); } $this-dumpInformationFilePath = null; -} - -/** - * Establishes a database connection using the load balancer - * - * @return DatabaseBase - * @throws MWException - */ -protected function establishDbConnection() { -$loadBalancer = $this-importContext-getLoadBalancer(); -$db
[MediaWiki-commits] [Gerrit] Fix MultiHttpClient to return correct errors - change (mediawiki/core)
Nikerabbit has uploaded a new change for review. https://gerrit.wikimedia.org/r/210664 Change subject: Fix MultiHttpClient to return correct errors .. Fix MultiHttpClient to return correct errors Bug: T89758 Change-Id: Ia1f1986d150df1a9f463d48f1a914a04608550f8 --- M includes/libs/MultiHttpClient.php 1 file changed, 20 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/64/210664/1 diff --git a/includes/libs/MultiHttpClient.php b/includes/libs/MultiHttpClient.php index 16e0d4f..2b1e227 100644 --- a/includes/libs/MultiHttpClient.php +++ b/includes/libs/MultiHttpClient.php @@ -189,6 +189,7 @@ // @TODO: use a per-host rolling handle window (e.g. CURLMOPT_MAX_HOST_CONNECTIONS) $batches = array_chunk( $indexes, $this-maxConnsPerHost ); + $infos = array(); foreach ( $batches as $batch ) { // Attach all cURL handles for this batch @@ -201,6 +202,10 @@ // Do any available work... do { $mrc = curl_multi_exec( $chm, $active ); + $info = curl_multi_info_read( $chm ); + if ( $info !== false ) { + $infos[] = $info; + } } while ( $mrc == CURLM_CALL_MULTI_PERFORM ); // Wait (if possible) for available work... if ( $active 0 $mrc == CURLM_OK ) { @@ -216,10 +221,22 @@ foreach ( $reqs as $index = $req ) { $ch = $handles[$index]; curl_multi_remove_handle( $chm, $ch ); - if ( curl_errno( $ch ) !== 0 ) { - $req['response']['error'] = (curl error: . - curl_errno( $ch ) . ) . curl_error( $ch ); + + foreach ( $infos as $info ) { + if ( $info['handle'] !== $ch ) { + continue; + } + + $errno = $info['result']; + if ( $errno !== 0 ) { + $req['response']['error'] = (curl error: $errno); + + if ( version_compare( PHP_VERSION, '5.5.0' ) = 0 ) { + $req['response']['error'] .= . curl_strerror( $errno ); + } + } } + // For convenience with the list() operator $req['response'][0] = $req['response']['code']; $req['response'][1] = $req['response']['reason']; -- To view, visit https://gerrit.wikimedia.org/r/210664 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia1f1986d150df1a9f463d48f1a914a04608550f8 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] New Wikidata deployment build - wmf/1.26wmf6 - change (mediawiki...Wikidata)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210669 Change subject: New Wikidata deployment build - wmf/1.26wmf6 .. New Wikidata deployment build - wmf/1.26wmf6 Change-Id: If94de7ffbaa1c9c12823e40e87a9d4881f42bc68 --- M WikibaseClient.settings.php M WikibaseRepo.settings.php M composer.json M composer.lock M extensions/Wikibase/.travis.yml M extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh M extensions/Wikibase/build/travis/install.sh M extensions/Wikibase/client/WikibaseClient.i18n.alias.php M extensions/Wikibase/client/WikibaseClient.i18n.magic.php M extensions/Wikibase/client/i18n/aeb-latn.json A extensions/Wikibase/client/i18n/an.json M extensions/Wikibase/client/i18n/azb.json M extensions/Wikibase/client/i18n/be.json M extensions/Wikibase/client/i18n/ca.json M extensions/Wikibase/client/i18n/ckb.json M extensions/Wikibase/client/i18n/cy.json A extensions/Wikibase/client/i18n/ee.json M extensions/Wikibase/client/i18n/fa.json M extensions/Wikibase/client/i18n/hu.json A extensions/Wikibase/client/i18n/jv.json M extensions/Wikibase/client/i18n/ka.json M extensions/Wikibase/client/i18n/ku-latn.json M extensions/Wikibase/client/i18n/la.json M extensions/Wikibase/client/i18n/mk.json M extensions/Wikibase/client/i18n/os.json M extensions/Wikibase/client/i18n/sa.json M extensions/Wikibase/client/i18n/scn.json M extensions/Wikibase/client/i18n/si.json M extensions/Wikibase/client/i18n/so.json M extensions/Wikibase/client/i18n/szl.json M extensions/Wikibase/client/i18n/ta.json M extensions/Wikibase/client/i18n/tr.json M extensions/Wikibase/client/i18n/vec.json M extensions/Wikibase/client/i18n/xmf.json M extensions/Wikibase/client/i18n/yo.json M extensions/Wikibase/client/includes/Changes/AffectedPagesFinder.php M extensions/Wikibase/client/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibrary.php M extensions/Wikibase/client/includes/DataAccess/Scribunto/WikibaseLuaBindings.php M extensions/Wikibase/client/includes/DataAccess/Scribunto/mw.wikibase.entity.lua M extensions/Wikibase/client/includes/DataAccess/Scribunto/mw.wikibase.lua M extensions/Wikibase/client/includes/Hooks/BaseTemplateAfterPortletHandler.php M extensions/Wikibase/client/includes/Hooks/ParserAfterParseHookHandler.php M extensions/Wikibase/client/includes/Usage/SiteLinkUsageLookup.php M extensions/Wikibase/client/includes/Usage/Sql/EntityUsageTableBuilder.php M extensions/Wikibase/client/includes/Usage/Sql/UsageTableUpdater.php M extensions/Wikibase/client/includes/specials/SpecialUnconnectedPages.php M extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php M extensions/Wikibase/client/maintenance/populateEntityUsage.php M extensions/Wikibase/client/maintenance/populateInterwiki.php M extensions/Wikibase/client/maintenance/updateSubscriptions.php M extensions/Wikibase/client/resources/Resources.php M extensions/Wikibase/client/tests/phpunit/includes/Changes/AffectedPagesFinderTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/EntityAccessorTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseEntityLibraryTests.lua M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/SnakSerializationRendererTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/WikibaseLuaBindingsTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/WikibaseDataAccessTestItemSetUpHelper.php M extensions/Wikibase/client/tests/phpunit/includes/Hooks/DataUpdateHookHandlersTest.php M extensions/Wikibase/client/tests/phpunit/includes/SiteLinkCommentCreatorTest.php M extensions/Wikibase/client/tests/phpunit/includes/Usage/SiteLinkUsageLookupTest.php M extensions/Wikibase/client/tests/phpunit/includes/WikibaseClientTest.php M extensions/Wikibase/client/tests/phpunit/includes/api/PageTermsTest.php M extensions/Wikibase/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php M extensions/Wikibase/docs/lua.wiki M extensions/Wikibase/docs/options.wiki A extensions/Wikibase/lib/i18n/aeb-latn.json A extensions/Wikibase/lib/i18n/an.json A extensions/Wikibase/lib/i18n/ang.json M extensions/Wikibase/lib/i18n/bn.json M extensions/Wikibase/lib/i18n/ce.json M extensions/Wikibase/lib/i18n/cs.json M extensions/Wikibase/lib/i18n/da.json M extensions/Wikibase/lib/i18n/fa.json M extensions/Wikibase/lib/i18n/fi.json M extensions/Wikibase/lib/i18n/fr.json M extensions/Wikibase/lib/i18n/gl.json M extensions/Wikibase/lib/i18n/ilo.json M extensions/Wikibase/lib/i18n/is.json M extensions/Wikibase/lib/i18n/it.json M extensions/Wikibase/lib/i18n/lrc.json M extensions/Wikibase/lib/i18n/ms.json M
[MediaWiki-commits] [Gerrit] Corrected css classes and i18n messages. - change (mediawiki...WikidataQualityConstraints)
Soeren.oldag has uploaded a new change for review. https://gerrit.wikimedia.org/r/210658 Change subject: Corrected css classes and i18n messages. .. Corrected css classes and i18n messages. Change-Id: I7247f39382990781aa5e199c4455775f71a30db1 --- M i18n/en.json M i18n/qqq.json M modules/SpecialConstraintReportPage.css M specials/SpecialConstraintReport.php 4 files changed, 10 insertions(+), 8 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityConstraints refs/changes/58/210658/1 diff --git a/i18n/en.json b/i18n/en.json index 1fe6074..ed01e9f 100755 --- a/i18n/en.json +++ b/i18n/en.json @@ -7,6 +7,7 @@ wbqc-constraintreport-explanation-part-two: The constraints are parsed from the property talk pages once a week, so if you add/delete/modify a constraint it might take up to a week until this gets taken into account by this constraint report. There is currently work in progress to migrate the constraints to statements on properties, enabling this special page to do live-checks., wbqc-constraintreport-form-submit-label: Check, wbqc-constraintreport-form-entityid-placeholder: Qxx/Pxx, + wbqc-constraintreport-result-headline: Result for $1, wbqc-constraintreport-empty-result: There are no constraint defined on this entity., wbqc-constraintreport-status-violation: Violation, wbqc-constraintreport-status-compliance: Compliance, diff --git a/i18n/qqq.json b/i18n/qqq.json index f1521c7..94dd9ab 100755 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -12,7 +12,8 @@ wbqc-constraintreport-explanation-part-two: Explanation (part two), what this special page does and how it gets its data., wbqc-constraintreport-form-submit-label: Label of the button, that starts the check.\n{{Identical|Check}}, wbqc-constraintreport-form-entityid-placeholder: Entity id placeholder for the input field., - wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., +wbqc-constraintreport-result-headline: Result headline, +wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., wbqc-constraintreport-status-violation: Status for claims that are violated against a constraint., wbqc-constraintreport-status-compliance: Status for claims that comply with a constraint, wbqc-constraintreport-status-todo: Status for constraints which cannot be checked yet., diff --git a/modules/SpecialConstraintReportPage.css b/modules/SpecialConstraintReportPage.css index 5f601d8..de89095 100755 --- a/modules/SpecialConstraintReportPage.css +++ b/modules/SpecialConstraintReportPage.css @@ -1,23 +1,23 @@ /* Entity id form */ -.wbqc-checkresult-form { +.wbqc-constraintreport-form { margin-top: 10px; margin-bottom: 20px; } -.wbqc-checkresult-form-entity-id { +.wbqc-constraintreport-form-entity-id { width: 120px; } -.wbqc-checkresult-form-submit { +.wbqc-constraintreport-form-submit { margin-left: 5px; } /* Notices */ -.wbqc-checkresult-notice { +.wbqc-constraintreport-notice { font-style: italic; } -.wbqc-checkresult-notice-error { +.wbqc-constraintreport-notice-error { font-weight: bold; color: #BA; } diff --git a/specials/SpecialConstraintReport.php b/specials/SpecialConstraintReport.php index 9888255..5fc2d17 100755 --- a/specials/SpecialConstraintReport.php +++ b/specials/SpecialConstraintReport.php @@ -441,8 +441,8 @@ $entityId-getSerialization() ); return - Html::openElement( 'h3', array( 'class' = 'wbqc-clear' ) ) //TODO delete if not wished - . $this-msg( 'wbqc-constraintreport-result-headline', $entityLink )-text() + Html::openElement( 'h3') + . $this-msg( ' ', $entityLink )-text() . Html::closeElement( 'h3' ); } -- To view, visit https://gerrit.wikimedia.org/r/210658 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I7247f39382990781aa5e199c4455775f71a30db1 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/WikidataQualityConstraints Gerrit-Branch: master Gerrit-Owner: Soeren.oldag soeren_ol...@freenet.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fixed UpdateTable script. External data can now be deleted i... - change (mediawiki...WikidataQualityExternalValidation)
Soeren.oldag has uploaded a new change for review. https://gerrit.wikimedia.org/r/210662 Change subject: Fixed UpdateTable script. External data can now be deleted in batches. .. Fixed UpdateTable script. External data can now be deleted in batches. Change-Id: Ia2a9b32770973e52a84c2d031d751182ce307a61 --- M includes/ExternalDataRepo.php M includes/UpdateTable/ImportContext.php M includes/UpdateTable/Importer.php M maintenance/UpdateTable.php 4 files changed, 26 insertions(+), 69 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityExternalValidation refs/changes/62/210662/1 diff --git a/includes/ExternalDataRepo.php b/includes/ExternalDataRepo.php index 1cc6068..6bc9fd1 100644 --- a/includes/ExternalDataRepo.php +++ b/includes/ExternalDataRepo.php @@ -130,26 +130,40 @@ * Deletes all external data of dump with given id. * * @param string $dumpId + * @param int $batchSize * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ -public function deleteOfDump( $dumpId ) { +public function deleteOfDump( $dumpId, $batchSize = 1000 ) { $this-assertIsString( $dumpId, '$dumpId' ); -return $this-deleteOfDumps( array( $dumpId ) ); +return $this-deleteOfDumps( array( $dumpId ), $batchSize ); } /** * Deletes all external data of multiple dumps with given ids. * * @param array $dumpIds + * @param int $batchSize * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ -public function deleteOfDumps( array $dumpIds ) { +public function deleteOfDumps( array $dumpIds, $batchSize = 1000 ) { $this-assertIsArrayOfStrings( $dumpIds, '$dumpIds' ); $db = wfGetDB( DB_MASTER ); +$condition = $this-buildSqlInCondition( 'dump_id', $dumpIds ); +if ( $db-getType() === 'sqlite' ) { +$db-delete( DUMP_DATA_TABLE, $condition ); +} else { +do { +$db-commit( __METHOD__, 'flush' ); +wfWaitForSlaves(); +$table = $db-tableName( DUMP_DATA_TABLE ); +$db-query( sprintf('DELETE FROM %s WHERE %s LIMIT %s', $table, $condition, $batchSize ) ); +} while ( $db-affectedRows() 0 ); +} + return $db-delete( $this-tableName, array( $this-buildSqlInCondition( 'dump_id', $dumpIds ) ) diff --git a/includes/UpdateTable/ImportContext.php b/includes/UpdateTable/ImportContext.php index b674877..12c3945 100644 --- a/includes/UpdateTable/ImportContext.php +++ b/includes/UpdateTable/ImportContext.php @@ -3,7 +3,6 @@ namespace WikidataQuality\ExternalValidation\UpdateTable; use Doctrine\Instantiator\Exception\InvalidArgumentException; -use LoadBalancer; /** @@ -25,11 +24,6 @@ private $tarFilePath; /** -* @var LoadBalancer -*/ - private $loadBalancer; - - /** * @var int */ private $batchSize; @@ -40,30 +34,14 @@ private $quiet; /** -* @param LoadBalancer $loadBalancer * @param int $batchSize * @param bool $quiet * @param string $tarFilePath */ - public function __construct( LoadBalancer $loadBalancer, $batchSize, $quiet, $tarFilePath ) { - $this-setLoadBalancer( $loadBalancer ); + public function __construct( $batchSize, $quiet, $tarFilePath ) { $this-setBatchSize( $batchSize ); $this-setQuiet( $quiet ); $this-setTarFilePath( $tarFilePath ); - } - - /** -* @return LoadBalancer -*/ - public function getLoadBalancer() { - return $this-loadBalancer; - } - - /** -* @param LoadBalancer $loadBalancer -*/ - public function setLoadBalancer( LoadBalancer $loadBalancer ) { - $this-loadBalancer = $loadBalancer; } /** diff --git a/includes/UpdateTable/Importer.php b/includes/UpdateTable/Importer.php index cc7f4c2..1506a43 100755 --- a/includes/UpdateTable/Importer.php +++ b/includes/UpdateTable/Importer.php @@ -73,9 +73,10 @@ if ( !$this-importContext-isQuiet() ) { print \n; +print Delete old database entries...\n; } -$this-externalDataRepo-deleteOfDumps( $dumpIds ); +$this-externalDataRepo-deleteOfDumps( $dumpIds, $this-importContext-getBatchSize() ); if ( !$this-importContext-isQuiet() ) { print \n; @@ -111,29 +112,6 @@ unlink( $this-dumpInformationFilePath ); } $this-dumpInformationFilePath = null; -} - -/** - * Establishes a database connection using the load balancer - * - * @return DatabaseBase - * @throws MWException - */ -protected function
[MediaWiki-commits] [Gerrit] Breaking change: ApiQueryMessageGroups workflow format - change (mediawiki...Translate)
Nikerabbit has submitted this change and it was merged. Change subject: Breaking change: ApiQueryMessageGroups workflow format .. Breaking change: ApiQueryMessageGroups workflow format As of I7b37295e8, response properties beginning with an underscore are treated by the MediaWiki API as internal metadata, and are stripped from the response. _name and _canchange no longer have the leading underscore. If we want to preserve them, we have to either rename them to drop the underscore prefix, or mark them as non-metadata using ApiResult::setPreserveKeysList(). The former is cleaner but the latter is less invasive. See also: http://www.gossamer-threads.com/lists/wiki/wikitech/584489 Also, the way booleans are handled has changed, making all items unselectable on Special:Translate. Rather than figuring out how to make API understand these are booleans, I opted for the simple change of outputting 1 for true and absence for nothing. Change-Id: I3bc87f3a508f0026efd176f0ed14331539bc61c0 Task: T97912 --- M api/ApiQueryMessageGroups.php M resources/js/ext.translate.workflowselector.js 2 files changed, 8 insertions(+), 5 deletions(-) Approvals: Santhosh: Looks good to me, approved jenkins-bot: Verified diff --git a/api/ApiQueryMessageGroups.php b/api/ApiQueryMessageGroups.php index a948478..dcff3cf 100644 --- a/api/ApiQueryMessageGroups.php +++ b/api/ApiQueryMessageGroups.php @@ -247,8 +247,11 @@ $allowed = $user-isAllowed( $config['right'] ); } - $stateConfig[$state]['_canchange'] = $allowed; - $stateConfig[$state]['_name'] = + if ( $allowed ) { + $stateConfig[$state]['canchange'] = 1; + } + + $stateConfig[$state]['name'] = $this-msg( translate-workflow-state-$state )-text(); } } diff --git a/resources/js/ext.translate.workflowselector.js b/resources/js/ext.translate.workflowselector.js index 4ddd555..4d2c002 100644 --- a/resources/js/ext.translate.workflowselector.js +++ b/resources/js/ext.translate.workflowselector.js @@ -110,16 +110,16 @@ $state = $( 'li' ) .data( 'state', data ) - .text( data._name ); + .text( data.name ); - if ( data._canchange id !== instance.currentState ) { + if ( data.canchange id !== instance.currentState ) { $state.addClass( 'changeable' ); } else { $state.addClass( 'unchangeable' ); } if ( id === instance.currentState ) { - $display.text( instance.getStateDisplay( data._name ) ); + $display.text( instance.getStateDisplay( data.name ) ); $state.addClass( 'selected' ); } -- To view, visit https://gerrit.wikimedia.org/r/208469 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I3bc87f3a508f0026efd176f0ed14331539bc61c0 Gerrit-PatchSet: 3 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Ori.livneh o...@wikimedia.org Gerrit-Reviewer: Anomie bjor...@wikimedia.org Gerrit-Reviewer: Nikerabbit niklas.laxst...@gmail.com Gerrit-Reviewer: Santhosh santhosh.thottin...@gmail.com Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Show an invitation to translate a new article in VE, too - change (mediawiki...ContentTranslation)
Amire80 has uploaded a new change for review. https://gerrit.wikimedia.org/r/210667 Change subject: Show an invitation to translate a new article in VE, too .. Show an invitation to translate a new article in VE, too Bug: T88600 Change-Id: I51203510fa84fb27e28d325f1948d0e3f3db036e --- M modules/campaigns/ext.cx.campaigns.contributionsmenu.js 1 file changed, 15 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ContentTranslation refs/changes/67/210667/1 diff --git a/modules/campaigns/ext.cx.campaigns.contributionsmenu.js b/modules/campaigns/ext.cx.campaigns.contributionsmenu.js index 051477f..13827c8 100644 --- a/modules/campaigns/ext.cx.campaigns.contributionsmenu.js +++ b/modules/campaigns/ext.cx.campaigns.contributionsmenu.js @@ -11,9 +11,14 @@ var campaign = 'contributionsmenu'; function isPageCreation() { + var uri = mw.Uri(); + return mw.config.get( 'wgArticleId' ) === 0 mw.config.get( 'wgNamespaceNumber' ) === 0 - mw.config.get( 'wgAction' ) !== 'view'; + ( + mw.config.get( 'wgAction' ) !== 'view' || + uri.query.veaction === 'edit' + ); } function getTranslationsItem() { @@ -126,6 +131,15 @@ if ( !$.client.test( blacklist, null, true ) ) { showInvitation(); + + // Show it after creating a new article using VE + mw.hook( 've.activationComplete' ).add( function () { + var $trigger; + + $trigger = $( '#pt-mycontris a' ); + $trigger.data( 'callout' ).$dialog.find( 'li.cx-campaign-translations' ) + .replaceWith( getTranslationsItem() ); + } ); } } ); }( jQuery, mediaWiki ) ); -- To view, visit https://gerrit.wikimedia.org/r/210667 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I51203510fa84fb27e28d325f1948d0e3f3db036e Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/ContentTranslation Gerrit-Branch: master Gerrit-Owner: Amire80 amir.ahar...@mail.huji.ac.il ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Corrected css classes and i18n messages (again). - change (mediawiki...WikidataQualityConstraints)
Dominic.sauer has submitted this change and it was merged. Change subject: Corrected css classes and i18n messages (again). .. Corrected css classes and i18n messages (again). Change-Id: Icde908d96fad99899a93bdbc775bdc1436bb2a6d --- M WikibaseQualityConstraints.php M i18n/en.json M i18n/qqq.json M modules/SpecialConstraintReportPage.css M modules/SpecialConstraintReportPage.js M specials/SpecialConstraintReport.php 6 files changed, 41 insertions(+), 27 deletions(-) Approvals: Dominic.sauer: Verified; Looks good to me, approved diff --git a/WikibaseQualityConstraints.php b/WikibaseQualityConstraints.php index bd5af10..12a2c67 100755 --- a/WikibaseQualityConstraints.php +++ b/WikibaseQualityConstraints.php @@ -30,7 +30,8 @@ // Define modules $GLOBALS['wgResourceModules']['SpecialConstraintReportPage'] = array ( - 'styles' = '/modules/SpecialConstraintReportPage.css', +'styles' = '/modules/SpecialConstraintReportPage.css', +'scripts' = '/modules/SpecialConstraintReportPage.js', 'localBasePath' = __DIR__, 'remoteExtPath' = 'WikibaseQualityConstraints' ); diff --git a/i18n/en.json b/i18n/en.json index 848784f..ed01e9f 100755 --- a/i18n/en.json +++ b/i18n/en.json @@ -5,7 +5,13 @@ wbqc-constraintreport: Constraint report, wbqc-constraintreport-explanation-part-one: This special page performs constraints checks on every entity you want. The entities are fetched from the live system so every constraint violation you fix there will be instantly removed from this list., wbqc-constraintreport-explanation-part-two: The constraints are parsed from the property talk pages once a week, so if you add/delete/modify a constraint it might take up to a week until this gets taken into account by this constraint report. There is currently work in progress to migrate the constraints to statements on properties, enabling this special page to do live-checks., + wbqc-constraintreport-form-submit-label: Check, + wbqc-constraintreport-form-entityid-placeholder: Qxx/Pxx, + wbqc-constraintreport-result-headline: Result for $1, wbqc-constraintreport-empty-result: There are no constraint defined on this entity., + wbqc-constraintreport-status-violation: Violation, + wbqc-constraintreport-status-compliance: Compliance, + wbqc-constraintreport-status-todo: Todo, wbqc-constraintreport-result-table-header-claim: Claim, wbqc-constraintreport-result-table-header-constraint: Constraint, wbqc-constraintreport-result-link-to-claim: go to claim, diff --git a/i18n/qqq.json b/i18n/qqq.json index faebf27..94dd9ab 100755 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -8,8 +8,15 @@ ] }, wbqc-constraintreport: {{doc-special|ConstraintReport}}, -wbqc-constraintreport-explanation-part-one: Explanation (part one), what this special page does and how it gets its data., - wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., + wbqc-constraintreport-explanation-part-one: Explanation (part one), what this special page does and how it gets its data., + wbqc-constraintreport-explanation-part-two: Explanation (part two), what this special page does and how it gets its data., + wbqc-constraintreport-form-submit-label: Label of the button, that starts the check.\n{{Identical|Check}}, + wbqc-constraintreport-form-entityid-placeholder: Entity id placeholder for the input field., +wbqc-constraintreport-result-headline: Result headline, +wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., + wbqc-constraintreport-status-violation: Status for claims that are violated against a constraint., + wbqc-constraintreport-status-compliance: Status for claims that comply with a constraint, + wbqc-constraintreport-status-todo: Status for constraints which cannot be checked yet., wbqc-constraintreport-result-table-header-claim: Header of the column that displays a link to the claim, the used property and its value.\n{{Identical|Claim}}, wbqc-constraintreport-result-table-header-constraint: Header of the column that gives information about which constraint was checked.\n{{Identical|Constraint}}, wbqc-constraintreport-result-link-to-claim: Text for the link to a claim group on the entity page., diff --git a/modules/SpecialConstraintReportPage.css b/modules/SpecialConstraintReportPage.css index 5dcb71b..de89095 100755 --- a/modules/SpecialConstraintReportPage.css +++ b/modules/SpecialConstraintReportPage.css @@ -1,23 +1,23 @@ /* Entity id form */ -.wbqc-checkresult-form { +.wbqc-constraintreport-form { margin-top: 10px; margin-bottom: 20px; } -.wbqc-checkresult-form-entity-id { +.wbqc-constraintreport-form-entity-id {
[MediaWiki-commits] [Gerrit] Browser tests mail notifications for reading-wmf - change (integration/config)
jenkins-bot has submitted this change and it was merged. Change subject: Browser tests mail notifications for reading-wmf .. Browser tests mail notifications for reading-wmf WMF engineering got reorganized. Send Gather and MobileFrontend browser tests email notifications to reading-...@lists.wikimedia.org Bug: T98477 Change-Id: I754182eee2473926ab10a0ccce7ed70ad5161942 --- M jjb/browsertests.yaml 1 file changed, 5 insertions(+), 2 deletions(-) Approvals: Zfilipin: Looks good to me, approved jenkins-bot: Verified Objections: Hashar: There's a problem with this change, please improve diff --git a/jjb/browsertests.yaml b/jjb/browsertests.yaml index b3dfd76..1993894 100644 --- a/jjb/browsertests.yaml +++ b/jjb/browsertests.yaml @@ -26,6 +26,9 @@ - qa: emails-qa-alerts qa-ale...@lists.wikimedia.org + - reading: emails-reading +qa-ale...@lists.wikimedia.org reading-...@lists.wikimedia.org + - ULS: emails-ULS aahar...@wikimedia.org kmis...@wikimedia.org qa-ale...@lists.wikimedia.org @@ -232,7 +235,7 @@ mediawiki_credentials_id: Selenium_user-at-beta.wmflabs.org mediawiki_url: en.m.wikipedia.beta.wmflabs.org platform: linux -recipients: *emails-qa +recipients: *emails-reading repository: mediawiki/extensions/Gather jobs: @@ -264,7 +267,7 @@ mediawiki_credentials_id: Selenium_user-at-beta.wmflabs.org mediawiki_url: en.m.wikipedia.beta.wmflabs.org platform: linux -recipients: *emails-qa +recipients: *emails-reading repository: mediawiki/extensions/MobileFrontend jobs: -- To view, visit https://gerrit.wikimedia.org/r/210657 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I754182eee2473926ab10a0ccce7ed70ad5161942 Gerrit-PatchSet: 1 Gerrit-Project: integration/config Gerrit-Branch: master Gerrit-Owner: Hashar has...@free.fr Gerrit-Reviewer: Hashar has...@free.fr Gerrit-Reviewer: Zfilipin zfili...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Revert Improve detection of non-content parser runs. - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Revert Improve detection of non-content parser runs. .. Revert Improve detection of non-content parser runs. agree with the intention here, but has unintended side effects. the wikibase_item page prop gets removed when saving a client page, as do all the language links from wikibase. we need another solution. This reverts commit 851039817b336b241057332bb72f083f277e31b1. Change-Id: I016346641c11b59a26add06874ea4ff9e4646813 --- M client/includes/Hooks/ParserAfterParseHookHandler.php 1 file changed, 16 insertions(+), 12 deletions(-) Approvals: Daniel Kinzler: Looks good to me, approved jenkins-bot: Verified diff --git a/client/includes/Hooks/ParserAfterParseHookHandler.php b/client/includes/Hooks/ParserAfterParseHookHandler.php index d29cad5..f192897 100644 --- a/client/includes/Hooks/ParserAfterParseHookHandler.php +++ b/client/includes/Hooks/ParserAfterParseHookHandler.php @@ -72,22 +72,17 @@ * @return bool */ public static function onParserAfterParse( Parser $parser = null, $text = null, StripState $stripState = null ) { - if ( $parser === null ) { + // this hook tries to access repo SiteLinkTable + // it interferes with any test that parses something, like a page or a message + if ( $parser === null || defined( 'MW_PHPUNIT_TEST' ) ) { return true; } - // This hook tries to access repo SiteLinkTable - // it interferes with any test that parses something, like a page or a message. - if ( defined( 'MW_PHPUNIT_TEST' ) ) { - return true; - } + // Only run this once, for the article content and not interface stuff - // We only care about existing page content being rendered to HTML, not interface - // messages or dynamic text or template expansion via the API. - if ( $parser-getRevisionId() === null || $parser-OutputType() !== Parser::OT_HTML ) { - // CAVEAT: This means we also bail out on edit previews. To fix that, we would need - // a way to detect preview parses by looking at the Parser object. - // Perhaps WikitextContent could set some flag in the ParserOptions. + // This check needs to be here as this method is being invoked a lot, + // thus calling self::newFromGlobalState would be quite heavy + if ( $parser-getOptions()-getInterfaceMessage() ) { return true; } @@ -125,6 +120,15 @@ public function doParserAfterParse( Parser $parser ) { $title = $parser-getTitle(); + // Doing this only makes sense when actually creating html for page views, not when + // for example substing a template. + // Please note: While all cases where this matches don't need to go through this many + // that don't match (have OT_HTML) still actually wouldn't need to go through this... + // for example message parses, but we don't have a good way to identify those. + if ( $parser-OutputType() !== Parser::OT_HTML ) { + return true; + } + if ( !$this-namespaceChecker-isWikibaseEnabled( $title-getNamespace() ) ) { // shorten out return true; -- To view, visit https://gerrit.wikimedia.org/r/210666 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I016346641c11b59a26add06874ea4ff9e4646813 Gerrit-PatchSet: 3 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Aude aude.w...@gmail.com Gerrit-Reviewer: Daniel Kinzler daniel.kinz...@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] Corrected css classes and i18n messages (again). - change (mediawiki...WikidataQualityConstraints)
Soeren.oldag has uploaded a new change for review. https://gerrit.wikimedia.org/r/210659 Change subject: Corrected css classes and i18n messages (again). .. Corrected css classes and i18n messages (again). Change-Id: Icde908d96fad99899a93bdbc775bdc1436bb2a6d --- M WikibaseQualityConstraints.php M i18n/en.json M i18n/qqq.json M modules/SpecialConstraintReportPage.css M modules/SpecialConstraintReportPage.js M specials/SpecialConstraintReport.php 6 files changed, 41 insertions(+), 27 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityConstraints refs/changes/59/210659/1 diff --git a/WikibaseQualityConstraints.php b/WikibaseQualityConstraints.php index bd5af10..12a2c67 100755 --- a/WikibaseQualityConstraints.php +++ b/WikibaseQualityConstraints.php @@ -30,7 +30,8 @@ // Define modules $GLOBALS['wgResourceModules']['SpecialConstraintReportPage'] = array ( - 'styles' = '/modules/SpecialConstraintReportPage.css', +'styles' = '/modules/SpecialConstraintReportPage.css', +'scripts' = '/modules/SpecialConstraintReportPage.js', 'localBasePath' = __DIR__, 'remoteExtPath' = 'WikibaseQualityConstraints' ); diff --git a/i18n/en.json b/i18n/en.json index 848784f..ed01e9f 100755 --- a/i18n/en.json +++ b/i18n/en.json @@ -5,7 +5,13 @@ wbqc-constraintreport: Constraint report, wbqc-constraintreport-explanation-part-one: This special page performs constraints checks on every entity you want. The entities are fetched from the live system so every constraint violation you fix there will be instantly removed from this list., wbqc-constraintreport-explanation-part-two: The constraints are parsed from the property talk pages once a week, so if you add/delete/modify a constraint it might take up to a week until this gets taken into account by this constraint report. There is currently work in progress to migrate the constraints to statements on properties, enabling this special page to do live-checks., + wbqc-constraintreport-form-submit-label: Check, + wbqc-constraintreport-form-entityid-placeholder: Qxx/Pxx, + wbqc-constraintreport-result-headline: Result for $1, wbqc-constraintreport-empty-result: There are no constraint defined on this entity., + wbqc-constraintreport-status-violation: Violation, + wbqc-constraintreport-status-compliance: Compliance, + wbqc-constraintreport-status-todo: Todo, wbqc-constraintreport-result-table-header-claim: Claim, wbqc-constraintreport-result-table-header-constraint: Constraint, wbqc-constraintreport-result-link-to-claim: go to claim, diff --git a/i18n/qqq.json b/i18n/qqq.json index faebf27..94dd9ab 100755 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -8,8 +8,15 @@ ] }, wbqc-constraintreport: {{doc-special|ConstraintReport}}, -wbqc-constraintreport-explanation-part-one: Explanation (part one), what this special page does and how it gets its data., - wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., + wbqc-constraintreport-explanation-part-one: Explanation (part one), what this special page does and how it gets its data., + wbqc-constraintreport-explanation-part-two: Explanation (part two), what this special page does and how it gets its data., + wbqc-constraintreport-form-submit-label: Label of the button, that starts the check.\n{{Identical|Check}}, + wbqc-constraintreport-form-entityid-placeholder: Entity id placeholder for the input field., +wbqc-constraintreport-result-headline: Result headline, +wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., + wbqc-constraintreport-status-violation: Status for claims that are violated against a constraint., + wbqc-constraintreport-status-compliance: Status for claims that comply with a constraint, + wbqc-constraintreport-status-todo: Status for constraints which cannot be checked yet., wbqc-constraintreport-result-table-header-claim: Header of the column that displays a link to the claim, the used property and its value.\n{{Identical|Claim}}, wbqc-constraintreport-result-table-header-constraint: Header of the column that gives information about which constraint was checked.\n{{Identical|Constraint}}, wbqc-constraintreport-result-link-to-claim: Text for the link to a claim group on the entity page., diff --git a/modules/SpecialConstraintReportPage.css b/modules/SpecialConstraintReportPage.css index 5dcb71b..de89095 100755 --- a/modules/SpecialConstraintReportPage.css +++ b/modules/SpecialConstraintReportPage.css @@ -1,23 +1,23 @@ /* Entity id form */ -.wbqc-checkresult-form { +.wbqc-constraintreport-form { margin-top: 10px; margin-bottom:
[MediaWiki-commits] [Gerrit] Adding a new MariaDB master node, part of a new shard (m5) f... - change (operations/puppet)
Jcrespo has uploaded a new change for review. https://gerrit.wikimedia.org/r/210660 Change subject: Adding a new MariaDB master node, part of a new shard (m5) for miscelaneous services in labs Bug: T92693 .. Adding a new MariaDB master node, part of a new shard (m5) for miscelaneous services in labs Bug: T92693 Change-Id: I3afc0d9a475c932c625d8c5f287e51b44e8cf311 --- M manifests/site.pp 1 file changed, 10 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/60/210660/1 diff --git a/manifests/site.pp b/manifests/site.pp index 67153c5..8f82722 100644 --- a/manifests/site.pp +++ b/manifests/site.pp @@ -771,6 +771,16 @@ } } +# m5 shard +node 'db1009.eqiad.wmnet' { + +$cluster = 'mysql' +class { 'role::mariadb::misc': +shard = 'm5', +master = true, +} +} + ## researchdb s1 node 'db1047.eqiad.wmnet' { -- To view, visit https://gerrit.wikimedia.org/r/210660 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3afc0d9a475c932c625d8c5f287e51b44e8cf311 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Jcrespo jcre...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Change beta-update-databases to python script - change (integration/config)
jenkins-bot has submitted this change and it was merged. Change subject: Change beta-update-databases to python script .. Change beta-update-databases to python script Should be merged after the puppet repo change addint the script (Ie063022b7b4bfc7fa4e1dac2fd15f32bf3a02d3d) Bug: T96199 Bug: T98342 Change-Id: Ida843ac40009150c9398caeef1061c81f667aa0f --- M jjb/beta.yaml 1 file changed, 8 insertions(+), 54 deletions(-) Approvals: Hashar: Looks good to me, approved jenkins-bot: Verified diff --git a/jjb/beta.yaml b/jjb/beta.yaml index 7e3603a..ecaa864 100644 --- a/jjb/beta.yaml +++ b/jjb/beta.yaml @@ -60,71 +60,25 @@ # Job to run MediaWiki update.php script on all the beta wikis. # -# It is a matrix job which is a very nice feature in Jenkins to have a job run -# with different input parameters. It is current drawback is that the list of -# databases is hardcoded in the Jenkins job (ie below) when it should really be -# generated out of the current list of database (which is all-labs.dblist in -# the repository operations/mediawiki-config.git). FIXME We should workaround -# this by having an integration test that would make sure boths repositories -# are in sync. +# Set TMPDIR to point to the tmpfs if it exists. - job-template: name: beta-update-databases-{datacenter} defaults: beta node: deployment-bastion-{datacenter} -project-type: matrix - -axes: - - axis: -type: label-expression -name: label -values: - - deployment-bastion-{datacenter} - - axis: -type: user-defined -name: wikidb -values: - - aawiki - - arwiki - - cawiki - - commonswiki - - deploymentwiki - - dewiki - - ee_prototypewiki - - enwiki - - en_rtlwiki - - enwikibooks - - enwikinews - - enwikiquote - - enwikisource - - enwikiversity - - enwiktionary - - eowiki - - eswiki - - fawiki - - hewiki - - hiwiki - - jawiki - - kowiki - - loginwiki - - metawiki - - ruwiki - - simplewiki - - sqwiki - - testwiki - - ukwiki - - wikidatawiki - - zhwiki - -# The 'wikidb' axis defined above is exported by Jenkins as an -# environnement variable. Makes it trivial to run on all databases. builders: - - shell: mwscript update.php --wiki=$wikidb --quick + - global-setup + - shell: | + . /srv/deployment/integration/slave-scripts/bin/global-set-env.sh + /usr/local/bin/wmf-beta-update-databases.py publishers: + - global-teardown - beta-irc wrappers: + - ansicolor + - timestamps - timeout: timeout: 45 -- To view, visit https://gerrit.wikimedia.org/r/210619 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ida843ac40009150c9398caeef1061c81f667aa0f Gerrit-PatchSet: 3 Gerrit-Project: integration/config Gerrit-Branch: master Gerrit-Owner: Thcipriani tcipri...@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 Improve detection of non-content parser runs. - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210666 Change subject: Revert Improve detection of non-content parser runs. .. Revert Improve detection of non-content parser runs. agree with the intention here, but has unintended side effects. the wikibase_item page prop gets moved when saving a client page, as do all the language links from wikibase. we need another solution. This reverts commit 851039817b336b241057332bb72f083f277e31b1. Change-Id: I016346641c11b59a26add06874ea4ff9e4646813 --- M client/includes/Hooks/ParserAfterParseHookHandler.php 1 file changed, 16 insertions(+), 12 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/66/210666/1 diff --git a/client/includes/Hooks/ParserAfterParseHookHandler.php b/client/includes/Hooks/ParserAfterParseHookHandler.php index d29cad5..f192897 100644 --- a/client/includes/Hooks/ParserAfterParseHookHandler.php +++ b/client/includes/Hooks/ParserAfterParseHookHandler.php @@ -72,22 +72,17 @@ * @return bool */ public static function onParserAfterParse( Parser $parser = null, $text = null, StripState $stripState = null ) { - if ( $parser === null ) { + // this hook tries to access repo SiteLinkTable + // it interferes with any test that parses something, like a page or a message + if ( $parser === null || defined( 'MW_PHPUNIT_TEST' ) ) { return true; } - // This hook tries to access repo SiteLinkTable - // it interferes with any test that parses something, like a page or a message. - if ( defined( 'MW_PHPUNIT_TEST' ) ) { - return true; - } + // Only run this once, for the article content and not interface stuff - // We only care about existing page content being rendered to HTML, not interface - // messages or dynamic text or template expansion via the API. - if ( $parser-getRevisionId() === null || $parser-OutputType() !== Parser::OT_HTML ) { - // CAVEAT: This means we also bail out on edit previews. To fix that, we would need - // a way to detect preview parses by looking at the Parser object. - // Perhaps WikitextContent could set some flag in the ParserOptions. + // This check needs to be here as this method is being invoked a lot, + // thus calling self::newFromGlobalState would be quite heavy + if ( $parser-getOptions()-getInterfaceMessage() ) { return true; } @@ -125,6 +120,15 @@ public function doParserAfterParse( Parser $parser ) { $title = $parser-getTitle(); + // Doing this only makes sense when actually creating html for page views, not when + // for example substing a template. + // Please note: While all cases where this matches don't need to go through this many + // that don't match (have OT_HTML) still actually wouldn't need to go through this... + // for example message parses, but we don't have a good way to identify those. + if ( $parser-OutputType() !== Parser::OT_HTML ) { + return true; + } + if ( !$this-namespaceChecker-isWikibaseEnabled( $title-getNamespace() ) ) { // shorten out return true; -- To view, visit https://gerrit.wikimedia.org/r/210666 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I016346641c11b59a26add06874ea4ff9e4646813 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Aude aude.w...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Fix duplicate 'new' tag and menu item CTA - change (mediawiki...Gather)
Jhernandez has uploaded a new change for review. https://gerrit.wikimedia.org/r/210668 Change subject: Fix duplicate 'new' tag and menu item CTA .. Fix duplicate 'new' tag and menu item CTA * Do not append the tutorial or the menu tag if there already exists one. * Only emit the comletion event once on CollectionEditOverlay (hide is always called in those cases, no need to emit it explicitly). * Only listen to 'collection-edit-completed' once for every collection creation (was keeping the listening of previous created collections and triggering the handler for the event multiple times). Bug: T98947 Change-Id: Ie5f7f6d7149d1c42eeb6a769c8fb0de3864bc1cc --- M resources/ext.gather.collection.editor/CollectionEditOverlay.js M resources/ext.gather.init/init.js M resources/ext.gather.watchstar/CollectionsContentOverlay.js 3 files changed, 17 insertions(+), 11 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather refs/changes/68/210668/1 diff --git a/resources/ext.gather.collection.editor/CollectionEditOverlay.js b/resources/ext.gather.collection.editor/CollectionEditOverlay.js index 08e6936..836c61e 100644 --- a/resources/ext.gather.collection.editor/CollectionEditOverlay.js +++ b/resources/ext.gather.collection.editor/CollectionEditOverlay.js @@ -240,13 +240,12 @@ } else { toast.show( self.options.editSuccessMsg, 'toast' ); } + self.hide(); self._reloadCollection(); - self._emitCompleted(); } ); } else if ( this._stateChanged ) { this.hide(); this._reloadCollection(); - this._emitCompleted(); } else { // nothing to do. this.hide(); diff --git a/resources/ext.gather.init/init.js b/resources/ext.gather.init/init.js index e06b6bf..286fdf2 100644 --- a/resources/ext.gather.init/init.js +++ b/resources/ext.gather.init/init.js @@ -98,17 +98,24 @@ showPointer( watchstar ); } watchstar.on( 'completed', function ( firstTimeUser, isNewCollection ) { + var $menuItem = $( '#mw-mf-page-left .collection-menu-item' ); if ( isNewCollection ) { // FIXME: Rename pointer overlay? - new PageActionOverlay( { - target: $( '#mw-mf-main-menu-button' ), - summary: mw.msg( 'gather-menu-guider' ), - cancelMsg: mw.msg( 'gather-add-to-collection-cancel' ) - } ).show(); + // Only append the overlay if it is not there yet + if ( $( '#mw-mf-page-center .tutorial-overlay' ).length === 0 ) { + new PageActionOverlay( { + target: $( '#mw-mf-main-menu-button' ), + summary: mw.msg( 'gather-menu-guider' ), + cancelMsg: mw.msg( 'gather-add-to-collection-cancel' ) + } ).show(); + } // FIXME: Hacky.. Should use MainMenu but Bug: T93257. - new Tag( { - label: 'new' - } ).appendTo( '#mw-mf-page-left .collection-menu-item' ); + // Only append the tag if there is none. + if ( $menuItem.find( '.gather-tag' ).length === 0 ) { + new Tag( { + label: 'new' + } ).appendTo( $menuItem ); + } } } ); } diff --git a/resources/ext.gather.watchstar/CollectionsContentOverlay.js b/resources/ext.gather.watchstar/CollectionsContentOverlay.js index 6456989..6c23cca 100644 --- a/resources/ext.gather.watchstar/CollectionsContentOverlay.js +++ b/resources/ext.gather.watchstar/CollectionsContentOverlay.js @@ -361,7 +361,7 @@ return api.addCollection( title ).done( function ( collection ) { api.addPageToCollection( collection.id, page ).done( function () { self._collectionStateChange( collection, true );
[MediaWiki-commits] [Gerrit] Browser tests mail notifications for reading-wmf - change (integration/config)
Hashar has uploaded a new change for review. https://gerrit.wikimedia.org/r/210657 Change subject: Browser tests mail notifications for reading-wmf .. Browser tests mail notifications for reading-wmf WMF engineering got reorganized. Send Gather and MobileFrontend browser tests email notifications to reading-...@lists.wikimedia.org Bug: T98477 Change-Id: I754182eee2473926ab10a0ccce7ed70ad5161942 --- M jjb/browsertests.yaml 1 file changed, 5 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/integration/config refs/changes/57/210657/1 diff --git a/jjb/browsertests.yaml b/jjb/browsertests.yaml index b3dfd76..1993894 100644 --- a/jjb/browsertests.yaml +++ b/jjb/browsertests.yaml @@ -26,6 +26,9 @@ - qa: emails-qa-alerts qa-ale...@lists.wikimedia.org + - reading: emails-reading +qa-ale...@lists.wikimedia.org reading-...@lists.wikimedia.org + - ULS: emails-ULS aahar...@wikimedia.org kmis...@wikimedia.org qa-ale...@lists.wikimedia.org @@ -232,7 +235,7 @@ mediawiki_credentials_id: Selenium_user-at-beta.wmflabs.org mediawiki_url: en.m.wikipedia.beta.wmflabs.org platform: linux -recipients: *emails-qa +recipients: *emails-reading repository: mediawiki/extensions/Gather jobs: @@ -264,7 +267,7 @@ mediawiki_credentials_id: Selenium_user-at-beta.wmflabs.org mediawiki_url: en.m.wikipedia.beta.wmflabs.org platform: linux -recipients: *emails-qa +recipients: *emails-reading repository: mediawiki/extensions/MobileFrontend jobs: -- To view, visit https://gerrit.wikimedia.org/r/210657 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I754182eee2473926ab10a0ccce7ed70ad5161942 Gerrit-PatchSet: 1 Gerrit-Project: integration/config Gerrit-Branch: master Gerrit-Owner: Hashar has...@free.fr ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Drop BC code for MediaWiki 1.22 - change (mediawiki...Translate)
jenkins-bot has submitted this change and it was merged. Change subject: Drop BC code for MediaWiki 1.22 .. Drop BC code for MediaWiki 1.22 Minimum MediaWiki version is now 1.23, as has been indicated for a quarter on https://www.mediawiki.org/wiki/Extension:Translate already. Updated few comments, @copyright cleanup as per earlier similar changes. Change-Id: Ic36d7f728824606edc0fbc104542825575f609b8 --- M Autoload.php D PageTranslation.i18n.php D Translate.i18n.php M Translate.php D TranslateGroupDescriptions.i18n.php D TranslateSandbox.i18n.php D TranslateSearch.i18n.php M specials/SpecialAggregateGroups.php M specials/SpecialImportTranslations.php M specials/SpecialLanguageStats.php M specials/SpecialMagic.php M specials/SpecialManageGroups.php M specials/SpecialManageTranslatorSandbox.php M specials/SpecialMessageGroupStats.php M specials/SpecialMyLanguage.php M specials/SpecialPageMigration.php M specials/SpecialPagePreparation.php M specials/SpecialSearchTranslations.php M specials/SpecialSupportedLanguages.php M specials/SpecialTranslate.php M specials/SpecialTranslationStash.php M specials/SpecialTranslationStats.php M specials/SpecialTranslations.php D specials/TranslateSpecialPage.php M tag/SpecialPageTranslation.php M tag/SpecialPageTranslationDeletePage.php M tag/SpecialPageTranslationMovePage.php M tests/phpunit/SpecialPagesTest.php M utils/MessageIndex.php 29 files changed, 101 insertions(+), 318 deletions(-) Approvals: Santhosh: Looks good to me, approved jenkins-bot: Verified diff --git a/Autoload.php b/Autoload.php index 3d522e8..658e295 100644 --- a/Autoload.php +++ b/Autoload.php @@ -37,7 +37,6 @@ * There are few more special pages in page translation section. * @{ */ -$al['TranslateSpecialPage'] = $dir/specials/TranslateSpecialPage.php; $al['SpecialAggregateGroups'] = $dir/specials/SpecialAggregateGroups.php; $al['SpecialImportTranslations'] = $dir/specials/SpecialImportTranslations.php; $al['SpecialLanguageStats'] = $dir/specials/SpecialLanguageStats.php; diff --git a/PageTranslation.i18n.php b/PageTranslation.i18n.php deleted file mode 100644 index 2a4719b..000 --- a/PageTranslation.i18n.php +++ /dev/null @@ -1,35 +0,0 @@ -?php -/** - * This is a backwards-compatibility shim, generated by: - * https://git.wikimedia.org/blob/mediawiki%2Fcore.git/HEAD/maintenance%2FgenerateJsonI18n.php - * - * Beginning with MediaWiki 1.23, translation strings are stored in json files, - * and the EXTENSION.i18n.php file only exists to provide compatibility with - * older releases of MediaWiki. For more information about this migration, see: - * https://www.mediawiki.org/wiki/Requests_for_comment/Localisation_format - * - * This shim maintains compatibility back to MediaWiki 1.17. - */ -$messages = array(); -if ( !function_exists( 'wfJsonI18nShimc5096afb82829a9f' ) ) { - function wfJsonI18nShimc5096afb82829a9f( $cache, $code, $cachedData ) { - $codeSequence = array_merge( array( $code ), $cachedData['fallbackSequence'] ); - foreach ( $codeSequence as $csCode ) { - $fileName = dirname( __FILE__ ) . /i18n/pagetranslation/$csCode.json; - if ( is_readable( $fileName ) ) { - $data = FormatJson::decode( file_get_contents( $fileName ), true ); - foreach ( array_keys( $data ) as $key ) { - if ( $key === '' || $key[0] === '@' ) { - unset( $data[$key] ); - } - } - $cachedData['messages'] = array_merge( $data, $cachedData['messages'] ); - } - - $cachedData['deps'][] = new FileDependency( $fileName ); - } - return true; - } - - $GLOBALS['wgHooks']['LocalisationCacheRecache'][] = 'wfJsonI18nShimc5096afb82829a9f'; -} diff --git a/Translate.i18n.php b/Translate.i18n.php deleted file mode 100644 index ac594e1..000 --- a/Translate.i18n.php +++ /dev/null @@ -1,35 +0,0 @@ -?php -/** - * This is a backwards-compatibility shim, generated by: - * https://git.wikimedia.org/blob/mediawiki%2Fcore.git/HEAD/maintenance%2FgenerateJsonI18n.php - * - * Beginning with MediaWiki 1.23, translation strings are stored in json files, - * and the EXTENSION.i18n.php file only exists to provide compatibility with - * older releases of MediaWiki. For more information about this migration, see: - * https://www.mediawiki.org/wiki/Requests_for_comment/Localisation_format - * - * This shim maintains compatibility back to MediaWiki 1.17. - */ -$messages = array(); -if ( !function_exists( 'wfJsonI18nShim2a9d547473babbda' ) ) { - function wfJsonI18nShim2a9d547473babbda( $cache, $code, $cachedData ) { - $codeSequence =
[MediaWiki-commits] [Gerrit] Fixed UpdateTable script. External data can now be deleted i... - change (mediawiki...WikidataQualityExternalValidation)
Soeren.oldag has uploaded a new change for review. https://gerrit.wikimedia.org/r/210661 Change subject: Fixed UpdateTable script. External data can now be deleted in batches. .. Fixed UpdateTable script. External data can now be deleted in batches. Change-Id: Ia2a9b32770973e52a84c2d031d751182ce307a61 --- M includes/ExternalDataRepo.php M includes/UpdateTable/ImportContext.php M includes/UpdateTable/Importer.php M maintenance/UpdateTable.php 4 files changed, 26 insertions(+), 69 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityExternalValidation refs/changes/61/210661/1 diff --git a/includes/ExternalDataRepo.php b/includes/ExternalDataRepo.php index 1cc6068..6bc9fd1 100644 --- a/includes/ExternalDataRepo.php +++ b/includes/ExternalDataRepo.php @@ -130,26 +130,40 @@ * Deletes all external data of dump with given id. * * @param string $dumpId + * @param int $batchSize * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ -public function deleteOfDump( $dumpId ) { +public function deleteOfDump( $dumpId, $batchSize = 1000 ) { $this-assertIsString( $dumpId, '$dumpId' ); -return $this-deleteOfDumps( array( $dumpId ) ); +return $this-deleteOfDumps( array( $dumpId ), $batchSize ); } /** * Deletes all external data of multiple dumps with given ids. * * @param array $dumpIds + * @param int $batchSize * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ -public function deleteOfDumps( array $dumpIds ) { +public function deleteOfDumps( array $dumpIds, $batchSize = 1000 ) { $this-assertIsArrayOfStrings( $dumpIds, '$dumpIds' ); $db = wfGetDB( DB_MASTER ); +$condition = $this-buildSqlInCondition( 'dump_id', $dumpIds ); +if ( $db-getType() === 'sqlite' ) { +$db-delete( DUMP_DATA_TABLE, $condition ); +} else { +do { +$db-commit( __METHOD__, 'flush' ); +wfWaitForSlaves(); +$table = $db-tableName( DUMP_DATA_TABLE ); +$db-query( sprintf('DELETE FROM %s WHERE %s LIMIT %s', $table, $condition, $batchSize ) ); +} while ( $db-affectedRows() 0 ); +} + return $db-delete( $this-tableName, array( $this-buildSqlInCondition( 'dump_id', $dumpIds ) ) diff --git a/includes/UpdateTable/ImportContext.php b/includes/UpdateTable/ImportContext.php index b674877..12c3945 100644 --- a/includes/UpdateTable/ImportContext.php +++ b/includes/UpdateTable/ImportContext.php @@ -3,7 +3,6 @@ namespace WikidataQuality\ExternalValidation\UpdateTable; use Doctrine\Instantiator\Exception\InvalidArgumentException; -use LoadBalancer; /** @@ -25,11 +24,6 @@ private $tarFilePath; /** -* @var LoadBalancer -*/ - private $loadBalancer; - - /** * @var int */ private $batchSize; @@ -40,30 +34,14 @@ private $quiet; /** -* @param LoadBalancer $loadBalancer * @param int $batchSize * @param bool $quiet * @param string $tarFilePath */ - public function __construct( LoadBalancer $loadBalancer, $batchSize, $quiet, $tarFilePath ) { - $this-setLoadBalancer( $loadBalancer ); + public function __construct( $batchSize, $quiet, $tarFilePath ) { $this-setBatchSize( $batchSize ); $this-setQuiet( $quiet ); $this-setTarFilePath( $tarFilePath ); - } - - /** -* @return LoadBalancer -*/ - public function getLoadBalancer() { - return $this-loadBalancer; - } - - /** -* @param LoadBalancer $loadBalancer -*/ - public function setLoadBalancer( LoadBalancer $loadBalancer ) { - $this-loadBalancer = $loadBalancer; } /** diff --git a/includes/UpdateTable/Importer.php b/includes/UpdateTable/Importer.php index cc7f4c2..1506a43 100755 --- a/includes/UpdateTable/Importer.php +++ b/includes/UpdateTable/Importer.php @@ -73,9 +73,10 @@ if ( !$this-importContext-isQuiet() ) { print \n; +print Delete old database entries...\n; } -$this-externalDataRepo-deleteOfDumps( $dumpIds ); +$this-externalDataRepo-deleteOfDumps( $dumpIds, $this-importContext-getBatchSize() ); if ( !$this-importContext-isQuiet() ) { print \n; @@ -111,29 +112,6 @@ unlink( $this-dumpInformationFilePath ); } $this-dumpInformationFilePath = null; -} - -/** - * Establishes a database connection using the load balancer - * - * @return DatabaseBase - * @throws MWException - */ -protected function
[MediaWiki-commits] [Gerrit] New Wikidata Build - 2015-05-13T10:00:01+0000 - change (mediawiki...Wikidata)
jenkins-bot has submitted this change and it was merged. Change subject: New Wikidata Build - 2015-05-13T10:00:01+ .. New Wikidata Build - 2015-05-13T10:00:01+ Change-Id: I393686a6b5bf43b8e0b39b96ee8b114f551b38b4 --- M composer.lock M extensions/Wikibase/client/WikibaseClient.i18n.alias.php M extensions/Wikibase/client/WikibaseClient.i18n.magic.php M extensions/Wikibase/client/includes/DataAccess/Scribunto/mw.wikibase.entity.lua M extensions/Wikibase/client/includes/DataAccess/Scribunto/mw.wikibase.lua M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseEntityLibraryTests.lua M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua M extensions/Wikibase/client/tests/phpunit/includes/api/PageTermsTest.php M extensions/Wikibase/lib/includes/ClaimGuidValidator.php M extensions/Wikibase/lib/includes/PidLock.php M extensions/Wikibase/lib/includes/Validators/UrlValidator.php M extensions/Wikibase/lib/includes/changes/ChangeRow.php M extensions/Wikibase/lib/includes/parsers/MediaWikiNumberUnlocalizer.php M extensions/Wikibase/lib/includes/serializers/SerializationOptions.php M extensions/Wikibase/repo/Wikibase.i18n.alias.php M extensions/Wikibase/repo/i18n/be-tarask.json M extensions/Wikibase/repo/i18n/de.json M extensions/Wikibase/repo/i18n/gl.json M extensions/Wikibase/repo/i18n/zh-hans.json M extensions/Wikibase/repo/includes/LinkedData/HttpAcceptParser.php M extensions/Wikibase/repo/includes/content/DeferredCopyEntityHolder.php M extensions/Wikibase/repo/includes/content/DeferredDecodingEntityHolder.php M extensions/Wikibase/repo/includes/content/EntityHolder.php M extensions/Wikibase/repo/includes/content/EntityInstanceHolder.php M extensions/Wikibase/repo/includes/rdf/RdfVocabulary.php M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q4_all.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q4_minimal.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q4_statements.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q4_values.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q6_no_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q6_with_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q7_all_refs_seen.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q7_no_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q7_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q10_redirect.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q1_info.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q1_simple.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q2_labels.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q3_links.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q3_sitelinks.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_all_statements.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_claims.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_props.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_resolved.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_truthy_statements.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_values.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q5_badges.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q6_no_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q6_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q6_with_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q7_Q9_dedup.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q7_no_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q7_references.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q7_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q8_baddates.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dump_empty.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dump_entities.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dump_redirect.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dump_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dumpheader.nt M extensions/Wikibase/repo/tests/phpunit/includes/Validators/SnakValidatorTest.php M extensions/Wikibase/repo/tests/phpunit/includes/content/DeferredDecodingEntityHolderTest.php M extensions/Wikibase/repo/tests/phpunit/includes/content/ItemContentTest.php M extensions/Wikibase/repo/tests/phpunit/includes/rdf/ComplexValueRdfBuilderTest.php M extensions/Wikibase/repo/tests/phpunit/includes/specials/SpecialMergeItemsTest.php M extensions/Wikibase/repo/tests/phpunit/includes/store/sql/SqlChangeDispatchCoordinatorTest.php M vendor/composer/installed.json 67 files changed, 963 insertions(+), 888
[MediaWiki-commits] [Gerrit] config: Updated language list - change (mediawiki...cxserver)
KartikMistry has uploaded a new change for review. https://gerrit.wikimedia.org/r/210656 Change subject: config: Updated language list .. config: Updated language list Change-Id: I27017fba049ff3802d3568b33c38930a8a2c7203 --- M config.defaults.js 1 file changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/cxserver refs/changes/56/210656/1 diff --git a/config.defaults.js b/config.defaults.js index 4d09451..4358933 100644 --- a/config.defaults.js +++ b/config.defaults.js @@ -23,8 +23,8 @@ cert: null, // Service registry registry: { - source: [ 'af', 'ak', 'an', 'ar', 'ast', 'az', 'ba', 'bg', 'bm', 'bs', 'ca', 'ceb', 'cr', 'cs', 'cv', 'cy', 'de', 'ee', 'el', 'en', 'eo', 'es', 'eu', 'ff', 'fr', 'gl', 'gu', 'hi', 'hr', 'id', 'it', 'ja', 'kg', 'ki', 'kk', 'km', 'kn', 'koi', 'kv', 'ky', 'kz', 'lg', 'lez', 'min', 'mk', 'ms', 'mt', 'nl', 'no', 'nn', 'ny', 'oc', 'om', 'pa', 'pl', 'pt', 'rn', 'ru', 'sah', 'sg', 'sh', 'simple', 'sl', 'ss', 'st', 'ti', 'tn', 'tr', 'ts', 'tt', 'tyv', 'tum', 'tw', 'udm', 'uk', 'ur', 'uz', 've', 'vi', 'war', 'xh', 'zh', 'zu' ], - target: [ 'af', 'ak', 'an', 'ar', 'ast', 'az', 'ba', 'bg', 'bm', 'bs', 'ca', 'ceb', 'cr', 'cs', 'cv', 'cy', 'ee', 'el', 'eo', 'es', 'eu', 'ff', 'fr', 'gl', 'gu', 'hi', 'hr', 'id', 'it', 'ja', 'kg', 'ki', 'kk', 'km', 'kn', 'koi', 'kv', 'ky', 'kz', 'lg', 'lez', 'min', 'mk', 'ms', 'mt', 'nl', 'no', 'nn', 'ny', 'oc', 'om', 'pa', 'pl', 'pt', 'rn', 'ru', 'sah', 'sg', 'sh', 'simple', 'sl', 'ss', 'st', 'ti', 'tn', 'tr', 'ts', 'tt', 'tyv', 'tum', 'tw', 'udm', 'uk', 'ur', 'uz', 've', 'vi', 'war', 'xh', 'zh', 'zu' ], + source: [ 'ab', 'af', 'ak', 'an', 'ar', 'ast', 'az', 'ba', 'bg', 'bm', 'bs', 'ca', 'ceb', 'cr', 'cs', 'cv', 'cy', 'da', 'de', 'ee', 'el', 'en', 'eo', 'es', 'eu', 'ff', 'fr', 'gag', 'gl', 'gu', 'hi', 'hr', 'id', 'it', 'ja', 'kaa', 'kbd', 'kg', 'ki', 'kk', 'km', 'kn', 'koi', 'krc', 'kv', 'ky', 'kz', 'lad', 'lg', 'lez', 'min', 'mk', 'ms', 'mt', 'mw', 'nl', 'no', 'nn', 'ny', 'oc', 'om', 'os', 'pa', 'pl', 'pt', 'rmy', 'rn', 'roa-rup', 'ru', 'sah', 'sg', 'sh', 'simple', 'sl', 'sq', 'ss', 'st', 'sv', 'ti', 'tn', 'tr', 'ts', 'tt', 'tum', 'tyv', 'tw', 'udm', 'uk', 'ur', 'uz', 've', 'vi', 'war', 'xh', 'zh', 'zu' ], + target: [ 'ab', 'af', 'ak', 'an', 'ar', 'ast', 'az', 'ba', 'bg', 'bm', 'bs', 'ca', 'ceb', 'cr', 'cs', 'cv', 'cy', 'da', 'ee', 'el', 'eo', 'es', 'eu', 'ff', 'fr', 'gag', 'gl', 'gu', 'hi', 'hr', 'id', 'it', 'ja', 'kaa', 'kbd', 'kg', 'ki', 'kk', 'km', 'kn', 'koi', 'krc', 'kv', 'ky', 'kz', 'lad', 'lg', 'lez', 'min', 'mk', 'ms', 'mt', 'mwl', 'nl', 'no', 'nn', 'ny', 'oc', 'om', 'os', 'pa', 'pl', 'pt', 'rmy', 'rn', 'roa-rup', 'ru', 'sah', 'sg', 'sh', 'simple', 'sl', 'sq', 'ss', 'st', 'sv', 'ti', 'tn', 'tr', 'ts', 'tt', 'tyv', 'tum', 'tw', 'udm', 'uk', 'ur', 'uz', 've', 'vi', 'war', 'xh', 'zh', 'zu' ], mt: { Apertium: { af: [ 'nl' ], -- To view, visit https://gerrit.wikimedia.org/r/210656 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I27017fba049ff3802d3568b33c38930a8a2c7203 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/services/cxserver Gerrit-Branch: master Gerrit-Owner: KartikMistry kartik.mis...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Create global variables related to mediawiki.ui icons - change (mediawiki/core)
jenkins-bot has submitted this change and it was merged. Change subject: Create global variables related to mediawiki.ui icons .. Create global variables related to mediawiki.ui icons Change-Id: I6f2e64592e8985c9c14f88b0e91df1d0314a27d0 --- M resources/src/mediawiki.less/mediawiki.ui/variables.less M resources/src/mediawiki.ui/components/icons.less 2 files changed, 10 insertions(+), 8 deletions(-) Approvals: Bartosz Dziewoński: Looks good to me, approved jenkins-bot: Verified diff --git a/resources/src/mediawiki.less/mediawiki.ui/variables.less b/resources/src/mediawiki.less/mediawiki.ui/variables.less index e91302b..f6bf382 100644 --- a/resources/src/mediawiki.less/mediawiki.ui/variables.less +++ b/resources/src/mediawiki.less/mediawiki.ui/variables.less @@ -60,3 +60,8 @@ // Global border radius to be used to buttons and inputs @borderRadius: 2px; + + +// Icon related variables +@iconSize: 1.4em; +@iconGutterWidth: 1em; diff --git a/resources/src/mediawiki.ui/components/icons.less b/resources/src/mediawiki.ui/components/icons.less index ad951b0..5107f8e 100644 --- a/resources/src/mediawiki.ui/components/icons.less +++ b/resources/src/mediawiki.ui/components/icons.less @@ -1,8 +1,5 @@ @import mediawiki.mixins; - -// Variables -@iconSize: 1.4em; -@gutterWidth: 1em; +@import mediawiki.ui/variables; // Mixins .mixin-mw-ui-icon-bgimage(@iconSvg, @iconPng) { @@ -42,7 +39,7 @@ // // Styleguide 6.1.1. .mw-ui-icon-element { - @width: @iconSize + ( 2 * @gutterWidth ); + @width: @iconSize + ( 2 * @iconGutterWidth ); text-indent: -999px; overflow: hidden; @@ -53,7 +50,7 @@ left: 0; right: 0; position: absolute; - margin: 0 @gutterWidth; + margin: 0 @iconGutterWidth; } } @@ -81,7 +78,7 @@ :before { position: relative; width: @iconSize; - margin-right: @gutterWidth; + margin-right: @iconGutterWidth; } } @@ -96,7 +93,7 @@ position: relative; float: right; width: @iconSize; - margin-left: @gutterWidth; + margin-left: @iconGutterWidth; } } } -- To view, visit https://gerrit.wikimedia.org/r/210395 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I6f2e64592e8985c9c14f88b0e91df1d0314a27d0 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Bmansurov bmansu...@wikimedia.org Gerrit-Reviewer: Bartosz Dziewoński matma@gmail.com Gerrit-Reviewer: Edokter er...@darcoury.nl Gerrit-Reviewer: Jack Phoenix j...@countervandalism.net Gerrit-Reviewer: Krinkle krinklem...@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 UpdateTable script. External data can now be deleted i... - change (mediawiki...WikidataQualityExternalValidation)
Dominic.sauer has submitted this change and it was merged. Change subject: Fixed UpdateTable script. External data can now be deleted in batches. .. Fixed UpdateTable script. External data can now be deleted in batches. Change-Id: Ia2a9b32770973e52a84c2d031d751182ce307a61 --- M includes/ExternalDataRepo.php M includes/UpdateTable/ImportContext.php M includes/UpdateTable/Importer.php M maintenance/UpdateTable.php 4 files changed, 26 insertions(+), 69 deletions(-) Approvals: Dominic.sauer: Verified; Looks good to me, approved diff --git a/includes/ExternalDataRepo.php b/includes/ExternalDataRepo.php index 1cc6068..6bc9fd1 100644 --- a/includes/ExternalDataRepo.php +++ b/includes/ExternalDataRepo.php @@ -130,26 +130,40 @@ * Deletes all external data of dump with given id. * * @param string $dumpId + * @param int $batchSize * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ -public function deleteOfDump( $dumpId ) { +public function deleteOfDump( $dumpId, $batchSize = 1000 ) { $this-assertIsString( $dumpId, '$dumpId' ); -return $this-deleteOfDumps( array( $dumpId ) ); +return $this-deleteOfDumps( array( $dumpId ), $batchSize ); } /** * Deletes all external data of multiple dumps with given ids. * * @param array $dumpIds + * @param int $batchSize * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ -public function deleteOfDumps( array $dumpIds ) { +public function deleteOfDumps( array $dumpIds, $batchSize = 1000 ) { $this-assertIsArrayOfStrings( $dumpIds, '$dumpIds' ); $db = wfGetDB( DB_MASTER ); +$condition = $this-buildSqlInCondition( 'dump_id', $dumpIds ); +if ( $db-getType() === 'sqlite' ) { +$db-delete( DUMP_DATA_TABLE, $condition ); +} else { +do { +$db-commit( __METHOD__, 'flush' ); +wfWaitForSlaves(); +$table = $db-tableName( DUMP_DATA_TABLE ); +$db-query( sprintf('DELETE FROM %s WHERE %s LIMIT %s', $table, $condition, $batchSize ) ); +} while ( $db-affectedRows() 0 ); +} + return $db-delete( $this-tableName, array( $this-buildSqlInCondition( 'dump_id', $dumpIds ) ) diff --git a/includes/UpdateTable/ImportContext.php b/includes/UpdateTable/ImportContext.php index b674877..12c3945 100644 --- a/includes/UpdateTable/ImportContext.php +++ b/includes/UpdateTable/ImportContext.php @@ -3,7 +3,6 @@ namespace WikidataQuality\ExternalValidation\UpdateTable; use Doctrine\Instantiator\Exception\InvalidArgumentException; -use LoadBalancer; /** @@ -25,11 +24,6 @@ private $tarFilePath; /** -* @var LoadBalancer -*/ - private $loadBalancer; - - /** * @var int */ private $batchSize; @@ -40,30 +34,14 @@ private $quiet; /** -* @param LoadBalancer $loadBalancer * @param int $batchSize * @param bool $quiet * @param string $tarFilePath */ - public function __construct( LoadBalancer $loadBalancer, $batchSize, $quiet, $tarFilePath ) { - $this-setLoadBalancer( $loadBalancer ); + public function __construct( $batchSize, $quiet, $tarFilePath ) { $this-setBatchSize( $batchSize ); $this-setQuiet( $quiet ); $this-setTarFilePath( $tarFilePath ); - } - - /** -* @return LoadBalancer -*/ - public function getLoadBalancer() { - return $this-loadBalancer; - } - - /** -* @param LoadBalancer $loadBalancer -*/ - public function setLoadBalancer( LoadBalancer $loadBalancer ) { - $this-loadBalancer = $loadBalancer; } /** diff --git a/includes/UpdateTable/Importer.php b/includes/UpdateTable/Importer.php index cc7f4c2..1506a43 100755 --- a/includes/UpdateTable/Importer.php +++ b/includes/UpdateTable/Importer.php @@ -73,9 +73,10 @@ if ( !$this-importContext-isQuiet() ) { print \n; +print Delete old database entries...\n; } -$this-externalDataRepo-deleteOfDumps( $dumpIds ); +$this-externalDataRepo-deleteOfDumps( $dumpIds, $this-importContext-getBatchSize() ); if ( !$this-importContext-isQuiet() ) { print \n; @@ -111,29 +112,6 @@ unlink( $this-dumpInformationFilePath ); } $this-dumpInformationFilePath = null; -} - -/** - * Establishes a database connection using the load balancer - * - * @return DatabaseBase - * @throws MWException - */ -protected function establishDbConnection() { -$loadBalancer = $this-importContext-getLoadBalancer(); -$db
[MediaWiki-commits] [Gerrit] add missing i18n for exception - change (mediawiki...WikidataQualityConstraints)
Jonaskeutel has uploaded a new change for review. https://gerrit.wikimedia.org/r/210663 Change subject: add missing i18n for exception .. add missing i18n for exception Change-Id: I9ceef99a9f69d5fe6138e16e7f56011f84caf7d9 --- M i18n/en.json M i18n/qqq.json 2 files changed, 2 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityConstraints refs/changes/63/210663/1 diff --git a/i18n/en.json b/i18n/en.json old mode 100755 new mode 100644 index ed01e9f..d7b27e3 --- a/i18n/en.json +++ b/i18n/en.json @@ -11,6 +11,7 @@ wbqc-constraintreport-empty-result: There are no constraint defined on this entity., wbqc-constraintreport-status-violation: Violation, wbqc-constraintreport-status-compliance: Compliance, + wbqc-constraintreport-status-exception: Exception, wbqc-constraintreport-status-todo: Todo, wbqc-constraintreport-result-table-header-claim: Claim, wbqc-constraintreport-result-table-header-constraint: Constraint, diff --git a/i18n/qqq.json b/i18n/qqq.json old mode 100755 new mode 100644 index 94dd9ab..1f9f2b3 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -16,6 +16,7 @@ wbqc-constraintreport-empty-result: Message that appears, when there are no constraints defined for the given entity., wbqc-constraintreport-status-violation: Status for claims that are violated against a constraint., wbqc-constraintreport-status-compliance: Status for claims that comply with a constraint, + wbqc-constraintreport-status-exception: Status for claims that were marked as a exception, wbqc-constraintreport-status-todo: Status for constraints which cannot be checked yet., wbqc-constraintreport-result-table-header-claim: Header of the column that displays a link to the claim, the used property and its value.\n{{Identical|Claim}}, wbqc-constraintreport-result-table-header-constraint: Header of the column that gives information about which constraint was checked.\n{{Identical|Constraint}}, -- To view, visit https://gerrit.wikimedia.org/r/210663 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I9ceef99a9f69d5fe6138e16e7f56011f84caf7d9 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/WikidataQualityConstraints Gerrit-Branch: v1 Gerrit-Owner: Jonaskeutel jonas.keu...@student.hpi.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-05-13T10:00:01+0000 - change (mediawiki...Wikidata)
WikidataBuilder has uploaded a new change for review. https://gerrit.wikimedia.org/r/210665 Change subject: New Wikidata Build - 2015-05-13T10:00:01+ .. New Wikidata Build - 2015-05-13T10:00:01+ Change-Id: I393686a6b5bf43b8e0b39b96ee8b114f551b38b4 --- M composer.lock M extensions/Wikibase/client/WikibaseClient.i18n.alias.php M extensions/Wikibase/client/WikibaseClient.i18n.magic.php M extensions/Wikibase/client/includes/DataAccess/Scribunto/mw.wikibase.entity.lua M extensions/Wikibase/client/includes/DataAccess/Scribunto/mw.wikibase.lua M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseEntityLibraryTests.lua M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua M extensions/Wikibase/client/tests/phpunit/includes/api/PageTermsTest.php M extensions/Wikibase/lib/includes/ClaimGuidValidator.php M extensions/Wikibase/lib/includes/PidLock.php M extensions/Wikibase/lib/includes/Validators/UrlValidator.php M extensions/Wikibase/lib/includes/changes/ChangeRow.php M extensions/Wikibase/lib/includes/parsers/MediaWikiNumberUnlocalizer.php M extensions/Wikibase/lib/includes/serializers/SerializationOptions.php M extensions/Wikibase/repo/Wikibase.i18n.alias.php M extensions/Wikibase/repo/i18n/be-tarask.json M extensions/Wikibase/repo/i18n/de.json M extensions/Wikibase/repo/i18n/gl.json M extensions/Wikibase/repo/i18n/zh-hans.json M extensions/Wikibase/repo/includes/LinkedData/HttpAcceptParser.php M extensions/Wikibase/repo/includes/content/DeferredCopyEntityHolder.php M extensions/Wikibase/repo/includes/content/DeferredDecodingEntityHolder.php M extensions/Wikibase/repo/includes/content/EntityHolder.php M extensions/Wikibase/repo/includes/content/EntityInstanceHolder.php M extensions/Wikibase/repo/includes/rdf/RdfVocabulary.php M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q4_all.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q4_minimal.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q4_statements.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q4_values.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q6_no_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q6_with_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q7_all_refs_seen.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q7_no_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/FullStatementRdfBuilder/Q7_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q10_redirect.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q1_info.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q1_simple.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q2_labels.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q3_links.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q3_sitelinks.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_all_statements.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_claims.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_props.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_resolved.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_truthy_statements.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q4_values.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q5_badges.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q6_no_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q6_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q6_with_qualifiers.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q7_Q9_dedup.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q7_no_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q7_references.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q7_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/Q8_baddates.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dump_empty.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dump_entities.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dump_redirect.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dump_refs.nt M extensions/Wikibase/repo/tests/phpunit/data/rdf/dumpheader.nt M extensions/Wikibase/repo/tests/phpunit/includes/Validators/SnakValidatorTest.php M extensions/Wikibase/repo/tests/phpunit/includes/content/DeferredDecodingEntityHolderTest.php M extensions/Wikibase/repo/tests/phpunit/includes/content/ItemContentTest.php M extensions/Wikibase/repo/tests/phpunit/includes/rdf/ComplexValueRdfBuilderTest.php M extensions/Wikibase/repo/tests/phpunit/includes/specials/SpecialMergeItemsTest.php M extensions/Wikibase/repo/tests/phpunit/includes/store/sql/SqlChangeDispatchCoordinatorTest.php M vendor/composer/installed.json 67 files
[MediaWiki-commits] [Gerrit] Go to main pane after selecting element on a search - change (mediawiki...Gather)
Jhernandez has uploaded a new change for review. https://gerrit.wikimedia.org/r/210670 Change subject: Go to main pane after selecting element on a search .. Go to main pane after selecting element on a search When editing a collection. * Clear the text field. * When selecting element go back to main pane. Bug: T98542 Change-Id: I867e7d66be5ba3b0316a9823014b6507c39efa1e --- M resources/ext.gather.collection.editor/CollectionEditOverlay.js M resources/ext.gather.page.search/CollectionPageList.js M resources/ext.gather.page.search/CollectionSearchPanel.js 3 files changed, 47 insertions(+), 21 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather refs/changes/70/210670/1 diff --git a/resources/ext.gather.collection.editor/CollectionEditOverlay.js b/resources/ext.gather.collection.editor/CollectionEditOverlay.js index 08e6936..56e69ce 100644 --- a/resources/ext.gather.collection.editor/CollectionEditOverlay.js +++ b/resources/ext.gather.collection.editor/CollectionEditOverlay.js @@ -81,6 +81,7 @@ if ( options options.collection ) { this.id = options.collection.id; } + this.activePane = 'main'; this.api = new CollectionsApi(); Overlay.prototype.initialize.apply( this, arguments ); this.$clear = this.$( '.search-header .clear' ); @@ -112,6 +113,7 @@ pages: pages, el: self.$( '.panel' ) } ); + self.searchPanel.on( 'change', $.proxy( self, 'onCollectionMembersChange' ) ); self.searchPanel.show(); } ); }, @@ -120,31 +122,40 @@ * @private */ _switchToFirstPane: function () { - this.$( this._selectors.edit ) - .add( this._selectors.search ) - .addClass( 'hidden' ); - this.$( this._selectors.manage ).removeClass( 'hidden' ); + if ( this.activePane !== 'main' ) { + this.activePane = 'main'; + this.$( this._selectors.edit ) + .add( this._selectors.search ) + .addClass( 'hidden' ); + this.$( this._selectors.manage ).removeClass( 'hidden' ); + } }, /** * Switch to search pane. * @private */ _switchToSearchPane: function () { - this.$( this._selectors.edit ) - .add( this._selectors.manage ) - .addClass( 'hidden' ); - this.$( this._selectors.search ).removeClass( 'hidden' ); - this.$( '.search-header input' ).focus(); + if ( this.activePane !== 'search' ) { + this.activePane = 'search'; + this.$( this._selectors.edit ) + .add( this._selectors.manage ) + .addClass( 'hidden' ); + this.$( this._selectors.search ).removeClass( 'hidden' ); + this.$( '.search-header input' ).focus(); + } }, /** * Switch to edit pane. * @private */ _switchToEditPane: function () { - this.$( this._selectors.manage ) - .add( this._selectors.search ) - .addClass( 'hidden' ); - this.$( this._selectors.edit ).removeClass( 'hidden' ); + if ( this.activePane !== 'edit' ) { + this.activePane = 'edit'; + this.$( this._selectors.manage ) + .add( this._selectors.search ) + .addClass( 'hidden' ); + this.$( this._selectors.edit ).removeClass( 'hidden' ); + } }, /** * Event handler when the search input is cleared @@ -156,6 +167,16 @@ this.$( '.search-header input' ).focus(); }, /** +* Event handler for when the collection members change. If the search pane +* is active then clear the input and go back to the
[MediaWiki-commits] [Gerrit] add TL factory + adopted tests - change (mediawiki...WikidataQualityConstraints)
Soeren.oldag has submitted this change and it was merged. Change subject: add TL factory + adopted tests .. add TL factory + adopted tests Change-Id: Ibf4f9aab9924842ef89103c707b34930f0b3d9c6 --- M includes/Constraint.php D includes/ConstraintCheck/CheckerMapBuilder.php M includes/ConstraintCheck/Result/CheckResult.php D includes/ConstraintParameterMap.php A includes/ConstraintReportFactory.php M specials/SpecialConstraintReport.php D tests/phpunit/CheckerMapBuilderTest.php D tests/phpunit/ConstraintParameterMapTest.php A tests/phpunit/ConstraintReportFactoryTest.php M tests/phpunit/DelegatingConstraintCheckerTest.php M tests/phpunit/EvaluateConstraintReportJobServiceTest.php M tests/phpunit/Specials/SpecialConstraintReportTest.php 12 files changed, 212 insertions(+), 217 deletions(-) Approvals: Soeren.oldag: Verified; Looks good to me, approved diff --git a/includes/Constraint.php b/includes/Constraint.php index 4e89ec8..4588351 100644 --- a/includes/Constraint.php +++ b/includes/Constraint.php @@ -15,7 +15,7 @@ public function __construct( $constraintEntry ) { $this-constraintTypeQid = $constraintEntry-constraint_type_qid; - $parameterMap = ConstraintParameterMap::getMap(); + $parameterMap = ConstraintReportFactory::getDefaultInstance()-getConstraintParameterMap(); $constraintParameter = array(); $jsonParameter = json_decode( $constraintEntry-constraint_parameters ); $helper = new ConstraintReportHelper(); diff --git a/includes/ConstraintCheck/CheckerMapBuilder.php b/includes/ConstraintCheck/CheckerMapBuilder.php deleted file mode 100644 index 90f324e..000 --- a/includes/ConstraintCheck/CheckerMapBuilder.php +++ /dev/null @@ -1,75 +0,0 @@ -?php - -namespace WikidataQuality\ConstraintReport\ConstraintCheck; - -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\CommonsLinkChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\FormatChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\OneOfChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\QualifierChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\RangeChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\TypeChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\ConflictsWithChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\QualifiersChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\TargetRequiredClaimChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\ItemChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\MandatoryQualifiersChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\ValueTypeChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\SymmetricChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\InverseChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\DiffWithinRangeChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\SingleValueChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\MultiValueChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Checker\UniqueValueChecker; -use WikidataQuality\ConstraintReport\ConstraintCheck\Helper\ConnectionCheckerHelper; -use WikidataQuality\ConstraintReport\ConstraintCheck\Helper\RangeCheckerHelper; -use WikidataQuality\ConstraintReport\ConstraintCheck\Helper\TypeCheckerHelper; - - -/** - * Builds a map that maps from the constraint name - * to its corresponding checker - * - * @package WikidataQuality\ConstraintReport\ConstraintCheck - * @author BP2014N1 - * @license GNU GPL v2+ - */ -class CheckerMapBuilder { - - /** -* @var CheckerMapBuilder -*/ - private $checkerMap; - - public function __construct( $lookup, $constraintReportHelper ) { - $connectionCheckerHelper = new ConnectionCheckerHelper(); - $rangeCheckerHelper = new RangeCheckerHelper(); - $typeCheckerHelper = new TypeCheckerHelper( $lookup ); - - $map = array( - 'Conflicts with' = new ConflictsWithChecker( $lookup, $constraintReportHelper, $connectionCheckerHelper ), - 'Item' = new ItemChecker( $lookup, $constraintReportHelper, $connectionCheckerHelper ), - 'Target required claim' = new TargetRequiredClaimChecker( $lookup, $constraintReportHelper, $connectionCheckerHelper ), - 'Symmetric' = new SymmetricChecker( $lookup, $constraintReportHelper, $connectionCheckerHelper ), - 'Inverse' = new InverseChecker( $lookup, $constraintReportHelper, $connectionCheckerHelper ), - 'Qualifier' = new QualifierChecker(
[MediaWiki-commits] [Gerrit] MediaWiki and Apex themes: Re-crush SVG files - change (oojs/ui)
Jforrester has uploaded a new change for review. https://gerrit.wikimedia.org/r/210685 Change subject: MediaWiki and Apex themes: Re-crush SVG files .. MediaWiki and Apex themes: Re-crush SVG files Some of these had never been crushed, and for others SVGO has got better since it was last run on them (current version: 0.5.1). Command: svgo --pretty --disable=removeXMLProcInst --disable=cleanupIDs --disable=collapseGroups Change-Id: Iaf2ee47bcd9b6fe97f7f6d61cd0d3c6263e4de04 --- M src/themes/apex/images/icons/add.svg M src/themes/apex/images/icons/advanced.svg M src/themes/apex/images/icons/alert.svg M src/themes/apex/images/icons/align-center.svg M src/themes/apex/images/icons/align-float-left.svg M src/themes/apex/images/icons/align-float-right.svg M src/themes/apex/images/icons/arched-arrow-ltr.svg M src/themes/apex/images/icons/arched-arrow-rtl.svg M src/themes/apex/images/icons/arrow-ltr.svg M src/themes/apex/images/icons/arrow-rtl.svg M src/themes/apex/images/icons/bigger-ltr.svg M src/themes/apex/images/icons/bigger-rtl.svg M src/themes/apex/images/icons/block.svg M src/themes/apex/images/icons/blockUndo-ltr.svg M src/themes/apex/images/icons/blockUndo-rtl.svg M src/themes/apex/images/icons/bold-a.svg M src/themes/apex/images/icons/bold-arab-ain.svg M src/themes/apex/images/icons/bold-arab-dad.svg M src/themes/apex/images/icons/bold-armn-to.svg M src/themes/apex/images/icons/bold-b.svg M src/themes/apex/images/icons/bold-cyrl-be.svg M src/themes/apex/images/icons/bold-cyrl-te.svg M src/themes/apex/images/icons/bold-cyrl-zhe.svg M src/themes/apex/images/icons/bold-f.svg M src/themes/apex/images/icons/bold-g.svg M src/themes/apex/images/icons/bold-geor-man.svg M src/themes/apex/images/icons/bold-l.svg M src/themes/apex/images/icons/bold-n.svg M src/themes/apex/images/icons/bold-v.svg M src/themes/apex/images/icons/cancel.svg M src/themes/apex/images/icons/caret-ltr.svg M src/themes/apex/images/icons/caret-rtl.svg M src/themes/apex/images/icons/caretDown.svg M src/themes/apex/images/icons/caretUp.svg M src/themes/apex/images/icons/case-sensitive.svg M src/themes/apex/images/icons/check.svg M src/themes/apex/images/icons/circle.svg M src/themes/apex/images/icons/close.svg M src/themes/apex/images/icons/code.svg M src/themes/apex/images/icons/collapse.svg M src/themes/apex/images/icons/comment.svg M src/themes/apex/images/icons/downTriangle.svg M src/themes/apex/images/icons/edit-ltr.svg M src/themes/apex/images/icons/edit-rtl.svg M src/themes/apex/images/icons/editLock-ltr.svg M src/themes/apex/images/icons/editLock-rtl.svg M src/themes/apex/images/icons/editUndo-ltr.svg M src/themes/apex/images/icons/editUndo-rtl.svg M src/themes/apex/images/icons/expand.svg M src/themes/apex/images/icons/external-link-ltr.svg M src/themes/apex/images/icons/external-link-rtl.svg M src/themes/apex/images/icons/find-ltr.svg M src/themes/apex/images/icons/find-rtl.svg M src/themes/apex/images/icons/flag-ltr.svg M src/themes/apex/images/icons/flag-rtl.svg M src/themes/apex/images/icons/flagUndo-ltr.svg M src/themes/apex/images/icons/flagUndo-rtl.svg M src/themes/apex/images/icons/help-ltr.svg M src/themes/apex/images/icons/help-rtl.svg M src/themes/apex/images/icons/history.svg M src/themes/apex/images/icons/indent-ltr.svg M src/themes/apex/images/icons/indent-rtl.svg M src/themes/apex/images/icons/info.svg M src/themes/apex/images/icons/insert.svg M src/themes/apex/images/icons/italic-a.svg M src/themes/apex/images/icons/italic-arab-keheh-jeem.svg M src/themes/apex/images/icons/italic-arab-meem.svg M src/themes/apex/images/icons/italic-armn-sha.svg M src/themes/apex/images/icons/italic-c.svg M src/themes/apex/images/icons/italic-d.svg M src/themes/apex/images/icons/italic-e.svg M src/themes/apex/images/icons/italic-geor-kan.svg M src/themes/apex/images/icons/italic-i.svg M src/themes/apex/images/icons/italic-k.svg M src/themes/apex/images/icons/italic-s.svg M src/themes/apex/images/icons/language.svg M src/themes/apex/images/icons/layout-ltr.svg M src/themes/apex/images/icons/layout-rtl.svg M src/themes/apex/images/icons/link.svg M src/themes/apex/images/icons/listBullet-ltr.svg M src/themes/apex/images/icons/listBullet-rtl.svg M src/themes/apex/images/icons/listNumbered-ltr.svg M src/themes/apex/images/icons/listNumbered-rtl.svg M src/themes/apex/images/icons/lock.svg M src/themes/apex/images/icons/menu.svg M src/themes/apex/images/icons/move-ltr.svg M src/themes/apex/images/icons/move-rtl.svg M src/themes/apex/images/icons/move.svg M src/themes/apex/images/icons/newline-ltr.svg M src/themes/apex/images/icons/newline-rtl.svg M src/themes/apex/images/icons/noWikiText-ltr.svg M src/themes/apex/images/icons/noWikiText-rtl.svg M src/themes/apex/images/icons/outdent-ltr.svg M src/themes/apex/images/icons/outdent-rtl.svg M src/themes/apex/images/icons/outline-ltr.svg M src/themes/apex/images/icons/outline-rtl.svg M
[MediaWiki-commits] [Gerrit] Make config script more robust. - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210673 Change subject: Make config script more robust. .. Make config script more robust. Make it independent of the current state of LocalSettings.php: Either add opening and closing PHP tags when the file is closed with one, or don't. This is necessary because I plan to change when this script is executed by our CI. At that point the CIs LocalSettings.php is not closed with a PHP tag, where as when it is currently execute there is a closing PHP tag. Bug: T97529 Change-Id: Ie5611fd24c0f245b2aceb48610a866c61cf8a4e1 (cherry picked from commit daeed233b32d4f4da6a2eeb51d1beb6cf8d8902c) --- M build/jenkins/mw-apply-wb-settings.sh 1 file changed, 12 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/73/210673/1 diff --git a/build/jenkins/mw-apply-wb-settings.sh b/build/jenkins/mw-apply-wb-settings.sh index b18bb1a..49d80b7 100755 --- a/build/jenkins/mw-apply-wb-settings.sh +++ b/build/jenkins/mw-apply-wb-settings.sh @@ -54,7 +54,14 @@ cd $WORKSPACE/src -echo '?php' LocalSettings.php +if [ $(tail -n1 LocalSettings.php) = ? ] +then + PHPTAGS=true +fi +if [ -v PHPTAGS ] +then + echo '?php' LocalSettings.php +fi apply_experimental_settings @@ -68,4 +75,7 @@ usage fi -echo '?' LocalSettings.php +if [ -v PHPTAGS ] +then + echo '?' LocalSettings.php +fi -- To view, visit https://gerrit.wikimedia.org/r/210673 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie5611fd24c0f245b2aceb48610a866c61cf8a4e1 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.26wmf4 Gerrit-Owner: Aude aude.w...@gmail.com Gerrit-Reviewer: JanZerebecki jan.wikime...@zerebecki.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update Wikidata - waitForSlaves in updateSubscriptions script - change (mediawiki/core)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210686 Change subject: Update Wikidata - waitForSlaves in updateSubscriptions script .. Update Wikidata - waitForSlaves in updateSubscriptions script Change-Id: Ic5aff689591d14d79ca28c66b191f3237fba6200 --- M extensions/Wikidata 1 file changed, 0 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/86/210686/1 diff --git a/extensions/Wikidata b/extensions/Wikidata index ac044e2..79e11ec 16 --- a/extensions/Wikidata +++ b/extensions/Wikidata -Subproject commit ac044e2241858746e3c07766869b6ddd4fa042f7 +Subproject commit 79e11ecc73daf12c5404a69760566711a3629cf6 -- To view, visit https://gerrit.wikimedia.org/r/210686 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic5aff689591d14d79ca28c66b191f3237fba6200 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: wmf/1.26wmf5 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] Make PPFrame::RECOVER_COMMENTS actually work - change (mediawiki/core)
PleaseStand has uploaded a new change for review. https://gerrit.wikimedia.org/r/210677 Change subject: Make PPFrame::RECOVER_COMMENTS actually work .. Make PPFrame::RECOVER_COMMENTS actually work Because of a missing condition, it generally only had an effect on output type Parser::OT_WIKI (during a pre-save transform). Bug: T98841 Change-Id: I1e47696434fe87475f9902e6bfb8990566456e2f --- M RELEASE-NOTES-1.26 M includes/parser/Preprocessor_DOM.php M includes/parser/Preprocessor_Hash.php M tests/parser/parserTests.txt 4 files changed, 10 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/77/210677/1 diff --git a/RELEASE-NOTES-1.26 b/RELEASE-NOTES-1.26 index 3d6651f..050a557 100644 --- a/RELEASE-NOTES-1.26 +++ b/RELEASE-NOTES-1.26 @@ -20,6 +20,8 @@ === Bug fixes in 1.26 === * (bug 51283) load.php sometimes sends 304 response without full headers +* (T98841) {{msgnw:}} will correctly recover the original code of comments + even when it is not substituted as part of a pre-save transform. === Action API changes in 1.26 === * API action=querylist=tags: The displayname can now be boolean false if the diff --git a/includes/parser/Preprocessor_DOM.php b/includes/parser/Preprocessor_DOM.php index 0351f2a..bbf7aa1 100644 --- a/includes/parser/Preprocessor_DOM.php +++ b/includes/parser/Preprocessor_DOM.php @@ -1195,15 +1195,16 @@ } elseif ( $contextNode-nodeName == 'comment' ) { # HTML-style comment # Remove it in HTML, pre+remove and STRIP_COMMENTS modes - if ( $this-parser-ot['html'] + # Not in RECOVER_COMMENTS mode (extractSections, msgnw) though. + if ( ( $this-parser-ot['html'] || ( $this-parser-ot['pre'] $this-parser-mOptions-getRemoveComments() ) || ( $flags PPFrame::STRIP_COMMENTS ) + ) !( $flags PPFrame::RECOVER_COMMENTS ) ) { $out .= ''; } elseif ( $this-parser-ot['wiki'] !( $flags PPFrame::RECOVER_COMMENTS ) ) { # Add a strip marker in PST mode so that pstPass2() can # run some old-fashioned regexes on the result. - # Not in RECOVER_COMMENTS mode (extractSections) though. $out .= $this-parser-insertStripItem( $contextNode-textContent ); } else { # Recover the literal comment in RECOVER_COMMENTS and pre+no-remove diff --git a/includes/parser/Preprocessor_Hash.php b/includes/parser/Preprocessor_Hash.php index af91ad4..26b524d 100644 --- a/includes/parser/Preprocessor_Hash.php +++ b/includes/parser/Preprocessor_Hash.php @@ -1118,15 +1118,16 @@ } elseif ( $contextNode-name == 'comment' ) { # HTML-style comment # Remove it in HTML, pre+remove and STRIP_COMMENTS modes - if ( $this-parser-ot['html'] + # Not in RECOVER_COMMENTS mode (extractSections, msgnw) though. + if ( ( $this-parser-ot['html'] || ( $this-parser-ot['pre'] $this-parser-mOptions-getRemoveComments() ) || ( $flags PPFrame::STRIP_COMMENTS ) + ) !( $flags PPFrame::RECOVER_COMMENTS ) ) { $out .= ''; } elseif ( $this-parser-ot['wiki'] !( $flags PPFrame::RECOVER_COMMENTS ) ) { # Add a strip marker in PST mode so that pstPass2() can # run some old-fashioned regexes on the result. - # Not in RECOVER_COMMENTS mode (extractSections) though. $out .= $this-parser-insertStripItem( $contextNode-firstChild-value ); } else { # Recover the literal comment in RECOVER_COMMENTS and pre+no-remove diff --git a/tests/parser/parserTests.txt b/tests/parser/parserTests.txt index
[MediaWiki-commits] [Gerrit] Wait for slaves in BulkSubscriptionUpdater - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Wait for slaves in BulkSubscriptionUpdater .. Wait for slaves in BulkSubscriptionUpdater especially needed for the purge subscriptions option Change-Id: I0babedaa0fb0cef1e1cf1ae5c526854d078da7bd (cherry picked from commit 434f1a92bbcd0b586a3e695daac5a6179c39d560) --- M client/includes/store/sql/BulkSubscriptionUpdater.php M client/maintenance/updateSubscriptions.php M client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php 3 files changed, 22 insertions(+), 0 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/client/includes/store/sql/BulkSubscriptionUpdater.php b/client/includes/store/sql/BulkSubscriptionUpdater.php index c85fb93..e48105d 100644 --- a/client/includes/store/sql/BulkSubscriptionUpdater.php +++ b/client/includes/store/sql/BulkSubscriptionUpdater.php @@ -36,6 +36,13 @@ private $subscriberWikiId; /** +* @var string|false The repo wiki's id, as used by the LoadBalancer. Used for wait for slaves. +* False indicates to use the local wiki's database, and is the default +* for the repoWiki setting. +*/ + private $repoWiki; + + /** * @var int */ private $batchSize; @@ -57,6 +64,9 @@ * connections to the repo. * @param string $subscriberWikiId The local wiki's global ID, to be used as the subscriber ID * in the repo's subscription table. +* @param string|false $repoWiki The repo wiki's id, as used by the LoadBalancer. +* False (default of the repoWiki setting) indicates to +* use local wiki database. * @param int $batchSize * * @throws InvalidArgumentException @@ -65,10 +75,15 @@ ConsistentReadConnectionManager $localConnectionManager, ConsistentReadConnectionManager $repoConnectionManager, $subscriberWikiId, + $repoWiki, $batchSize = 1000 ) { if ( !is_string( $subscriberWikiId ) ) { throw new InvalidArgumentException( '$subscriberWikiId must be a string' ); + } + + if ( !is_string( $repoWiki ) $repoWiki !== false ) { + throw new InvalidArgumentException( '$repoWiki must be a string or false' ); } if ( !is_int( $batchSize ) || $batchSize 1 ) { @@ -79,6 +94,7 @@ $this-repoConnectionManager = $repoConnectionManager; $this-subscriberWikiId = $subscriberWikiId; + $this-repoWiki = $repoWiki; $this-batchSize = $batchSize; $this-exceptionHandler = new LogWarningExceptionHandler(); @@ -124,6 +140,8 @@ $continuation = $startEntity === null ? null : array( $startEntity-getSerialization() ); while ( true ) { + wfWaitForSlaves( null, $this-repoWiki ); + $count = $this-processUpdateBatch( $continuation ); if ( $count 0 ) { @@ -263,6 +281,8 @@ $this-repoConnectionManager-forceMaster(); while ( true ) { + wfWaitForSlaves( null, $this-repoWiki ); + $count = $this-processDeletionBatch( $continuation ); if ( $count 0 ) { diff --git a/client/maintenance/updateSubscriptions.php b/client/maintenance/updateSubscriptions.php index 31455dd..0c36dbe 100644 --- a/client/maintenance/updateSubscriptions.php +++ b/client/maintenance/updateSubscriptions.php @@ -61,6 +61,7 @@ new ConsistentReadConnectionManager( wfGetLB() ), new ConsistentReadConnectionManager( wfGetLB( $repoDB ), $repoDB ), $clientId, + $repoDB, $this-mBatchSize ); diff --git a/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php b/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php index 743c754..49d72a9 100644 --- a/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php +++ b/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php @@ -53,6 +53,7 @@ new ConsistentReadConnectionManager( $loadBalancer, false ), new ConsistentReadConnectionManager( $loadBalancer, false ), 'testwiki', + false, $batchSize ); } -- To view, visit https://gerrit.wikimedia.org/r/210672 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
[MediaWiki-commits] [Gerrit] New Wikidata deployment build - wmf/1.26wmf6 - change (mediawiki...Wikidata)
jenkins-bot has submitted this change and it was merged. Change subject: New Wikidata deployment build - wmf/1.26wmf6 .. New Wikidata deployment build - wmf/1.26wmf6 Change-Id: If94de7ffbaa1c9c12823e40e87a9d4881f42bc68 --- M WikibaseClient.settings.php M WikibaseRepo.settings.php M composer.json M composer.lock M extensions/Wikibase/.travis.yml M extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh M extensions/Wikibase/build/travis/install.sh M extensions/Wikibase/client/WikibaseClient.i18n.alias.php M extensions/Wikibase/client/WikibaseClient.i18n.magic.php M extensions/Wikibase/client/i18n/aeb-latn.json A extensions/Wikibase/client/i18n/an.json M extensions/Wikibase/client/i18n/azb.json M extensions/Wikibase/client/i18n/be.json M extensions/Wikibase/client/i18n/ca.json M extensions/Wikibase/client/i18n/ckb.json M extensions/Wikibase/client/i18n/cy.json A extensions/Wikibase/client/i18n/ee.json M extensions/Wikibase/client/i18n/fa.json M extensions/Wikibase/client/i18n/hu.json A extensions/Wikibase/client/i18n/jv.json M extensions/Wikibase/client/i18n/ka.json M extensions/Wikibase/client/i18n/ku-latn.json M extensions/Wikibase/client/i18n/la.json M extensions/Wikibase/client/i18n/mk.json M extensions/Wikibase/client/i18n/os.json M extensions/Wikibase/client/i18n/sa.json M extensions/Wikibase/client/i18n/scn.json M extensions/Wikibase/client/i18n/si.json M extensions/Wikibase/client/i18n/so.json M extensions/Wikibase/client/i18n/szl.json M extensions/Wikibase/client/i18n/ta.json M extensions/Wikibase/client/i18n/tr.json M extensions/Wikibase/client/i18n/vec.json M extensions/Wikibase/client/i18n/xmf.json M extensions/Wikibase/client/i18n/yo.json M extensions/Wikibase/client/includes/Changes/AffectedPagesFinder.php M extensions/Wikibase/client/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibrary.php M extensions/Wikibase/client/includes/DataAccess/Scribunto/WikibaseLuaBindings.php M extensions/Wikibase/client/includes/DataAccess/Scribunto/mw.wikibase.entity.lua M extensions/Wikibase/client/includes/DataAccess/Scribunto/mw.wikibase.lua M extensions/Wikibase/client/includes/Hooks/BaseTemplateAfterPortletHandler.php M extensions/Wikibase/client/includes/Hooks/ParserAfterParseHookHandler.php M extensions/Wikibase/client/includes/Usage/SiteLinkUsageLookup.php M extensions/Wikibase/client/includes/Usage/Sql/EntityUsageTableBuilder.php M extensions/Wikibase/client/includes/Usage/Sql/UsageTableUpdater.php M extensions/Wikibase/client/includes/specials/SpecialUnconnectedPages.php M extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php M extensions/Wikibase/client/maintenance/populateEntityUsage.php M extensions/Wikibase/client/maintenance/populateInterwiki.php M extensions/Wikibase/client/maintenance/updateSubscriptions.php M extensions/Wikibase/client/resources/Resources.php M extensions/Wikibase/client/tests/phpunit/includes/Changes/AffectedPagesFinderTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/EntityAccessorTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseEntityLibraryTests.lua M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/Scribunto_LuaWikibaseLibraryTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/SnakSerializationRendererTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/Scribunto/WikibaseLuaBindingsTest.php M extensions/Wikibase/client/tests/phpunit/includes/DataAccess/WikibaseDataAccessTestItemSetUpHelper.php M extensions/Wikibase/client/tests/phpunit/includes/Hooks/DataUpdateHookHandlersTest.php M extensions/Wikibase/client/tests/phpunit/includes/SiteLinkCommentCreatorTest.php M extensions/Wikibase/client/tests/phpunit/includes/Usage/SiteLinkUsageLookupTest.php M extensions/Wikibase/client/tests/phpunit/includes/WikibaseClientTest.php M extensions/Wikibase/client/tests/phpunit/includes/api/PageTermsTest.php M extensions/Wikibase/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php M extensions/Wikibase/docs/lua.wiki M extensions/Wikibase/docs/options.wiki A extensions/Wikibase/lib/i18n/aeb-latn.json A extensions/Wikibase/lib/i18n/an.json A extensions/Wikibase/lib/i18n/ang.json M extensions/Wikibase/lib/i18n/bn.json M extensions/Wikibase/lib/i18n/ce.json M extensions/Wikibase/lib/i18n/cs.json M extensions/Wikibase/lib/i18n/da.json M extensions/Wikibase/lib/i18n/fa.json M extensions/Wikibase/lib/i18n/fi.json M extensions/Wikibase/lib/i18n/fr.json M extensions/Wikibase/lib/i18n/gl.json M extensions/Wikibase/lib/i18n/ilo.json M extensions/Wikibase/lib/i18n/is.json M extensions/Wikibase/lib/i18n/it.json M extensions/Wikibase/lib/i18n/lrc.json M extensions/Wikibase/lib/i18n/ms.json M
[MediaWiki-commits] [Gerrit] Update Wikidata branch to wmf/1.26wmf6 - change (mediawiki...release)
jenkins-bot has submitted this change and it was merged. Change subject: Update Wikidata branch to wmf/1.26wmf6 .. Update Wikidata branch to wmf/1.26wmf6 Change-Id: I9af5e3f3168be183aa0312ba44e1ae0118011bbb --- M make-wmf-branch/default.conf 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/make-wmf-branch/default.conf b/make-wmf-branch/default.conf index 8e45863..f80e183 100644 --- a/make-wmf-branch/default.conf +++ b/make-wmf-branch/default.conf @@ -182,7 +182,7 @@ 'DonationInterface' = 'deployment', // to use instead of the above - 'Wikidata' = 'wmf/1.26wmf4', + 'Wikidata' = 'wmf/1.26wmf6', // For wikitech use only! 'SemanticMediaWiki' = '1.8.x', -- To view, visit https://gerrit.wikimedia.org/r/210671 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I9af5e3f3168be183aa0312ba44e1ae0118011bbb Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/tools/release Gerrit-Branch: master 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] depool db1060 for thread pool reconfig - change (operations/mediawiki-config)
Springle has uploaded a new change for review. https://gerrit.wikimedia.org/r/210676 Change subject: depool db1060 for thread pool reconfig .. depool db1060 for thread pool reconfig Change-Id: If9d5b427c4f822877603afd9ae110845270a4ff9 --- M wmf-config/db-eqiad.php 1 file changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config refs/changes/76/210676/1 diff --git a/wmf-config/db-eqiad.php b/wmf-config/db-eqiad.php index 6c9a655..2bf0beb 100755 --- a/wmf-config/db-eqiad.php +++ b/wmf-config/db-eqiad.php @@ -103,7 +103,7 @@ 'db1021' = 0, # 1.4TB 64GB, dump, vslow 'db1036' = 0, # 1.4TB 64GB, watchlist, recentchanges, contributions, logpager 'db1054' = 200, # 2.8TB 96GB, api - 'db1060' = 200, # 2.8TB 96GB, api + # thread pool reconfig 'db1060' = 200, # 2.8TB 96GB, api 'db1063' = 400, # 2.8TB 128GB 'db1067' = 500, # 2.8TB 160GB ), @@ -202,7 +202,7 @@ ), 'api' = array( 'db1054' = 1, - 'db1060' = 1, + # thread pool reconfig 'db1060' = 1, ), 'watchlist' = array( 'db1036' = 1, -- To view, visit https://gerrit.wikimedia.org/r/210676 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: If9d5b427c4f822877603afd9ae110845270a4ff9 Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Springle sprin...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Prevent indexing of User: namespace on ukwiki - change (operations/mediawiki-config)
Glaisher has uploaded a new change for review. https://gerrit.wikimedia.org/r/210680 Change subject: Prevent indexing of User: namespace on ukwiki .. Prevent indexing of User: namespace on ukwiki Bug: T98926 Change-Id: I64fbefb7077390666d48cbc9d2d335186a498df9 --- M wmf-config/InitialiseSettings.php 1 file changed, 3 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config refs/changes/80/210680/1 diff --git a/wmf-config/InitialiseSettings.php b/wmf-config/InitialiseSettings.php index 58826a5..355d073 100644 --- a/wmf-config/InitialiseSettings.php +++ b/wmf-config/InitialiseSettings.php @@ -10086,6 +10086,9 @@ NS_HELP_TALK = 'noindex,follow', NS_CATEGORY_TALK = 'noindex,follow', ), + 'ukwiki' = array( + NS_USER = 'noindex,follow', // T98926 + ), 'zhwiki' = array( 118 = 'noindex,nofollow', // T91223 119 = 'noindex,nofollow', -- To view, visit https://gerrit.wikimedia.org/r/210680 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I64fbefb7077390666d48cbc9d2d335186a498df9 Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Glaisher glaisher.w...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Changed description of UpdateTable script. Removed nonsense ... - change (mediawiki...WikidataQualityExternalValidation)
Soeren.oldag has uploaded a new change for review. https://gerrit.wikimedia.org/r/210682 Change subject: Changed description of UpdateTable script. Removed nonsense lines. .. Changed description of UpdateTable script. Removed nonsense lines. Change-Id: Ic1d039991eef68e9c0c376f5d537a5eea58afa2a --- M includes/ExternalDataRepo.php M maintenance/UpdateTable.php 2 files changed, 1 insertion(+), 9 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityExternalValidation refs/changes/82/210682/1 diff --git a/includes/ExternalDataRepo.php b/includes/ExternalDataRepo.php index 6bc9fd1..fbcb278 100644 --- a/includes/ExternalDataRepo.php +++ b/includes/ExternalDataRepo.php @@ -145,7 +145,6 @@ * * @param array $dumpIds * @param int $batchSize - * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ public function deleteOfDumps( array $dumpIds, $batchSize = 1000 ) { @@ -163,11 +162,6 @@ $db-query( sprintf('DELETE FROM %s WHERE %s LIMIT %s', $table, $condition, $batchSize ) ); } while ( $db-affectedRows() 0 ); } - -return $db-delete( -$this-tableName, -array( $this-buildSqlInCondition( 'dump_id', $dumpIds ) ) -); } /** diff --git a/maintenance/UpdateTable.php b/maintenance/UpdateTable.php index 9d6de5b..a62746c 100644 --- a/maintenance/UpdateTable.php +++ b/maintenance/UpdateTable.php @@ -3,8 +3,6 @@ namespace WikidataQuality\ExternalValidation\Maintenance; use Maintenance; -use WikidataQuality\ExternalValidation\DumpMetaInformation\DumpMetaInformationRepo; -use WikidataQuality\ExternalValidation\ExternalDataRepo; use WikidataQuality\ExternalValidation\ExternalValidationFactory; use WikidataQuality\ExternalValidation\UpdateTable\ImportContext; use WikidataQuality\ExternalValidation\UpdateTable\Importer; @@ -29,7 +27,7 @@ public function __construct() { parent::__construct(); -$this-mDescription = Downloads dumps of external databases and imports the entities into the local database.; +$this-mDescription = Imports external entities from a given TAR file into the local database. TAR file can be generated using the DumpConverter.; $this-addOption( 'tar-file', 'TAR file that contains external data for import.', true, true ); $this-setBatchSize( 1000 ); } -- To view, visit https://gerrit.wikimedia.org/r/210682 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic1d039991eef68e9c0c376f5d537a5eea58afa2a Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/WikidataQualityExternalValidation Gerrit-Branch: master Gerrit-Owner: Soeren.oldag soeren_ol...@freenet.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update Wikidata - waitForSlaves for updateSubscriptions script - change (mediawiki...Wikidata)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210684 Change subject: Update Wikidata - waitForSlaves for updateSubscriptions script .. Update Wikidata - waitForSlaves for updateSubscriptions script also changes for travis and jenkins builds, which have changed since the deployment branch was made. Change-Id: Idbe8dacdd11337ffc1d0e0964e82d2e116ceee7c --- M composer.json M composer.lock M extensions/Wikibase/.travis.yml M extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh M extensions/Wikibase/build/travis/install.sh M extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php M extensions/Wikibase/client/maintenance/updateSubscriptions.php M extensions/Wikibase/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php M vendor/composer/installed.json 9 files changed, 44 insertions(+), 12 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikidata refs/changes/84/210684/1 diff --git a/composer.json b/composer.json index 52172ab..55594dc 100644 --- a/composer.json +++ b/composer.json @@ -5,7 +5,7 @@ repositories: [ { type: vcs, - url: https://git.wikimedia.org/git/mediawiki/extensions/Wikibase.git; + url: https://gerrit.wikimedia.org/r/mediawiki/extensions/Wikibase.git; }, { type: vcs, diff --git a/composer.lock b/composer.lock index 404b5f6..c42360b 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file;, This file is @generated automatically ], -hash: 70bd36b4d0c521e3a184fdd7e0c95fe3, +hash: dccb290555a2dca0e70584c37c009bb3, packages: [ { name: composer/installers, @@ -1212,8 +1212,8 @@ version: dev-wmf/1.26wmf4, source: { type: git, -url: https://git.wikimedia.org/git/mediawiki/extensions/Wikibase.git;, -reference: c6df5a162ec8128ff9036217739b3e0927caa2ce +url: https://gerrit.wikimedia.org/r/mediawiki/extensions/Wikibase.git;, +reference: 820f66d33caaed5a6510ea4e84a979aa8a46daae }, require: { data-values/common: ~0.2.0, @@ -1283,7 +1283,7 @@ issues: https://bugzilla.wikimedia.org/;, irc: irc://irc.freenode.net/wikidata }, -time: 2015-05-11 10:40:03 +time: 2015-05-13 13:06:16 }, { name: wikibase/wikimedia-badges, diff --git a/extensions/Wikibase/.travis.yml b/extensions/Wikibase/.travis.yml index fa86f35..416b453 100644 --- a/extensions/Wikibase/.travis.yml +++ b/extensions/Wikibase/.travis.yml @@ -14,7 +14,7 @@ - env: DBTYPE=mysql LANG=en MW=master WB=repo php: 5.6 - env: DBTYPE=sqlite LANG=en MW=master WB=both - php: hhvm-nightly + php: hhvm before_script: - bash ./build/travis/install.sh diff --git a/extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh b/extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh index b18bb1a..49d80b7 100755 --- a/extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh +++ b/extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh @@ -54,7 +54,14 @@ cd $WORKSPACE/src -echo '?php' LocalSettings.php +if [ $(tail -n1 LocalSettings.php) = ? ] +then + PHPTAGS=true +fi +if [ -v PHPTAGS ] +then + echo '?php' LocalSettings.php +fi apply_experimental_settings @@ -68,4 +75,7 @@ usage fi -echo '?' LocalSettings.php +if [ -v PHPTAGS ] +then + echo '?' LocalSettings.php +fi diff --git a/extensions/Wikibase/build/travis/install.sh b/extensions/Wikibase/build/travis/install.sh index 498e748..2ab6361 100755 --- a/extensions/Wikibase/build/travis/install.sh +++ b/extensions/Wikibase/build/travis/install.sh @@ -4,7 +4,7 @@ PHPVERSION=`phpenv version-name` -if [ ${PHPVERSION} = 'hhvm-nightly' ] +if [ ${PHPVERSION} = 'hhvm' ] then PHPINI=/etc/hhvm/php.ini echo hhvm.enable_zend_compat = true $PHPINI diff --git a/extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php b/extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php index c85fb93..e48105d 100644 --- a/extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php +++ b/extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php @@ -36,6 +36,13 @@ private $subscriberWikiId; /** +* @var string|false The repo wiki's id, as used by the LoadBalancer. Used for wait for slaves. +* False indicates to use the local wiki's database, and is the default +* for the repoWiki setting. +*/ + private $repoWiki; + + /** * @var int
[MediaWiki-commits] [Gerrit] Wait for slaves in BulkSubscriptionUpdater - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210672 Change subject: Wait for slaves in BulkSubscriptionUpdater .. Wait for slaves in BulkSubscriptionUpdater especially needed for the purge subscriptions option Change-Id: I0babedaa0fb0cef1e1cf1ae5c526854d078da7bd (cherry picked from commit 434f1a92bbcd0b586a3e695daac5a6179c39d560) --- M client/includes/store/sql/BulkSubscriptionUpdater.php M client/maintenance/updateSubscriptions.php M client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php 3 files changed, 22 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/72/210672/1 diff --git a/client/includes/store/sql/BulkSubscriptionUpdater.php b/client/includes/store/sql/BulkSubscriptionUpdater.php index c85fb93..e48105d 100644 --- a/client/includes/store/sql/BulkSubscriptionUpdater.php +++ b/client/includes/store/sql/BulkSubscriptionUpdater.php @@ -36,6 +36,13 @@ private $subscriberWikiId; /** +* @var string|false The repo wiki's id, as used by the LoadBalancer. Used for wait for slaves. +* False indicates to use the local wiki's database, and is the default +* for the repoWiki setting. +*/ + private $repoWiki; + + /** * @var int */ private $batchSize; @@ -57,6 +64,9 @@ * connections to the repo. * @param string $subscriberWikiId The local wiki's global ID, to be used as the subscriber ID * in the repo's subscription table. +* @param string|false $repoWiki The repo wiki's id, as used by the LoadBalancer. +* False (default of the repoWiki setting) indicates to +* use local wiki database. * @param int $batchSize * * @throws InvalidArgumentException @@ -65,10 +75,15 @@ ConsistentReadConnectionManager $localConnectionManager, ConsistentReadConnectionManager $repoConnectionManager, $subscriberWikiId, + $repoWiki, $batchSize = 1000 ) { if ( !is_string( $subscriberWikiId ) ) { throw new InvalidArgumentException( '$subscriberWikiId must be a string' ); + } + + if ( !is_string( $repoWiki ) $repoWiki !== false ) { + throw new InvalidArgumentException( '$repoWiki must be a string or false' ); } if ( !is_int( $batchSize ) || $batchSize 1 ) { @@ -79,6 +94,7 @@ $this-repoConnectionManager = $repoConnectionManager; $this-subscriberWikiId = $subscriberWikiId; + $this-repoWiki = $repoWiki; $this-batchSize = $batchSize; $this-exceptionHandler = new LogWarningExceptionHandler(); @@ -124,6 +140,8 @@ $continuation = $startEntity === null ? null : array( $startEntity-getSerialization() ); while ( true ) { + wfWaitForSlaves( null, $this-repoWiki ); + $count = $this-processUpdateBatch( $continuation ); if ( $count 0 ) { @@ -263,6 +281,8 @@ $this-repoConnectionManager-forceMaster(); while ( true ) { + wfWaitForSlaves( null, $this-repoWiki ); + $count = $this-processDeletionBatch( $continuation ); if ( $count 0 ) { diff --git a/client/maintenance/updateSubscriptions.php b/client/maintenance/updateSubscriptions.php index 31455dd..0c36dbe 100644 --- a/client/maintenance/updateSubscriptions.php +++ b/client/maintenance/updateSubscriptions.php @@ -61,6 +61,7 @@ new ConsistentReadConnectionManager( wfGetLB() ), new ConsistentReadConnectionManager( wfGetLB( $repoDB ), $repoDB ), $clientId, + $repoDB, $this-mBatchSize ); diff --git a/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php b/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php index 743c754..49d72a9 100644 --- a/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php +++ b/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php @@ -53,6 +53,7 @@ new ConsistentReadConnectionManager( $loadBalancer, false ), new ConsistentReadConnectionManager( $loadBalancer, false ), 'testwiki', + false, $batchSize ); } -- To view, visit https://gerrit.wikimedia.org/r/210672 To unsubscribe, visit
[MediaWiki-commits] [Gerrit] Bulk revision deletion and tag editing from contributions - change (mediawiki/core)
Cenarium has uploaded a new change for review. https://gerrit.wikimedia.org/r/210675 Change subject: Bulk revision deletion and tag editing from contributions .. Bulk revision deletion and tag editing from contributions This allows to delete revisions in bulk from Special:Contributions, as requested in T78092 and T28230, as well as tag editing (T98611). This only works for contributions from a single user (not newbies). For revision deletion, a log entry is added for each target page. Change-Id: I53aad4c844355a45bfe4296d76d24dae2021ddaa --- M autoload.php A includes/changetags/ChangeTagsContribsItem.php A includes/changetags/ChangeTagsContribsList.php M includes/changetags/ChangeTagsList.php A includes/revisiondelete/RevDelContribsItem.php A includes/revisiondelete/RevDelContribsList.php M includes/revisiondelete/RevDelList.php M includes/revisiondelete/RevisionDeleter.php M includes/specials/SpecialContributions.php M includes/specials/SpecialEditTags.php M includes/specials/SpecialRevisiondelete.php 11 files changed, 543 insertions(+), 10 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/75/210675/1 diff --git a/autoload.php b/autoload.php index 6c623a3..cb1ae74 100644 --- a/autoload.php +++ b/autoload.php @@ -206,6 +206,8 @@ 'CgzCopyTransaction' = __DIR__ . '/maintenance/storage/recompressTracked.php', 'ChangePassword' = __DIR__ . '/maintenance/changePassword.php', 'ChangeTags' = __DIR__ . '/includes/changetags/ChangeTags.php', + 'ChangeTagsContribsItem' = __DIR__ . '/includes/changetags/ChangeTagsContribsItem.php', + 'ChangeTagsContribsList' = __DIR__ . '/includes/changetags/ChangeTagsContribsList.php', 'ChangeTagsList' = __DIR__ . '/includes/changetags/ChangeTagsList.php', 'ChangeTagsLogItem' = __DIR__ . '/includes/changetags/ChangeTagsLogItem.php', 'ChangeTagsLogList' = __DIR__ . '/includes/changetags/ChangeTagsLogList.php', @@ -1026,6 +1028,8 @@ 'RevDelArchivedFileItem' = __DIR__ . '/includes/revisiondelete/RevDelArchivedFileItem.php', 'RevDelArchivedFileList' = __DIR__ . '/includes/revisiondelete/RevDelArchivedFileList.php', 'RevDelArchivedRevisionItem' = __DIR__ . '/includes/revisiondelete/RevDelArchivedRevisionItem.php', + 'RevDelContribsItem' = __DIR__ . '/includes/revisiondelete/RevDelContribsItem.php', + 'RevDelContribsList' = __DIR__ . '/includes/revisiondelete/RevDelContribsList.php', 'RevDelFileItem' = __DIR__ . '/includes/revisiondelete/RevDelFileItem.php', 'RevDelFileList' = __DIR__ . '/includes/revisiondelete/RevDelFileList.php', 'RevDelItem' = __DIR__ . '/includes/revisiondelete/RevDelItem.php', diff --git a/includes/changetags/ChangeTagsContribsItem.php b/includes/changetags/ChangeTagsContribsItem.php new file mode 100644 index 000..09490ef --- /dev/null +++ b/includes/changetags/ChangeTagsContribsItem.php @@ -0,0 +1,104 @@ +?php +/** + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * http://www.gnu.org/copyleft/gpl.html + * + * @file + * @ingroup Change tagging + */ + +/** + * Item class for a live revision table row with its associated change tags. + * @since 1.25 + */ +class ChangeTagsContribsItem extends RevisionItem { + /** +* @return string Comma-separated list of tags +*/ + public function getTags() { + return $this-row-ts_tags; + } + + /** +* Get the HTML link to the revision text. +* Overridden by RevDelArchiveItem. +* @return string +*/ + protected function getRevisionLink() { + $date = htmlspecialchars( $this-list-getLanguage()-userTimeAndDate( + $this-revision-getTimestamp(), $this-list-getUser() ) ); + + if ( $this-isDeleted() !$this-canViewContent() ) { + return $date; + } + + return Linker::linkKnown( + $this-revision-getTitle(), + $date, + array(), + array( + 'oldid' = $this-revision-getId(), + 'unhide' = 1 +
[MediaWiki-commits] [Gerrit] Fix / adjust travis tests for hhvm - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210678 Change subject: Fix / adjust travis tests for hhvm .. Fix / adjust travis tests for hhvm The job is now hhvm instead of hhvm-nightly. Change-Id: Ic9f174d7135c9954747a57581b816f53830511c7 (cherry picked from commit b185c81dcbd433c00ded95826e98a9d8a1498e9c) --- M build/travis/install.sh 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/78/210678/1 diff --git a/build/travis/install.sh b/build/travis/install.sh index 498e748..2ab6361 100755 --- a/build/travis/install.sh +++ b/build/travis/install.sh @@ -4,7 +4,7 @@ PHPVERSION=`phpenv version-name` -if [ ${PHPVERSION} = 'hhvm-nightly' ] +if [ ${PHPVERSION} = 'hhvm' ] then PHPINI=/etc/hhvm/php.ini echo hhvm.enable_zend_compat = true $PHPINI -- To view, visit https://gerrit.wikimedia.org/r/210678 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic9f174d7135c9954747a57581b816f53830511c7 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.26wmf4 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] Update Wikidata - waitForSlaves in updateSubscriptions script - change (mediawiki/core)
jenkins-bot has submitted this change and it was merged. Change subject: Update Wikidata - waitForSlaves in updateSubscriptions script .. Update Wikidata - waitForSlaves in updateSubscriptions script Change-Id: Ic5aff689591d14d79ca28c66b191f3237fba6200 --- 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 ac044e2..79e11ec 16 --- a/extensions/Wikidata +++ b/extensions/Wikidata -Subproject commit ac044e2241858746e3c07766869b6ddd4fa042f7 +Subproject commit 79e11ecc73daf12c5404a69760566711a3629cf6 -- To view, visit https://gerrit.wikimedia.org/r/210686 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic5aff689591d14d79ca28c66b191f3237fba6200 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: wmf/1.26wmf5 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] Support changing icon variants on hover - change (mediawiki/core)
Catrope has uploaded a new change for review. https://gerrit.wikimedia.org/r/210688 Change subject: Support changing icon variants on hover .. Support changing icon variants on hover This introduces .mw-ui-icon-{name}-{variant}-hover which only displays the icon when the containing .mw-ui-hovericon element is hovered. Change-Id: I5be26cee39ec77daef3506be20a7a4f59787de36 --- M resources/Resources.php 1 file changed, 15 insertions(+), 15 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/88/210688/1 diff --git a/resources/Resources.php b/resources/Resources.php index ae5b3f9..94e3864 100644 --- a/resources/Resources.php +++ b/resources/Resources.php @@ -1768,7 +1768,7 @@ 'localBasePath' = $IP/resources/lib/oojs-ui/themes/mediawiki, 'data' = 'icons.json', 'selectorWithoutVariant' = '.oo-ui-icon-{name}, .mw-ui-icon-{name}:after, .mw-ui-icon-{name}:before', - 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before', + 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before, .mw-ui-hovericon:hover .mw-ui-icon-{name}-{variant}-hover:before, .mw-ui-hovericon.mw-ui-icon-{name}-{variant}-hover:hover:before', ), 'oojs-ui.styles.indicators' = array( 'class' = 'ResourceLoaderImageModule', @@ -1785,98 +1785,98 @@ 'localBasePath' = $IP/resources/lib/oojs-ui/themes/mediawiki, 'data' = 'icons-alerts.json', 'selectorWithoutVariant' = '.oo-ui-icon-{name}, .mw-ui-icon-{name}:after, .mw-ui-icon-{name}:before', - 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before', + 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before, .mw-ui-hovericon:hover .mw-ui-icon-{name}-{variant}-hover:before, .mw-ui-hovericon.mw-ui-icon-{name}-{variant}-hover:hover:before', ), 'oojs-ui.styles.icons-content' = array( 'class' = 'ResourceLoaderImageModule', 'localBasePath' = $IP/resources/lib/oojs-ui/themes/mediawiki, 'data' = 'icons-content.json', 'selectorWithoutVariant' = '.oo-ui-icon-{name}, .mw-ui-icon-{name}:after, .mw-ui-icon-{name}:before', - 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before', + 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before, .mw-ui-hovericon:hover .mw-ui-icon-{name}-{variant}-hover:before, .mw-ui-hovericon.mw-ui-icon-{name}-{variant}-hover:hover:before', ), 'oojs-ui.styles.icons-editing-advanced' = array( 'class' = 'ResourceLoaderImageModule', 'localBasePath' = $IP/resources/lib/oojs-ui/themes/mediawiki, 'data' = 'icons-editing-advanced.json', 'selectorWithoutVariant' = '.oo-ui-icon-{name}, .mw-ui-icon-{name}:after, .mw-ui-icon-{name}:before', - 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before', + 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before, .mw-ui-hovericon:hover .mw-ui-icon-{name}-{variant}-hover:before, .mw-ui-hovericon.mw-ui-icon-{name}-{variant}-hover:hover:before', ), 'oojs-ui.styles.icons-editing-core' = array( 'class' = 'ResourceLoaderImageModule', 'localBasePath' = $IP/resources/lib/oojs-ui/themes/mediawiki, 'data' = 'icons-editing-core.json', 'selectorWithoutVariant' = '.oo-ui-icon-{name}, .mw-ui-icon-{name}:after, .mw-ui-icon-{name}:before', - 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name}, .mw-ui-icon-{name}-{variant}:after, .mw-ui-icon-{name}-{variant}:before', + 'selectorWithVariant' = '.oo-ui-image-{variant} .oo-ui-icon-{name}, .oo-ui-image-{variant}.oo-ui-icon-{name},
[MediaWiki-commits] [Gerrit] LinkPreviewDialog: fix bug in EventLogging patch - change (apps...wikipedia)
Mholloway has uploaded a new change for review. https://gerrit.wikimedia.org/r/210689 Change subject: LinkPreviewDialog: fix bug in EventLogging patch .. LinkPreviewDialog: fix bug in EventLogging patch Change-Id: I92fd15450c4c4f615bb4a2c74b1af09df90cbfa1 --- M wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia refs/changes/89/210689/1 diff --git a/wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java b/wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java index 7cd62dc..e30e01d 100755 --- a/wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java +++ b/wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java @@ -176,6 +176,7 @@ @Override public void onDismiss(DialogInterface dialogInterface) { +super.onDismiss(dialogInterface); if (!navigateSuccess) { funnel.logCancel(); } -- To view, visit https://gerrit.wikimedia.org/r/210689 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I92fd15450c4c4f615bb4a2c74b1af09df90cbfa1 Gerrit-PatchSet: 1 Gerrit-Project: apps/android/wikipedia Gerrit-Branch: master Gerrit-Owner: Mholloway mhollo...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update Wikidata branch to wmf/1.26wmf6 - change (mediawiki...release)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210671 Change subject: Update Wikidata branch to wmf/1.26wmf6 .. Update Wikidata branch to wmf/1.26wmf6 Change-Id: I9af5e3f3168be183aa0312ba44e1ae0118011bbb --- M make-wmf-branch/default.conf 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/tools/release refs/changes/71/210671/1 diff --git a/make-wmf-branch/default.conf b/make-wmf-branch/default.conf index 8e45863..f80e183 100644 --- a/make-wmf-branch/default.conf +++ b/make-wmf-branch/default.conf @@ -182,7 +182,7 @@ 'DonationInterface' = 'deployment', // to use instead of the above - 'Wikidata' = 'wmf/1.26wmf4', + 'Wikidata' = 'wmf/1.26wmf6', // For wikitech use only! 'SemanticMediaWiki' = '1.8.x', -- To view, visit https://gerrit.wikimedia.org/r/210671 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I9af5e3f3168be183aa0312ba44e1ae0118011bbb Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/tools/release Gerrit-Branch: master Gerrit-Owner: Aude aude.w...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update WatchListApi API query continuation - change (mediawiki...MobileFrontend)
Phuedx has uploaded a new change for review. https://gerrit.wikimedia.org/r/210679 Change subject: Update WatchListApi API query continuation .. Update WatchListApi API query continuation Also: * fix documented return type of WatchListApi#load * don't use 'query-continue' in the InfiniteScroll tests Bug: T96866 Change-Id: I53d2dfe8263e4c94be3cf7495569a949074a86be --- M resources/mobile.watchlist/WatchListApi.js M tests/qunit/mobile.infiniteScroll/test_InfiniteScroll.js M tests/qunit/mobile.watchlist/test_WatchListApi.js 3 files changed, 61 insertions(+), 35 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MobileFrontend refs/changes/79/210679/1 diff --git a/resources/mobile.watchlist/WatchListApi.js b/resources/mobile.watchlist/WatchListApi.js index 1435f35..461b221 100644 --- a/resources/mobile.watchlist/WatchListApi.js +++ b/resources/mobile.watchlist/WatchListApi.js @@ -20,28 +20,31 @@ // Try to keep it in sync with SpecialMobileWatchlist::LIMIT (php) this.limit = 50; - // If we initialize from HTML, we will get in lastTitle the last title - // from the list to start requesting from that. Construct the `next` - // value from such title. if ( lastTitle ) { - this.next = '0|' + lastTitle.replace( / /g, '_' ); - this.nextByLastItem = true; + this.continueParams = { + continue: '-||', + gwrcontinue: '0|' + lastTitle.replace( / /g, '_' ) + }; + this.shouldSkipFirstTitle = true; } else { - this.next = ''; - this.nextByLastItem = false; + this.continueParams = { + continue: '' + }; + this.shouldSkipFirstTitle = false; } + + this.canContinue = true; }, /** * Load the list of items on the watchlist * @returns {jQuery.Deferred} */ load: function () { - if ( this.next === false ) { - // console.log( 'End of list' ); + if ( this.canContinue === false ) { return $.Deferred(); } var self = this, - params = { + params = $.extend( { action: 'query', prop: 'pageimages|info', piprop: 'thumbnail', @@ -50,41 +53,43 @@ generator: 'watchlistraw', gwrnamespace: '0', gwrlimit: this.limit - }; - if ( this.next ) { - params.gwrcontinue = this.next; + }, this.continueParams ); + + if ( this.shouldSkipFirstTitle ) { // If we are calling the api from the last item of the previous page // (like the first time when grabbing the last title from the HTML), // then request one extra element (make room for that last title) which // will be removed later when parsing data. - if ( this.nextByLastItem ) { - params.gwrlimit += 1; - } + params.gwrlimit += 1; } return this.get( params, { url: this.apiUrl } ).then( function ( data ) { - if ( - data[ 'query-continue' ] - data[ 'query-continue' ].watchlistraw - ) { - self.next = data[ 'query-continue' ].watchlistraw.gwrcontinue; + if ( data.hasOwnProperty( 'continue' ) ) { + self.continueParams = data['continue']; } else { - self.next = false; + self.canContinue = false;
[MediaWiki-commits] [Gerrit] Add event logging for link preview - change (apps...wikipedia)
Dbrant has submitted this change and it was merged. Change subject: Add event logging for link preview .. Add event logging for link preview Bug: T95726 Change-Id: I07e7338b8beff162129f0d0c90c46e683f779cef --- M wikipedia/src/main/java/org/wikipedia/analytics/Funnel.java A wikipedia/src/main/java/org/wikipedia/analytics/LinkPreviewFunnel.java M wikipedia/src/main/java/org/wikipedia/analytics/SearchFunnel.java M wikipedia/src/main/java/org/wikipedia/analytics/SessionFunnel.java R wikipedia/src/main/java/org/wikipedia/analytics/ShareAFactFunnel.java M wikipedia/src/main/java/org/wikipedia/page/PageViewFragmentInternal.java M wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java A wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewVersion.java M wikipedia/src/main/java/org/wikipedia/page/snippet/ShareHandler.java 9 files changed, 194 insertions(+), 90 deletions(-) Approvals: Dbrant: Looks good to me, approved jenkins-bot: Verified diff --git a/wikipedia/src/main/java/org/wikipedia/analytics/Funnel.java b/wikipedia/src/main/java/org/wikipedia/analytics/Funnel.java index 4993331..4a13d4c 100644 --- a/wikipedia/src/main/java/org/wikipedia/analytics/Funnel.java +++ b/wikipedia/src/main/java/org/wikipedia/analytics/Funnel.java @@ -12,6 +12,8 @@ private final int revision; private final WikipediaApp app; +private static final int SAMPLE_LOG_ALL = 1; + /** * The tag used for any analytics-related events sent to the Log. */ @@ -26,6 +28,7 @@ protected WikipediaApp getApp() { return app; } + /** * Optionally pre-process the event data before sending to EL. * @@ -36,59 +39,71 @@ return eventData; } +protected void log(Site site, Object... params) { +log(site, SAMPLE_LOG_ALL, params); +} + /** * Logs an event. * - * @param siteThe wiki in which this action was performed. - * @param params Actual data for the event. Considered to be an array - *of alternating key and value items (for easier - *use in subclass constructors). + * @param site The wiki in which this action was performed. + * @param rate The sampling rate. + * @param paramsActual data for the event. Considered to be an array + * of alternating key and value items (for easier + * use in subclass constructors). * - *For example, what would be expressed in a more sane - *language as: + * For example, what would be expressed in a more sane + * language as: * - *.log({ - * page: List of mass murderers, - * section: 2014 - *}); + * .log({ + * page: List of mass murderers, + * section: 2014 + * }); * - *would be expressed here as + * would be expressed here as * - *.log( - * page, List of mass murderers, - * section, 2014 - *); + * .log( + * page, List of mass murderers, + * section, 2014 + * ); * - *This format should be only used in subclass methods directly. - *The subclass methods should take more explicit parameters - *depending on what they are logging. + * This format should be only used in subclass methods directly. + * The subclass methods should take more explicit parameters + * depending on what they are logging. */ -protected void log(Site site, Object... params) { +protected void log(Site site, int rate, Object... params) { if (!app.isEventLoggingEnabled()) { // Do not send events if the user opted out of EventLogging return; } -JSONObject eventData = new JSONObject(); -//Build the string which is logged to debug EventLogging code -String logString = this.getClass().getSimpleName() + : Sending event; -try { -for (int i = 0; i params.length; i += 2) { -eventData.put(params[i].toString(), params[i + 1]); -logString += , event_ + params[i] + = + params[i + 1]; +if (rate != 0) { +boolean chosen = app.getAppInstallIDInt() % rate == 0; + +if (chosen) { +JSONObject eventData = new JSONObject(); + +//Build the string
[MediaWiki-commits] [Gerrit] Updates to editor search panel styling and behaviour - change (mediawiki...Gather)
jenkins-bot has submitted this change and it was merged. Change subject: Updates to editor search panel styling and behaviour .. Updates to editor search panel styling and behaviour * Close search pane when an item is clicked * Minor styling tweaks Bug: T98762 Change-Id: I520c7231cce06cd08dc0c964df668d99f300533b --- M resources/ext.gather.collection.editor/CollectionEditOverlay.js M resources/ext.gather.collection.editor/editOverlay.less M resources/ext.gather.page.search/CollectionSearchPanel.js M resources/ext.gather.page.search/searchPanel.less 4 files changed, 11 insertions(+), 1 deletion(-) Approvals: Jhernandez: Looks good to me, approved jenkins-bot: Verified diff --git a/resources/ext.gather.collection.editor/CollectionEditOverlay.js b/resources/ext.gather.collection.editor/CollectionEditOverlay.js index 08e6936..6b145ba 100644 --- a/resources/ext.gather.collection.editor/CollectionEditOverlay.js +++ b/resources/ext.gather.collection.editor/CollectionEditOverlay.js @@ -112,6 +112,8 @@ pages: pages, el: self.$( '.panel' ) } ); + self.searchPanel.on( 'member-removed', $.proxy( self, '_switchToFirstPane' ) ); + self.searchPanel.on( 'member-added', $.proxy( self, '_switchToFirstPane' ) ); self.searchPanel.show(); } ); }, diff --git a/resources/ext.gather.collection.editor/editOverlay.less b/resources/ext.gather.collection.editor/editOverlay.less index bd17284..cb94a73 100644 --- a/resources/ext.gather.collection.editor/editOverlay.less +++ b/resources/ext.gather.collection.editor/editOverlay.less @@ -40,5 +40,6 @@ .panel { border: none; + padding: 0; } } diff --git a/resources/ext.gather.page.search/CollectionSearchPanel.js b/resources/ext.gather.page.search/CollectionSearchPanel.js index e6262e1..20c7ca4 100644 --- a/resources/ext.gather.page.search/CollectionSearchPanel.js +++ b/resources/ext.gather.page.search/CollectionSearchPanel.js @@ -99,9 +99,17 @@ } ); this.pageList.on( 'member-removed', function ( page ) { self._updateCollectionMembers( page, true ); + /** +* @event member-removed +*/ + self.emit( 'member-removed' ); } ); this.pageList.on( 'member-added', function ( page ) { self._updateCollectionMembers( page ); + /** +* @event member-added +*/ + self.emit( 'member-added' ); } ); } this.pageList.renderPageImages(); diff --git a/resources/ext.gather.page.search/searchPanel.less b/resources/ext.gather.page.search/searchPanel.less index d313d23..58f9ad7 100644 --- a/resources/ext.gather.page.search/searchPanel.less +++ b/resources/ext.gather.page.search/searchPanel.less @@ -26,7 +26,6 @@ .search { position: relative; border: solid 1px @colorGrayLightest; - margin-bottom: 8px; height: 3em; padding-left: 3em; -- To view, visit https://gerrit.wikimedia.org/r/210204 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I520c7231cce06cd08dc0c964df668d99f300533b 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] Switch travis to use hhvm instead of hhvm-nightly - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210674 Change subject: Switch travis to use hhvm instead of hhvm-nightly .. Switch travis to use hhvm instead of hhvm-nightly hhvm-nightly is no longer supported: https://github.com/travis-ci/travis-ci/issues/3788 Change-Id: Ic697ac6650fe8e2f55135140946d154f7c96c589 (cherry picked from commit 4207f08ff17f7e8b16e2c51fd5f6235438dc00d1) --- M .travis.yml 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/74/210674/1 diff --git a/.travis.yml b/.travis.yml index fa86f35..416b453 100644 --- a/.travis.yml +++ b/.travis.yml @@ -14,7 +14,7 @@ - env: DBTYPE=mysql LANG=en MW=master WB=repo php: 5.6 - env: DBTYPE=sqlite LANG=en MW=master WB=both - php: hhvm-nightly + php: hhvm before_script: - bash ./build/travis/install.sh -- To view, visit https://gerrit.wikimedia.org/r/210674 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic697ac6650fe8e2f55135140946d154f7c96c589 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.26wmf4 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] Make config script more robust. - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Make config script more robust. .. Make config script more robust. Make it independent of the current state of LocalSettings.php: Either add opening and closing PHP tags when the file is closed with one, or don't. This is necessary because I plan to change when this script is executed by our CI. At that point the CIs LocalSettings.php is not closed with a PHP tag, where as when it is currently execute there is a closing PHP tag. Bug: T97529 Change-Id: Ie5611fd24c0f245b2aceb48610a866c61cf8a4e1 (cherry picked from commit daeed233b32d4f4da6a2eeb51d1beb6cf8d8902c) --- M build/jenkins/mw-apply-wb-settings.sh 1 file changed, 12 insertions(+), 2 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/build/jenkins/mw-apply-wb-settings.sh b/build/jenkins/mw-apply-wb-settings.sh index b18bb1a..49d80b7 100755 --- a/build/jenkins/mw-apply-wb-settings.sh +++ b/build/jenkins/mw-apply-wb-settings.sh @@ -54,7 +54,14 @@ cd $WORKSPACE/src -echo '?php' LocalSettings.php +if [ $(tail -n1 LocalSettings.php) = ? ] +then + PHPTAGS=true +fi +if [ -v PHPTAGS ] +then + echo '?php' LocalSettings.php +fi apply_experimental_settings @@ -68,4 +75,7 @@ usage fi -echo '?' LocalSettings.php +if [ -v PHPTAGS ] +then + echo '?' LocalSettings.php +fi -- To view, visit https://gerrit.wikimedia.org/r/210673 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ie5611fd24c0f245b2aceb48610a866c61cf8a4e1 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.26wmf4 Gerrit-Owner: Aude aude.w...@gmail.com Gerrit-Reviewer: Aude aude.w...@gmail.com Gerrit-Reviewer: JanZerebecki jan.wikime...@zerebecki.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] depool db1060 for thread pool reconfig - change (operations/mediawiki-config)
jenkins-bot has submitted this change and it was merged. Change subject: depool db1060 for thread pool reconfig .. depool db1060 for thread pool reconfig Change-Id: If9d5b427c4f822877603afd9ae110845270a4ff9 --- M wmf-config/db-eqiad.php 1 file changed, 2 insertions(+), 2 deletions(-) Approvals: Springle: Looks good to me, approved jenkins-bot: Verified diff --git a/wmf-config/db-eqiad.php b/wmf-config/db-eqiad.php index 6c9a655..2bf0beb 100755 --- a/wmf-config/db-eqiad.php +++ b/wmf-config/db-eqiad.php @@ -103,7 +103,7 @@ 'db1021' = 0, # 1.4TB 64GB, dump, vslow 'db1036' = 0, # 1.4TB 64GB, watchlist, recentchanges, contributions, logpager 'db1054' = 200, # 2.8TB 96GB, api - 'db1060' = 200, # 2.8TB 96GB, api + # thread pool reconfig 'db1060' = 200, # 2.8TB 96GB, api 'db1063' = 400, # 2.8TB 128GB 'db1067' = 500, # 2.8TB 160GB ), @@ -202,7 +202,7 @@ ), 'api' = array( 'db1054' = 1, - 'db1060' = 1, + # thread pool reconfig 'db1060' = 1, ), 'watchlist' = array( 'db1036' = 1, -- To view, visit https://gerrit.wikimedia.org/r/210676 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: If9d5b427c4f822877603afd9ae110845270a4ff9 Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Springle sprin...@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] Switch travis to use hhvm instead of hhvm-nightly - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Switch travis to use hhvm instead of hhvm-nightly .. Switch travis to use hhvm instead of hhvm-nightly hhvm-nightly is no longer supported: https://github.com/travis-ci/travis-ci/issues/3788 Change-Id: Ic697ac6650fe8e2f55135140946d154f7c96c589 (cherry picked from commit 4207f08ff17f7e8b16e2c51fd5f6235438dc00d1) --- M .travis.yml 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/.travis.yml b/.travis.yml index fa86f35..416b453 100644 --- a/.travis.yml +++ b/.travis.yml @@ -14,7 +14,7 @@ - env: DBTYPE=mysql LANG=en MW=master WB=repo php: 5.6 - env: DBTYPE=sqlite LANG=en MW=master WB=both - php: hhvm-nightly + php: hhvm before_script: - bash ./build/travis/install.sh -- To view, visit https://gerrit.wikimedia.org/r/210674 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic697ac6650fe8e2f55135140946d154f7c96c589 Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.26wmf4 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] Fix / adjust travis tests for hhvm - change (mediawiki...Wikibase)
jenkins-bot has submitted this change and it was merged. Change subject: Fix / adjust travis tests for hhvm .. Fix / adjust travis tests for hhvm The job is now hhvm instead of hhvm-nightly. Change-Id: Ic9f174d7135c9954747a57581b816f53830511c7 (cherry picked from commit b185c81dcbd433c00ded95826e98a9d8a1498e9c) --- M build/travis/install.sh 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/build/travis/install.sh b/build/travis/install.sh index 498e748..2ab6361 100755 --- a/build/travis/install.sh +++ b/build/travis/install.sh @@ -4,7 +4,7 @@ PHPVERSION=`phpenv version-name` -if [ ${PHPVERSION} = 'hhvm-nightly' ] +if [ ${PHPVERSION} = 'hhvm' ] then PHPINI=/etc/hhvm/php.ini echo hhvm.enable_zend_compat = true $PHPINI -- To view, visit https://gerrit.wikimedia.org/r/210678 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic9f174d7135c9954747a57581b816f53830511c7 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: wmf/1.26wmf4 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] [FIX] TerminalHandler: Expect str in Python 2 - change (pywikibot/core)
XZise has uploaded a new change for review. https://gerrit.wikimedia.org/r/210681 Change subject: [FIX] TerminalHandler: Expect str in Python 2 .. [FIX] TerminalHandler: Expect str in Python 2 The args of a record are str in Python 2 (so basically bytes). It now compared the str with unicode which works in Python 3 (as both are the same there) or Python 2 if the warning message contains only ASCII characters. With 1e54a7d6 unicode_literals was added to the module which changed the strings into unicode in Python 2. And Python converts the string into unicode when it tries to do a __contains__ test. It decodes it using ASCII which fails when there are non-ASCII characters in the string. Bug: T98955 Change-Id: Ia421c085897e14e01a59e3c2a14822b2a7cd0ddd --- M pywikibot/userinterfaces/terminal_interface_base.py 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core refs/changes/81/210681/1 diff --git a/pywikibot/userinterfaces/terminal_interface_base.py b/pywikibot/userinterfaces/terminal_interface_base.py index 968a14b..c4468e3 100755 --- a/pywikibot/userinterfaces/terminal_interface_base.py +++ b/pywikibot/userinterfaces/terminal_interface_base.py @@ -491,7 +491,7 @@ msg = record.args[0] is_useless_source_output = any( s in msg for s in -('warn(', 'exceptions.', 'Warning)', 'Warning,')) +(str('warn('), str('exceptions.'), str('Warning)'), str('Warning,'))) if is_useless_source_output: record.args = ('\n'.join(record.args[0].splitlines()[0:-1]),) -- To view, visit https://gerrit.wikimedia.org/r/210681 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia421c085897e14e01a59e3c2a14822b2a7cd0ddd 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] Changed description of UpdateTable script. Removed nonsense ... - change (mediawiki...WikidataQualityExternalValidation)
Soeren.oldag has uploaded a new change for review. https://gerrit.wikimedia.org/r/210683 Change subject: Changed description of UpdateTable script. Removed nonsense lines. .. Changed description of UpdateTable script. Removed nonsense lines. Change-Id: Ic1d039991eef68e9c0c376f5d537a5eea58afa2a --- M includes/ExternalDataRepo.php M maintenance/UpdateTable.php 2 files changed, 1 insertion(+), 9 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityExternalValidation refs/changes/83/210683/1 diff --git a/includes/ExternalDataRepo.php b/includes/ExternalDataRepo.php index 6bc9fd1..fbcb278 100644 --- a/includes/ExternalDataRepo.php +++ b/includes/ExternalDataRepo.php @@ -145,7 +145,6 @@ * * @param array $dumpIds * @param int $batchSize - * @return bool|\ResultWrapper * @throws \DBUnexpectedError */ public function deleteOfDumps( array $dumpIds, $batchSize = 1000 ) { @@ -163,11 +162,6 @@ $db-query( sprintf('DELETE FROM %s WHERE %s LIMIT %s', $table, $condition, $batchSize ) ); } while ( $db-affectedRows() 0 ); } - -return $db-delete( -$this-tableName, -array( $this-buildSqlInCondition( 'dump_id', $dumpIds ) ) -); } /** diff --git a/maintenance/UpdateTable.php b/maintenance/UpdateTable.php index b862508..1119a7d 100644 --- a/maintenance/UpdateTable.php +++ b/maintenance/UpdateTable.php @@ -3,8 +3,6 @@ namespace WikidataQuality\ExternalValidation\Maintenance; use Maintenance; -use WikidataQuality\ExternalValidation\DumpMetaInformation\DumpMetaInformationRepo; -use WikidataQuality\ExternalValidation\ExternalDataRepo; use WikidataQuality\ExternalValidation\ExternalValidationFactory; use WikidataQuality\ExternalValidation\UpdateTable\ImportContext; use WikidataQuality\ExternalValidation\UpdateTable\Importer; @@ -29,7 +27,7 @@ public function __construct() { parent::__construct(); -$this-mDescription = Downloads dumps of external databases and imports the entities into the local database.; +$this-mDescription = Imports external entities from a given TAR file into the local database. TAR file can be generated using the DumpConverter.; $this-addOption( 'tar-file', 'TAR file that contains external data for import.', true, true ); $this-setBatchSize( 1000 ); } -- To view, visit https://gerrit.wikimedia.org/r/210683 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic1d039991eef68e9c0c376f5d537a5eea58afa2a Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/WikidataQualityExternalValidation Gerrit-Branch: v1 Gerrit-Owner: Soeren.oldag soeren_ol...@freenet.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update Wikidata - waitForSlaves for updateSubscriptions script - change (mediawiki...Wikidata)
jenkins-bot has submitted this change and it was merged. Change subject: Update Wikidata - waitForSlaves for updateSubscriptions script .. Update Wikidata - waitForSlaves for updateSubscriptions script also changes for travis and jenkins builds, which have changed since the deployment branch was made. Change-Id: Idbe8dacdd11337ffc1d0e0964e82d2e116ceee7c --- M composer.json M composer.lock M extensions/Wikibase/.travis.yml M extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh M extensions/Wikibase/build/travis/install.sh M extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php M extensions/Wikibase/client/maintenance/updateSubscriptions.php M extensions/Wikibase/client/tests/phpunit/includes/store/sql/BulkSubscriptionUpdaterTest.php M vendor/composer/installed.json 9 files changed, 44 insertions(+), 12 deletions(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/composer.json b/composer.json index 52172ab..55594dc 100644 --- a/composer.json +++ b/composer.json @@ -5,7 +5,7 @@ repositories: [ { type: vcs, - url: https://git.wikimedia.org/git/mediawiki/extensions/Wikibase.git; + url: https://gerrit.wikimedia.org/r/mediawiki/extensions/Wikibase.git; }, { type: vcs, diff --git a/composer.lock b/composer.lock index 404b5f6..c42360b 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file;, This file is @generated automatically ], -hash: 70bd36b4d0c521e3a184fdd7e0c95fe3, +hash: dccb290555a2dca0e70584c37c009bb3, packages: [ { name: composer/installers, @@ -1212,8 +1212,8 @@ version: dev-wmf/1.26wmf4, source: { type: git, -url: https://git.wikimedia.org/git/mediawiki/extensions/Wikibase.git;, -reference: c6df5a162ec8128ff9036217739b3e0927caa2ce +url: https://gerrit.wikimedia.org/r/mediawiki/extensions/Wikibase.git;, +reference: 820f66d33caaed5a6510ea4e84a979aa8a46daae }, require: { data-values/common: ~0.2.0, @@ -1283,7 +1283,7 @@ issues: https://bugzilla.wikimedia.org/;, irc: irc://irc.freenode.net/wikidata }, -time: 2015-05-11 10:40:03 +time: 2015-05-13 13:06:16 }, { name: wikibase/wikimedia-badges, diff --git a/extensions/Wikibase/.travis.yml b/extensions/Wikibase/.travis.yml index fa86f35..416b453 100644 --- a/extensions/Wikibase/.travis.yml +++ b/extensions/Wikibase/.travis.yml @@ -14,7 +14,7 @@ - env: DBTYPE=mysql LANG=en MW=master WB=repo php: 5.6 - env: DBTYPE=sqlite LANG=en MW=master WB=both - php: hhvm-nightly + php: hhvm before_script: - bash ./build/travis/install.sh diff --git a/extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh b/extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh index b18bb1a..49d80b7 100755 --- a/extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh +++ b/extensions/Wikibase/build/jenkins/mw-apply-wb-settings.sh @@ -54,7 +54,14 @@ cd $WORKSPACE/src -echo '?php' LocalSettings.php +if [ $(tail -n1 LocalSettings.php) = ? ] +then + PHPTAGS=true +fi +if [ -v PHPTAGS ] +then + echo '?php' LocalSettings.php +fi apply_experimental_settings @@ -68,4 +75,7 @@ usage fi -echo '?' LocalSettings.php +if [ -v PHPTAGS ] +then + echo '?' LocalSettings.php +fi diff --git a/extensions/Wikibase/build/travis/install.sh b/extensions/Wikibase/build/travis/install.sh index 498e748..2ab6361 100755 --- a/extensions/Wikibase/build/travis/install.sh +++ b/extensions/Wikibase/build/travis/install.sh @@ -4,7 +4,7 @@ PHPVERSION=`phpenv version-name` -if [ ${PHPVERSION} = 'hhvm-nightly' ] +if [ ${PHPVERSION} = 'hhvm' ] then PHPINI=/etc/hhvm/php.ini echo hhvm.enable_zend_compat = true $PHPINI diff --git a/extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php b/extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php index c85fb93..e48105d 100644 --- a/extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php +++ b/extensions/Wikibase/client/includes/store/sql/BulkSubscriptionUpdater.php @@ -36,6 +36,13 @@ private $subscriberWikiId; /** +* @var string|false The repo wiki's id, as used by the LoadBalancer. Used for wait for slaves. +* False indicates to use the local wiki's database, and is the default +* for the repoWiki setting. +*/ + private $repoWiki; + + /** * @var int */ private $batchSize; @@ -57,6 +64,9 @@
[MediaWiki-commits] [Gerrit] Enable usage tracking on Wikisource - change (operations/mediawiki-config)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210687 Change subject: Enable usage tracking on Wikisource .. Enable usage tracking on Wikisource This is nothing visible from a user's perspective, and is a prerequisite for arbitrary access. Change-Id: Icfe94b2dba99b10f4d4961b12b33289de008 --- M wmf-config/InitialiseSettings.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config refs/changes/87/210687/1 diff --git a/wmf-config/InitialiseSettings.php b/wmf-config/InitialiseSettings.php index ce60fbf..f988f0d 100644 --- a/wmf-config/InitialiseSettings.php +++ b/wmf-config/InitialiseSettings.php @@ -14848,11 +14848,11 @@ 'default' = true, 'enwikivoyage' = false, // Bug T98237 'fawiki' = false, // Bug T98237 - 'frwikisource' = false, // Bug T96683 'hewiki' = false, // Bug T98237 'nlwiki' = false, // Bug T96683 'testwiki' = false, 'wikidata' = false, + 'wikisource' = false, // Bug T96683 and T98240 ), 'wmgUseWikibaseRepo' = array( -- To view, visit https://gerrit.wikimedia.org/r/210687 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Icfe94b2dba99b10f4d4961b12b33289de008 Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Aude aude.w...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Only show colored icons on hover - change (mediawiki...Flow)
Catrope has uploaded a new change for review. https://gerrit.wikimedia.org/r/210690 Change subject: Only show colored icons on hover .. Only show colored icons on hover Depends on I5be26cee39 in MW core. Change-Id: I766b55b216c37b717f914545adf5d5fed42528fb --- M handlebars/compiled/flow_block_board-history.handlebars.php M handlebars/compiled/flow_block_topic.handlebars.php M handlebars/compiled/flow_block_topic_history.handlebars.php M handlebars/compiled/flow_block_topic_moderate_post.handlebars.php M handlebars/compiled/flow_block_topic_moderate_topic.handlebars.php M handlebars/compiled/flow_block_topiclist.handlebars.php M handlebars/compiled/flow_post.handlebars.php M handlebars/flow_moderation_actions_list.partial.handlebars 8 files changed, 127 insertions(+), 127 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Flow refs/changes/90/210690/1 -- To view, visit https://gerrit.wikimedia.org/r/210690 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I766b55b216c37b717f914545adf5d5fed42528fb Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Flow Gerrit-Branch: master Gerrit-Owner: Catrope roan.katt...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Enable usage tracking on Wikisource - change (operations/mediawiki-config)
jenkins-bot has submitted this change and it was merged. Change subject: Enable usage tracking on Wikisource .. Enable usage tracking on Wikisource This is nothing visible from a user's perspective, and is a prerequisite for arbitrary access. Change-Id: Icfe94b2dba99b10f4d4961b12b33289de008 --- M wmf-config/InitialiseSettings.php 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Aude: Looks good to me, approved jenkins-bot: Verified diff --git a/wmf-config/InitialiseSettings.php b/wmf-config/InitialiseSettings.php index ce60fbf..f988f0d 100644 --- a/wmf-config/InitialiseSettings.php +++ b/wmf-config/InitialiseSettings.php @@ -14848,11 +14848,11 @@ 'default' = true, 'enwikivoyage' = false, // Bug T98237 'fawiki' = false, // Bug T98237 - 'frwikisource' = false, // Bug T96683 'hewiki' = false, // Bug T98237 'nlwiki' = false, // Bug T96683 'testwiki' = false, 'wikidata' = false, + 'wikisource' = false, // Bug T96683 and T98240 ), 'wmgUseWikibaseRepo' = array( -- To view, visit https://gerrit.wikimedia.org/r/210687 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Icfe94b2dba99b10f4d4961b12b33289de008 Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master 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] Add Jan Zerebecki to contint-admins - change (operations/puppet)
Hashar has uploaded a new change for review. https://gerrit.wikimedia.org/r/210692 Change subject: Add Jan Zerebecki to contint-admins .. Add Jan Zerebecki to contint-admins Bug: T98961 Change-Id: I98241cdb9d6174164c33bf2d11384b8a14829c82 --- M modules/admin/data/data.yaml 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/92/210692/1 diff --git a/modules/admin/data/data.yaml b/modules/admin/data/data.yaml index 82f2762..7c78caf 100644 --- a/modules/admin/data/data.yaml +++ b/modules/admin/data/data.yaml @@ -125,7 +125,7 @@ gid: 719 description: users with some sudo permissions on jenkins hosts members: [bd808, cscott, dduvall, demon, krinkle, reedy, marktraceur, - twentyafterfour, zfilipin, thcipriani, legoktm] + twentyafterfour, zfilipin, thcipriani, legoktm, jzerebecki] privileges: ['ALL = (jenkins) NOPASSWD: ALL', 'ALL = (jenkins-slave) NOPASSWD: ALL', 'ALL = (gerritslave) NOPASSWD: ALL', -- To view, visit https://gerrit.wikimedia.org/r/210692 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I98241cdb9d6174164c33bf2d11384b8a14829c82 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Hashar has...@free.fr ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add test entry points (composer npm) - change (mediawiki...OOJsUIAjaxLogin)
Florianschmidtwelzow has uploaded a new change for review. https://gerrit.wikimedia.org/r/210693 Change subject: Add test entry points (composer npm) .. Add test entry points (composer npm) And add local files to gitignore Change-Id: Ifbb0d7a61f67c57ea575001aea6ab98be81d768f --- A .gitignore A composer.json A packages.json 3 files changed, 28 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/OOJsUIAjaxLogin refs/changes/93/210693/1 diff --git a/.gitignore b/.gitignore new file mode 100644 index 000..13e6098 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +node_modules/* +vendor/* +composer.lock + diff --git a/composer.json b/composer.json new file mode 100644 index 000..f261860 --- /dev/null +++ b/composer.json @@ -0,0 +1,13 @@ +{ +require-dev: { +jakub-onderka/php-parallel-lint: 0.8.*, +mediawiki/mediawiki-codesniffer: 0.1.0 +}, +scripts: { +test: [ +parallel-lint . --exclude vendor, +phpcs --standard=vendor/mediawiki/mediawiki-codesniffer/MediaWiki --extensions=php,php5,inc --ignore=vendor -p . +] +} +} + diff --git a/packages.json b/packages.json new file mode 100644 index 000..98ec22a --- /dev/null +++ b/packages.json @@ -0,0 +1,11 @@ +{ + scripts: { + test: jshint ./resources/ jscs ./resources/, + doc: jsduck + }, + devDependencies: { +jshint: 2.6.3, +jscs: 1.11.3 + } +} + -- To view, visit https://gerrit.wikimedia.org/r/210693 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ifbb0d7a61f67c57ea575001aea6ab98be81d768f Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/OOJsUIAjaxLogin Gerrit-Branch: master Gerrit-Owner: Florianschmidtwelzow florian.schmidt.wel...@t-online.de ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] remove temporary intel-microcode purge - change (operations/puppet)
BBlack has uploaded a new change for review. https://gerrit.wikimedia.org/r/210696 Change subject: remove temporary intel-microcode purge .. remove temporary intel-microcode purge Change-Id: I45745553319560c83171f8798cee8b612d8cc670 --- M modules/base/manifests/standard-packages.pp 1 file changed, 0 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/96/210696/1 diff --git a/modules/base/manifests/standard-packages.pp b/modules/base/manifests/standard-packages.pp index a2b444a..8df78a2 100644 --- a/modules/base/manifests/standard-packages.pp +++ b/modules/base/manifests/standard-packages.pp @@ -70,7 +70,5 @@ if $::is_virtual == 'false' { # lint:endignore package { 'mcelog': ensure = present } -# purging this due to buggy interactions with new kernels + initramfs - low cpu freq -package { 'intel-microcode': ensure = purged } } } -- To view, visit https://gerrit.wikimedia.org/r/210696 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I45745553319560c83171f8798cee8b612d8cc670 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] Revert abusive-search block from 51e15f3be - change (operations/puppet)
BBlack has uploaded a new change for review. https://gerrit.wikimedia.org/r/210695 Change subject: Revert abusive-search block from 51e15f3be .. Revert abusive-search block from 51e15f3be Change-Id: I0e597db2afd05106925ee294411e3d27878686c6 --- M templates/varnish/text-frontend.inc.vcl.erb 1 file changed, 0 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/95/210695/1 diff --git a/templates/varnish/text-frontend.inc.vcl.erb b/templates/varnish/text-frontend.inc.vcl.erb index 23fef9a..ae89fb5 100644 --- a/templates/varnish/text-frontend.inc.vcl.erb +++ b/templates/varnish/text-frontend.inc.vcl.erb @@ -78,9 +78,6 @@ if (req.request == POST req.url ~ index\.php\?option=com_jcetask=pluginplugin=imgmanagerfile=imgmanagermethod=formcid=) { error 403 Noise; } - if (req.url ~ ^/w/api.php\?srsearch=Sju\+svarta req.http.User-Agent ~ wikipedia) { - error 403 Stop doing this :p; - } } sub vcl_recv { -- To view, visit https://gerrit.wikimedia.org/r/210695 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I0e597db2afd05106925ee294411e3d27878686c6 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] update table script + refactoring - change (mediawiki...WikidataQualityConstraints)
Jonaskeutel has uploaded a new change for review. https://gerrit.wikimedia.org/r/210691 Change subject: update table script + refactoring .. update table script + refactoring Change-Id: I3ae96f7cdb47181a95c484adebff8c1dff9b01de --- M composer.json M includes/Constraint.php M includes/ConstraintCheck/Checker/CommonsLinkChecker.php M includes/ConstraintCheck/Checker/ConflictsWithChecker.php M includes/ConstraintCheck/Checker/DiffWithinRangeChecker.php M includes/ConstraintCheck/Checker/FormatChecker.php M includes/ConstraintCheck/Checker/InverseChecker.php M includes/ConstraintCheck/Checker/ItemChecker.php M includes/ConstraintCheck/Checker/MandatoryQualifiersChecker.php M includes/ConstraintCheck/Checker/OneOfChecker.php M includes/ConstraintCheck/Checker/QualifiersChecker.php M includes/ConstraintCheck/Checker/RangeChecker.php M includes/ConstraintCheck/Checker/TargetRequiredClaimChecker.php M includes/ConstraintCheck/Checker/TypeChecker.php M includes/ConstraintCheck/Checker/ValueTypeChecker.php M includes/ConstraintCheck/DelegatingConstraintChecker.php M includes/ConstraintRepository.php A maintenance/UpdateTable.php M tests/phpunit/ConstraintTest.php 19 files changed, 168 insertions(+), 42 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityConstraints refs/changes/91/210691/1 diff --git a/composer.json b/composer.json index e2ce46f..b60a41a 100644 --- a/composer.json +++ b/composer.json @@ -34,7 +34,8 @@ psr-4: { WikidataQuality\\ConstraintReport\\: includes/, WikidataQuality\\ConstraintReport\\Specials\\: specials/, - WikidataQuality\\ConstraintReport\\Tests\\: tests/phpunit/ + WikidataQuality\\ConstraintReport\\Tests\\: tests/phpunit/, + WikidataQuality\\ConstraintReport\\Maintenance: maintenance }, classmap: [ WikibaseQualityConstraintsHooks.php diff --git a/includes/Constraint.php b/includes/Constraint.php index 4588351..8a4803d 100644 --- a/includes/Constraint.php +++ b/includes/Constraint.php @@ -9,30 +9,59 @@ class Constraint { + /** +* @var string +*/ + private $constraintClaimGuid; + + /** +* @var string +*/ private $constraintTypeQid; - private $constraintParameter; - public function __construct( $constraintEntry ) { - $this-constraintTypeQid = $constraintEntry-constraint_type_qid; + /** +* @var string +*/ + private $propertyId; - $parameterMap = ConstraintReportFactory::getDefaultInstance()-getConstraintParameterMap(); - $constraintParameter = array(); - $jsonParameter = json_decode( $constraintEntry-constraint_parameters ); - $helper = new ConstraintReportHelper(); - if( array_key_exists( $this-constraintTypeQid, $parameterMap ) ) { - foreach( $parameterMap[$this-constraintTypeQid] as $par ) { - $constraintParameter[$par] = $helper-stringToArray( $helper-getParameterFromJson( $jsonParameter, $par ) ); - } - } - $constraintParameter['exceptions'] = $helper-stringToArray( $helper-getParameterFromJson( $jsonParameter, 'known_exception' ) ); - $this-constraintParameter = $constraintParameter; + /** +* @var array +*/ + private $constraintParameters; + + public function __construct( $constraintClaimGuid, $propertyId, $constraintTypeQid, $constraintParameters) { + $this-constraintClaimGuid = $constraintClaimGuid; + $this-constraintTypeQid = $constraintTypeQid; + $this-propertyId = $propertyId; + $this-constraintParameters = $constraintParameters; } + /** +* @return string +*/ + public function getConstraintClaimGuid() { + return $this-constraintClaimGuid; + } + + /** +* @return string +*/ public function getConstraintTypeQid() { return $this-constraintTypeQid; } - public function getConstraintParameter() { - return $this-constraintParameter; + /** +* @return string +*/ + public function getPropertyId() { + return $this-propertyId; } + + /** +* @return array +*/ + public function getConstraintParameters() { + return $this-constraintParameters; + } + } \ No newline at end of file diff --git a/includes/ConstraintCheck/Checker/CommonsLinkChecker.php b/includes/ConstraintCheck/Checker/CommonsLinkChecker.php index a57254e..3b95df0 100644 ---
[MediaWiki-commits] [Gerrit] Upgrade Elasticsearch plugins - change (operations...plugins)
Manybubbles has submitted this change and it was merged. Change subject: Upgrade Elasticsearch plugins .. Upgrade Elasticsearch plugins Highlighter to 1.3.0 and extra to 1.3.1 Change-Id: I40f4149fa41dc3048145de0da827c5b847d612c6 --- D experimental-highlighter-elasticsearch-plugin/experimental-highlighter-core-0.0.13.jar A experimental-highlighter-elasticsearch-plugin/experimental-highlighter-core-1.3.0.jar D experimental-highlighter-elasticsearch-plugin/experimental-highlighter-elasticsearch-plugin-0.0.13.jar A experimental-highlighter-elasticsearch-plugin/experimental-highlighter-elasticsearch-plugin-1.3.0.jar D experimental-highlighter-elasticsearch-plugin/experimental-highlighter-lucene-0.0.13.jar A experimental-highlighter-elasticsearch-plugin/experimental-highlighter-lucene-1.3.0.jar D extra/extra-1.3.0.jar A extra/extra-1.3.1.jar 8 files changed, 4 insertions(+), 4 deletions(-) Approvals: Manybubbles: Verified; Looks good to me, approved diff --git a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-core-0.0.13.jar b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-core-0.0.13.jar deleted file mode 100644 index bc52ab0..000 --- a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-core-0.0.13.jar +++ /dev/null @@ -1 +0,0 @@ -#$# git-fat 59c3fae97f6311adec028fe34af683e53bb20d34 127443 diff --git a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-core-1.3.0.jar b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-core-1.3.0.jar new file mode 100644 index 000..d281e10 --- /dev/null +++ b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-core-1.3.0.jar @@ -0,0 +1 @@ +#$# git-fat 39cb36e109613b541cc2b05b9db1fc2aa3cf09b4 127811 diff --git a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-elasticsearch-plugin-0.0.13.jar b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-elasticsearch-plugin-0.0.13.jar deleted file mode 100644 index de02be9..000 --- a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-elasticsearch-plugin-0.0.13.jar +++ /dev/null @@ -1 +0,0 @@ -#$# git-fat 8ab0acdd0a74329e9ccc4b0ecf2b919cda26cc7c39225 diff --git a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-elasticsearch-plugin-1.3.0.jar b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-elasticsearch-plugin-1.3.0.jar new file mode 100644 index 000..7621a66 --- /dev/null +++ b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-elasticsearch-plugin-1.3.0.jar @@ -0,0 +1 @@ +#$# git-fat 167329b5633589dce7818f51c46c0f1d5887339c39937 diff --git a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-lucene-0.0.13.jar b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-lucene-0.0.13.jar deleted file mode 100644 index e8f1ef7..000 --- a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-lucene-0.0.13.jar +++ /dev/null @@ -1 +0,0 @@ -#$# git-fat 0e9b4700864d2039d12a8ceeba555287447ca5f0 211891 diff --git a/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-lucene-1.3.0.jar b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-lucene-1.3.0.jar new file mode 100644 index 000..587187a --- /dev/null +++ b/experimental-highlighter-elasticsearch-plugin/experimental-highlighter-lucene-1.3.0.jar @@ -0,0 +1 @@ +#$# git-fat f74eea01fefff1a2db376bca61b4781882eee133 213417 diff --git a/extra/extra-1.3.0.jar b/extra/extra-1.3.0.jar deleted file mode 100644 index 405f5a3..000 --- a/extra/extra-1.3.0.jar +++ /dev/null @@ -1 +0,0 @@ -#$# git-fat 12ecf25e711ba0208caff3997758b1877c796358 188068 diff --git a/extra/extra-1.3.1.jar b/extra/extra-1.3.1.jar new file mode 100644 index 000..0585912 --- /dev/null +++ b/extra/extra-1.3.1.jar @@ -0,0 +1 @@ +#$# git-fat 9df087b3f34ad39095b158313552639f5a304f1f 217136 -- To view, visit https://gerrit.wikimedia.org/r/209541 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I40f4149fa41dc3048145de0da827c5b847d612c6 Gerrit-PatchSet: 1 Gerrit-Project: operations/software/elasticsearch/plugins Gerrit-Branch: master Gerrit-Owner: Manybubbles never...@wikimedia.org Gerrit-Reviewer: EBernhardson ebernhard...@wikimedia.org Gerrit-Reviewer: Jdouglas jdoug...@wikimedia.org Gerrit-Reviewer: Manybubbles never...@wikimedia.org Gerrit-Reviewer: Smalyshev smalys...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Allow semi-valid parsable JSON for graphs - change (mediawiki...Graph)
jenkins-bot has submitted this change and it was merged. Change subject: Allow semi-valid parsable JSON for graphs .. Allow semi-valid parsable JSON for graphs Change-Id: Id1c0f3e5c8fee4f326c622ffc246b586938507f7 --- M Graph.body.php 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Yurik: Looks good to me, approved jenkins-bot: Verified diff --git a/Graph.body.php b/Graph.body.php index 034e782..f47f3bf 100644 --- a/Graph.body.php +++ b/Graph.body.php @@ -90,7 +90,7 @@ global $wgGraphImgServiceUrl, $wgServerName, $wgGraphImgServiceAlways; $status = FormatJson::parse( $jsonText, FormatJson::TRY_FIXING | FormatJson::STRIP_COMMENTS ); - if ( !$status-isGood() ) { + if ( !$status-isOK() ) { return $status-getWikiText(); } -- To view, visit https://gerrit.wikimedia.org/r/210697 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Id1c0f3e5c8fee4f326c622ffc246b586938507f7 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Graph Gerrit-Branch: master Gerrit-Owner: Yurik yu...@wikimedia.org Gerrit-Reviewer: Yurik yu...@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] puppetmaster: Move system::role to the role class - change (operations/puppet)
Alexandros Kosiaris has submitted this change and it was merged. Change subject: puppetmaster: Move system::role to the role class .. puppetmaster: Move system::role to the role class For some reason it was still in the module class. Move it to the role classes and differentiate between frontend/backend Change-Id: Icf2905e24dd1a9996f1df1a24a501bf50b9a110b --- M manifests/role/puppetmaster.pp M modules/puppetmaster/manifests/init.pp 2 files changed, 8 insertions(+), 2 deletions(-) Approvals: jenkins-bot: Verified Dzahn: Looks good to me, approved diff --git a/manifests/role/puppetmaster.pp b/manifests/role/puppetmaster.pp index 610b572..010e150 100644 --- a/manifests/role/puppetmaster.pp +++ b/manifests/role/puppetmaster.pp @@ -14,6 +14,10 @@ include role::puppetmaster::config include passwords::puppet::database +system::role { 'puppetmaster': +description = 'Puppetmaster backend' +} + class { '::puppetmaster': allow_from = $role::puppetmaster::config::allow_from, server_type = 'frontend', @@ -42,6 +46,10 @@ include role::puppetmaster::config include passwords::puppet::database +system::role { 'puppetmaster': +description = 'Puppetmaster backend' +} + class { '::puppetmaster': allow_from = $role::puppetmaster::config::allow_from, server_type = 'backend', diff --git a/modules/puppetmaster/manifests/init.pp b/modules/puppetmaster/manifests/init.pp index 1391899..a0a3438 100644 --- a/modules/puppetmaster/manifests/init.pp +++ b/modules/puppetmaster/manifests/init.pp @@ -31,8 +31,6 @@ $config={}, ){ -system::role { 'puppetmaster': description = 'Puppetmaster' } - $gitdir = '/var/lib/git' $volatiledir = '/var/lib/puppet/volatile' -- To view, visit https://gerrit.wikimedia.org/r/209260 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Icf2905e24dd1a9996f1df1a24a501bf50b9a110b Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Alexandros Kosiaris akosia...@wikimedia.org Gerrit-Reviewer: Alexandros Kosiaris akosia...@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] update table script + refactoring - change (mediawiki...WikidataQualityConstraints)
Soeren.oldag has uploaded a new change for review. https://gerrit.wikimedia.org/r/210694 Change subject: update table script + refactoring .. update table script + refactoring Change-Id: I3ae96f7cdb47181a95c484adebff8c1dff9b01de --- M composer.json M includes/Constraint.php M includes/ConstraintCheck/Checker/CommonsLinkChecker.php M includes/ConstraintCheck/Checker/ConflictsWithChecker.php M includes/ConstraintCheck/Checker/DiffWithinRangeChecker.php M includes/ConstraintCheck/Checker/FormatChecker.php M includes/ConstraintCheck/Checker/InverseChecker.php M includes/ConstraintCheck/Checker/ItemChecker.php M includes/ConstraintCheck/Checker/MandatoryQualifiersChecker.php M includes/ConstraintCheck/Checker/OneOfChecker.php M includes/ConstraintCheck/Checker/QualifiersChecker.php M includes/ConstraintCheck/Checker/RangeChecker.php M includes/ConstraintCheck/Checker/TargetRequiredClaimChecker.php M includes/ConstraintCheck/Checker/TypeChecker.php M includes/ConstraintCheck/Checker/ValueTypeChecker.php M includes/ConstraintCheck/DelegatingConstraintChecker.php M includes/ConstraintRepository.php A maintenance/UpdateTable.php M phpunit.xml.dist M tests/phpunit/ConstraintRepositoryTest.php M tests/phpunit/ConstraintTest.php A tests/phpunit/Maintenance/UpdateTableTest.php A tests/phpunit/Maintenance/constraints.csv 23 files changed, 344 insertions(+), 67 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataQualityConstraints refs/changes/94/210694/1 diff --git a/composer.json b/composer.json index e2ce46f..b60a41a 100644 --- a/composer.json +++ b/composer.json @@ -34,7 +34,8 @@ psr-4: { WikidataQuality\\ConstraintReport\\: includes/, WikidataQuality\\ConstraintReport\\Specials\\: specials/, - WikidataQuality\\ConstraintReport\\Tests\\: tests/phpunit/ + WikidataQuality\\ConstraintReport\\Tests\\: tests/phpunit/, + WikidataQuality\\ConstraintReport\\Maintenance: maintenance }, classmap: [ WikibaseQualityConstraintsHooks.php diff --git a/includes/Constraint.php b/includes/Constraint.php index 4588351..8a4803d 100644 --- a/includes/Constraint.php +++ b/includes/Constraint.php @@ -9,30 +9,59 @@ class Constraint { + /** +* @var string +*/ + private $constraintClaimGuid; + + /** +* @var string +*/ private $constraintTypeQid; - private $constraintParameter; - public function __construct( $constraintEntry ) { - $this-constraintTypeQid = $constraintEntry-constraint_type_qid; + /** +* @var string +*/ + private $propertyId; - $parameterMap = ConstraintReportFactory::getDefaultInstance()-getConstraintParameterMap(); - $constraintParameter = array(); - $jsonParameter = json_decode( $constraintEntry-constraint_parameters ); - $helper = new ConstraintReportHelper(); - if( array_key_exists( $this-constraintTypeQid, $parameterMap ) ) { - foreach( $parameterMap[$this-constraintTypeQid] as $par ) { - $constraintParameter[$par] = $helper-stringToArray( $helper-getParameterFromJson( $jsonParameter, $par ) ); - } - } - $constraintParameter['exceptions'] = $helper-stringToArray( $helper-getParameterFromJson( $jsonParameter, 'known_exception' ) ); - $this-constraintParameter = $constraintParameter; + /** +* @var array +*/ + private $constraintParameters; + + public function __construct( $constraintClaimGuid, $propertyId, $constraintTypeQid, $constraintParameters) { + $this-constraintClaimGuid = $constraintClaimGuid; + $this-constraintTypeQid = $constraintTypeQid; + $this-propertyId = $propertyId; + $this-constraintParameters = $constraintParameters; } + /** +* @return string +*/ + public function getConstraintClaimGuid() { + return $this-constraintClaimGuid; + } + + /** +* @return string +*/ public function getConstraintTypeQid() { return $this-constraintTypeQid; } - public function getConstraintParameter() { - return $this-constraintParameter; + /** +* @return string +*/ + public function getPropertyId() { + return $this-propertyId; } + + /** +* @return array +*/ + public function getConstraintParameters() { + return $this-constraintParameters; + } + } \ No newline at end of file diff --git
[MediaWiki-commits] [Gerrit] LinkPreviewDialog: fix bug in EventLogging patch - change (apps...wikipedia)
Dbrant has submitted this change and it was merged. Change subject: LinkPreviewDialog: fix bug in EventLogging patch .. LinkPreviewDialog: fix bug in EventLogging patch Change-Id: I92fd15450c4c4f615bb4a2c74b1af09df90cbfa1 --- M wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java 1 file changed, 1 insertion(+), 0 deletions(-) Approvals: Dbrant: Looks good to me, approved diff --git a/wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java b/wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java index 7cd62dc..e30e01d 100755 --- a/wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java +++ b/wikipedia/src/main/java/org/wikipedia/page/linkpreview/LinkPreviewDialog.java @@ -176,6 +176,7 @@ @Override public void onDismiss(DialogInterface dialogInterface) { +super.onDismiss(dialogInterface); if (!navigateSuccess) { funnel.logCancel(); } -- To view, visit https://gerrit.wikimedia.org/r/210689 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I92fd15450c4c4f615bb4a2c74b1af09df90cbfa1 Gerrit-PatchSet: 1 Gerrit-Project: apps/android/wikipedia Gerrit-Branch: master Gerrit-Owner: Mholloway mhollo...@wikimedia.org Gerrit-Reviewer: BearND bsitzm...@wikimedia.org Gerrit-Reviewer: Brion VIBBER br...@wikimedia.org Gerrit-Reviewer: Dbrant dbr...@wikimedia.org Gerrit-Reviewer: Niedzielski sniedziel...@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] puppetmaster: Remove the package installed site - change (operations/puppet)
Alexandros Kosiaris has submitted this change and it was merged. Change subject: puppetmaster: Remove the package installed site .. puppetmaster: Remove the package installed site puppetmaster-passenger installs by default a puppetmaster site we do not want enabled. Remove it. Also populate the default after puppetmaster-passenger has been populated Change-Id: I37a635beaa208f3bf6a37099049a3c790a42da63 --- M modules/puppetmaster/manifests/passenger.pp 1 file changed, 12 insertions(+), 5 deletions(-) Approvals: Alexandros Kosiaris: Looks good to me, approved jenkins-bot: Verified diff --git a/modules/puppetmaster/manifests/passenger.pp b/modules/puppetmaster/manifests/passenger.pp index 790dd21..347e105 100644 --- a/modules/puppetmaster/manifests/passenger.pp +++ b/modules/puppetmaster/manifests/passenger.pp @@ -35,6 +35,12 @@ content = template('puppetmaster/ports.conf.erb'), } +# Unfortunately priority does not allows to use apache::site for this +# Purging the package installed puppetmaster site +file { '/etc/apache2/site-enabled/puppetmaster': +ensure = absent, +} + # Since we are running puppet via passenger, we need to ensure # the puppetmaster service is stopped, since they use the same port # and will conflict when both started. @@ -46,11 +52,12 @@ } # We also make sure puppet master can not be manually started file { '/etc/default/puppetmaster': -ensure = present, -owner = 'root', -group = 'root', -mode = '0444', -source = 'puppet:///modules/puppetmaster/default', +ensure = present, +owner = 'root', +group = 'root', +mode= '0444', +source = 'puppet:///modules/puppetmaster/default', +require = Package['puppetmaster-passenger'], } } -- To view, visit https://gerrit.wikimedia.org/r/209259 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I37a635beaa208f3bf6a37099049a3c790a42da63 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Alexandros Kosiaris akosia...@wikimedia.org Gerrit-Reviewer: Alexandros Kosiaris akosia...@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] Improve constructor parameter naming and order in LangLinkHa... - change (mediawiki...Wikibase)
Aude has uploaded a new change for review. https://gerrit.wikimedia.org/r/210699 Change subject: Improve constructor parameter naming and order in LangLinkHandler .. Improve constructor parameter naming and order in LangLinkHandler most importantly, it takes a SiteStore object and not sites. Change-Id: I4188f63af6601e3aeaaedd6590b06f8f17bcd176 --- M client/includes/LangLinkHandler.php M client/includes/WikibaseClient.php M client/tests/phpunit/includes/Hooks/ParserAfterParseHookHandlerTest.php M client/tests/phpunit/includes/LangLinkHandlerTest.php 4 files changed, 13 insertions(+), 13 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/99/210699/1 diff --git a/client/includes/LangLinkHandler.php b/client/includes/LangLinkHandler.php index 32505c8..549bb06 100644 --- a/client/includes/LangLinkHandler.php +++ b/client/includes/LangLinkHandler.php @@ -39,11 +39,6 @@ private $badgeDisplay; /** -* @var string -*/ - private $siteId; - - /** * @var NamespaceChecker */ private $namespaceChecker; @@ -66,6 +61,11 @@ /** * @var string */ + private $siteId; + + /** +* @var string +*/ private $siteGroup; /** @@ -76,30 +76,30 @@ /** * @param OtherProjectsSidebarGeneratorFactory $otherProjectsSidebarGeneratorFactory * @param LanguageLinkBadgeDisplay $badgeDisplay -* @param string $siteId The global site ID for the local wiki * @param NamespaceChecker $namespaceChecker determines which namespaces wikibase is enabled on * @param SiteLinkLookup $siteLinkLookup A site link lookup service * @param EntityLookup $entityLookup An entity lookup service * @param SiteStore $sites +* @param string $siteId The global site ID for the local wiki * @param string $siteGroup The ID of the site group to use for showing language links. */ public function __construct( OtherProjectsSidebarGeneratorFactory $otherProjectsSidebarGeneratorFactory, LanguageLinkBadgeDisplay $badgeDisplay, - $siteId, NamespaceChecker $namespaceChecker, SiteLinkLookup $siteLinkLookup, EntityLookup $entityLookup, - SiteStore $sites, + SiteStore $siteStore, + $siteId, $siteGroup ) { $this-otherProjectsSidebarGeneratorFactory = $otherProjectsSidebarGeneratorFactory; $this-badgeDisplay = $badgeDisplay; - $this-siteId = $siteId; $this-namespaceChecker = $namespaceChecker; $this-siteLinkLookup = $siteLinkLookup; $this-entityLookup = $entityLookup; - $this-siteStore = $sites; + $this-siteStore = $siteStore; + $this-siteId = $siteId; $this-siteGroup = $siteGroup; } diff --git a/client/includes/WikibaseClient.php b/client/includes/WikibaseClient.php index 551e6b2..f2cf9a9 100644 --- a/client/includes/WikibaseClient.php +++ b/client/includes/WikibaseClient.php @@ -540,11 +540,11 @@ $this-langLinkHandler = new LangLinkHandler( $this-getOtherProjectsSidebarGeneratorFactory(), $this-getLanguageLinkBadgeDisplay(), - $this-settings-getSetting( 'siteGlobalID' ), $this-getNamespaceChecker(), $this-getStore()-getSiteLinkLookup(), $this-getStore()-getEntityLookup(), $this-getSiteStore(), + $this-settings-getSetting( 'siteGlobalID' ), $this-getLangLinkSiteGroup() ); } diff --git a/client/tests/phpunit/includes/Hooks/ParserAfterParseHookHandlerTest.php b/client/tests/phpunit/includes/Hooks/ParserAfterParseHookHandlerTest.php index 2a30e26..14ad1d6 100644 --- a/client/tests/phpunit/includes/Hooks/ParserAfterParseHookHandlerTest.php +++ b/client/tests/phpunit/includes/Hooks/ParserAfterParseHookHandlerTest.php @@ -173,11 +173,11 @@ $langLinkHandler = new LangLinkHandler( $this-getOtherProjectsSidebarGeneratorFactory( $settings, $mockRepo ), $badgeDisplay, - $settings-getSetting( 'siteGlobalID' ), $namespaceChecker, $mockRepo, $mockRepo, $this-getSiteStore(), + $settings-getSetting( 'siteGlobalID' ), $settings-getSetting(
[MediaWiki-commits] [Gerrit] Allow customizing Flow AJAX timeout - change (mediawiki...Flow)
Mattflaschen has uploaded a new change for review. https://gerrit.wikimedia.org/r/210749 Change subject: Allow customizing Flow AJAX timeout .. Allow customizing Flow AJAX timeout Change-Id: I8264f2b2e5558b2291130407546fc8b1a753e593 --- M Flow.php M Hooks.php M modules/engine/misc/flow-api.js 3 files changed, 16 insertions(+), 6 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Flow refs/changes/49/210749/1 diff --git a/Flow.php b/Flow.php index e58ce32..717fe7a 100644 --- a/Flow.php +++ b/Flow.php @@ -377,6 +377,9 @@ $wgFlowAbuseFilterEmergencyDisableCount = 50; $wgFlowAbuseFilterEmergencyDisableAge = 86400; // One day. +// Timeout for Flow's AJAX requests (only affects ones that go through flow-api.js), in seconds +$wgFlowAjaxTimeout = 30; + // Actions that must pass through to MediaWiki on Flow-enabled pages $wgFlowCoreActionWhitelist = array( 'info', 'protect', 'unprotect', 'unwatch', 'watch', 'history', 'wikilove', 'move', 'delete' ); diff --git a/Hooks.php b/Hooks.php index 83e72e8..245bca3 100644 --- a/Hooks.php +++ b/Hooks.php @@ -588,13 +588,14 @@ return true; } - // Static variables that do not vary by request + // Static variables that do not vary by request; delivered through startup module public static function onResourceLoaderGetConfigVars( $vars ) { - global $wgFlowEditorList; + global $wgFlowEditorList, $wgFlowAjaxTimeout; $vars['wgFlowEditorList'] = $wgFlowEditorList; $vars['wgFlowMaxTopicLength'] = Flow\Model\PostRevision::MAX_TOPIC_LENGTH; $vars['wgFlowMentionTemplate'] = wfMessage( 'flow-ve-mention-template' )-inContentLanguage()-plain(); + $vars['wgFlowAjaxTimeout'] = $wgFlowAjaxTimeout; return true; } diff --git a/modules/engine/misc/flow-api.js b/modules/engine/misc/flow-api.js index d87ac01..1256d80 100644 --- a/modules/engine/misc/flow-api.js +++ b/modules/engine/misc/flow-api.js @@ -40,18 +40,24 @@ */ function flowApiCall( params, method ) { var mwApi, tokenType, - $deferred = $.Deferred(); + $deferred = $.Deferred(), + ajaxTimeoutSec = mw.config.get( 'wgFlowAjaxTimeout' ), + apiConstructorParams = { ajax: {} }; + + if ( ajaxTimeoutSec !== null ajaxTimeoutSec 0 ) { + apiConstructorParams.ajax.timeout = ajaxTimeoutSec * 1000; + } // IE8 caches POST under some conditions, prevent that here. // IE8 is most likely the only browser we support that doesn't // have addEventListener, and anything else that gets caught // up isn't that bad off. if ( !document.addEventListener ) { - mwApi = new mw.Api( { ajax: { cache: false } } ); - } else { - mwApi = new mw.Api(); + apiConstructorParams.ajax.cache = false; } + mwApi = new mw.Api( apiConstructorParams ); + params = params || {}; // Server is using page instead of title // @todo this should not be necessary -- To view, visit https://gerrit.wikimedia.org/r/210749 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8264f2b2e5558b2291130407546fc8b1a753e593 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Flow Gerrit-Branch: master Gerrit-Owner: Mattflaschen mflasc...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Allow customizing Flow AJAX timeout - change (mediawiki...Flow)
jenkins-bot has submitted this change and it was merged. Change subject: Allow customizing Flow AJAX timeout .. Allow customizing Flow AJAX timeout Change-Id: I8264f2b2e5558b2291130407546fc8b1a753e593 --- M Flow.php M Hooks.php M modules/engine/misc/flow-api.js 3 files changed, 16 insertions(+), 6 deletions(-) Approvals: Sbisson: Looks good to me, approved jenkins-bot: Verified diff --git a/Flow.php b/Flow.php index e58ce32..717fe7a 100644 --- a/Flow.php +++ b/Flow.php @@ -377,6 +377,9 @@ $wgFlowAbuseFilterEmergencyDisableCount = 50; $wgFlowAbuseFilterEmergencyDisableAge = 86400; // One day. +// Timeout for Flow's AJAX requests (only affects ones that go through flow-api.js), in seconds +$wgFlowAjaxTimeout = 30; + // Actions that must pass through to MediaWiki on Flow-enabled pages $wgFlowCoreActionWhitelist = array( 'info', 'protect', 'unprotect', 'unwatch', 'watch', 'history', 'wikilove', 'move', 'delete' ); diff --git a/Hooks.php b/Hooks.php index 83e72e8..245bca3 100644 --- a/Hooks.php +++ b/Hooks.php @@ -588,13 +588,14 @@ return true; } - // Static variables that do not vary by request + // Static variables that do not vary by request; delivered through startup module public static function onResourceLoaderGetConfigVars( $vars ) { - global $wgFlowEditorList; + global $wgFlowEditorList, $wgFlowAjaxTimeout; $vars['wgFlowEditorList'] = $wgFlowEditorList; $vars['wgFlowMaxTopicLength'] = Flow\Model\PostRevision::MAX_TOPIC_LENGTH; $vars['wgFlowMentionTemplate'] = wfMessage( 'flow-ve-mention-template' )-inContentLanguage()-plain(); + $vars['wgFlowAjaxTimeout'] = $wgFlowAjaxTimeout; return true; } diff --git a/modules/engine/misc/flow-api.js b/modules/engine/misc/flow-api.js index d87ac01..1256d80 100644 --- a/modules/engine/misc/flow-api.js +++ b/modules/engine/misc/flow-api.js @@ -40,18 +40,24 @@ */ function flowApiCall( params, method ) { var mwApi, tokenType, - $deferred = $.Deferred(); + $deferred = $.Deferred(), + ajaxTimeoutSec = mw.config.get( 'wgFlowAjaxTimeout' ), + apiConstructorParams = { ajax: {} }; + + if ( ajaxTimeoutSec !== null ajaxTimeoutSec 0 ) { + apiConstructorParams.ajax.timeout = ajaxTimeoutSec * 1000; + } // IE8 caches POST under some conditions, prevent that here. // IE8 is most likely the only browser we support that doesn't // have addEventListener, and anything else that gets caught // up isn't that bad off. if ( !document.addEventListener ) { - mwApi = new mw.Api( { ajax: { cache: false } } ); - } else { - mwApi = new mw.Api(); + apiConstructorParams.ajax.cache = false; } + mwApi = new mw.Api( apiConstructorParams ); + params = params || {}; // Server is using page instead of title // @todo this should not be necessary -- To view, visit https://gerrit.wikimedia.org/r/210749 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I8264f2b2e5558b2291130407546fc8b1a753e593 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Flow Gerrit-Branch: master Gerrit-Owner: Mattflaschen mflasc...@wikimedia.org Gerrit-Reviewer: Sbisson sbis...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add 1.26wmf6 symlinks - change (operations/mediawiki-config)
jenkins-bot has submitted this change and it was merged. Change subject: Add 1.26wmf6 symlinks .. Add 1.26wmf6 symlinks Change-Id: I4117e6b32d068ce65ebde7598d9948f1c475053c --- A docroot/bits/static/1.26wmf6/extensions A docroot/bits/static/1.26wmf6/resources A docroot/bits/static/1.26wmf6/skins A w/static/1.26wmf6/extensions A w/static/1.26wmf6/resources A w/static/1.26wmf6/skins M w/static/current/extensions M w/static/current/resources M w/static/current/skins 9 files changed, 9 insertions(+), 3 deletions(-) Approvals: 20after4: Looks good to me, approved jenkins-bot: Verified diff --git a/docroot/bits/static/1.26wmf6/extensions b/docroot/bits/static/1.26wmf6/extensions new file mode 12 index 000..75d6fd1 --- /dev/null +++ b/docroot/bits/static/1.26wmf6/extensions @@ -0,0 +1 @@ +/srv/mediawiki/php-1.26wmf6/extensions \ No newline at end of file diff --git a/docroot/bits/static/1.26wmf6/resources b/docroot/bits/static/1.26wmf6/resources new file mode 12 index 000..237dbad --- /dev/null +++ b/docroot/bits/static/1.26wmf6/resources @@ -0,0 +1 @@ +/srv/mediawiki/php-1.26wmf6/resources \ No newline at end of file diff --git a/docroot/bits/static/1.26wmf6/skins b/docroot/bits/static/1.26wmf6/skins new file mode 12 index 000..8fa4ceb --- /dev/null +++ b/docroot/bits/static/1.26wmf6/skins @@ -0,0 +1 @@ +/srv/mediawiki/php-1.26wmf6/skins/ \ No newline at end of file diff --git a/w/static/1.26wmf6/extensions b/w/static/1.26wmf6/extensions new file mode 12 index 000..75d6fd1 --- /dev/null +++ b/w/static/1.26wmf6/extensions @@ -0,0 +1 @@ +/srv/mediawiki/php-1.26wmf6/extensions \ No newline at end of file diff --git a/w/static/1.26wmf6/resources b/w/static/1.26wmf6/resources new file mode 12 index 000..237dbad --- /dev/null +++ b/w/static/1.26wmf6/resources @@ -0,0 +1 @@ +/srv/mediawiki/php-1.26wmf6/resources \ No newline at end of file diff --git a/w/static/1.26wmf6/skins b/w/static/1.26wmf6/skins new file mode 12 index 000..2577508 --- /dev/null +++ b/w/static/1.26wmf6/skins @@ -0,0 +1 @@ +/srv/mediawiki/php-1.26wmf6/skins \ No newline at end of file diff --git a/w/static/current/extensions b/w/static/current/extensions index 26312cc..91ff710 12 --- a/w/static/current/extensions +++ b/w/static/current/extensions @@ -1 +1 @@ -/srv/mediawiki/php-1.26wmf4/extensions \ No newline at end of file +/srv/mediawiki/php-1.26wmf5/extensions \ No newline at end of file diff --git a/w/static/current/resources b/w/static/current/resources index 41d4d72..781c8c3 12 --- a/w/static/current/resources +++ b/w/static/current/resources @@ -1 +1 @@ -/srv/mediawiki/php-1.26wmf4/resources \ No newline at end of file +/srv/mediawiki/php-1.26wmf5/resources \ No newline at end of file diff --git a/w/static/current/skins b/w/static/current/skins index d72559d..bc39c02 12 --- a/w/static/current/skins +++ b/w/static/current/skins @@ -1 +1 @@ -/srv/mediawiki/php-1.26wmf4/skins \ No newline at end of file +/srv/mediawiki/php-1.26wmf5/skins \ No newline at end of file -- To view, visit https://gerrit.wikimedia.org/r/210756 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I4117e6b32d068ce65ebde7598d9948f1c475053c Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: 20after4 mmod...@wikimedia.org Gerrit-Reviewer: 20after4 mmod...@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] Remove 1.25wmf24 symlinks - change (operations/mediawiki-config)
jenkins-bot has submitted this change and it was merged. Change subject: Remove 1.25wmf24 symlinks .. Remove 1.25wmf24 symlinks Change-Id: I1879f2c619ed6ffb06a2a844414d52c3621131d6 --- D docroot/bits/static-1.25wmf24/extensions D docroot/bits/static-1.25wmf24/resources D docroot/bits/static-1.25wmf24/skins D w/static-1.25wmf24/extensions D w/static-1.25wmf24/resources D w/static-1.25wmf24/skins 6 files changed, 0 insertions(+), 6 deletions(-) Approvals: 20after4: Looks good to me, approved jenkins-bot: Verified diff --git a/docroot/bits/static-1.25wmf24/extensions b/docroot/bits/static-1.25wmf24/extensions deleted file mode 12 index bde9059..000 --- a/docroot/bits/static-1.25wmf24/extensions +++ /dev/null @@ -1 +0,0 @@ -/srv/mediawiki/php-1.25wmf24/extensions \ No newline at end of file diff --git a/docroot/bits/static-1.25wmf24/resources b/docroot/bits/static-1.25wmf24/resources deleted file mode 12 index 1aa8bb2..000 --- a/docroot/bits/static-1.25wmf24/resources +++ /dev/null @@ -1 +0,0 @@ -/srv/mediawiki/php-1.25wmf24/resources \ No newline at end of file diff --git a/docroot/bits/static-1.25wmf24/skins b/docroot/bits/static-1.25wmf24/skins deleted file mode 12 index 35c4f52..000 --- a/docroot/bits/static-1.25wmf24/skins +++ /dev/null @@ -1 +0,0 @@ -/srv/mediawiki/php-1.25wmf24/skins/ \ No newline at end of file diff --git a/w/static-1.25wmf24/extensions b/w/static-1.25wmf24/extensions deleted file mode 12 index bde9059..000 --- a/w/static-1.25wmf24/extensions +++ /dev/null @@ -1 +0,0 @@ -/srv/mediawiki/php-1.25wmf24/extensions \ No newline at end of file diff --git a/w/static-1.25wmf24/resources b/w/static-1.25wmf24/resources deleted file mode 12 index 1aa8bb2..000 --- a/w/static-1.25wmf24/resources +++ /dev/null @@ -1 +0,0 @@ -/srv/mediawiki/php-1.25wmf24/resources \ No newline at end of file diff --git a/w/static-1.25wmf24/skins b/w/static-1.25wmf24/skins deleted file mode 12 index 8257cce..000 --- a/w/static-1.25wmf24/skins +++ /dev/null @@ -1 +0,0 @@ -/srv/mediawiki/php-1.25wmf24/skins \ No newline at end of file -- To view, visit https://gerrit.wikimedia.org/r/210755 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I1879f2c619ed6ffb06a2a844414d52c3621131d6 Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: 20after4 mmod...@wikimedia.org Gerrit-Reviewer: 20after4 mmod...@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] registration: Fix having multiple callbacks for a single hook - change (mediawiki/core)
Legoktm has uploaded a new change for review. https://gerrit.wikimedia.org/r/210761 Change subject: registration: Fix having multiple callbacks for a single hook .. registration: Fix having multiple callbacks for a single hook Bug: T98975 Change-Id: I40ff36090d18344fabdb018519209671b7883fa1 --- M includes/registration/ExtensionProcessor.php M tests/phpunit/includes/registration/ExtensionProcessorTest.php 2 files changed, 24 insertions(+), 2 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/61/210761/1 diff --git a/includes/registration/ExtensionProcessor.php b/includes/registration/ExtensionProcessor.php index 4b9a754..23a2993 100644 --- a/includes/registration/ExtensionProcessor.php +++ b/includes/registration/ExtensionProcessor.php @@ -152,8 +152,10 @@ protected function extractHooks( array $info ) { if ( isset( $info['Hooks'] ) ) { - foreach ( $info['Hooks'] as $name = $callable ) { - $this-globals['wgHooks'][$name][] = $callable; + foreach ( $info['Hooks'] as $name = $value ) { + foreach ( (array)$value as $callback ) { + $this-globals['wgHooks'][$name][] = $callback; + } } $this-processed[] = 'Hooks'; } diff --git a/tests/phpunit/includes/registration/ExtensionProcessorTest.php b/tests/phpunit/includes/registration/ExtensionProcessorTest.php index b95316c..d47ffa9 100644 --- a/tests/phpunit/includes/registration/ExtensionProcessorTest.php +++ b/tests/phpunit/includes/registration/ExtensionProcessorTest.php @@ -36,6 +36,10 @@ } public static function provideRegisterHooks() { + // Format: + // Current $wgHooks + // Content in extension.json + // Expected value of $wgHooks return array( // No hooks array( @@ -64,6 +68,22 @@ 'FooBaz' = array( 'FooBazCallback' ), ), ), + // Callbacks for FooBaz wrapped in an array + array( + array(), + array( 'Hooks' = array( 'FooBaz' = array( 'Callback1' ) ) ) + self::$default, + array( + 'FooBaz' = array( 'Callback1' ), + ), + ), + // Multiple callbacks for FooBaz hook + array( + array(), + array( 'Hooks' = array( 'FooBaz' = array( 'Callback1', 'Callback2' ) ) ) + self::$default, + array( + 'FooBaz' = array( 'Callback1', 'Callback2' ), + ), + ), ); } -- To view, visit https://gerrit.wikimedia.org/r/210761 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I40ff36090d18344fabdb018519209671b7883fa1 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Legoktm legoktm.wikipe...@gmail.com ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] enable frontend caching for graphoid T98803 - change (operations/puppet)
BBlack has submitted this change and it was merged. Change subject: enable frontend caching for graphoid T98803 .. enable frontend caching for graphoid T98803 Change-Id: I9ca9a67c488a0ae44adb6155a5a6da78994716a2 --- M templates/varnish/parsoid-frontend.inc.vcl.erb 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: BBlack: Looks good to me, approved jenkins-bot: Verified diff --git a/templates/varnish/parsoid-frontend.inc.vcl.erb b/templates/varnish/parsoid-frontend.inc.vcl.erb index a01bbcd..f442754 100644 --- a/templates/varnish/parsoid-frontend.inc.vcl.erb +++ b/templates/varnish/parsoid-frontend.inc.vcl.erb @@ -11,7 +11,7 @@ } if (req.http.Host ~ graphoid ) { set req.backend = graphoid_backend; - return (pass); + return (lookup); } if (req.http.Host ~ restbase || req.http.Host ~ rest\. ) { set req.backend = restbase_backend; -- To view, visit https://gerrit.wikimedia.org/r/210754 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I9ca9a67c488a0ae44adb6155a5a6da78994716a2 Gerrit-PatchSet: 2 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: BBlack bbl...@wikimedia.org Gerrit-Reviewer: BBlack bbl...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Updating to latest masters - change (mediawiki...ocg-collection)
Cscott has submitted this change and it was merged. Change subject: Updating to latest masters .. Updating to latest masters Deployed new bunder (24365a9154a86c6870e89b2256ee5bc1d88f5a49): * Add --php-api option for local debugging. * Fix file revision lookup failures. * T93292: Allow bundler to fetch parsed articles from RESTBase. * Switch from es6-shim to core-js; update prfun and jshint. Deployed new latexer (efae1a449bfaf2fa925f1968101fafedf87edb48): * Switch from es6-shim to core-js; update prfun and jshint. Deployed new service (efa690d717ae257879a4dfbdd7ecc9227b586bed): * Remove deprecated `download` command. * Add script to allow date-based cache cleaning. * Update docs and config options to allow use of RESTBase. * Switch from es6-shim to core-js; update prfun and jshint. Deployed new texter (e325556133e9ece9af20631d91635574a0b6f8d0): * Switch from es6-shim to core-js; update prfun and jshint. Change-Id: Ic61cd50bad1ad52da54298e4f89c7ba6e1e26335 --- M mw-ocg-bundler M mw-ocg-latexer M mw-ocg-service M mw-ocg-texter 4 files changed, 0 insertions(+), 0 deletions(-) Approvals: Cscott: Verified; Looks good to me, approved diff --git a/mw-ocg-bundler b/mw-ocg-bundler index 8565c79..24365a9 16 --- a/mw-ocg-bundler +++ b/mw-ocg-bundler -Subproject commit 8565c79549e107ffa10fa817d00348b85ba9dbb9 +Subproject commit 24365a9154a86c6870e89b2256ee5bc1d88f5a49 diff --git a/mw-ocg-latexer b/mw-ocg-latexer index 39534c0..efae1a4 16 --- a/mw-ocg-latexer +++ b/mw-ocg-latexer -Subproject commit 39534c0e9f0a48b6c3565fe8b50f437103e0d218 +Subproject commit efae1a449bfaf2fa925f1968101fafedf87edb48 diff --git a/mw-ocg-service b/mw-ocg-service index f6f3788..efa690d 16 --- a/mw-ocg-service +++ b/mw-ocg-service -Subproject commit f6f3788da146e92dce8dcb11a14479c8b117f2be +Subproject commit efa690d717ae257879a4dfbdd7ecc9227b586bed diff --git a/mw-ocg-texter b/mw-ocg-texter index 5d189e4..e325556 16 --- a/mw-ocg-texter +++ b/mw-ocg-texter -Subproject commit 5d189e4a351556390d30cbdac920e3d788264a24 +Subproject commit e325556133e9ece9af20631d91635574a0b6f8d0 -- To view, visit https://gerrit.wikimedia.org/r/210762 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ic61cd50bad1ad52da54298e4f89c7ba6e1e26335 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/services/ocg-collection Gerrit-Branch: master Gerrit-Owner: Cscott canan...@wikimedia.org Gerrit-Reviewer: Cscott canan...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Update code to unify the package.json - change (mediawiki...ocg-collection)
Cscott has submitted this change and it was merged. Change subject: Update code to unify the package.json .. Update code to unify the package.json Use core-js and the latest prfun, and a specific version of semver. Change-Id: I6a40d7b1e3f31173416f3ea0953b8ca17202c885 --- M Makefile M package.json M unify-package-json.js 3 files changed, 24 insertions(+), 13 deletions(-) Approvals: Cscott: Verified; Looks good to me, approved diff --git a/Makefile b/Makefile index 2b05f49..ea77c09 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ core: export LINK=g++ rm -f ./package.json - npm install prfun semver + npm install core-js@0.9.x prfun@2.1.x semver@4.1.x ./unify-package-json.js npm install npm update diff --git a/package.json b/package.json index fd1c938..4ca28e7 100644 --- a/package.json +++ b/package.json @@ -7,9 +7,9 @@ }, dependencies: { commander: ~2.5.0, +core-js: ~0.9.1, domino: ~1.0.17, -es6-shim: ~0.20.2, -prfun: ~1.0.1, +prfun: ~2.1.1, readable-stream: ~1.0.0, request: ~2.47.0, rimraf: ~2.2.2, @@ -34,9 +34,9 @@ gelf-stream: ~0.2.4 }, devDependencies: { -jshint: ~2.5.0, +jshint: ~2.6.3, mocha: ~2.0.1, -request: ~2.47.0, -mw-ocg-bundler: wikimedia/mediawiki-extensions-Collection-OfflineContentGenerator-bundler#master +npm-travis: ~1.0.0, +request: ~2.47.0 } } \ No newline at end of file diff --git a/unify-package-json.js b/unify-package-json.js index 74254f2..479f818 100755 --- a/unify-package-json.js +++ b/unify-package-json.js @@ -11,17 +11,26 @@ * library (since we want to use fancy non-standard Promise features). */ +var haveAllPackages = true; +['core-js','prfun','semver'].forEach(function(pkg) { + try { + require(pkg); + } catch (err) { + console.err( The '+pkg+' library could not be loaded. Please `npm install +pkg+` ); + haveAllPackages = false; + } +}); +if (!haveAllPackages) { + process.exit(1); +} + +require('core-js'); // for Map/Set var child_process = require( 'child_process' ), semver = require( 'semver' ), fs = require( 'fs' ), path = require( 'path' ), - util = require( 'util' ); - -try { - require('prfun'); -} catch ( err ) { - console.err( The 'prfun' library could not be loaded. Please `npm install prfun`) -} + util = require( 'util' ), + Promise = require( 'prfun' ); function findPackageJson() { var readdir = Promise.promisify(fs.readdir, false, fs); @@ -94,6 +103,8 @@ optdeps = iterate( 'optionalDependencies', packageObjs ); console.info( 'Unifying unified development dependencies' ); glodevdeps = iterate( 'devDependencies', packageObjs ); + // Hack around the 'mw-ocg-bundler' dev dependency; don't make it global + delete glodevdeps['mw-ocg-bundler']; return { 'dependencies': glodeps, -- To view, visit https://gerrit.wikimedia.org/r/210791 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I6a40d7b1e3f31173416f3ea0953b8ca17202c885 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/services/ocg-collection Gerrit-Branch: wmf-deploy Gerrit-Owner: Cscott canan...@wikimedia.org Gerrit-Reviewer: Cscott canan...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Added DjVU class and djvutext.py in core - change (pywikibot/core)
Mpaa has uploaded a new change for review. https://gerrit.wikimedia.org/r/210808 Change subject: Added DjVU class and djvutext.py in core .. Added DjVU class and djvutext.py in core Added: - DjVu class: wrapper to access djvu file text and properties - added tests for DjVu class - ported djvutext.py functionality from compat (basing it on Bot class) Change-Id: I88ba445fd49046430dfcb78d5b8a0ab46e2343fb --- A djvusub.py A pywikibot/tools/djvu.py A scripts/djvutext.py A tests/data/djvu/myfile.djvu A tests/data/djvu/myfile_wo_text.djvu A tests/data/myfile_wo_text.djvu A tests/djvu_tests.py 7 files changed, 391 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core refs/changes/08/210808/1 diff --git a/djvusub.py b/djvusub.py new file mode 100644 index 000..1f39af2 --- /dev/null +++ b/djvusub.py @@ -0,0 +1,53 @@ +#!/usr/bin/python +# -*- coding: utf-8 -*- + +import os +import sys +import codecs +import subprocess +import pywikibot + +filename = 'myfile.djvu' + +def number_of_images(): +dp = subprocess.Popen(['djvused', '-e', n, filename], stdout=subprocess.PIPE, stderr=subprocess.PIPE) +(stdoutdata, stderrdata) = dp.communicate() +if dp.returncode != 0: +pywikibot.error(stderrdata) +count = int(stdoutdata) +pywikibot.output(page count = %d % count) +return count + +def has_text(): +#cmd = udjvudump \%s\ \%s\.out % (self.djvu, self.djvu) +dp = subprocess.Popen(['djvudump', filename], stdout=subprocess.PIPE, stderr=subprocess.PIPE) +(stdoutdata, stderrdata) = dp.communicate() +if dp.returncode != 0: +pywikibot.error(stderrdata) +txt = dp.stdout.read() +txt = txt.decode('utf-8') +pywikibot.output(txt) +dp.stdout.close() +return 'TXTz' in txt + +def get_page(): +dp = subprocess.Popen(['djvutxt', '--page=1', filename], stdout=subprocess.PIPE, stderr=subprocess.PIPE) +(stdoutdata, stderrdata) = dp.communicate() +if dp.returncode != 0: +pywikibot.error(stderrdata) +#import pdb; pdb.set_trace() +txt = dp.stdout.read() +txt = txt.decode('utf-8') +pywikibot.output(txt) +dp.stdout.close() +#cmd = udjvutxt --page=%d \%s\ \%s.out\ % (pageno, self.djvu, self.djvu) +#os.system(cmd.encode(sys.stdout.encoding)) +#f = codecs.open(u%s.out % self.djvu, 'r', +#config.textfile_encoding, 'replace') +#djvu_text = f.read() +#f.close() +return txt + +print(number_of_images()) +print(has_text()) +x = get_page() diff --git a/pywikibot/tools/djvu.py b/pywikibot/tools/djvu.py new file mode 100644 index 000..b7145bc --- /dev/null +++ b/pywikibot/tools/djvu.py @@ -0,0 +1,95 @@ +#!/usr/bin/python +# -*- coding: utf-8 -*- +Wrapper around djvulibre to access djvu files properties and content. +# +# (C) Pywikibot team, 2015 +# +# Distributed under the terms of the MIT license. +# +from __future__ import unicode_literals + +__version__ = '$Id$' + +import os.path +import subprocess + +import pywikibot + + +class DjVu(object): + +Wrapper around djvulibre to access djvu files properties and content. + +Perform file existance checks. + +Control characters in djvu text-layer are converted for convenience +(see # http://djvu.sourceforge.net/doc/man/djvused.html for control chars +details). + + + +def __init__(self, file_djvu): + +Constructor. + +@param djvu: filename (including path) to djvu file +@type djvu: string/unicode + +try: +file_djvu = os.path.expanduser(file_djvu) +except AttributeError: +raise AttributeError('No djvu filename defined.') + +try: +with open(file_djvu): +self.file_djvu = file_djvu +except IOError: +# Does not exist OR no read permissions. +raise + +def number_of_images(self): +Return the (cached) number of images in the djvu file. +if not hasattr(self, '_n'): +dp = subprocess.Popen(['djvused', '-e', n, self.file_djvu], + stdout=subprocess.PIPE, stderr=subprocess.PIPE) +(stdoutdata, stderrdata) = dp.communicate() +if dp.returncode != 0: +pywikibot.error('djvulibre library error!\n%s' % stderrdata) +self._n = int(stdoutdata) +return self._n + +def has_text(self): +Test if the djvu file has a text-layer. +if not hasattr(self, '_has_text'): +dp = subprocess.Popen(['djvudump', self.file_djvu], + stdout=subprocess.PIPE, stderr=subprocess.PIPE) +(stdoutdata, stderrdata) = dp.communicate() +#import pdb; pdb.set_trace() +if dp.returncode != 0: +pywikibot.error('djvulibre library error!\n%s' % stderrdata) +txt =
[MediaWiki-commits] [Gerrit] Version 2.7: various JS fixes and stuff - change (mediawiki...VoteNY)
Jack Phoenix has uploaded a new change for review. https://gerrit.wikimedia.org/r/210813 Change subject: Version 2.7: various JS fixes and stuff .. Version 2.7: various JS fixes and stuff * CSS and JS are now separate RL modules * JS rewritten to use jQuery instead of sajax * Fixed a scoping bug from the previous patchset * Fixed other scoping bugs so that you can revoke your vote w/o reloading the page, no matter what * JS module is not loaded for users w/o the 'voteny' user right * JS is not loaded on Special:TopRatings anymore, it was only loaded there ever back when this extension had inline JS to prevent over 9000 JS errors, plus it wouldn't have worked because wgArticleId is 0 for special pages * Special page alias file added Change-Id: I6668238a0ab6272b0a7b3b167832ebb2d3abe2c2 --- M SpecialTopRatings.php M Vote.js M VoteHooks.php A VoteNY.alias.php M VoteNY.php 5 files changed, 127 insertions(+), 65 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/VoteNY refs/changes/13/210813/1 diff --git a/SpecialTopRatings.php b/SpecialTopRatings.php index 86e1850..202e3bc 100644 --- a/SpecialTopRatings.php +++ b/SpecialTopRatings.php @@ -30,6 +30,9 @@ // Set the page title, robot policies, etc. $this-setHeaders(); + $out = $this-getOutput(); + $user = $this-getUser(); + $categoryName = $namespace = ''; // Parse the parameters passed to the special page @@ -47,9 +50,13 @@ $limit = 50; } - // Add JS (and CSS) -- needed so that users can vote on this page and - // so that their browsers' consoles won't be filled with JS errors ;-) - $this-getOutput()-addModules( 'ext.voteNY' ); + // Add CSS + $out-addModuleStyles( 'ext.voteNY.styles' ); + /* scroll down some lines to see why I'm not including JS here anymore + if ( $user-isAllowed( 'voteny' ) ) { + $out-addModules( 'ext.voteNY.scripts' ); + } + */ $ratings = array(); $output = ''; @@ -106,12 +113,21 @@ // If we have some ratings, start building HTML output if ( !empty( $ratings ) ) { /* XXX dirrty hack! because when we include this page, the JS - is not included, but we want things to work still */ - if ( $this-including() ) { +* is not included, but we want things to work still +* Actually, this is way harder than what it looks like. +* The JS uses wgArticleId but when directly viewing Special:TopRatings, +* wgArticleId is zero, because special pages aren't articles. +* As for including the special page, then wgArticleId would likely +* point at the ID of the page that includes {{Special:TopRatings}}, +* which would be stupid and wrong. +* Besides, shouldn't you check out the images/pages that you're gonna +* vote for? Yeah, that's what I thought, too. + if ( $this-including() $user-isAllowed( 'voteny' ) ) { global $wgExtensionAssetsPath; $output .= 'script type=text/javascript src=' . $wgExtensionAssetsPath . '/VoteNY/Vote.js/script'; } + */ // yes, array_keys() is needed foreach ( array_keys( $ratings ) as $discardThis = $pageId ) { @@ -147,7 +163,7 @@ } // Output everything! - $this-getOutput()-addHTML( $output ); + $out-addHTML( $output ); } /** diff --git a/Vote.js b/Vote.js index d3b6742..70226cd 100644 --- a/Vote.js +++ b/Vote.js @@ -1,8 +1,9 @@ /** * JavaScript functions for Vote extension. * - * TODO: Should refactor this into a jQuery widget. The widget should get a PageID in its - * constructor so it can work on any page for any page and with multiple instances per page. + * TODO: Should refactor this into a jQuery widget. + * The widget should get a PageID in its constructor so it can work on any page + * for any page and with multiple instances per page. * * @constructor * @@ -24,12 +25,18 @@ * @param PageID Integer: internal ID number of the current article */ this.clickVote = function( TheVote, PageID ) { - sajax_request_type = 'POST'; - sajax_do_call( 'wfVoteClick', [ TheVote, PageID ], function( request ) { -
[MediaWiki-commits] [Gerrit] Kill minor ghost of PayflowPro - change (mediawiki...DonationInterface)
Awight has uploaded a new change for review. https://gerrit.wikimedia.org/r/210740 Change subject: Kill minor ghost of PayflowPro .. Kill minor ghost of PayflowPro Change-Id: I99564e36452aad410f48c8e69df5bc79faf6d00b --- M DonationInterface.php M DonationInterfaceFormSettings.php 2 files changed, 0 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/DonationInterface refs/changes/40/210740/1 diff --git a/DonationInterface.php b/DonationInterface.php index 684cebc..df4e677 100644 --- a/DonationInterface.php +++ b/DonationInterface.php @@ -727,7 +727,6 @@ $wgAmazonGatewayHtmlFormDir, $wgGlobalCollectGatewayHtmlFormDir, $wgPaypalGatewayHtmlFormDir, - $wgPayflowProGatewayHtmlFormDir, $wgWorldPayGatewayHtmlFormDir; /** @@ -879,7 +878,6 @@ 'gc' = $wgGlobalCollectGatewayHtmlFormDir, 'paypal' = $wgPaypalGatewayHtmlFormDir, 'amazon' = $wgAmazonGatewayHtmlFormDir, - // 'pfp' = $wgPayflowProGatewayHtmlFormDir, ); if ( $wgDonationInterfaceEnableAdyen === true ) { diff --git a/DonationInterfaceFormSettings.php b/DonationInterfaceFormSettings.php index c3a12a6..43ea871 100644 --- a/DonationInterfaceFormSettings.php +++ b/DonationInterfaceFormSettings.php @@ -6,7 +6,6 @@ $wgAmazonGatewayHtmlFormDir, $wgGlobalCollectGatewayHtmlFormDir, $wgPaypalGatewayHtmlFormDir, - $wgPayflowProGatewayHtmlFormDir, $wgWorldPayGatewayHtmlFormDir, $wgDonationInterfaceAllowedHtmlForms, $wgDonationInterfaceEnableAdyen, -- To view, visit https://gerrit.wikimedia.org/r/210740 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I99564e36452aad410f48c8e69df5bc79faf6d00b Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/DonationInterface Gerrit-Branch: master Gerrit-Owner: Awight awi...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] wikitech-static monitoring, fix check command setup - change (operations/puppet)
Dzahn has submitted this change and it was merged. Change subject: wikitech-static monitoring,fix check command setup .. wikitech-static monitoring,fix check command setup It should be named ending in .cfg.erb, not just .erb. And additionally config stanza from nagios_common module is needed. (in the past we edited checkcommands.cfg directly) Bug:T89323 Change-Id: Iddd6713641e5246fd8812750bcf2f83c22142d42 --- M modules/icinga/manifests/plugins.pp R modules/icinga/templates/check_commands/check_wikitech_static.cfg.erb 2 files changed, 8 insertions(+), 0 deletions(-) Approvals: jenkins-bot: Verified Dzahn: Looks good to me, approved diff --git a/modules/icinga/manifests/plugins.pp b/modules/icinga/manifests/plugins.pp index e5dc512..8aeaeda 100644 --- a/modules/icinga/manifests/plugins.pp +++ b/modules/icinga/manifests/plugins.pp @@ -125,6 +125,14 @@ group = 'icinga' } +nagios_common::check_command::config { 'check_wikitech_static.cfg': +ensure = present, +content= template('icinga/check_commands/check_wikitech_static.cfg.erb'), +config_dir = '/etc/icinga', +owner = 'icinga', +group = 'icinga' +} + # Include check_elasticsearch from elasticsearch module include elasticsearch::nagios::plugin diff --git a/modules/icinga/templates/check_commands/check_wikitech_static.erb b/modules/icinga/templates/check_commands/check_wikitech_static.cfg.erb similarity index 100% rename from modules/icinga/templates/check_commands/check_wikitech_static.erb rename to modules/icinga/templates/check_commands/check_wikitech_static.cfg.erb -- To view, visit https://gerrit.wikimedia.org/r/210739 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Iddd6713641e5246fd8812750bcf2f83c22142d42 Gerrit-PatchSet: 3 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Dzahn dz...@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] wikitech-static monitoring, fix template name - change (operations/puppet)
Dzahn has uploaded a new change for review. https://gerrit.wikimedia.org/r/210739 Change subject: wikitech-static monitoring, fix template name .. wikitech-static monitoring, fix template name It should be named ending in .cfg.erb, not just .erb. Bug:T89323 Change-Id: Iddd6713641e5246fd8812750bcf2f83c22142d42 --- R modules/icinga/templates/check_commands/check_wikitech_static.cfg.erb 1 file changed, 0 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/39/210739/1 diff --git a/modules/icinga/templates/check_commands/check_wikitech_static.erb b/modules/icinga/templates/check_commands/check_wikitech_static.cfg.erb similarity index 100% rename from modules/icinga/templates/check_commands/check_wikitech_static.erb rename to modules/icinga/templates/check_commands/check_wikitech_static.cfg.erb -- To view, visit https://gerrit.wikimedia.org/r/210739 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iddd6713641e5246fd8812750bcf2f83c22142d42 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] Add ActivityUpdateJob to autoloader - change (mediawiki/core)
jenkins-bot has submitted this change and it was merged. Change subject: Add ActivityUpdateJob to autoloader .. Add ActivityUpdateJob to autoloader Follows-up 836ad263c. Ran generateLocalAutoload.php. Change-Id: I12f597aa0d8100a60f2c631797a76627acbaa2ec --- M autoload.php 1 file changed, 1 insertion(+), 0 deletions(-) Approvals: Aaron Schulz: Looks good to me, approved jenkins-bot: Verified diff --git a/autoload.php b/autoload.php index 6c623a3..d158481 100644 --- a/autoload.php +++ b/autoload.php @@ -8,6 +8,7 @@ 'AbstractContent' = __DIR__ . '/includes/content/AbstractContent.php', 'Action' = __DIR__ . '/includes/actions/Action.php', 'ActiveUsersPager' = __DIR__ . '/includes/specials/SpecialActiveusers.php', + 'ActivityUpdateJob' = __DIR__ . '/includes/jobqueue/jobs/ActivityUpdateJob.php', 'AjaxDispatcher' = __DIR__ . '/includes/AjaxDispatcher.php', 'AjaxResponse' = __DIR__ . '/includes/AjaxResponse.php', 'AllMessagesTablePager' = __DIR__ . '/includes/specials/SpecialAllMessages.php', -- To view, visit https://gerrit.wikimedia.org/r/210738 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I12f597aa0d8100a60f2c631797a76627acbaa2ec Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Krinkle krinklem...@gmail.com Gerrit-Reviewer: Aaron Schulz asch...@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] resourceloader: Implement ResourceLoaderRawFilePath for 'med... - change (mediawiki/core)
Krinkle has uploaded a new change for review. https://gerrit.wikimedia.org/r/210741 Change subject: resourceloader: Implement ResourceLoaderRawFilePath for 'mediawiki.js' .. resourceloader: Implement ResourceLoaderRawFilePath for 'mediawiki.js' When adding files to this module, they all imply a global scope. While most files have their own closure, it is still inconsistent with normal modules which always have a closure via mw.loader.implement. Base modules like 'mediawiki' are lacking such a closure, thus making it hard to share variables within the different files that make up the module without making it a globally public. The use case is 13203c0a2180e5, where we could expose the sha1() library within the scope of this module only. Change-Id: I93fcd045f47ec6a595b26f739939e1d371832ac9 --- M autoload.php A includes/resourceloader/ResourceLoaderRawFilePath.php M resources/Resources.php 3 files changed, 55 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/41/210741/1 diff --git a/autoload.php b/autoload.php index 6c623a3..491cb2b 100644 --- a/autoload.php +++ b/autoload.php @@ -1008,6 +1008,7 @@ 'ResourceLoaderLanguageDataModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderLanguageDataModule.php', 'ResourceLoaderLanguageNamesModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderLanguageNamesModule.php', 'ResourceLoaderModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderModule.php', + 'ResourceLoaderRawFileModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderRawFilePath.php', 'ResourceLoaderSiteModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderSiteModule.php', 'ResourceLoaderSkinModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderSkinModule.php', 'ResourceLoaderSpecialCharacterDataModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderSpecialCharacterDataModule.php', diff --git a/includes/resourceloader/ResourceLoaderRawFilePath.php b/includes/resourceloader/ResourceLoaderRawFilePath.php new file mode 100644 index 000..7da1ba1 --- /dev/null +++ b/includes/resourceloader/ResourceLoaderRawFilePath.php @@ -0,0 +1,53 @@ +?php +/** + * Module containing files that are loaded without ResourceLoader. + * + * Primary usecase being base modules loaded by the startup module, + * such as jquery and the mw.loader client itself. These make use of + * ResourceLoaderModule and load.php for convenience but aren't actually + * registered in the startup module (as it would have to load itself). + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * http://www.gnu.org/copyleft/gpl.html + * + * @file + * @author Trevor Parscal + * @author Roan Kattouw + */ + +class ResourceLoaderRawFileModule extends ResourceLoaderFileModule { + + /** +* Enable raw mode to omit mw.loader.state() call as mw.loader +* does not yet exist when these modules execute. +* @var boolean +*/ + protected $raw = true; + + /** +* Get all JavaScript code. +* +* @param ResourceLoaderContext $context +* @return string JavaScript code +*/ + public function getScript( ResourceLoaderContext $context ) { + $script = parent::getScript( $context ); + // Add closure explicitly because raw modules can't be wrapped mw.loader.implement. + // Unlike with mw.loader.implement, this closure is immediately invoked. + // @see ResourceLoader::makeModuleResponse + // @see ResourceLoader::makeLoaderImplementScript + return new XmlJsCode( (function () {\n{$script}\n}()); ); + } +} diff --git a/resources/Resources.php b/resources/Resources.php index ae5b3f9..ac85d3a 100644 --- a/resources/Resources.php +++ b/resources/Resources.php @@ -773,6 +773,7 @@ /* MediaWiki */ 'mediawiki' = array( + 'class' = 'ResourceLoaderRawFileModule', // Keep maintenance/jsduck/eg-iframe.html in sync 'scripts' = array( 'resources/src/mediawiki/mediawiki.js', @@ -780,7 +781,6 @@
[MediaWiki-commits] [Gerrit] resourceloader: Implement ResourceLoaderRawFileModule for 'm... - change (mediawiki/core)
Krinkle has uploaded a new change for review. https://gerrit.wikimedia.org/r/210742 Change subject: resourceloader: Implement ResourceLoaderRawFileModule for 'mediawiki.js' .. resourceloader: Implement ResourceLoaderRawFileModule for 'mediawiki.js' When adding files to this module, they all imply a global scope. While most files have their own closure, it is still inconsistent with normal modules which always have a closure via mw.loader.implement. Base modules like 'mediawiki' are lacking such a closure, thus making it hard to share variables within the different files that make up the module without making it a globally public. The use case is 13203c0a2180e5, where we could expose the sha1() library within the scope of this module only. Change-Id: I93fcd045f47ec6a595b26f739939e1d371832ac9 fixup Change-Id: I09fbad2b93ad6857d7c3760b031eda7f8a7eb5c1 --- M autoload.php A includes/resourceloader/ResourceLoaderRawFileModule.php M resources/Resources.php 3 files changed, 55 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/42/210742/1 diff --git a/autoload.php b/autoload.php index 6c623a3..4e44bc4 100644 --- a/autoload.php +++ b/autoload.php @@ -1008,6 +1008,7 @@ 'ResourceLoaderLanguageDataModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderLanguageDataModule.php', 'ResourceLoaderLanguageNamesModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderLanguageNamesModule.php', 'ResourceLoaderModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderModule.php', + 'ResourceLoaderRawFileModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderRawFileModule.php', 'ResourceLoaderSiteModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderSiteModule.php', 'ResourceLoaderSkinModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderSkinModule.php', 'ResourceLoaderSpecialCharacterDataModule' = __DIR__ . '/includes/resourceloader/ResourceLoaderSpecialCharacterDataModule.php', diff --git a/includes/resourceloader/ResourceLoaderRawFileModule.php b/includes/resourceloader/ResourceLoaderRawFileModule.php new file mode 100644 index 000..7da1ba1 --- /dev/null +++ b/includes/resourceloader/ResourceLoaderRawFileModule.php @@ -0,0 +1,53 @@ +?php +/** + * Module containing files that are loaded without ResourceLoader. + * + * Primary usecase being base modules loaded by the startup module, + * such as jquery and the mw.loader client itself. These make use of + * ResourceLoaderModule and load.php for convenience but aren't actually + * registered in the startup module (as it would have to load itself). + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * http://www.gnu.org/copyleft/gpl.html + * + * @file + * @author Trevor Parscal + * @author Roan Kattouw + */ + +class ResourceLoaderRawFileModule extends ResourceLoaderFileModule { + + /** +* Enable raw mode to omit mw.loader.state() call as mw.loader +* does not yet exist when these modules execute. +* @var boolean +*/ + protected $raw = true; + + /** +* Get all JavaScript code. +* +* @param ResourceLoaderContext $context +* @return string JavaScript code +*/ + public function getScript( ResourceLoaderContext $context ) { + $script = parent::getScript( $context ); + // Add closure explicitly because raw modules can't be wrapped mw.loader.implement. + // Unlike with mw.loader.implement, this closure is immediately invoked. + // @see ResourceLoader::makeModuleResponse + // @see ResourceLoader::makeLoaderImplementScript + return new XmlJsCode( (function () {\n{$script}\n}()); ); + } +} diff --git a/resources/Resources.php b/resources/Resources.php index ae5b3f9..ac85d3a 100644 --- a/resources/Resources.php +++ b/resources/Resources.php @@ -773,6 +773,7 @@ /* MediaWiki */ 'mediawiki' = array( + 'class' = 'ResourceLoaderRawFileModule', // Keep maintenance/jsduck/eg-iframe.html in sync 'scripts' = array(
[MediaWiki-commits] [Gerrit] Kill minor ghost of PayflowPro - change (mediawiki...DonationInterface)
jenkins-bot has submitted this change and it was merged. Change subject: Kill minor ghost of PayflowPro .. Kill minor ghost of PayflowPro Change-Id: I99564e36452aad410f48c8e69df5bc79faf6d00b --- M DonationInterface.php M DonationInterfaceFormSettings.php 2 files changed, 0 insertions(+), 3 deletions(-) Approvals: Ejegg: Looks good to me, approved jenkins-bot: Verified diff --git a/DonationInterface.php b/DonationInterface.php index 684cebc..df4e677 100644 --- a/DonationInterface.php +++ b/DonationInterface.php @@ -727,7 +727,6 @@ $wgAmazonGatewayHtmlFormDir, $wgGlobalCollectGatewayHtmlFormDir, $wgPaypalGatewayHtmlFormDir, - $wgPayflowProGatewayHtmlFormDir, $wgWorldPayGatewayHtmlFormDir; /** @@ -879,7 +878,6 @@ 'gc' = $wgGlobalCollectGatewayHtmlFormDir, 'paypal' = $wgPaypalGatewayHtmlFormDir, 'amazon' = $wgAmazonGatewayHtmlFormDir, - // 'pfp' = $wgPayflowProGatewayHtmlFormDir, ); if ( $wgDonationInterfaceEnableAdyen === true ) { diff --git a/DonationInterfaceFormSettings.php b/DonationInterfaceFormSettings.php index c3a12a6..43ea871 100644 --- a/DonationInterfaceFormSettings.php +++ b/DonationInterfaceFormSettings.php @@ -6,7 +6,6 @@ $wgAmazonGatewayHtmlFormDir, $wgGlobalCollectGatewayHtmlFormDir, $wgPaypalGatewayHtmlFormDir, - $wgPayflowProGatewayHtmlFormDir, $wgWorldPayGatewayHtmlFormDir, $wgDonationInterfaceAllowedHtmlForms, $wgDonationInterfaceEnableAdyen, -- To view, visit https://gerrit.wikimedia.org/r/210740 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I99564e36452aad410f48c8e69df5bc79faf6d00b Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/DonationInterface Gerrit-Branch: master Gerrit-Owner: Awight awi...@wikimedia.org Gerrit-Reviewer: Ejegg eeggles...@wikimedia.org Gerrit-Reviewer: Ssmith ssm...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Add options to updater - change (wikidata...rdf)
Smalyshev has uploaded a new change for review. https://gerrit.wikimedia.org/r/210743 Change subject: Add options to updater .. Add options to updater Change-Id: If19dc98fb1706142f0307b13e6efa6884f54581c --- M dist/src/script/runUpdate.sh M docs/getting-started.md 2 files changed, 18 insertions(+), 6 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/wikidata/query/rdf refs/changes/43/210743/1 diff --git a/dist/src/script/runUpdate.sh b/dist/src/script/runUpdate.sh index 0789479..257ce73 100755 --- a/dist/src/script/runUpdate.sh +++ b/dist/src/script/runUpdate.sh @@ -10,6 +10,8 @@ h) HOST=${OPTARG};; c) CONTEXT=${OPTARG};; n) NAMESPACE=${OPTARG};; + l) LANGS=${OPTARG};; + s) SKIPSITE=1;; esac done @@ -17,10 +19,19 @@ then echo Usage: $0 -n namespace [-h host] [-c context] exit 1 + +if [ -z $LANGS ]; then + ARGS= else - CP=lib/wikidata-query-tools-*-jar-with-dependencies.jar - MAIN=org.wikidata.query.rdf.tool.Update - SPARQL_URL=$HOST/$CONTEXT/namespace/$NAMESPACE/sparql - echo Updating via $SPARQL_URL - java -cp $CP $MAIN --sparqlUrl $SPARQL_URL + ARGS=--labelLanguage $LANGS --singleLabel $LANGS fi + +if [ ! -z SKIPSITE ]; then + ARGS=$ARGS --skipSiteLinks +fi + +CP=lib/wikidata-query-tools-*-jar-with-dependencies.jar +MAIN=org.wikidata.query.rdf.tool.Update +SPARQL_URL=$HOST/$CONTEXT/namespace/$NAMESPACE/sparql +echo Updating via $SPARQL_URL +java -cp $CP $MAIN $ARGS --sparqlUrl $SPARQL_URL diff --git a/docs/getting-started.md b/docs/getting-started.md index 6a6531d..7b5cd85 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -79,7 +79,8 @@ $ ./runUpdate.sh -n wdq ``` -The updater is designed to run constantly, but can be interrupted and resumed at any time. Note that if you loaded an old dump, or did not load any dump at all, it may require very long time for the data to be full syncronized, as updater only picks up recently edited items. +The updater is designed to run constantly, but can be interrupted and resumed at any time. Note that if you loaded an old dump, or did not load any dump at all, it may require very long time for the data to be full syncronized, as updater only picks up recently edited items. +Use the same set of language/skip options as in the `munge.sh` script, e.g. `-l en -s`. ## Run queries -- To view, visit https://gerrit.wikimedia.org/r/210743 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: If19dc98fb1706142f0307b13e6efa6884f54581c Gerrit-PatchSet: 1 Gerrit-Project: wikidata/query/rdf Gerrit-Branch: master Gerrit-Owner: Smalyshev smalys...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] update DonationInterface submodule - change (mediawiki/core)
Awight has uploaded a new change for review. https://gerrit.wikimedia.org/r/210744 Change subject: update DonationInterface submodule .. update DonationInterface submodule Change-Id: I9917b489bb02e48230913b3133faa30f4700a9f5 --- M extensions/DonationInterface 1 file changed, 0 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/44/210744/1 diff --git a/extensions/DonationInterface b/extensions/DonationInterface index 2e84a4f..2bc8454 16 --- a/extensions/DonationInterface +++ b/extensions/DonationInterface -Subproject commit 2e84a4fe63f334c9427f17e3042eb4be3caa2aef +Subproject commit 2bc84544eeed05896853dede7a3e7111dcf60b9e -- To view, visit https://gerrit.wikimedia.org/r/210744 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I9917b489bb02e48230913b3133faa30f4700a9f5 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: fundraising/REL1_23 Gerrit-Owner: Awight awi...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] update DonationInterface submodule - change (mediawiki/core)
Awight has submitted this change and it was merged. Change subject: update DonationInterface submodule .. update DonationInterface submodule Change-Id: I9917b489bb02e48230913b3133faa30f4700a9f5 --- M extensions/DonationInterface 1 file changed, 0 insertions(+), 0 deletions(-) Approvals: Awight: Looks good to me, approved jenkins-bot: Verified diff --git a/extensions/DonationInterface b/extensions/DonationInterface index 2e84a4f..2bc8454 16 --- a/extensions/DonationInterface +++ b/extensions/DonationInterface -Subproject commit 2e84a4fe63f334c9427f17e3042eb4be3caa2aef +Subproject commit 2bc84544eeed05896853dede7a3e7111dcf60b9e -- To view, visit https://gerrit.wikimedia.org/r/210744 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I9917b489bb02e48230913b3133faa30f4700a9f5 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: fundraising/REL1_23 Gerrit-Owner: Awight awi...@wikimedia.org Gerrit-Reviewer: Awight awi...@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] Fix duplicate 'new' tag and menu item CTA - change (mediawiki...Gather)
Robmoen has uploaded a new change for review. https://gerrit.wikimedia.org/r/210745 Change subject: Fix duplicate 'new' tag and menu item CTA .. Fix duplicate 'new' tag and menu item CTA * Do not append the tutorial or the menu tag if there already exists one. * Only emit the comletion event once on CollectionEditOverlay (hide is always called in those cases, no need to emit it explicitly). * Only listen to 'collection-edit-completed' once for every collection creation (was keeping the listening of previous created collections and triggering the handler for the event multiple times). Bug: T98947 Change-Id: Ie5f7f6d7149d1c42eeb6a769c8fb0de3864bc1cc (cherry picked from commit 368b15f3e24e7b31dfd0670746560d39d2128802) --- M resources/ext.gather.collection.editor/CollectionEditOverlay.js M resources/ext.gather.init/init.js M resources/ext.gather.watchstar/CollectionsContentOverlay.js 3 files changed, 17 insertions(+), 11 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather refs/changes/45/210745/1 diff --git a/resources/ext.gather.collection.editor/CollectionEditOverlay.js b/resources/ext.gather.collection.editor/CollectionEditOverlay.js index 08e6936..836c61e 100644 --- a/resources/ext.gather.collection.editor/CollectionEditOverlay.js +++ b/resources/ext.gather.collection.editor/CollectionEditOverlay.js @@ -240,13 +240,12 @@ } else { toast.show( self.options.editSuccessMsg, 'toast' ); } + self.hide(); self._reloadCollection(); - self._emitCompleted(); } ); } else if ( this._stateChanged ) { this.hide(); this._reloadCollection(); - this._emitCompleted(); } else { // nothing to do. this.hide(); diff --git a/resources/ext.gather.init/init.js b/resources/ext.gather.init/init.js index e06b6bf..286fdf2 100644 --- a/resources/ext.gather.init/init.js +++ b/resources/ext.gather.init/init.js @@ -98,17 +98,24 @@ showPointer( watchstar ); } watchstar.on( 'completed', function ( firstTimeUser, isNewCollection ) { + var $menuItem = $( '#mw-mf-page-left .collection-menu-item' ); if ( isNewCollection ) { // FIXME: Rename pointer overlay? - new PageActionOverlay( { - target: $( '#mw-mf-main-menu-button' ), - summary: mw.msg( 'gather-menu-guider' ), - cancelMsg: mw.msg( 'gather-add-to-collection-cancel' ) - } ).show(); + // Only append the overlay if it is not there yet + if ( $( '#mw-mf-page-center .tutorial-overlay' ).length === 0 ) { + new PageActionOverlay( { + target: $( '#mw-mf-main-menu-button' ), + summary: mw.msg( 'gather-menu-guider' ), + cancelMsg: mw.msg( 'gather-add-to-collection-cancel' ) + } ).show(); + } // FIXME: Hacky.. Should use MainMenu but Bug: T93257. - new Tag( { - label: 'new' - } ).appendTo( '#mw-mf-page-left .collection-menu-item' ); + // Only append the tag if there is none. + if ( $menuItem.find( '.gather-tag' ).length === 0 ) { + new Tag( { + label: 'new' + } ).appendTo( $menuItem ); + } } } ); } diff --git a/resources/ext.gather.watchstar/CollectionsContentOverlay.js b/resources/ext.gather.watchstar/CollectionsContentOverlay.js index 6456989..6c23cca 100644 --- a/resources/ext.gather.watchstar/CollectionsContentOverlay.js +++ b/resources/ext.gather.watchstar/CollectionsContentOverlay.js @@ -361,7 +361,7 @@ return api.addCollection( title ).done( function ( collection ) { api.addPageToCollection( collection.id, page ).done( function () {
[MediaWiki-commits] [Gerrit] API: Add 'wrfromtitle' and 'wrtotitle' to list=watchlistraw - change (mediawiki/core)
Anomie has uploaded a new change for review. https://gerrit.wikimedia.org/r/210746 Change subject: API: Add 'wrfromtitle' and 'wrtotitle' to list=watchlistraw .. API: Add 'wrfromtitle' and 'wrtotitle' to list=watchlistraw Naming is fromtitle rather than just from because from parameters in API query modules generally mean a title without namespace, and this should make use of the client-supplied namespace. Bug: T98985 Change-Id: I8370f47f6eed71ea97a44a66eb6be2a8f89fea53 --- M includes/api/ApiQueryBase.php M includes/api/ApiQueryWatchlistRaw.php M includes/api/i18n/en.json M includes/api/i18n/qqq.json 4 files changed, 51 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/46/210746/1 diff --git a/includes/api/ApiQueryBase.php b/includes/api/ApiQueryBase.php index 89e92b8..c66e21b 100644 --- a/includes/api/ApiQueryBase.php +++ b/includes/api/ApiQueryBase.php @@ -504,7 +504,7 @@ * capitalization settings. * * @param string $titlePart Title part -* @param int $defaultNamespace Namespace of the title +* @param int $namespace Namespace of the title * @return string DBkey (no namespace prefix) */ public function titlePartToKey( $titlePart, $namespace = NS_MAIN ) { @@ -526,6 +526,24 @@ } /** +* Convert an input title or title prefix into a namespace constant and dbkey. +* +* @since 1.26 +* @param string $titlePart Title part +* @param int $defaultNamespace Default namespace if none is given +* @return array (int, string) Namespace number and DBkey +*/ + public function prefixedTitlePartToKey( $titlePart, $defaultNamespace = NS_MAIN ) { + $t = Title::newFromText( $titlePart . 'x', $defaultNamespace ); + if ( !$t || $t-hasFragment() || $t-isExternal() ) { + // Invalid title (e.g. bad chars) or contained a '#'. + $this-dieUsageMsg( array( 'invalidtitle', $titlePart ) ); + } + + return array( $t-getNamespace(), substr( $t-getDbKey(), 0, -1 ) ); + } + + /** * Gets the personalised direction parameter description * * @param string $p ModulePrefix diff --git a/includes/api/ApiQueryWatchlistRaw.php b/includes/api/ApiQueryWatchlistRaw.php index 493c192..f45d7d7 100644 --- a/includes/api/ApiQueryWatchlistRaw.php +++ b/includes/api/ApiQueryWatchlistRaw.php @@ -83,6 +83,28 @@ ); } + if ( isset( $params['fromtitle'] ) ) { + list( $ns, $title ) = $this-prefixedTitlePartToKey( $params['fromtitle'] ); + $title = $this-getDB()-addQuotes( $title ); + $op = $params['dir'] == 'ascending' ? '' : ''; + $this-addWhere( + wl_namespace $op $ns OR . + (wl_namespace = $ns AND . + wl_title $op= $title) + ); + } + + if ( isset( $params['totitle'] ) ) { + list( $ns, $title ) = $this-prefixedTitlePartToKey( $params['totitle'] ); + $title = $this-getDB()-addQuotes( $title ); + $op = $params['dir'] == 'ascending' ? '' : ''; // Reversed from above! + $this-addWhere( + wl_namespace $op $ns OR . + (wl_namespace = $ns AND . + wl_title $op= $title) + ); + } + $sort = ( $params['dir'] == 'descending' ? ' DESC' : '' ); // Don't ORDER BY wl_namespace if it's constant in the WHERE clause if ( count( $params['namespace'] ) == 1 ) { @@ -172,6 +194,12 @@ ), ApiBase::PARAM_HELP_MSG = 'api-help-param-direction', ), + 'fromtitle' = array( + ApiBase::PARAM_TYPE = 'string' + ), + 'totitle' = array( + ApiBase::PARAM_TYPE = 'string' + ), ); } diff --git a/includes/api/i18n/en.json b/includes/api/i18n/en.json index 3c53be1..b899de7 100644 --- a/includes/api/i18n/en.json +++ b/includes/api/i18n/en.json @@ -996,6 +996,8 @@ apihelp-query+watchlistraw-param-show: Only list items that meet these criteria., apihelp-query+watchlistraw-param-owner: Used along with $1token to access a different user's watchlist., apihelp-query+watchlistraw-param-token: A security token (available in the user's
[MediaWiki-commits] [Gerrit] Set Flow AJAX timeout to 90 s for development - change (mediawiki/vagrant)
jenkins-bot has submitted this change and it was merged. Change subject: Set Flow AJAX timeout to 90 s for development .. Set Flow AJAX timeout to 90 s for development Change-Id: Icb48723cde3eb3b73996e288b1d9e4af5f48e094 --- M puppet/modules/role/templates/flow/conf.php.erb 1 file changed, 2 insertions(+), 0 deletions(-) Approvals: Sbisson: Looks good to me, approved jenkins-bot: Verified diff --git a/puppet/modules/role/templates/flow/conf.php.erb b/puppet/modules/role/templates/flow/conf.php.erb index e7365d5..e46609a 100644 --- a/puppet/modules/role/templates/flow/conf.php.erb +++ b/puppet/modules/role/templates/flow/conf.php.erb @@ -1,4 +1,6 @@ // see https://www.mediawiki.org/wiki/Extension:Flow +$wgFlowAjaxTimeout = 90; // Seconds + $wgFlowEventLogging = true; $wgFlowServerCompileTemplates = true; // always recompile in dev mode $wgFlowContentFormat = 'html'; // Parsoid dependency -- To view, visit https://gerrit.wikimedia.org/r/210750 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Icb48723cde3eb3b73996e288b1d9e4af5f48e094 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/vagrant Gerrit-Branch: master Gerrit-Owner: Mattflaschen mflasc...@wikimedia.org Gerrit-Reviewer: Ori.livneh o...@wikimedia.org Gerrit-Reviewer: Sbisson sbis...@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 queue stuff in Astropay ResultSwitcher - change (mediawiki...DonationInterface)
Ejegg has uploaded a new change for review. https://gerrit.wikimedia.org/r/210769 Change subject: Do queue stuff in Astropay ResultSwitcher .. Do queue stuff in Astropay ResultSwitcher Run post-process hooks and delete limbo message Bug: T90504 Change-Id: I3143b684e1ff89efc903660188292744b9b4aa86 --- M astropay_gateway/astropay.adapter.php 1 file changed, 3 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/DonationInterface refs/changes/69/210769/1 diff --git a/astropay_gateway/astropay.adapter.php b/astropay_gateway/astropay.adapter.php index 4c8f873..d0632ef 100644 --- a/astropay_gateway/astropay.adapter.php +++ b/astropay_gateway/astropay.adapter.php @@ -471,6 +471,9 @@ $status = $this-findCodeAction( 'PaymentStatus', 'result', $response['result'] ); $this-logger-info( Payment status $status coming back to ResultSwitcher ); $this-finalizeInternalStatus( $status ); + $this-runPostProcessHooks(); + $this-deleteLimboMessage(); + $this-doLimboStompTransaction( TRUE ); // TODO: stop mirroring to STOMP break; case 'NewInvoice': $this-processNewInvoiceResponse( $response ); -- To view, visit https://gerrit.wikimedia.org/r/210769 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3143b684e1ff89efc903660188292744b9b4aa86 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/DonationInterface Gerrit-Branch: master Gerrit-Owner: Ejegg eeggles...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] TWN: Fix mobile-frontend-editor-previewing-page truncated text - change (mediawiki...MobileFrontend)
jenkins-bot has submitted this change and it was merged. Change subject: TWN: Fix mobile-frontend-editor-previewing-page truncated text .. TWN: Fix mobile-frontend-editor-previewing-page truncated text In some languages, like I23aed80 Bug: T98840 Change-Id: Ia6956b3b05c424461278b5c96c02df33f5ee274f --- M i18n/en.json 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Jdlrobson: Looks good to me, approved jenkins-bot: Verified diff --git a/i18n/en.json b/i18n/en.json index 7218fd2..3ec9c09 100644 --- a/i18n/en.json +++ b/i18n/en.json @@ -117,7 +117,7 @@ mobile-frontend-editor-newpage-prompt: This page doesn't exist. Why not be bold and create it?, mobile-frontend-editor-placeholder: This section is empty. Be the first to expand it!, mobile-frontend-editor-placeholder-new-page: {{GENDER:$1|You are creating}} a new page on {{SITENAME}}!, - mobile-frontend-editor-previewing-page: strongPreviewing/strongspan $1/span, + mobile-frontend-editor-previewing-page: spanstrongPreviewing/strong $1/span, mobile-frontend-editor-redirect-title: Redirecting to editor..., mobile-frontend-editor-save: Save, mobile-frontend-editor-source-editor: Edit source, -- To view, visit https://gerrit.wikimedia.org/r/210722 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ia6956b3b05c424461278b5c96c02df33f5ee274f Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/MobileFrontend Gerrit-Branch: master Gerrit-Owner: Florianschmidtwelzow florian.schmidt.wel...@t-online.de Gerrit-Reviewer: Jdlrobson jrob...@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] Adyen: delete from memcache limbo queue - change (mediawiki...DonationInterface)
Awight has uploaded a new change for review. https://gerrit.wikimedia.org/r/210811 Change subject: Adyen: delete from memcache limbo queue .. Adyen: delete from memcache limbo queue Should delete from memcache limbo store when sending a Stomp antimessage. Change-Id: I7feaacde94605f6be21e70c1adc29a8b6163ac0a --- M adyen_gateway/adyen.adapter.php 1 file changed, 2 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/DonationInterface refs/changes/11/210811/1 diff --git a/adyen_gateway/adyen.adapter.php b/adyen_gateway/adyen.adapter.php index 97a9b85..24bf2e4 100644 --- a/adyen_gateway/adyen.adapter.php +++ b/adyen_gateway/adyen.adapter.php @@ -505,7 +505,8 @@ // FIXME: Why put that two places in transaction_result? $this-setTransactionResult( $this-getFinalStatus(), 'txn_message' ); $this-runPostProcessHooks(); - $this-doLimboStompTransaction( TRUE ); // add antimessage + $this-deleteLimboMessage(); + $this-doLimboStompTransaction( TRUE ); // TODO: stop mirroring to stomp return null; } -- To view, visit https://gerrit.wikimedia.org/r/210811 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I7feaacde94605f6be21e70c1adc29a8b6163ac0a Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/DonationInterface Gerrit-Branch: deployment Gerrit-Owner: Awight awi...@wikimedia.org Gerrit-Reviewer: Ejegg eeggles...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Kill minor ghost of PayflowPro - change (mediawiki...DonationInterface)
Awight has uploaded a new change for review. https://gerrit.wikimedia.org/r/210810 Change subject: Kill minor ghost of PayflowPro .. Kill minor ghost of PayflowPro Change-Id: I99564e36452aad410f48c8e69df5bc79faf6d00b --- M DonationInterface.php M DonationInterfaceFormSettings.php 2 files changed, 0 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/DonationInterface refs/changes/10/210810/1 diff --git a/DonationInterface.php b/DonationInterface.php index 2419f92..ecfaf6c 100644 --- a/DonationInterface.php +++ b/DonationInterface.php @@ -727,7 +727,6 @@ $wgAmazonGatewayHtmlFormDir, $wgGlobalCollectGatewayHtmlFormDir, $wgPaypalGatewayHtmlFormDir, - $wgPayflowProGatewayHtmlFormDir, $wgWorldPayGatewayHtmlFormDir; /** @@ -879,7 +878,6 @@ 'gc' = $wgGlobalCollectGatewayHtmlFormDir, 'paypal' = $wgPaypalGatewayHtmlFormDir, 'amazon' = $wgAmazonGatewayHtmlFormDir, - // 'pfp' = $wgPayflowProGatewayHtmlFormDir, ); if ( $wgDonationInterfaceEnableAdyen === true ) { diff --git a/DonationInterfaceFormSettings.php b/DonationInterfaceFormSettings.php index c3a12a6..43ea871 100644 --- a/DonationInterfaceFormSettings.php +++ b/DonationInterfaceFormSettings.php @@ -6,7 +6,6 @@ $wgAmazonGatewayHtmlFormDir, $wgGlobalCollectGatewayHtmlFormDir, $wgPaypalGatewayHtmlFormDir, - $wgPayflowProGatewayHtmlFormDir, $wgWorldPayGatewayHtmlFormDir, $wgDonationInterfaceAllowedHtmlForms, $wgDonationInterfaceEnableAdyen, -- To view, visit https://gerrit.wikimedia.org/r/210810 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I99564e36452aad410f48c8e69df5bc79faf6d00b Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/DonationInterface Gerrit-Branch: deployment Gerrit-Owner: Awight awi...@wikimedia.org ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Rebuilding dependencies - change (mediawiki...ocg-collection)
Cscott has uploaded a new change for review. https://gerrit.wikimedia.org/r/210809 Change subject: Rebuilding dependencies .. Rebuilding dependencies Change-Id: Ibd01c04535601682c79794d8f222e4c72defede0 --- M node_modules/bunyan-syslog/build/Makefile M node_modules/bunyan-syslog/package.json M node_modules/busboy/node_modules/dicer/node_modules/streamsearch/package.json M node_modules/busboy/node_modules/dicer/package.json M node_modules/commander/Readme.md M node_modules/commander/index.js M node_modules/commander/package.json A node_modules/core-js/.eslintrc A node_modules/core-js/.gitattributes A node_modules/core-js/.npmignore A node_modules/core-js/.travis.yml A node_modules/core-js/Gruntfile.js A node_modules/core-js/LICENSE A node_modules/core-js/README.md A node_modules/core-js/bower.json A node_modules/core-js/build/Gruntfile.ls A node_modules/core-js/build/build.ls A node_modules/core-js/build/config.ls A node_modules/core-js/client/core.js A node_modules/core-js/client/core.min.js A node_modules/core-js/client/core.min.js.map A node_modules/core-js/client/library.js A node_modules/core-js/client/library.min.js A node_modules/core-js/client/library.min.js.map A node_modules/core-js/client/shim.js A node_modules/core-js/client/shim.min.js A node_modules/core-js/client/shim.min.js.map A node_modules/core-js/core/$for.js A node_modules/core-js/core/_.js A node_modules/core-js/core/array.js A node_modules/core-js/core/date.js A node_modules/core-js/core/delay.js A node_modules/core-js/core/dict.js A node_modules/core-js/core/function.js A node_modules/core-js/core/global.js A node_modules/core-js/core/index.js A node_modules/core-js/core/log.js A node_modules/core-js/core/number.js A node_modules/core-js/core/object.js A node_modules/core-js/core/string.js A node_modules/core-js/es5/index.js A node_modules/core-js/es6/array.js A node_modules/core-js/es6/function.js A node_modules/core-js/es6/index.js A node_modules/core-js/es6/map.js A node_modules/core-js/es6/math.js A node_modules/core-js/es6/number.js A node_modules/core-js/es6/object.js A node_modules/core-js/es6/promise.js A node_modules/core-js/es6/reflect.js A node_modules/core-js/es6/regexp.js A node_modules/core-js/es6/set.js A node_modules/core-js/es6/string.js A node_modules/core-js/es6/symbol.js A node_modules/core-js/es6/weak-map.js A node_modules/core-js/es6/weak-set.js A node_modules/core-js/es7/array.js A node_modules/core-js/es7/index.js A node_modules/core-js/es7/map.js A node_modules/core-js/es7/object.js A node_modules/core-js/es7/regexp.js A node_modules/core-js/es7/set.js A node_modules/core-js/es7/string.js A node_modules/core-js/fn/$for.js A node_modules/core-js/fn/_.js A node_modules/core-js/fn/array/concat.js A node_modules/core-js/fn/array/copy-within.js A node_modules/core-js/fn/array/entries.js A node_modules/core-js/fn/array/every.js A node_modules/core-js/fn/array/fill.js A node_modules/core-js/fn/array/filter.js A node_modules/core-js/fn/array/find-index.js A node_modules/core-js/fn/array/find.js A node_modules/core-js/fn/array/for-each.js A node_modules/core-js/fn/array/from.js A node_modules/core-js/fn/array/includes.js A node_modules/core-js/fn/array/index-of.js A node_modules/core-js/fn/array/index.js A node_modules/core-js/fn/array/join.js A node_modules/core-js/fn/array/keys.js A node_modules/core-js/fn/array/last-index-of.js A node_modules/core-js/fn/array/map.js A node_modules/core-js/fn/array/of.js A node_modules/core-js/fn/array/pop.js A node_modules/core-js/fn/array/push.js A node_modules/core-js/fn/array/reduce-right.js A node_modules/core-js/fn/array/reduce.js A node_modules/core-js/fn/array/reverse.js A node_modules/core-js/fn/array/shift.js A node_modules/core-js/fn/array/slice.js A node_modules/core-js/fn/array/some.js A node_modules/core-js/fn/array/sort.js A node_modules/core-js/fn/array/splice.js A node_modules/core-js/fn/array/turn.js A node_modules/core-js/fn/array/unshift.js A node_modules/core-js/fn/array/values.js A node_modules/core-js/fn/clear-immediate.js A node_modules/core-js/fn/date/add-locale.js A node_modules/core-js/fn/date/format-utc.js A node_modules/core-js/fn/date/format.js A node_modules/core-js/fn/date/index.js A node_modules/core-js/fn/delay.js A node_modules/core-js/fn/dict.js A node_modules/core-js/fn/function/has-instance.js A node_modules/core-js/fn/function/index.js A node_modules/core-js/fn/function/name.js A node_modules/core-js/fn/function/part.js A node_modules/core-js/fn/get-iterator.js A node_modules/core-js/fn/global.js A node_modules/core-js/fn/is-iterable.js A node_modules/core-js/fn/log.js A node_modules/core-js/fn/map.js A node_modules/core-js/fn/math/acosh.js A node_modules/core-js/fn/math/asinh.js A node_modules/core-js/fn/math/atanh.js A node_modules/core-js/fn/math/cbrt.js A node_modules/core-js/fn/math/clz32.js A node_modules/core-js/fn/math/cosh.js A
[MediaWiki-commits] [Gerrit] Adyen: delete from memcache limbo queue - change (mediawiki...DonationInterface)
jenkins-bot has submitted this change and it was merged. Change subject: Adyen: delete from memcache limbo queue .. Adyen: delete from memcache limbo queue Should delete from memcache limbo store when sending a Stomp antimessage. Change-Id: I7feaacde94605f6be21e70c1adc29a8b6163ac0a --- M adyen_gateway/adyen.adapter.php 1 file changed, 2 insertions(+), 1 deletion(-) Approvals: Awight: Looks good to me, approved jenkins-bot: Verified diff --git a/adyen_gateway/adyen.adapter.php b/adyen_gateway/adyen.adapter.php index 97a9b85..24bf2e4 100644 --- a/adyen_gateway/adyen.adapter.php +++ b/adyen_gateway/adyen.adapter.php @@ -505,7 +505,8 @@ // FIXME: Why put that two places in transaction_result? $this-setTransactionResult( $this-getFinalStatus(), 'txn_message' ); $this-runPostProcessHooks(); - $this-doLimboStompTransaction( TRUE ); // add antimessage + $this-deleteLimboMessage(); + $this-doLimboStompTransaction( TRUE ); // TODO: stop mirroring to stomp return null; } -- To view, visit https://gerrit.wikimedia.org/r/210811 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I7feaacde94605f6be21e70c1adc29a8b6163ac0a Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/DonationInterface Gerrit-Branch: deployment Gerrit-Owner: Awight awi...@wikimedia.org Gerrit-Reviewer: Awight awi...@wikimedia.org Gerrit-Reviewer: Ejegg eeggles...@wikimedia.org Gerrit-Reviewer: jenkins-bot ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits