Milimetric has submitted this change and it was merged.

Change subject: Disable the deprecated option by_wiki
......................................................................


Disable the deprecated option by_wiki

The previous patch adds a new way of exploding reports with files.
After deploying the previous patch, all repositories that use
exploding by wiki should be updated to use the new way.
And finally, this patch can be merged.

Bug: T132481
Change-Id: Icd2fc80095e1fdebaa0cc04525a77491b8053af0
---
M reportupdater/reader.py
M reportupdater/reportupdater.py
M reportupdater/utils.py
M update_reports.py
D wikis.txt
5 files changed, 2 insertions(+), 876 deletions(-)

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



diff --git a/reportupdater/reader.py b/reportupdater/reader.py
index 0a0d408..b2dc891 100644
--- a/reportupdater/reader.py
+++ b/reportupdater/reader.py
@@ -14,7 +14,7 @@
 import logging
 from datetime import datetime, date
 from report import Report
-from utils import DATE_FORMAT, raise_critical, get_wikis
+from utils import DATE_FORMAT, raise_critical
 
 
 class Reader(object):
@@ -146,8 +146,6 @@
 
     def get_explode_by(self, report_config, query_folder):
         explode_by = {}
-        if 'by_wiki' in report_config and report_config['by_wiki'] is True:
-            explode_by['wiki'] = get_wikis(self.config) + ['all']
         if 'explode_by' in report_config:
             for placeholder, values_str in 
report_config['explode_by'].iteritems():
                 values = [value.strip() for value in values_str.split(',')]
@@ -158,7 +156,7 @@
                             read_values = [v.strip() for v in 
explode_file.readlines()]
                         if (len(read_values) > 0):
                             explode_by[placeholder] = read_values
-                    except IOError, e:
+                    except IOError:
                         explode_by[placeholder] = values
                 elif len(values) > 1:
                     explode_by[placeholder] = values
diff --git a/reportupdater/reportupdater.py b/reportupdater/reportupdater.py
index 8ed5183..e11863c 100644
--- a/reportupdater/reportupdater.py
+++ b/reportupdater/reportupdater.py
@@ -42,7 +42,6 @@
         config['current_exec_time'] = current_exec_time
         config['query_folder'] = params['query_folder']
         config['output_folder'] = params['output_folder']
-        config['wikis_path'] = params['wikis_path']
 
         reader = Reader(config)
         selector = Selector(reader, config)
@@ -63,7 +62,6 @@
         'pid_file_path': os.path.join(query_folder, '.reportupdater.pid'),
         'config_path': os.path.join(query_folder, 'config.yaml'),
         'output_folder': os.path.join(project_root, 'output'),
-        'wikis_path': os.path.join(project_root, 'wikis.txt'),
         'log_level': logging.WARNING
     }
     passed_params = {k: v for k, v in passed_params.iteritems() if v is not 
None}
diff --git a/reportupdater/utils.py b/reportupdater/utils.py
index 032a74a..d894717 100644
--- a/reportupdater/utils.py
+++ b/reportupdater/utils.py
@@ -64,20 +64,6 @@
     return previous_results
 
 
-def get_wikis(config):
-    if 'wikis_path' not in config:
-        raise_critical(KeyError, 'Wikis path is not in config.')
-    try:
-        wikis_file = io.open(config['wikis_path'], 'r')
-    except Exception, e:
-        raise_critical(RuntimeError, 'Could not open the wikis file (' + 
str(e) + ').')
-    wikis = []
-    for wiki in wikis_file:
-        wikis.append(wiki.strip())
-    wikis_file.close()
-    return wikis
-
-
 def get_exploded_report_output_path(output_folder, explode_by, report_key):
     output_folder = os.path.join(output_folder, report_key)
     placeholders = sorted(explode_by.keys())
diff --git a/update_reports.py b/update_reports.py
index 20dd7a1..45e33c5 100755
--- a/update_reports.py
+++ b/update_reports.py
@@ -24,8 +24,6 @@
                         help='Folder to write the TSV files to.')
     parser.add_argument('--config-path',
                         help='Yaml configuration file. Default: 
<query_folder>/config.yaml.')
-    parser.add_argument('--wikis_path',
-                        help='All wikis list file path. Default: wikis.txt.')
     parser.add_argument('-l', '--log-level',
                         help='(debug|info|warning|error|critical)')
     args = vars(parser.parse_args())
diff --git a/wikis.txt b/wikis.txt
deleted file mode 100644
index d2c30cc..0000000
--- a/wikis.txt
+++ /dev/null
@@ -1,854 +0,0 @@
-aawiki
-aawikibooks
-aawiktionary
-abwiki
-abwiktionary
-acewiki
-advisorywiki
-adywiki
-afwiki
-afwikibooks
-afwikiquote
-afwiktionary
-akwiki
-akwikibooks
-akwiktionary
-alswiki
-alswikibooks
-alswikiquote
-alswiktionary
-amwiki
-amwikiquote
-amwiktionary
-angwiki
-angwikibooks
-angwikiquote
-angwikisource
-angwiktionary
-anwiki
-anwiktionary
-arcwiki
-arwiki
-arwikibooks
-arwikimedia
-arwikinews
-arwikiquote
-arwikisource
-arwikiversity
-arwiktionary
-arzwiki
-astwiki
-astwikibooks
-astwikiquote
-astwiktionary
-aswiki
-aswikibooks
-aswikisource
-aswiktionary
-avwiki
-avwiktionary
-aywiki
-aywikibooks
-aywiktionary
-azwiki
-azwikibooks
-azwikiquote
-azwikisource
-azwiktionary
-barwiki
-bat_smgwiki
-bawiki
-bawikibooks
-bclwiki
-bdwikimedia
-be_x_oldwiki
-betawikiversity
-bewiki
-bewikibooks
-bewikimedia
-bewikiquote
-bewikisource
-bewiktionary
-bgwiki
-bgwikibooks
-bgwikinews
-bgwikiquote
-bgwikisource
-bgwiktionary
-bhwiki
-bhwiktionary
-biwiki
-biwikibooks
-biwiktionary
-bjnwiki
-bmwiki
-bmwikibooks
-bmwikiquote
-bmwiktionary
-bnwiki
-bnwikibooks
-bnwikisource
-bnwiktionary
-bowiki
-bowikibooks
-bowiktionary
-bpywiki
-brwiki
-brwikimedia
-brwikiquote
-brwikisource
-brwiktionary
-bswiki
-bswikibooks
-bswikinews
-bswikiquote
-bswikisource
-bswiktionary
-bugwiki
-bxrwiki
-cawiki
-cawikibooks
-cawikinews
-cawikiquote
-cawikisource
-cawiktionary
-cbk_zamwiki
-cdowiki
-cebwiki
-cewiki
-chowiki
-chrwiki
-chrwiktionary
-chwiki
-chwikibooks
-chwiktionary
-chywiki
-ckbwiki
-commonswiki
-cowiki
-cowikibooks
-cowikimedia
-cowikiquote
-cowiktionary
-crhwiki
-crwiki
-crwikiquote
-crwiktionary
-csbwiki
-csbwiktionary
-cswiki
-cswikibooks
-cswikinews
-cswikiquote
-cswikisource
-cswikiversity
-cswiktionary
-cuwiki
-cvwiki
-cvwikibooks
-cywiki
-cywikibooks
-cywikiquote
-cywikisource
-cywiktionary
-dawiki
-dawikibooks
-dawikiquote
-dawikisource
-dawiktionary
-dewiki
-dewikibooks
-dewikinews
-dewikiquote
-dewikisource
-dewikiversity
-dewikivoyage
-dewiktionary
-diqwiki
-dkwikimedia
-donatewiki
-dsbwiki
-dvwiki
-dvwiktionary
-dzwiki
-dzwiktionary
-eewiki
-elwiki
-elwikibooks
-elwikinews
-elwikiquote
-elwikisource
-elwikiversity
-elwikivoyage
-elwiktionary
-emlwiki
-enwiki
-enwikibooks
-enwikinews
-enwikiquote
-enwikisource
-enwikiversity
-enwikivoyage
-enwiktionary
-eowiki
-eowikibooks
-eowikinews
-eowikiquote
-eowikisource
-eowiktionary
-eswiki
-eswikibooks
-eswikinews
-eswikiquote
-eswikisource
-eswikiversity
-eswikivoyage
-eswiktionary
-etwiki
-etwikibooks
-etwikimedia
-etwikiquote
-etwikisource
-etwiktionary
-euwiki
-euwikibooks
-euwikiquote
-euwiktionary
-extwiki
-fawiki
-fawikibooks
-fawikinews
-fawikiquote
-fawikisource
-fawiktionary
-ffwiki
-fiu_vrowiki
-fiwiki
-fiwikibooks
-fiwikimedia
-fiwikinews
-fiwikiquote
-fiwikisource
-fiwikiversity
-fiwiktionary
-fjwiki
-fjwiktionary
-foundationwiki
-fowiki
-fowikisource
-fowiktionary
-frpwiki
-frrwiki
-frwiki
-frwikibooks
-frwikinews
-frwikiquote
-frwikisource
-frwikiversity
-frwikivoyage
-frwiktionary
-furwiki
-fywiki
-fywikibooks
-fywiktionary
-gagwiki
-ganwiki
-gawiki
-gawikibooks
-gawikiquote
-gawiktionary
-gdwiki
-gdwiktionary
-glkwiki
-glwiki
-glwikibooks
-glwikiquote
-glwikisource
-glwiktionary
-gnwiki
-gnwikibooks
-gnwiktionary
-gotwiki
-gotwikibooks
-guwiki
-guwikibooks
-guwikiquote
-guwikisource
-guwiktionary
-gvwiki
-gvwiktionary
-hakwiki
-hawiki
-hawiktionary
-hawwiki
-hewiki
-hewikibooks
-hewikinews
-hewikiquote
-hewikisource
-hewikivoyage
-hewiktionary
-hifwiki
-hiwiki
-hiwikibooks
-hiwikiquote
-hiwiktionary
-howiki
-hrwiki
-hrwikibooks
-hrwikiquote
-hrwikisource
-hrwiktionary
-hsbwiki
-hsbwiktionary
-htwiki
-htwikisource
-huwiki
-huwikibooks
-huwikinews
-huwikiquote
-huwikisource
-huwiktionary
-hywiki
-hywikibooks
-hywikiquote
-hywikisource
-hywiktionary
-hzwiki
-iawiki
-iawikibooks
-iawiktionary
-idwiki
-idwikibooks
-idwikiquote
-idwikisource
-idwiktionary
-iewiki
-iewikibooks
-iewiktionary
-igwiki
-iiwiki
-ikwiki
-ikwiktionary
-ilowiki
-incubatorwiki
-iowiki
-iowiktionary
-iswiki
-iswikibooks
-iswikiquote
-iswikisource
-iswiktionary
-itwiki
-itwikibooks
-itwikinews
-itwikiquote
-itwikisource
-itwikiversity
-itwikivoyage
-itwiktionary
-iuwiki
-iuwiktionary
-jawiki
-jawikibooks
-jawikinews
-jawikiquote
-jawikisource
-jawikiversity
-jawiktionary
-jbowiki
-jbowiktionary
-jvwiki
-jvwiktionary
-kaawiki
-kabwiki
-kawiki
-kawikibooks
-kawikiquote
-kawiktionary
-kbdwiki
-kgwiki
-kiwiki
-kjwiki
-kkwiki
-kkwikibooks
-kkwikiquote
-kkwiktionary
-klwiki
-klwiktionary
-kmwiki
-kmwikibooks
-kmwiktionary
-knwiki
-knwikibooks
-knwikiquote
-knwikisource
-knwiktionary
-koiwiki
-kowiki
-kowikibooks
-kowikinews
-kowikiquote
-kowikisource
-kowikiversity
-kowiktionary
-krcwiki
-krwiki
-krwikiquote
-kshwiki
-kswiki
-kswikibooks
-kswikiquote
-kswiktionary
-kuwiki
-kuwikibooks
-kuwikiquote
-kuwiktionary
-kvwiki
-kwwiki
-kwwikiquote
-kwwiktionary
-kywiki
-kywikibooks
-kywikiquote
-kywiktionary
-ladwiki
-lawiki
-lawikibooks
-lawikiquote
-lawikisource
-lawiktionary
-lbewiki
-lbwiki
-lbwikibooks
-lbwikiquote
-lbwiktionary
-lezwiki
-lgwiki
-lijwiki
-liwiki
-liwikibooks
-liwikiquote
-liwikisource
-liwiktionary
-lmowiki
-lnwiki
-lnwikibooks
-lnwiktionary
-loginwiki
-lowiki
-lowiktionary
-ltgwiki
-ltwiki
-ltwikibooks
-ltwikiquote
-ltwikisource
-ltwiktionary
-lvwiki
-lvwikibooks
-lvwiktionary
-map_bmswiki
-mdfwiki
-mediawikiwiki
-metawiki
-mgwiki
-mgwikibooks
-mgwiktionary
-mhrwiki
-mhwiki
-mhwiktionary
-minwiki
-miwiki
-miwikibooks
-miwiktionary
-mkwiki
-mkwikibooks
-mkwikimedia
-mkwikisource
-mkwiktionary
-mlwiki
-mlwikibooks
-mlwikiquote
-mlwikisource
-mlwiktionary
-mnwiki
-mnwikibooks
-mnwiktionary
-mowiki
-mowiktionary
-mrjwiki
-mrwiki
-mrwikibooks
-mrwikiquote
-mrwikisource
-mrwiktionary
-mswiki
-mswikibooks
-mswiktionary
-mtwiki
-mtwiktionary
-muswiki
-mwlwiki
-mxwikimedia
-myvwiki
-mywiki
-mywikibooks
-mywiktionary
-mznwiki
-nahwiki
-nahwikibooks
-nahwiktionary
-napwiki
-nawiki
-nawikibooks
-nawikiquote
-nawiktionary
-nds_nlwiki
-ndswiki
-ndswikibooks
-ndswikiquote
-ndswiktionary
-newiki
-newikibooks
-newiktionary
-newwiki
-ngwiki
-nlwiki
-nlwikibooks
-nlwikimedia
-nlwikinews
-nlwikiquote
-nlwikisource
-nlwikivoyage
-nlwiktionary
-nnwiki
-nnwikiquote
-nnwiktionary
-nostalgiawiki
-novwiki
-nowiki
-nowikibooks
-nowikimedia
-nowikinews
-nowikiquote
-nowikisource
-nowiktionary
-nrmwiki
-nsowiki
-nvwiki
-nycwikimedia
-nywiki
-nzwikimedia
-ocwiki
-ocwikibooks
-ocwiktionary
-omwiki
-omwiktionary
-orwiki
-orwiktionary
-oswiki
-outreachwiki
-pa_uswikimedia
-pagwiki
-pamwiki
-papwiki
-pawiki
-pawikibooks
-pawiktionary
-pcdwiki
-pdcwiki
-pflwiki
-pihwiki
-piwiki
-piwiktionary
-plwiki
-plwikibooks
-plwikimedia
-plwikinews
-plwikiquote
-plwikisource
-plwikivoyage
-plwiktionary
-pmswiki
-pnbwiki
-pnbwiktionary
-pntwiki
-pswiki
-pswikibooks
-pswiktionary
-ptwiki
-ptwikibooks
-ptwikinews
-ptwikiquote
-ptwikisource
-ptwikiversity
-ptwikivoyage
-ptwiktionary
-qualitywiki
-quwiki
-quwikibooks
-quwikiquote
-quwiktionary
-rmwiki
-rmwikibooks
-rmwiktionary
-rmywiki
-rnwiki
-rnwiktionary
-roa_rupwiki
-roa_rupwiktionary
-roa_tarawiki
-rowiki
-rowikibooks
-rowikinews
-rowikiquote
-rowikisource
-rowikivoyage
-rowiktionary
-rswikimedia
-ruewiki
-ruwiki
-ruwikibooks
-ruwikimedia
-ruwikinews
-ruwikiquote
-ruwikisource
-ruwikiversity
-ruwikivoyage
-ruwiktionary
-rwwiki
-rwwiktionary
-sahwiki
-sahwikisource
-sawiki
-sawikibooks
-sawikiquote
-sawikisource
-sawiktionary
-scnwiki
-scnwiktionary
-scowiki
-scwiki
-scwiktionary
-sdwiki
-sdwikinews
-sdwiktionary
-sewiki
-sewikibooks
-sewikimedia
-sgwiki
-sgwiktionary
-shwiki
-shwiktionary
-simplewiki
-simplewikibooks
-simplewikiquote
-simplewiktionary
-siwiki
-siwikibooks
-siwiktionary
-skwiki
-skwikibooks
-skwikiquote
-skwikisource
-skwiktionary
-slwiki
-slwikibooks
-slwikiquote
-slwikisource
-slwikiversity
-slwiktionary
-smwiki
-smwiktionary
-snwiki
-snwiktionary
-sourceswiki
-sowiki
-sowiktionary
-specieswiki
-sqwiki
-sqwikibooks
-sqwikinews
-sqwikiquote
-sqwiktionary
-srnwiki
-srwiki
-srwikibooks
-srwikinews
-srwikiquote
-srwikisource
-srwiktionary
-sswiki
-sswiktionary
-stqwiki
-strategywiki
-stwiki
-stwiktionary
-suwiki
-suwikibooks
-suwikiquote
-suwiktionary
-svwiki
-svwikibooks
-svwikinews
-svwikiquote
-svwikisource
-svwikiversity
-svwikivoyage
-svwiktionary
-swwiki
-swwikibooks
-swwiktionary
-szlwiki
-tawiki
-tawikibooks
-tawikinews
-tawikiquote
-tawikisource
-tawiktionary
-tcywiki
-tenwiki
-test2wiki
-testwiki
-testwikidatawiki
-tetwiki
-tewiki
-tewikibooks
-tewikiquote
-tewikisource
-tewiktionary
-tgwiki
-tgwikibooks
-tgwiktionary
-thwiki
-thwikibooks
-thwikinews
-thwikiquote
-thwikisource
-thwiktionary
-tiwiki
-tiwiktionary
-tkwiki
-tkwikibooks
-tkwikiquote
-tkwiktionary
-tlwiki
-tlwikibooks
-tlwiktionary
-tnwiki
-tnwiktionary
-towiki
-towiktionary
-tpiwiki
-tpiwiktionary
-trwiki
-trwikibooks
-trwikimedia
-trwikinews
-trwikiquote
-trwikisource
-trwiktionary
-tswiki
-tswiktionary
-ttwiki
-ttwikibooks
-ttwikiquote
-ttwiktionary
-tumwiki
-twwiki
-twwiktionary
-tyvwiki
-tywiki
-uawikimedia
-udmwiki
-ugwiki
-ugwikibooks
-ugwikiquote
-ugwiktionary
-ukwiki
-ukwikibooks
-ukwikimedia
-ukwikinews
-ukwikiquote
-ukwikisource
-ukwikivoyage
-ukwiktionary
-urwiki
-urwikibooks
-urwikiquote
-urwiktionary
-usabilitywiki
-uzwiki
-uzwikibooks
-uzwikiquote
-uzwiktionary
-vecwiki
-vecwikisource
-vecwiktionary
-vepwiki
-vewiki
-vewikimedia
-viwiki
-viwikibooks
-viwikiquote
-viwikisource
-viwikivoyage
-viwiktionary
-vlswiki
-votewiki
-vowiki
-vowikibooks
-vowikiquote
-vowiktionary
-warwiki
-wawiki
-wawikibooks
-wawiktionary
-wikidatawiki
-wikimania2005wiki
-wikimania2006wiki
-wikimania2007wiki
-wikimania2008wiki
-wikimania2009wiki
-wikimania2010wiki
-wikimania2011wiki
-wikimania2012wiki
-wikimania2013wiki
-wikimania2014wiki
-wowiki
-wowikiquote
-wowiktionary
-wuuwiki
-xalwiki
-xhwiki
-xhwikibooks
-xhwiktionary
-xmfwiki
-yiwiki
-yiwikisource
-yiwiktionary
-yowiki
-yowikibooks
-yowiktionary
-zawiki
-zawikibooks
-zawikiquote
-zawiktionary
-zeawiki
-zh_classicalwiki
-zh_min_nanwiki
-zh_min_nanwikibooks
-zh_min_nanwikiquote
-zh_min_nanwikisource
-zh_min_nanwiktionary
-zh_yuewiki
-zhwiki
-zhwikibooks
-zhwikinews
-zhwikiquote
-zhwikisource
-zhwikivoyage
-zhwiktionary
-zuwiki
-zuwikibooks
-zuwiktionary

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Icd2fc80095e1fdebaa0cc04525a77491b8053af0
Gerrit-PatchSet: 4
Gerrit-Project: analytics/reportupdater
Gerrit-Branch: master
Gerrit-Owner: Mforns <mfo...@wikimedia.org>
Gerrit-Reviewer: Mforns <mfo...@wikimedia.org>
Gerrit-Reviewer: Milimetric <dandree...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

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

Reply via email to