[MediaWiki-commits] [Gerrit] mediawiki...Translate[master]: Special:TranslationStats: use mediawiki.widgets.datetime if ...
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/310332 ) Change subject: Special:TranslationStats: use mediawiki.widgets.datetime if available .. Special:TranslationStats: use mediawiki.widgets.datetime if available Change-Id: I22f06f264b143fd7bb5c65516d9265170974b893 --- M Resources.php M resources/js/ext.translate.special.translationstats.js 2 files changed, 50 insertions(+), 19 deletions(-) Approvals: Amire80: Looks good to me, approved jenkins-bot: Verified diff --git a/Resources.php b/Resources.php index 5721ec1..aeb270d 100644 --- a/Resources.php +++ b/Resources.php @@ -526,10 +526,6 @@ $wgResourceModules['ext.translate.special.translationstats'] = array( 'scripts' => 'resources/js/ext.translate.special.translationstats.js', - 'dependencies' => array( - 'jquery.ui.datepicker', - ), - 'targets' => array( 'desktop' ), ) + $resourcePaths; $wgResourceModules['ext.translate.statsbar'] = array( diff --git a/resources/js/ext.translate.special.translationstats.js b/resources/js/ext.translate.special.translationstats.js index 2e55304..9c28f01 100644 --- a/resources/js/ext.translate.special.translationstats.js +++ b/resources/js/ext.translate.special.translationstats.js @@ -4,24 +4,59 @@ * * @author Amir E. Aharoni * @author Siebrand Mazeland + * @author Niklas Laxström * @copyright Copyright © 2012-2013 Amir E. Aharoni, Siebrand Mazeland * @license GPL-2.0+ */ -jQuery( document ).ready( function ( $ ) { +( function ( $, mw ) { 'use strict'; - // Based on UploadWizard, TranslationNotifications - $( '#start' ) - .datepicker( { - dateFormat: 'yy-mm-ddT00:00:00', - constrainInput: false, - showOn: 'focus', - changeMonth: true, - changeYear: true, - showAnim: false, - showButtonPanel: true, - maxDate: new Date() - } ) - .attr( 'autocomplete', 'off' ); -} ); + $( function () { + var $input = $( '#start' ), + datepicker = mw.loader.getState( 'mediawiki.widgets.datetime' ) === null; + + // Remove when MediaWiki 1.27 is no longer supported + if ( datepicker ) { + mw.loader.using( 'jquery.ui.datepicker' ).done( function () { + $input.datepicker( { + dateFormat: 'yy-mm-ddT00:00:00', + constrainInput: false, + showOn: 'focus', + changeMonth: true, + changeYear: true, + showAnim: false, + showButtonPanel: true, + maxDate: new Date() + } ) + .attr( 'autocomplete', 'off' ); + } ); + } else { + mw.loader.using( 'mediawiki.widgets.datetime' ).done( function () { + var widget, defaultValue, defaultDate; + + defaultDate = new Date(); + defaultDate.setDate( 1 ); + + if ( $input.val() ) { + defaultValue = new Date( $input.val() ); + } + + widget = new mw.widgets.datetime.DateTimeInputWidget( { + formatter: { + format: '${year|0}-${month|0}-${day|0}', + defaultDate: defaultDate + }, + type: 'date', + value: defaultValue, + max: new Date() + } ); + + $input.after( widget.$element ).hide(); + widget.on( 'change', function ( data ) { + $input.val( data + 'T00:00:00' ); + } ); + } ); + } + } ); +}( jQuery, mediaWiki ) ); -- To view, visit https://gerrit.wikimedia.org/r/310332 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I22f06f264b143fd7bb5c65516d9265170974b893 Gerrit-PatchSet: 7 Gerrit-Project: mediawiki/extensions/Translate Gerrit-Branch: master Gerrit-Owner: Nikerabbit Gerrit-Reviewer: Amire80 Gerrit-Reviewer: Anomie Gerri
[MediaWiki-commits] [Gerrit] research...wheels[master]: Add wheels for uwsgi and depends
Nschaaf has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326907 ) Change subject: Add wheels for uwsgi and depends .. Add wheels for uwsgi and depends --- M Makefile M wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl M wheels/aniso8601-1.2.0-py3-none-any.whl M wheels/itsdangerous-0.24-py3-none-any.whl A wheels/numpy-1.11.2-cp34-cp34m-manylinux1_x86_64.whl M wheels/sklearn-0.0-py2.py3-none-any.whl A wheels/uWSGI-2.0.14-cp34-cp34m-linux_x86_64.whl 7 files changed, 2 insertions(+), 1 deletion(-) Approvals: Nschaaf: Verified; Looks good to me, approved diff --git a/Makefile b/Makefile index 561f504..a2aa943 100644 --- a/Makefile +++ b/Makefile @@ -3,4 +3,5 @@ pip wheel uwsgi -w wheels && \ git clone https://gerrit.wikimedia.org/r/research/recommendation-api && \ pip wheel ./recommendation-api -w wheels && \ - rm -rf recommendation-api + rm -rf recommendation-api && \ + rm ./wheels/recommendation*.whl diff --git a/wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl b/wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl index f67d384..cb6e87c 100644 --- a/wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl +++ b/wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl Binary files differ diff --git a/wheels/aniso8601-1.2.0-py3-none-any.whl b/wheels/aniso8601-1.2.0-py3-none-any.whl index 5585235..eddd4c0 100644 --- a/wheels/aniso8601-1.2.0-py3-none-any.whl +++ b/wheels/aniso8601-1.2.0-py3-none-any.whl Binary files differ diff --git a/wheels/itsdangerous-0.24-py3-none-any.whl b/wheels/itsdangerous-0.24-py3-none-any.whl index 00f970f..c056f72 100644 --- a/wheels/itsdangerous-0.24-py3-none-any.whl +++ b/wheels/itsdangerous-0.24-py3-none-any.whl Binary files differ diff --git a/wheels/numpy-1.11.2-cp34-cp34m-manylinux1_x86_64.whl b/wheels/numpy-1.11.2-cp34-cp34m-manylinux1_x86_64.whl new file mode 100644 index 000..c6cb433 --- /dev/null +++ b/wheels/numpy-1.11.2-cp34-cp34m-manylinux1_x86_64.whl Binary files differ diff --git a/wheels/sklearn-0.0-py2.py3-none-any.whl b/wheels/sklearn-0.0-py2.py3-none-any.whl index 1c5aea1..75daedb 100644 --- a/wheels/sklearn-0.0-py2.py3-none-any.whl +++ b/wheels/sklearn-0.0-py2.py3-none-any.whl Binary files differ diff --git a/wheels/uWSGI-2.0.14-cp34-cp34m-linux_x86_64.whl b/wheels/uWSGI-2.0.14-cp34-cp34m-linux_x86_64.whl new file mode 100644 index 000..c7d2e3f --- /dev/null +++ b/wheels/uWSGI-2.0.14-cp34-cp34m-linux_x86_64.whl Binary files differ -- To view, visit https://gerrit.wikimedia.org/r/326907 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ie474a92fe312d510cbc8995892203307a44748c1 Gerrit-PatchSet: 1 Gerrit-Project: research/recommendation-api/wheels Gerrit-Branch: master Gerrit-Owner: Nschaaf Gerrit-Reviewer: Nschaaf ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] integration/config[master]: Inject skin/ext dependencies
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326469 ) Change subject: Inject skin/ext dependencies .. Inject skin/ext dependencies Up until previous commit, we only supported injecting extensions and only on extensions jobs. We now support skins, apply the mecanism on a couple repositories that have been identified to need that: CustomPage extension requires the skin CustomPage. BlueSpiceSkin skin requires the extension BlueSpiceFoundation Add tests to exercise the feature. Bug: T151593 Change-Id: Idc1d5774fe79d4f3542529bd18e09f06fcf6e3d0 --- M tests/test_zuul_mw_dependencies.py M zuul/parameter_functions.py 2 files changed, 28 insertions(+), 0 deletions(-) Approvals: Paladox: Looks good to me, but someone else must approve Hashar: Looks good to me, approved jenkins-bot: Verified diff --git a/tests/test_zuul_mw_dependencies.py b/tests/test_zuul_mw_dependencies.py index bc30074..de6098a 100644 --- a/tests/test_zuul_mw_dependencies.py +++ b/tests/test_zuul_mw_dependencies.py @@ -128,3 +128,25 @@ get_dependencies('skins/Child', mapping), set(['skin/Common']) ) + +def test_inject_skin_on_an_extension(self): +deps = self.fetch_dependencies( +job_name='mwext-testextension-hhvm', +project='mediawiki/extensions/CustomPage') +self.assertDictContainsSubset( +{ +'EXT_NAME': 'CustomPage', +'SKIN_DEPENDENCIES': 'mediawiki/skins/CustomPage', +}, +deps) + +def test_inject_extension_on_a_skin(self): +deps = self.fetch_dependencies( +job_name='mw-testskin', +project='mediawiki/skins/BlueSpiceSkin') +self.assertDictContainsSubset( +{ +'SKIN_NAME': 'BlueSpiceSkin', +'EXT_DEPENDENCIES': 'mediawiki/extensions/BlueSpiceFoundation', +}, +deps) diff --git a/zuul/parameter_functions.py b/zuul/parameter_functions.py index 7e5fbb9..cf1cb13 100644 --- a/zuul/parameter_functions.py +++ b/zuul/parameter_functions.py @@ -101,6 +101,11 @@ # 'skins/'. The has is used by the set_mw_dependencies() parameter function # below. dependencies = { +# Skins are listed first to highlight the skin dependencies +'skins/BlueSpiceSkin': ['BlueSpiceFoundation'], + +# Extensions +# One can add a skin by using: 'skin/X' 'AbuseFilter': ['AntiSpoof'], 'ApiFeatureUsage': ['Elastica'], 'Arrays': ['Loops', 'ParserFunctions', 'Variables'], @@ -116,6 +121,7 @@ 'ContentTranslation': ['Echo', 'EventLogging', 'GuidedTour', 'UniversalLanguageSelector', 'Wikidata'], 'CookieWarning': ['MobileFrontend'], +'CustomPage': ['skins/CustomPage'], 'Disambiguator': ['VisualEditor'], 'DonationInterface': ['ContributionTracking'], 'EducationProgram': ['cldr', 'WikiEditor'], -- To view, visit https://gerrit.wikimedia.org/r/326469 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Idc1d5774fe79d4f3542529bd18e09f06fcf6e3d0 Gerrit-PatchSet: 2 Gerrit-Project: integration/config Gerrit-Branch: master Gerrit-Owner: Hashar Gerrit-Reviewer: Hashar Gerrit-Reviewer: Legoktm Gerrit-Reviewer: Paladox Gerrit-Reviewer: jenkins-bot <> ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] integration/config[master]: Support skin as dependencies
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/323540 ) Change subject: Support skin as dependencies .. Support skin as dependencies Rename Zuul method set_ext_dependencies to a more generic set_mw_dependencies Dependent skins are injected via a new SKIN_DEPENDENCIES variable. We only need to clone the repositories, the MediaWiki installer takes care of injecting/installing them in LocalSettings.php unlike extensions that rely on extensions_load.txt. Refactor/enhance tests to take skins in account. Add a few tests for get_dependencies() Bug: T151593 Signed-off-by: Antoine Musso Change-Id: Icad88b9b0995199eb3e75b9e5ce9f7a0acfee16e --- M jjb/mediawiki-extensions.yaml D tests/test_zuul_ext_dependencies.py A tests/test_zuul_mw_dependencies.py M zuul/parameter_functions.py 4 files changed, 192 insertions(+), 94 deletions(-) Approvals: Paladox: Looks good to me, but someone else must approve Hashar: Looks good to me, approved jenkins-bot: Verified diff --git a/jjb/mediawiki-extensions.yaml b/jjb/mediawiki-extensions.yaml index 69b69d4..1ece20c 100644 --- a/jjb/mediawiki-extensions.yaml +++ b/jjb/mediawiki-extensions.yaml @@ -66,11 +66,16 @@ builders: - shell: "echo $ZUUL_PROJECT > deps.txt" - shell: "echo -e $EXT_DEPENDENCIES >> deps.txt" + - shell: "echo -e $SKIN_DEPENDENCIES > deps_skins.txt" + # Clone both extensions and skins, but only extensions get listed for the + # extensions autoloader in integration/jenkins.git, skins are + # automatically injected by MediaWiki upon installation. - zuul-cloner: projects: > mediawiki/core mediawiki/vendor $(cat deps.txt) + $(cat deps_skins.txt) - ve-submodules-update - shell: "mv deps.txt src/extensions_load.txt" - mw-install-mysql @@ -83,10 +88,12 @@ builders: - shell: "echo $ZUUL_PROJECT > deps.txt" - shell: "echo -e $EXT_DEPENDENCIES >> deps.txt" + - shell: "echo -e $SKIN_DEPENDENCIES > deps_skins.txt" - zuul-cloner: projects: > mediawiki/core $(cat deps.txt) + $(cat deps_skins.txt) - ve-submodules-update - shell: "mv deps.txt src/extensions_load.txt" - composer-validate: diff --git a/tests/test_zuul_ext_dependencies.py b/tests/test_zuul_ext_dependencies.py deleted file mode 100644 index d9c798f..000 --- a/tests/test_zuul_ext_dependencies.py +++ /dev/null @@ -1,73 +0,0 @@ -import os -import unittest - -from fakes import FakeJob - -dependencies = {} # defined for flake8 -get_dependencies = None # defined for flake8 -set_parameters = None # defined for flake8 -# Import function -execfile(os.path.join( -os.path.dirname(os.path.abspath(__file__)), -'../zuul/parameter_functions.py')) - - -class TestExtDependencies(unittest.TestCase): -def assertHasDependencies(self, params): -self.assertIn('EXT_DEPENDENCIES', params) - -def assertMissingDependencies(self, params): -self.assertNotIn('EXT_DEPENDENCIES', params) - -def fetch_dependencies(self, job_name=None, project=None): -if project: -params = {'ZUUL_PROJECT': project} -else: -params = {'ZUUL_PROJECT': 'mediawiki/extensions/Example'} -job = FakeJob(job_name if job_name else 'mwext-testextension-hhvm') -set_parameters(None, job, params) -return params - -def test_ext_name(self): -params = self.fetch_dependencies( -project='mediawiki/extensions/Example') - -self.assertIn('EXT_NAME', params) -self.assertEqual(params['EXT_NAME'], 'Example') - -def test_cyclical_dependencies(self): -"""verifies that cyclical dependencies are possible""" - -mapping = {'Foo': ['Bar'], 'Bar': ['Foo']} - -self.assertEqual(get_dependencies('Foo', mapping), set(['Foo', 'Bar'])) - -def test_resolvable_dependencies(self): -"""verifies that we can resolve all of the dependencies""" -for ext_name in dependencies: -self.assertHasDependencies(self.fetch_dependencies( -project='mediawiki/extensions/' + ext_name)) - -def test_job_name(self): -self.assertHasDependencies(self.fetch_dependencies( -job_name='mwext-testextension-hhvm')) -self.assertHasDependencies(self.fetch_dependencies( -job_name='mwext-qunit-jessie')) -self.assertHasDependencies(self.fetch_dependencies( -job_name='mwext-qunit-composer-jessie')) -self.assertHasDependencies(self.fetch_dependencies( -job_name='mwext-mw-selenium-composer-jessie')) -self.assertHasDependencies(self.fetch_dependencies( -job_name='mwext-mw-selenium-jessie')) -self.assertMissingDependencies(self.fetch_dependencies( -job_name='mediawiki-co
[MediaWiki-commits] [Gerrit] research...wheels[master]: Add wheels for uwsgi and depends
Nschaaf has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326907 ) Change subject: Add wheels for uwsgi and depends .. Add wheels for uwsgi and depends --- M Makefile M wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl M wheels/aniso8601-1.2.0-py3-none-any.whl M wheels/itsdangerous-0.24-py3-none-any.whl A wheels/numpy-1.11.2-cp34-cp34m-manylinux1_x86_64.whl M wheels/sklearn-0.0-py2.py3-none-any.whl A wheels/uWSGI-2.0.14-cp34-cp34m-linux_x86_64.whl 7 files changed, 2 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/research/recommendation-api/wheels refs/changes/07/326907/1 diff --git a/Makefile b/Makefile index 561f504..a2aa943 100644 --- a/Makefile +++ b/Makefile @@ -3,4 +3,5 @@ pip wheel uwsgi -w wheels && \ git clone https://gerrit.wikimedia.org/r/research/recommendation-api && \ pip wheel ./recommendation-api -w wheels && \ - rm -rf recommendation-api + rm -rf recommendation-api && \ + rm ./wheels/recommendation*.whl diff --git a/wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl b/wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl index f67d384..cb6e87c 100644 --- a/wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl +++ b/wheels/MarkupSafe-0.23-cp34-cp34m-linux_x86_64.whl Binary files differ diff --git a/wheels/aniso8601-1.2.0-py3-none-any.whl b/wheels/aniso8601-1.2.0-py3-none-any.whl index 5585235..eddd4c0 100644 --- a/wheels/aniso8601-1.2.0-py3-none-any.whl +++ b/wheels/aniso8601-1.2.0-py3-none-any.whl Binary files differ diff --git a/wheels/itsdangerous-0.24-py3-none-any.whl b/wheels/itsdangerous-0.24-py3-none-any.whl index 00f970f..c056f72 100644 --- a/wheels/itsdangerous-0.24-py3-none-any.whl +++ b/wheels/itsdangerous-0.24-py3-none-any.whl Binary files differ diff --git a/wheels/numpy-1.11.2-cp34-cp34m-manylinux1_x86_64.whl b/wheels/numpy-1.11.2-cp34-cp34m-manylinux1_x86_64.whl new file mode 100644 index 000..c6cb433 --- /dev/null +++ b/wheels/numpy-1.11.2-cp34-cp34m-manylinux1_x86_64.whl Binary files differ diff --git a/wheels/sklearn-0.0-py2.py3-none-any.whl b/wheels/sklearn-0.0-py2.py3-none-any.whl index 1c5aea1..75daedb 100644 --- a/wheels/sklearn-0.0-py2.py3-none-any.whl +++ b/wheels/sklearn-0.0-py2.py3-none-any.whl Binary files differ diff --git a/wheels/uWSGI-2.0.14-cp34-cp34m-linux_x86_64.whl b/wheels/uWSGI-2.0.14-cp34-cp34m-linux_x86_64.whl new file mode 100644 index 000..c7d2e3f --- /dev/null +++ b/wheels/uWSGI-2.0.14-cp34-cp34m-linux_x86_64.whl Binary files differ -- To view, visit https://gerrit.wikimedia.org/r/326907 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie474a92fe312d510cbc8995892203307a44748c1 Gerrit-PatchSet: 1 Gerrit-Project: research/recommendation-api/wheels Gerrit-Branch: master Gerrit-Owner: Nschaaf ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] mediawiki...JsonConfig[master]: Reindex tabular data array for easier lua access
Yurik has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326906 ) Change subject: Reindex tabular data array for easier lua access .. Reindex tabular data array for easier lua access Bug: T152809 Change-Id: I5262edc279cd7737623e721faed968fa43b170b6 --- M includes/JCLuaLibrary.php 1 file changed, 14 insertions(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/JsonConfig refs/changes/06/326906/1 diff --git a/includes/JCLuaLibrary.php b/includes/JCLuaLibrary.php index 1bc5ee6..5b6f0e3 100644 --- a/includes/JCLuaLibrary.php +++ b/includes/JCLuaLibrary.php @@ -72,6 +72,20 @@ } else { /** @var JCDataContent $content */ $result = $content->getLocalizedData( $language ); + + if ( $content instanceof JCTabularContent ) { + // Tabular data should be Lua-reindexed for easier processing + $columns = count( $result->schema->fields ); + if ( $columns > 0 ) { + $rowIndexes = range( 1, $columns ); + $result->schema->fields = array_combine( $rowIndexes, $result->schema->fields ); + $result->data = + array_combine( range( 1, count( $result ) ), + array_map( function ( $row ) use ( $rowIndexes ) { + return array_combine( $rowIndexes, $row ); + }, $result->data ) ); + } + } } return [ $result ]; -- To view, visit https://gerrit.wikimedia.org/r/326906 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I5262edc279cd7737623e721faed968fa43b170b6 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/JsonConfig Gerrit-Branch: master Gerrit-Owner: Yurik ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] integration/config[master]: Remove MoodBar
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326878 ) Change subject: Remove MoodBar .. Remove MoodBar Change-Id: I0b6d4fda5a0174471d0b46f75bf166e8e8d35e86 --- M zuul/layout.yaml 1 file changed, 0 insertions(+), 9 deletions(-) Approvals: Hashar: Looks good to me, approved jenkins-bot: Verified diff --git a/zuul/layout.yaml b/zuul/layout.yaml index 58a5a5d..4cf9ede 100644 --- a/zuul/layout.yaml +++ b/zuul/layout.yaml @@ -4182,15 +4182,6 @@ check: - jsonlint - - name: mediawiki/extensions/MoodBar -template: - - name: composer-test - - name: extension-unittests-generic - - name: npm -check: - - jsonlint - - jshint - - name: mediawiki/extensions/MP3MediaHandler template: - name: extension-unittests-generic -- To view, visit https://gerrit.wikimedia.org/r/326878 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I0b6d4fda5a0174471d0b46f75bf166e8e8d35e86 Gerrit-PatchSet: 2 Gerrit-Project: integration/config Gerrit-Branch: master Gerrit-Owner: MaxSem Gerrit-Reviewer: Hashar Gerrit-Reviewer: Legoktm Gerrit-Reviewer: jenkins-bot <> ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] research/recommendation-api[master]: Use related-articles in translation recommendation
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326903 ) Change subject: Use related-articles in translation recommendation .. Use related-articles in translation recommendation Bug: T151793 Change-Id: Iff6b932606cebb7fc239fdb1d64703525069c782 --- M recommendation/api/external_data/fetcher.py M recommendation/api/external_data/wikidata.py M recommendation/api/types/translation/candidate_finders.py M recommendation/api/types/translation/translation.py M recommendation/data/labs_setup.sh 5 files changed, 31 insertions(+), 4 deletions(-) Approvals: Nschaaf: Looks good to me, approved jenkins-bot: Verified diff --git a/recommendation/api/external_data/fetcher.py b/recommendation/api/external_data/fetcher.py index 76e8b6b..6d6fdf7 100644 --- a/recommendation/api/external_data/fetcher.py +++ b/recommendation/api/external_data/fetcher.py @@ -108,3 +108,8 @@ seed = 'morelike:' + seed params['srsearch'] = seed return endpoint, params + + +def get_related_articles(source, seed): +return get('http://recommend-related-articles.wmflabs.org/types/related_articles/v1/articles', + dict(source=source, seed=seed, count=500)) diff --git a/recommendation/api/external_data/wikidata.py b/recommendation/api/external_data/wikidata.py index 82f7178..7359fbc 100644 --- a/recommendation/api/external_data/wikidata.py +++ b/recommendation/api/external_data/wikidata.py @@ -9,11 +9,11 @@ WikidataItem = collections.namedtuple('WikidataItem', ['id', 'title', 'url']) -def query(params): +def query(params, expected_sitelinks=1): """ Query the wikidata endpoint and return a list of WikidataItem - This only includes items that have exactly 1 sitelink + This only includes items that have exactly expected_sitelinks sitelink """ endpoint = configuration.get_config_value('endpoints', 'wikidata') try: @@ -28,7 +28,7 @@ for id, entity in entities.items(): sitelinks = entity.get('sitelinks', {}) -if len(sitelinks.keys()) != 1: +if len(sitelinks.keys()) != expected_sitelinks: continue sitelink = sitelinks.popitem()[1] @@ -43,7 +43,12 @@ def get_items_in_source_missing_in_target_by_titles(source, target, titles): params = configuration.get_config_dict('wikidata_titles_to_items_params') params['sites'] = params['sites'].format(source=source) +# We want the sitefilter to include both the source and target +# wikis. This sets up the scenario where if there is only 1 sitelink +# present, that means that the article is missing in the target (since +# the title will have come from the source wiki) params['sitefilter'] = params['sitefilter'].format(target=target) +params['sitefilter'] += '|{}wiki'.format(source) params['titles'] = '|'.join(titles) items = query(params) diff --git a/recommendation/api/types/translation/candidate_finders.py b/recommendation/api/types/translation/candidate_finders.py index 70ae772..ba73bf2 100644 --- a/recommendation/api/types/translation/candidate_finders.py +++ b/recommendation/api/types/translation/candidate_finders.py @@ -112,3 +112,19 @@ articles.append(a) return articles[:n] + + +class RelatedArticleFinder(CandidateFinder): +def get_candidates(self, s, seed, n): +results = fetcher.get_related_articles(s, seed) +if len(results) == 0: +return MorelikeCandidateFinder().get_candidates(s, seed, n) + +articles = [] +for item in results: +a = Article(item['title']) +a.wikidata_id = item['wikidata_id'] +a.rank = item['score'] +articles.append(a) + +return articles[:n] diff --git a/recommendation/api/types/translation/translation.py b/recommendation/api/types/translation/translation.py index d271c50..f22a880 100644 --- a/recommendation/api/types/translation/translation.py +++ b/recommendation/api/types/translation/translation.py @@ -166,6 +166,7 @@ 'morelike': candidate_finders.MorelikeCandidateFinder(), 'wiki': candidate_finders.MorelikeCandidateFinder(), 'mostpopular': candidate_finders.PageviewCandidateFinder(), +'related_articles': candidate_finders.RelatedArticleFinder() } diff --git a/recommendation/data/labs_setup.sh b/recommendation/data/labs_setup.sh index 8290c97..377b2d1 100755 --- a/recommendation/data/labs_setup.sh +++ b/recommendation/data/labs_setup.sh @@ -31,7 +31,7 @@ cp ${TMP_PATH}/recommendation-api/recommendation/data/* ${ETC_PATH} cp ${ETC_PATH}/recommendation.nginx /etc/nginx/sites-available/recommendation ln -s /etc/nginx/sites-available/recommendation /etc/nginx/sites-enabled/ -cp ${ETC_PATH}/recommendation.service /etc/systemd/system/multi-user.target/wants/ +cp ${ETC_PATH}/recommendation.service /etc/systemd/system/multi-user.target.wants/ system
[MediaWiki-commits] [Gerrit] research...wheels[master]: Add uwsgi to wheel building
Nschaaf has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326905 ) Change subject: Add uwsgi to wheel building .. Add uwsgi to wheel building Change-Id: Iab92949cab6fc57d417156516652d8532a8ccda0 --- M Makefile 1 file changed, 1 insertion(+), 0 deletions(-) Approvals: Nschaaf: Verified; Looks good to me, approved diff --git a/Makefile b/Makefile index 6af7357..561f504 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,6 @@ all: mkdir -p wheels && \ + pip wheel uwsgi -w wheels && \ git clone https://gerrit.wikimedia.org/r/research/recommendation-api && \ pip wheel ./recommendation-api -w wheels && \ rm -rf recommendation-api -- To view, visit https://gerrit.wikimedia.org/r/326905 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Iab92949cab6fc57d417156516652d8532a8ccda0 Gerrit-PatchSet: 1 Gerrit-Project: research/recommendation-api/wheels Gerrit-Branch: master Gerrit-Owner: Nschaaf Gerrit-Reviewer: Nschaaf ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] research...wheels[master]: Add uwsgi to wheel building
Nschaaf has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326905 ) Change subject: Add uwsgi to wheel building .. Add uwsgi to wheel building Change-Id: Iab92949cab6fc57d417156516652d8532a8ccda0 --- M Makefile 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/research/recommendation-api/wheels refs/changes/05/326905/1 diff --git a/Makefile b/Makefile index 6af7357..561f504 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,6 @@ all: mkdir -p wheels && \ + pip wheel uwsgi -w wheels && \ git clone https://gerrit.wikimedia.org/r/research/recommendation-api && \ pip wheel ./recommendation-api -w wheels && \ rm -rf recommendation-api -- To view, visit https://gerrit.wikimedia.org/r/326905 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iab92949cab6fc57d417156516652d8532a8ccda0 Gerrit-PatchSet: 1 Gerrit-Project: research/recommendation-api/wheels Gerrit-Branch: master Gerrit-Owner: Nschaaf ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] operations/puppet[production]: Set systemd dependency correctly for vk statsv/el instances
Elukey has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326904 ) Change subject: Set systemd dependency correctly for vk statsv/el instances .. Set systemd dependency correctly for vk statsv/el instances While checking Varnishkafka graphs in Grafana I noticed that the varnishkafka statsv and eventlogging instances were restarting at the same time sporadically, meanwhile this didn't happen for the webrequest instance. I checked their systemd units and statsv/eventlogging are dependend on the varnish instance, not the varnish-frontend one. Add also some documentation to the role parameters. Change-Id: I3ebf095c2d77dbad4541e6a2808baf345454e561 --- M modules/role/manifests/cache/kafka/eventlogging.pp M modules/role/manifests/cache/kafka/statsv.pp M modules/role/manifests/cache/kafka/webrequest.pp 3 files changed, 42 insertions(+), 13 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/puppet refs/changes/04/326904/1 diff --git a/modules/role/manifests/cache/kafka/eventlogging.pp b/modules/role/manifests/cache/kafka/eventlogging.pp index c0e2b8b..98bc818 100644 --- a/modules/role/manifests/cache/kafka/eventlogging.pp +++ b/modules/role/manifests/cache/kafka/eventlogging.pp @@ -1,6 +1,22 @@ +# == Class role::cache::kafka::eventlogging +# +# Sets up a varnishkafka logging endpoint for collecting +# analytics events coming from external clients. +# +# More info: https://wikitech.wikimedia.org/wiki/Analytics/EventLogging +# +# === Parameters +# +# [*varnish_name*] +# The name of the varnish instance to read shared logs from. +# Default 'frontend' +# [*varnish_svc_name*] +# The name of the init unit for the above. +# Default 'varnish-frontend' +# class role::cache::kafka::eventlogging( -$varnish_name = $::hostname, -$varnish_svc_name = 'varnish', +$varnish_name = 'frontend', +$varnish_svc_name = 'varnish-frontend' ) inherits role::cache::kafka { # Set varnish.arg.q or varnish.arg.m according to Varnish version diff --git a/modules/role/manifests/cache/kafka/statsv.pp b/modules/role/manifests/cache/kafka/statsv.pp index 29f3e44..1ceb76d 100644 --- a/modules/role/manifests/cache/kafka/statsv.pp +++ b/modules/role/manifests/cache/kafka/statsv.pp @@ -1,16 +1,22 @@ -# == Class role::cache::kafka::statsv +# === Define role::cache::kafka::statsv +# # Sets up a varnishkafka logging endpoint for collecting # application level metrics. We are calling this system # statsv, as it is similar to statsd, but uses varnish # as its logging endpoint. # -# == Parameters -# $varnish_name - the name of the varnish instance to read shared logs from. Default $::hostname -# $varnish_svc_name - the name of the varnish init service to read shared logs from. Default 'varnish' +# === Parameters +# +# [*varnish_name*] +# The name of the varnish instance to read shared logs from. +# Default 'frontend' +# [*varnish_svc_name*] +# The name of the init unit for the above. +# Default 'varnish-frontend' # class role::cache::kafka::statsv( -$varnish_name = $::hostname, -$varnish_svc_name = 'varnish', +$varnish_name = 'frontend', +$varnish_svc_name = 'varnish-frontend' ) inherits role::cache::kafka { $format = "%{fake_tag0@hostname?${::fqdn}}x %{%FT%T@dt}t %{X-Client-IP@ip}o %{@uri_path}U %{@uri_query}q %{User-Agent@user_agent}i" diff --git a/modules/role/manifests/cache/kafka/webrequest.pp b/modules/role/manifests/cache/kafka/webrequest.pp index 4ea2ced..0d6841f 100644 --- a/modules/role/manifests/cache/kafka/webrequest.pp +++ b/modules/role/manifests/cache/kafka/webrequest.pp @@ -1,11 +1,18 @@ -# == Class role::cache::kafka::webrequest +# === Define role::cache::kafka::webrequest +# # Sets up a varnishkafka instance producing varnish # webrequest logs to the analytics Kafka brokers in eqiad. # -# == Parameters -# $topic- the name of kafka topic to which to send messages -# $varnish_name - the name of the varnish instance to read shared logs from. Default 'frontend' -# $varnish_svc_name - the name of the init unit for the above, default 'varnish-frontend' +# === Parameters +# +# [*topic*] +# the name of kafka topic to which to send messages. +# [*varnish_name*] +# The name of the varnish instance to read shared logs from. +# Default 'frontend' +# [*varnish_svc_name*] +# The name of the init unit for the above. +# Default 'varnish-frontend' # class role::cache::kafka::webrequest( $topic, -- To view, visit https://gerrit.wikimedia.org/r/326904 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3ebf095c2d77dbad4541e6a2808baf345454e561 Gerrit-PatchSet: 1 Gerrit-Project: operations/puppet Gerrit-Branch: production Gerrit-Owner: Elukey ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikim
[MediaWiki-commits] [Gerrit] research/recommendation-api[master]: Use related-articles in translation recommendation
Nschaaf has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326903 ) Change subject: Use related-articles in translation recommendation .. Use related-articles in translation recommendation Bug: T151793 Change-Id: Iff6b932606cebb7fc239fdb1d64703525069c782 --- M recommendation/api/external_data/fetcher.py M recommendation/api/external_data/wikidata.py M recommendation/api/types/translation/candidate_finders.py M recommendation/api/types/translation/translation.py M recommendation/data/labs_setup.sh 5 files changed, 35 insertions(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/research/recommendation-api refs/changes/03/326903/1 diff --git a/recommendation/api/external_data/fetcher.py b/recommendation/api/external_data/fetcher.py index 76e8b6b..6d6fdf7 100644 --- a/recommendation/api/external_data/fetcher.py +++ b/recommendation/api/external_data/fetcher.py @@ -108,3 +108,8 @@ seed = 'morelike:' + seed params['srsearch'] = seed return endpoint, params + + +def get_related_articles(source, seed): +return get('http://recommend-related-articles.wmflabs.org/types/related_articles/v1/articles', + dict(source=source, seed=seed, count=500)) diff --git a/recommendation/api/external_data/wikidata.py b/recommendation/api/external_data/wikidata.py index 82f7178..7359fbc 100644 --- a/recommendation/api/external_data/wikidata.py +++ b/recommendation/api/external_data/wikidata.py @@ -9,11 +9,11 @@ WikidataItem = collections.namedtuple('WikidataItem', ['id', 'title', 'url']) -def query(params): +def query(params, expected_sitelinks=1): """ Query the wikidata endpoint and return a list of WikidataItem - This only includes items that have exactly 1 sitelink + This only includes items that have exactly expected_sitelinks sitelink """ endpoint = configuration.get_config_value('endpoints', 'wikidata') try: @@ -28,7 +28,7 @@ for id, entity in entities.items(): sitelinks = entity.get('sitelinks', {}) -if len(sitelinks.keys()) != 1: +if len(sitelinks.keys()) != expected_sitelinks: continue sitelink = sitelinks.popitem()[1] @@ -43,7 +43,12 @@ def get_items_in_source_missing_in_target_by_titles(source, target, titles): params = configuration.get_config_dict('wikidata_titles_to_items_params') params['sites'] = params['sites'].format(source=source) +# We want the sitefilter to include both the source and target +# wikis. This sets up the scenario where if there is only 1 sitelink +# present, that means that the article is missing in the target (since +# the title will have come from the source wiki) params['sitefilter'] = params['sitefilter'].format(target=target) +params['sitefilter'] += '|{}wiki'.format(source) params['titles'] = '|'.join(titles) items = query(params) diff --git a/recommendation/api/types/translation/candidate_finders.py b/recommendation/api/types/translation/candidate_finders.py index 70ae772..ba73bf2 100644 --- a/recommendation/api/types/translation/candidate_finders.py +++ b/recommendation/api/types/translation/candidate_finders.py @@ -112,3 +112,19 @@ articles.append(a) return articles[:n] + + +class RelatedArticleFinder(CandidateFinder): +def get_candidates(self, s, seed, n): +results = fetcher.get_related_articles(s, seed) +if len(results) == 0: +return MorelikeCandidateFinder().get_candidates(s, seed, n) + +articles = [] +for item in results: +a = Article(item['title']) +a.wikidata_id = item['wikidata_id'] +a.rank = item['score'] +articles.append(a) + +return articles[:n] diff --git a/recommendation/api/types/translation/translation.py b/recommendation/api/types/translation/translation.py index d271c50..f22a880 100644 --- a/recommendation/api/types/translation/translation.py +++ b/recommendation/api/types/translation/translation.py @@ -166,6 +166,7 @@ 'morelike': candidate_finders.MorelikeCandidateFinder(), 'wiki': candidate_finders.MorelikeCandidateFinder(), 'mostpopular': candidate_finders.PageviewCandidateFinder(), +'related_articles': candidate_finders.RelatedArticleFinder() } diff --git a/recommendation/data/labs_setup.sh b/recommendation/data/labs_setup.sh index 8290c97..228241d 100755 --- a/recommendation/data/labs_setup.sh +++ b/recommendation/data/labs_setup.sh @@ -8,6 +8,10 @@ apt-get install -y git nginx npm python3 python3-pip pip3 install --upgrade pip +# Need to add uwsgi to the wheels +apt-get install -y build-essential python3-dev +pip3 install uwsgi + rm -rf ${TMP_PATH} mkdir -p ${TMP_PATH} mkdir -p ${SRV_PATH}/resources @@ -31,7 +35,7 @@ cp ${TMP_PATH}/recommendation-api/recommendation/data/* ${ETC_PATH} cp ${ETC_PATH}/recommendation.nginx /e
[MediaWiki-commits] [Gerrit] mediawiki...BlogPage[master]: Special:ArticleLists: Allow to add custom text under (t...
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326836 ) Change subject: Special:ArticleLists: Allow to add custom text under (this is supported by all other special pages). .. Special:ArticleLists: Allow to add custom text under (this is supported by all other special pages). See SpecialPage::outputHeader(). ArticleLists doesn't use call parent::execute() (probably to avoid adding noindex), so this was skipped. Reason for change: it makes sence to add a short description on the top of the blog. Change-Id: Idd16fd2f587ea98316aa96fefd40977c627bcccd --- M SpecialArticleLists.php 1 file changed, 8 insertions(+), 1 deletion(-) Approvals: Jack Phoenix: Looks good to me, approved jenkins-bot: Verified diff --git a/SpecialArticleLists.php b/SpecialArticleLists.php index a82929b..cffe104 100644 --- a/SpecialArticleLists.php +++ b/SpecialArticleLists.php @@ -42,6 +42,13 @@ $output = ''; if ( !$this->including() ) { $output .= '' . $this->msg( 'ah-new-articles' )->escaped() . ''; + + $descMsg = $this->msg( 'ah-new-articles-summary' ); + if ( !$descMsg->isDisabled() ) { + $output .= Xml::tags('div', array( + 'class' => 'mw-specialpage-summary' + ), $descMsg->parse() ); + } } // Try cache first @@ -130,4 +137,4 @@ $out->addHTML( $output ); } -} \ No newline at end of file +} -- To view, visit https://gerrit.wikimedia.org/r/326836 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Idd16fd2f587ea98316aa96fefd40977c627bcccd Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/BlogPage Gerrit-Branch: master Gerrit-Owner: Edward Chernenko Gerrit-Reviewer: Jack Phoenix Gerrit-Reviewer: jenkins-bot <> ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] translatewiki[master]: oregano: fix a bug found by shellcheck
Nikerabbit has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326902 ) Change subject: oregano: fix a bug found by shellcheck .. oregano: fix a bug found by shellcheck We do check for workdir, but we failed to stop processing due to use of incorrect variable, resulting bogus directories being created. Change-Id: If27e053f8a2a8bca6b5ce8d893c4cb88fa4fc31d --- M bin/oregano 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/translatewiki refs/changes/02/326902/1 diff --git a/bin/oregano b/bin/oregano index 3f33d0b..0b36190 100755 --- a/bin/oregano +++ b/bin/oregano @@ -12,7 +12,7 @@ COMMAND="" fi -case $1 in +case $COMMAND in deploy) mkdir -p targets tags -- To view, visit https://gerrit.wikimedia.org/r/326902 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: If27e053f8a2a8bca6b5ce8d893c4cb88fa4fc31d Gerrit-PatchSet: 1 Gerrit-Project: translatewiki Gerrit-Branch: master Gerrit-Owner: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] translatewiki[master]: repoupdate: Fix issues found by shellcheck
Nikerabbit has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326901 ) Change subject: repoupdate: Fix issues found by shellcheck .. repoupdate: Fix issues found by shellcheck * Add some quoting * Use $() instead of `` * Use $* instead of $@ * Guard against 'cd' failures * Remove unused variable WIKI * Remove unnecessary use of echo In addition: * Fixed a bug in doUpdate that prevented potlatch2 being updated * Use checkVar for remaining variable checks Change-Id: I5cbcfd40e04e95d8a7cd80ef969288c666c41882 --- M bin/repoupdate 1 file changed, 16 insertions(+), 31 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/translatewiki refs/changes/01/326901/1 diff --git a/bin/repoupdate b/bin/repoupdate index 1fb6d30..c93ec96 100755 --- a/bin/repoupdate +++ b/bin/repoupdate @@ -1,17 +1,16 @@ #!/bin/bash set -u -DIRSCRIPT="`dirname \"$0\"`" -DIRSCRIPT="`( cd \"$DIRSCRIPT\" && pwd )`" +DIRSCRIPT=$(dirname "$0") +DIRSCRIPT=$(cd "$DIRSCRIPT" && pwd) DIRLOG=/home/betawiki/logs/repo PROJECT=$1 -WIKI=/srv/mediawiki/targets/production -DIR="${2:-`pwd`}" -source $DIRSCRIPT/findexportroot -cd "$DIR" +DIR=${2:-$(pwd)} +source "$DIRSCRIPT/findexportroot" +cd "$DIR" || exit -echo "$(date --rfc-3339=seconds --utc) [$(whoami) at $DIR] $0 $@" >> $DIRLOG +echo "$(date --rfc-3339=seconds --utc) [$(whoami) at $DIR] $0 $*" >> $DIRLOG checkVar() { if [ -z "${!1:-}" ] @@ -26,7 +25,6 @@ VAR="REPO_$VAR" checkVar "$VAR" "$2" "${!VAR}" "$DIR/$1" "${3:-}" - exit 0 } # Ignore subrepos like Collection/OfflineContentGenerator @@ -79,17 +77,13 @@ if [ "$PROJECT" = "fudforum" ] then - svn up -q $PROJECT + svn up -q "$PROJECT" elif [ "$PROJECT" = "ihris" ] then - cd $PROJECT + cd "$PROJECT" || exit for MODULE in $REPO_IHRIS_MODULES - do - cd $MODULE - bzr pull -q - cd .. - done + do ( cd "$MODULE" && bzr pull -q ) done elif [ "$PROJECT" = "mifos" ] then @@ -97,34 +91,25 @@ elif [ "$PROJECT" = "mediawiki" ] then - if [ -z "$REPO_MEDIAWIKI_BRANCHES" ] - then echo "Add REPO_MEDIAWIKI_BRANCHES to REPOCONF"; exit 1 - fi - + checkVar 'REPO_MEDIAWIKI_BRANCHES' echo "$REPO_MEDIAWIKI_BRANCHES" | tr ' ' '\n' | xargs -P4 -I___ "$CLUPDATE_GERRIT" "$REPO_MEDIAWIKI" "$DIR/$PROJECT/___" "___" elif [ "$PROJECT" = "mediawiki-extensions" ] then - if [ -z "$REPO_MWEXTGIT" ] - then echo "Add REPO_MWEXTGIT to REPOCONF"; exit 1 - fi - - echo "$(fetchReposFromGerrit mediawiki/extensions/)" | + checkVar 'REPO_MWEXTGIT' + fetchReposFromGerrit mediawiki/extensions/ | xargs -P4 -I___ "$CLUPDATE_GERRIT" "$REPO_MWEXTGIT/___.git" "$DIR/$PROJECT/extensions/___" elif [ "$PROJECT" = "mediawiki-skins" ] then - if [ -z "$REPO_MWSKINGIT" ] - then echo "Add REPO_MWSKINGIT to REPOCONF"; exit 1 - fi - - echo "$(fetchReposFromGerrit mediawiki/skins/)" | + checkVar 'REPO_MWSKINGIT' + fetchReposFromGerrit mediawiki/skins/ | xargs -P4 -I___ "$CLUPDATE_GERRIT" "$REPO_MWSKINGIT/___.git" "$DIR/$PROJECT/___" elif [ "$PROJECT" = "nocc" ] then - svn up -q $PROJECT + svn up -q "$PROJECT" elif [ "$PROJECT" = "osm" ] then @@ -132,6 +117,6 @@ doUpdate "potlatch2" "$CLUPDATE" else - echo "`basename $0`: Unknown project" + echo "$(basename "$0"): Unknown project" exit 1 fi -- To view, visit https://gerrit.wikimedia.org/r/326901 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I5cbcfd40e04e95d8a7cd80ef969288c666c41882 Gerrit-PatchSet: 1 Gerrit-Project: translatewiki Gerrit-Branch: master Gerrit-Owner: Nikerabbit ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] mediawiki...ContentTranslation[master]: Temporarily disable template, category related tests
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326893 ) Change subject: Temporarily disable template, category related tests .. Temporarily disable template, category related tests They need to better rewritten for the recent rewrite and template editor changes using mock data. Bug: T153038 Change-Id: I7831a8b701a557c1aa73b6efc48b17ebc78e020f --- M ContentTranslation.hooks.php 1 file changed, 3 insertions(+), 2 deletions(-) Approvals: jenkins-bot: Verified Nikerabbit: Looks good to me, approved diff --git a/ContentTranslation.hooks.php b/ContentTranslation.hooks.php index bb7a231..b740ce8 100644 --- a/ContentTranslation.hooks.php +++ b/ContentTranslation.hooks.php @@ -373,9 +373,10 @@ $modules['qunit']['ext.cx.tools.tests'] = [ 'scripts' => [ - 'tests/qunit/tools/ext.cx.tools.template.test.js', + // TODO: Following commented tests need to better rewritten using mockdata. + // 'tests/qunit/tools/ext.cx.tools.template.test.js', 'tests/qunit/tools/ext.cx.tools.mtabuse.test.js', - 'tests/qunit/tools/ext.cx.tools.categories.test.js', + // 'tests/qunit/tools/ext.cx.tools.categories.test.js', ], 'dependencies' => [ 'ext.cx.model', -- To view, visit https://gerrit.wikimedia.org/r/326893 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I7831a8b701a557c1aa73b6efc48b17ebc78e020f Gerrit-PatchSet: 4 Gerrit-Project: mediawiki/extensions/ContentTranslation Gerrit-Branch: master Gerrit-Owner: Santhosh Gerrit-Reviewer: Nikerabbit Gerrit-Reviewer: jenkins-bot <> ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: Revert "mariadb: Depool db1051 for schema change"
Hello Marostegui, Florianschmidtwelzow, jenkins-bot, I'd like you to do a code review. Please visit https://gerrit.wikimedia.org/r/326900 to review the following change. Change subject: Revert "mariadb: Depool db1051 for schema change" .. Revert "mariadb: Depool db1051 for schema change" This reverts commit 6b2a057c74d05cdf9a945b6b8d2d450fac2fd5c3. Change-Id: Ic3a68e7d0c566037c03b3d208edd7109a7b8ef0d --- M wmf-config/db-eqiad.php 1 file changed, 6 insertions(+), 6 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config refs/changes/00/326900/1 diff --git a/wmf-config/db-eqiad.php b/wmf-config/db-eqiad.php index f945d08..c9d6a52 100644 --- a/wmf-config/db-eqiad.php +++ b/wmf-config/db-eqiad.php @@ -95,7 +95,7 @@ 's1' => [ 'db1057' => 0, # 2.8TB 96GB, master # 'db1052' => 1 , # 2.8TB 96GB, api, old master #Temporary master for db1095 - new sanitarium #T150960 -# 'db1051' => 50, # 2.8TB 96GB, watchlist, recentchanges, contributions, logpager - down for maintenance T69223 + 'db1051' => 50, # 2.8TB 96GB, watchlist, recentchanges, contributions, logpager 'db1055' => 50, # 2.8TB 96GB, watchlist, recentchanges, contributions, logpager 'db1065' => 50, # 2.8TB 160GB, api 'db1066' => 50, # 2.8TB 160GB, api @@ -238,23 +238,23 @@ 'groupLoadsBySection' => [ 's1' => [ 'watchlist' => [ -# 'db1051' => 1, + 'db1051' => 1, 'db1055' => 1, ], 'recentchanges' => [ -# 'db1051' => 1, + 'db1051' => 1, 'db1055' => 1, ], 'recentchangeslinked' => [ -# 'db1051' => 1, + 'db1051' => 1, 'db1055' => 1, ], 'contributions' => [ -# 'db1051' => 1, + 'db1051' => 1, 'db1055' => 1, ], 'logpager' => [ -# 'db1051' => 1, + 'db1051' => 1, 'db1055' => 1, ], 'dump' => [ -- To view, visit https://gerrit.wikimedia.org/r/326900 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic3a68e7d0c566037c03b3d208edd7109a7b8ef0d Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Jcrespo Gerrit-Reviewer: Florianschmidtwelzow Gerrit-Reviewer: Marostegui Gerrit-Reviewer: jenkins-bot <> ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] mediawiki...BlueSpiceExtensions[REL1_27]: BSReview: Fixed bug where only a review on the mainpage coul...
Pwirth has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326899 ) Change subject: BSReview: Fixed bug where only a review on the mainpage could be edited .. BSReview: Fixed bug where only a review on the mainpage could be edited => Manually cherry-picked I3aebed37d1e8d5a7f0426e4e4f5b278acbc96466 because of an unknowen error: org.eclipse.jgit.errors.MissingObjectException: Missing unknown a177cdabc7e83c30b71786f19e42055db873cfda Change-Id: I8e0198fe134fcd7940fadf9eba9f3cad738da743 --- M Review/includes/ReviewProcess.class.php 1 file changed, 5 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceExtensions refs/changes/99/326899/1 diff --git a/Review/includes/ReviewProcess.class.php b/Review/includes/ReviewProcess.class.php index 164103a..e7eea3f 100644 --- a/Review/includes/ReviewProcess.class.php +++ b/Review/includes/ReviewProcess.class.php @@ -315,7 +315,11 @@ if (!$update) { $dbw->insert('bs_review', $data); } else { - $dbw->update('bs_review', $data, array('rev_pid = ' . $update)); + $dbw->update( + 'bs_review', + $data, + array( "rev_pid = $this->pid" ) + ); } // Get Review-ID -- To view, visit https://gerrit.wikimedia.org/r/326899 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8e0198fe134fcd7940fadf9eba9f3cad738da743 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/BlueSpiceExtensions Gerrit-Branch: REL1_27 Gerrit-Owner: Pwirth ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: mariadb: Depool db1051 for schema change
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326493 ) Change subject: mariadb: Depool db1051 for schema change .. mariadb: Depool db1051 for schema change Bug: T69223 Change-Id: I7f95ead08cb663dcb775a23518ef9954c5c84a92 --- M wmf-config/db-eqiad.php 1 file changed, 6 insertions(+), 6 deletions(-) Approvals: Marostegui: Looks good to me, but someone else must approve jenkins-bot: Verified Jcrespo: Looks good to me, approved diff --git a/wmf-config/db-eqiad.php b/wmf-config/db-eqiad.php index c9d6a52..f945d08 100644 --- a/wmf-config/db-eqiad.php +++ b/wmf-config/db-eqiad.php @@ -95,7 +95,7 @@ 's1' => [ 'db1057' => 0, # 2.8TB 96GB, master # 'db1052' => 1 , # 2.8TB 96GB, api, old master #Temporary master for db1095 - new sanitarium #T150960 - 'db1051' => 50, # 2.8TB 96GB, watchlist, recentchanges, contributions, logpager +# 'db1051' => 50, # 2.8TB 96GB, watchlist, recentchanges, contributions, logpager - down for maintenance T69223 'db1055' => 50, # 2.8TB 96GB, watchlist, recentchanges, contributions, logpager 'db1065' => 50, # 2.8TB 160GB, api 'db1066' => 50, # 2.8TB 160GB, api @@ -238,23 +238,23 @@ 'groupLoadsBySection' => [ 's1' => [ 'watchlist' => [ - 'db1051' => 1, +# 'db1051' => 1, 'db1055' => 1, ], 'recentchanges' => [ - 'db1051' => 1, +# 'db1051' => 1, 'db1055' => 1, ], 'recentchangeslinked' => [ - 'db1051' => 1, +# 'db1051' => 1, 'db1055' => 1, ], 'contributions' => [ - 'db1051' => 1, +# 'db1051' => 1, 'db1055' => 1, ], 'logpager' => [ - 'db1051' => 1, +# 'db1051' => 1, 'db1055' => 1, ], 'dump' => [ -- To view, visit https://gerrit.wikimedia.org/r/326493 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I7f95ead08cb663dcb775a23518ef9954c5c84a92 Gerrit-PatchSet: 3 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Jcrespo Gerrit-Reviewer: Florianschmidtwelzow Gerrit-Reviewer: Jcrespo Gerrit-Reviewer: Marostegui Gerrit-Reviewer: jenkins-bot <> ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: db-codfw.php: Depool db2067
jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/326898 ) Change subject: db-codfw.php: Depool db2067 .. db-codfw.php: Depool db2067 db2067 is going to be used as a clone source for dbstore2001 and needs its replication stopped. Bug: T151552 Change-Id: I607361c5450edf66dbbac67d7dca0df5f92da98c --- M wmf-config/db-codfw.php 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Marostegui: Looks good to me, approved jenkins-bot: Verified diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php index d16a844..468d2eb 100644 --- a/wmf-config/db-codfw.php +++ b/wmf-config/db-codfw.php @@ -140,7 +140,7 @@ 'db2046' => 400, # 2.9TB 160GB 'db2053' => 100, # 2.9TB 160GB, dump (inactive), vslow 'db2060' => 100, # 3.3TB 160GB, api - 'db2067' => 400, # 3.3TB 160GB +# 'db2067' => 400, # 3.3TB 160GB #T151552 ], 's7' => [ 'db2029' => 0, # 2.9TB 96GB, master -- To view, visit https://gerrit.wikimedia.org/r/326898 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I607361c5450edf66dbbac67d7dca0df5f92da98c Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Marostegui Gerrit-Reviewer: Jcrespo Gerrit-Reviewer: Marostegui Gerrit-Reviewer: jenkins-bot <> ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] operations/mediawiki-config[master]: db-codfw.php: Depool db2067
Marostegui has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326898 ) Change subject: db-codfw.php: Depool db2067 .. db-codfw.php: Depool db2067 db2067 is going to be used as a clone source for dbstore2001 and needs its replication stopped. Bug: T151552 Change-Id: I607361c5450edf66dbbac67d7dca0df5f92da98c --- M wmf-config/db-codfw.php 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config refs/changes/98/326898/1 diff --git a/wmf-config/db-codfw.php b/wmf-config/db-codfw.php index d16a844..468d2eb 100644 --- a/wmf-config/db-codfw.php +++ b/wmf-config/db-codfw.php @@ -140,7 +140,7 @@ 'db2046' => 400, # 2.9TB 160GB 'db2053' => 100, # 2.9TB 160GB, dump (inactive), vslow 'db2060' => 100, # 3.3TB 160GB, api - 'db2067' => 400, # 3.3TB 160GB +# 'db2067' => 400, # 3.3TB 160GB #T151552 ], 's7' => [ 'db2029' => 0, # 2.9TB 96GB, master -- To view, visit https://gerrit.wikimedia.org/r/326898 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I607361c5450edf66dbbac67d7dca0df5f92da98c Gerrit-PatchSet: 1 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Marostegui ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] mediawiki...BlueSpiceExtensions[master]: BSReview: Fixed bug where only a review on the mainpage coul...
Pwirth has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/326410 ) Change subject: BSReview: Fixed bug where only a review on the mainpage could be edited .. BSReview: Fixed bug where only a review on the mainpage could be edited => Needs cherry-pick to REL1_27 and REL1_23 Change-Id: I3aebed37d1e8d5a7f0426e4e4f5b278acbc96466 --- M Review/includes/ReviewProcess.class.php 1 file changed, 5 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceExtensions refs/changes/10/326410/1 diff --git a/Review/includes/ReviewProcess.class.php b/Review/includes/ReviewProcess.class.php index 164103a..e7eea3f 100644 --- a/Review/includes/ReviewProcess.class.php +++ b/Review/includes/ReviewProcess.class.php @@ -315,7 +315,11 @@ if (!$update) { $dbw->insert('bs_review', $data); } else { - $dbw->update('bs_review', $data, array('rev_pid = ' . $update)); + $dbw->update( + 'bs_review', + $data, + array( "rev_pid = $this->pid" ) + ); } // Get Review-ID -- To view, visit https://gerrit.wikimedia.org/r/326410 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I3aebed37d1e8d5a7f0426e4e4f5b278acbc96466 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/BlueSpiceExtensions Gerrit-Branch: master Gerrit-Owner: Pwirth ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits