lists.wikimedia.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
List overview
Download
Pywikibot-commits
April 2022
----- 2024 -----
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
pywikibot-commits@lists.wikimedia.org
1 participants
126 discussions
Start a n
N
ew thread
[Gerrit] ...core[master]: [R1705] remove unecessary "else" after "return"
by jenkins-bot (Code Review)
jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778995
) Change subject: [R1705] remove unecessary "else" after "return" ...................................................................... [R1705] remove unecessary "else" after "return" Change-Id: I29242bb12ac6aa62560ebb79ac7679c1bfacbbd4 --- M scripts/dataextend.py 1 file changed, 69 insertions(+), 67 deletions(-) Approvals: D3r1ck01: Looks good to me, approved jenkins-bot: Verified diff --git a/scripts/dataextend.py b/scripts/dataextend.py index e75aefe..4dce815 100644 --- a/scripts/dataextend.py +++ b/scripts/dataextend.py @@ -1132,8 +1132,8 @@ if self.urlbase4: return [self.urlbase3.format(id=quote(self.id)), self.urlbase4.format(id=quote(self.id))] - else: - return [self.urlbase3.format(id=quote(self.id))] + + return [self.urlbase3.format(id=quote(self.id))] @staticmethod def commastrip(term): @@ -2215,22 +2215,21 @@ if not alt: alt = [] m = re.search(regex, html) - if m: - if dtype: - alt = [dtype] + alt - for alttype in alt: - if self.getdata(alttype, m.group(1), ask=False) and \ - self.getdata(alttype, m.group(1), ask=False) != 'XXX': - return self.getdata(alttype, m.group(1), ask=False) - for skip in skips: - if self.getdata(skip, m.group(1), ask=False) and self.getdata(skip, m.group(1), ask=False) != 'XXX': - return None - if dtype: - return self.getdata(dtype, m.group(1)) - else: - return m.group(1) - else: + if not m: return None + if dtype: + alt = [dtype] + alt + for alttype in alt: + if self.getdata(alttype, m.group(1), ask=False) \ + and self.getdata(alttype, m.group(1), ask=False) != 'XXX': + return self.getdata(alttype, m.group(1), ask=False) + for skip in skips: + if self.getdata(skip, m.group(1), ask=False) \ + and self.getdata(skip, m.group(1), ask=False) != 'XXX': + return None + if dtype: + return self.getdata(dtype, m.group(1)) + return m.group(1) def findallbyre(self, regex, html, dtype=None, skips=None, alt=None) -> list: if not skips: @@ -2601,11 +2600,11 @@ def findvoice(self, html): section = self.findbyre(r'(?s)<strong>Instrumente.*?<td[^<>]*>(.*?)</td>', html) - if section: - if '(' in section: - return self.findbyre(r'(?s)([\s\w]+)\(', section, 'voice') - else: - return self.findbyre(r'(?s)([\s\w]+)', section, 'voice') + if not section: + return None + if '(' in section: + return self.findbyre(r'(?s)([\s\w]+)\(', section, 'voice') + return self.findbyre(r'(?s)([\s\w]+)', section, 'voice') def findlanguagesspoken(self, html): if self.isperson: @@ -2670,9 +2669,10 @@ def findemployers(self, html): section = self.findbyre(r'(?s)<strong>Beziehungen zu Organisationen</strong>.*?(<td.*?</td>)', html) if section: - return self.findallbyre(r'(?s)[>;]([^<>;]*)[<;]', section, 'employer', alt=['university']) - else: - return self.findallbyre(r'Tätig an (?:d\w\w )?([^<>;]*)', html, 'employer', alt=['university']) + return self.findallbyre(r'(?s)[>;]([^<>;]*)[<;]', section, + 'employer', alt=['university']) + return self.findallbyre(r'Tätig an (?:d\w\w )?([^<>;]*)', html, + 'employer', alt=['university']) def findsources(self, html): section = self.findbyre(r'(?s)<strong>Quelle</strong>.*?<td[^<>]*(>.*?<)/td>', html) @@ -2713,9 +2713,12 @@ @property def url(self): if self.isperson: - return '
http://id.loc.gov/authorities/names/{id}.html
'.format(id=self.id) - elif self.id.startswith('s'): - return '
http://id.loc.gov/authorities/subjects/{id}.html
'.format(id=self.id) + return '
http://id.loc.gov/authorities/names/{id}.html
'.format( + id=self.id) + if self.id.startswith('s'): + return '
http://id.loc.gov/authorities/subjects/{id}.html
'.format( + id=self.id) + return None @property def isperson(self): @@ -3159,10 +3162,9 @@ def url(self): if self.isfilm: return '
https://www.imdb.com/title/{id}/
'.format(id=self.id) - elif self.isperson: + if self.isperson: return '
https://www.imdb.com/name/{id}/
'.format(id=self.id) - else: - return None + return None @property def isfilm(self): @@ -3289,13 +3291,13 @@ return self.findbyre(r'(?s)Datazione\s*</td>\s*<td[^<>]*>[^<>]*-(.*?)<', html) def findoccupations(self, html): - section = self.findbyre(r'(?s)Nota informativa.*?detail_value">([^<>]*?)\.', html) - if section: - if ',' in section or ';' in section: - return self.findallbyre(r'([^,;]+)', section, 'occupation') - else: - return self.findallbyre(r'(\w{3,})', section, 'occupation') - return None + section = self.findbyre( + r'(?s)Nota informativa.*?detail_value">([^<>]*?)\.', html) + if not section: + return None + if ',' in section or ';' in section: + return self.findallbyre(r'([^,;]+)', section, 'occupation') + return self.findallbyre(r'(\w{3,})', section, 'occupation') def findbirthplace(self, html): return self.findbyre(r'Nato ad? ([^<>]+) e morto', html, 'city') or \ @@ -3347,15 +3349,14 @@ section = self.findbyre(r'(?s)<dt>Heading:</dt>.*?>([^<>]*)</a', html) if section and 'approx' not in section and 'active' not in section: result = self.findbyre(r',([^,]*)-', section) - if result: - return result - else: - return section + return result if result else section + return None def findbirthplace(self, html): result = self.findbyre(r'(?s)<dt>Birth:</dt>(?:\s|<[^<>]*>)*<li>[^<>]*</li>\s*<li>(.*?)</li>', html) if result: return self.getdata('city', result) + return None def finddeathdate(self, html): result = self.findbyre(r'(?s)<dt>Death:</dt>.*?<li>(.*?)</li>', html) @@ -4376,8 +4377,7 @@ def findinstanceof(self, html): if self.isperson: return 'Q5' - else: - raise NotImplementedError # analysis only made for persons + raise NotImplementedError # analysis only made for persons def findbirthdate(self, html): return self.findbyre(r'</h2>\(([^<>]*?)—', html) @@ -5604,8 +5604,8 @@ section = self.findbyre(r'(?s)Sport:</span>(.*?)(?:<p>|<br>|</div>)', html) if section: return self.findallbyre(r'>([^<>]*)</', section, 'occupation') - else: - return ['Q2066131'] + + return ['Q2066131'] def findparticipations(self, html): section = self.findbyre(r'(?s)(<tbody>.*</tbody>)', html) @@ -5974,11 +5974,13 @@ def findadminloc(self, html): county = self.findbyre(r'>([^<>]+)</A> \(county\)', html) state = self.findbyre(r'>([^<>]+)</A> \(state\)', html) - if state: - if county: - return self.getdata('county', '{} county, {}'.format(county, state)) - else: - return self.getdata('state', state) + if not state: + return None + + if county: + return self.getdata('county', '{} county, {}' + .format(county, state)) + return self.getdata('state', state) def findcoords(self, html): lat = self.findbyre(r'Lat:\s*(-?\d+\.\d+)', html) @@ -6576,15 +6578,15 @@ values = self.getvalues('Place of Birth', html, 'city', link=True) if values: return values[0] - else: - return self.getvalue('Place of Birth', html, 'city') + + return self.getvalue('Place of Birth', html, 'city') def finddeathplace(self, html): values = self.getvalues('Place of Death', html, 'city', link=True) if values: return values[0] - else: - return self.getvalue('Place of Death', html, 'city') + + return self.getvalue('Place of Death', html, 'city') def findoccupations(self, html): sections = self.getvalues('Profession / Occupation', html) + \ @@ -7162,11 +7164,11 @@ def findnames(self, html): result = [self.findbyre(r'<h1[^<>]*>(.*?)<', html)] - section = self.findbyre(r'(?s)<th>Alternativnamn</th>\s*<td>(.*?)</td>', html) + section = self.findbyre( + r'(?s)<th>Alternativnamn</th>\s*<td>(.*?)</td>', html) if section: return result + self.findallbyre(r'>([^<>]+)<', section) - else: - return result + return result def findlongtext(self, html): return self.findbyre(r'(?s)<h3>Beskrivning</h3>(.*?)</div>', html) @@ -7242,9 +7244,9 @@ def findnames(self, html): section = self.findbyre(r'(?s)<dd class="description">(.*?)</dd>', html) if section: - return [self.findbyre(r'<dt class="artist">(.*?)<', html)] + self.findallbyre(r'(\w.+)', section) - else: - return [self.findbyre(r'<dt class="artist">(.*?)<', html)] + return [self.findbyre(r'<dt class="artist">(.*?)<', html)] \ + + self.findallbyre(r'(\w.+)', section) + return [self.findbyre(r'<dt class="artist">(.*?)<', html)] def findnationality(self, html): return self.findbyre(r'(?s)<dd class="lifespan">([^<>]+?),', html, 'country') @@ -10675,7 +10677,7 @@ def findgender(self, html): if 'Antragstellerin<' in html: return 'Q6581072' - elif 'Antragsteller<' in html: + if 'Antragsteller<' in html: return 'Q6581097' def findresidences(self, html): @@ -10790,12 +10792,12 @@ return 'Q5' def findnames(self, html): - result = [self.findbyre(r'<meta name="title" content="(.*?)[\(\|"]', html)] + result = [self.findbyre( + r'<meta name="title" content="(.*?)[\(\|"]', html)] section = self.getvalue('ainm eile', html) if section: return result + self.findallbyre(r'>([^<>]+)</', section) - else: - return result + return result def findbirthdate(self, html): return self.getvalue('dáta breithe', html) or \ @@ -11306,8 +11308,8 @@ for part in parts: result += self.findallbyre(r'([^,;\-\.]*\w)', part, 'subject') return result - else: - return self.findallbyre(r'Spécialité\s*:\s*([^<>]*\w)', html, 'subject') + return self.findallbyre( + r'Spécialité\s*:\s*([^<>]*\w)', html, 'subject') def findmemberships(self, html): return ['Q2124852'] -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778995
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: I29242bb12ac6aa62560ebb79ac7679c1bfacbbd4 Gerrit-Change-Number: 778995 Gerrit-PatchSet: 1 Gerrit-Owner: Xqt <info(a)gno.de> Gerrit-Reviewer: D3r1ck01 <xsavitar.wiki(a)aol.com> Gerrit-Reviewer: jenkins-bot Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...i18n[master]: Localisation updates from https://translatewiki.net.
by jenkins-bot (Code Review)
jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/i18n/+/779002
) Change subject: Localisation updates from
https://translatewiki.net
. ...................................................................... Localisation updates from
https://translatewiki.net
. Change-Id: Iadf6efa0c8919704a22b174863ac8805efccdd8b --- M blockpageschecker/mk.json A delinker/bn.json A delinker/he.json A delinker/mk.json A delinker/pt.json A delinker/te.json 6 files changed, 41 insertions(+), 1 deletion(-) Approvals: L10n-bot: Looks good to me, approved jenkins-bot: Verified diff --git a/blockpageschecker/mk.json b/blockpageschecker/mk.json index d16083b..098e0b3 100644 --- a/blockpageschecker/mk.json +++ b/blockpageschecker/mk.json @@ -6,6 +6,6 @@ ] }, "blockpageschecker-adding": "Бот: Додавам предлошка за заклучена страница", - "blockpageschecker-modifying": "Бот: Изменете ја застарената предлошка", + "blockpageschecker-modifying": "Бот: Измена на застарената предлошка", "blockpageschecker-deleting": "Бот: Брише застарена предлошка" } diff --git a/delinker/bn.json b/delinker/bn.json new file mode 100644 index 0000000..c71d56a --- /dev/null +++ b/delinker/bn.json @@ -0,0 +1,8 @@ +{ + "@metadata": { + "authors": [ + "আফতাবুজ্জামান" + ] + }, + "delinker-delink": "বট: [[%(title)s]] ফাইলটি সরানো হল, কারণ এটি [[:User:%(user)s]] কর্তৃক অপসারিত হয়েছে: ''%(comment)s''।" +} diff --git a/delinker/he.json b/delinker/he.json new file mode 100644 index 0000000..10fb719 --- /dev/null +++ b/delinker/he.json @@ -0,0 +1,8 @@ +{ + "@metadata": { + "authors": [ + "Amire80" + ] + }, + "delinker-delink": "בוט: הקובץ [[%(title)s]] הוסר, כיוון שנמחק על־ידי [[:User:%(user)s]]: ''%(comment)s''." +} diff --git a/delinker/mk.json b/delinker/mk.json new file mode 100644 index 0000000..f386b72 --- /dev/null +++ b/delinker/mk.json @@ -0,0 +1,8 @@ +{ + "@metadata": { + "authors": [ + "Bjankuloski06" + ] + }, + "delinker-delink": "Бот: Податотеката [[%(title)s]] е отстранета бидејќи е избришана од [[:User:%(user)s]]: ''%(comment)s''." +} diff --git a/delinker/pt.json b/delinker/pt.json new file mode 100644 index 0000000..4312bed --- /dev/null +++ b/delinker/pt.json @@ -0,0 +1,8 @@ +{ + "@metadata": { + "authors": [ + "Hamilton Abreu" + ] + }, + "delinker-delink": "Robô: O ficheiro [[%(title)s]] foi removido, porque foi eliminado por [[:User:%(user)s]]: ''%(comment)s''." +} diff --git a/delinker/te.json b/delinker/te.json new file mode 100644 index 0000000..5fdf227 --- /dev/null +++ b/delinker/te.json @@ -0,0 +1,8 @@ +{ + "@metadata": { + "authors": [ + "Chaduvari" + ] + }, + "delinker-delink": "బాట్: దస్త్రాన్ని [[:User:%(user)s]] తొలగించినందున, దాని [[%(title)s]] ను తీసేసాను: ''%(comment)s''." +} -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/i18n/+/779002
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/i18n Gerrit-Branch: master Gerrit-Change-Id: Iadf6efa0c8919704a22b174863ac8805efccdd8b Gerrit-Change-Number: 779002 Gerrit-PatchSet: 1 Gerrit-Owner: L10n-bot <l10n-bot(a)translatewiki.net> Gerrit-Reviewer: L10n-bot <l10n-bot(a)translatewiki.net> Gerrit-Reviewer: jenkins-bot Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...core[master]: [bugfix] Fix XMLDumpPageGenerator usage
by jenkins-bot (Code Review)
jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778690
) Change subject: [bugfix] Fix XMLDumpPageGenerator usage ...................................................................... [bugfix] Fix XMLDumpPageGenerator usage Bug: T305800 Change-Id: I6a13e20e23a9cb478319c73be68d6c169c93a3fb --- M scripts/replace.py 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: Matěj Suchánek: Looks good to me, approved jenkins-bot: Verified diff --git a/scripts/replace.py b/scripts/replace.py index 2410c19..7b748d3 100755 --- a/scripts/replace.py +++ b/scripts/replace.py @@ -1079,7 +1079,7 @@ precompile_exceptions(exceptions, regex, flags) if xmlFilename: - gen = pagegenerators.XmlDumpPageGenerator( + gen = pagegenerators.XMLDumpPageGenerator( xmlFilename, xmlStart, namespaces=genFactory.namespaces, site=site) elif sql_query is not None: # Only -excepttext option is considered by the query. Other -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778690
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: I6a13e20e23a9cb478319c73be68d6c169c93a3fb Gerrit-Change-Number: 778690 Gerrit-PatchSet: 1 Gerrit-Owner: Xqt <info(a)gno.de> Gerrit-Reviewer: D3r1ck01 <xsavitar.wiki(a)aol.com> Gerrit-Reviewer: Matěj Suchánek <matejsuchanek97(a)gmail.com> Gerrit-Reviewer: Udo T. <udo.t(a)gmx.eu> Gerrit-Reviewer: jenkins-bot Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...core[master]: [tests] Don't use werkzeug 2.1
by Xqt (Code Review)
Xqt has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778984
) Change subject: [tests] Don't use werkzeug 2.1 ...................................................................... [tests] Don't use werkzeug 2.1 pytest-httpbin needs httpbin which isn't activly supported. httpbin needs werkzeug but fails with werkzeug 2.1.0 and 2.1.1 force werkzeug <> 2.1 Bug: T305124 Change-Id: Idca235dd8e2ae73e361a691f2f10c23a96495c64 --- M dev-requirements.txt 1 file changed, 2 insertions(+), 2 deletions(-) Approvals: Xqt: Verified; Looks good to me, approved diff --git a/dev-requirements.txt b/dev-requirements.txt index 8002c06..178640e 100644 --- a/dev-requirements.txt +++ b/dev-requirements.txt @@ -11,8 +11,8 @@ pytest-attrib>=0.1.3 # pytest-httpbin needs httpbin needs werkzeug >= 0.14.1 # Python 3.8 needs werkzeug >= 0.15.5 -# httpbin 0.7 fails with werkzeug 2.1.0 (T305124) -werkzeug>=0.15.5,!=2.1.0 +# httpbin 0.7 fails with werkzeug 2.1.0/1 (T305124) +werkzeug>=0.15.5,!=2.1 # T293440: pytest-httpbin needs cffi >=1.0.0 # but Python 3.5 needs cffi < 1.15 which is not taken into account -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778984
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: Idca235dd8e2ae73e361a691f2f10c23a96495c64 Gerrit-Change-Number: 778984 Gerrit-PatchSet: 1 Gerrit-Owner: Xqt <info(a)gno.de> Gerrit-Reviewer: Xqt <info(a)gno.de> Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...core[master]: [tests] add missing flags paths
by Xqt (Code Review)
Xqt has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778777
) Change subject: [tests] add missing flags paths ...................................................................... [tests] add missing flags paths Change-Id: I0b0dd9cb4df2da179538e29d80d9265946bea192 --- M .codecov.yml 1 file changed, 16 insertions(+), 0 deletions(-) Approvals: Xqt: Verified; Looks good to me, approved diff --git a/.codecov.yml b/.codecov.yml index d8eb751..cbebd4c 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -50,3 +50,19 @@ gitter: default: url:
https://webhooks.gitter.im/e/f312b840da1c40d9f4be
+ +flags: + framework: + carryforward: true + paths: + - pywikibot + + tests: + carryforward: true + paths: + - tests + + scripts: + carryforward: true + paths: + - scripts -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778777
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: I0b0dd9cb4df2da179538e29d80d9265946bea192 Gerrit-Change-Number: 778777 Gerrit-PatchSet: 1 Gerrit-Owner: Xqt <info(a)gno.de> Gerrit-Reviewer: Xqt <info(a)gno.de> Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...core[master]: [tests] re-enable flags with codecov.yml
by Xqt (Code Review)
Xqt has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778672
) Change subject: [tests] re-enable flags with codecov.yml ...................................................................... [tests] re-enable flags with codecov.yml This reverts I2a83bc9ed46f195e5d719e6da384566be398d244 Change-Id: Ie88bf9d067aabe00a2264862ed87c91b7ea83323 --- M .codecov.yml 1 file changed, 11 insertions(+), 0 deletions(-) Approvals: Xqt: Verified; Looks good to me, approved diff --git a/.codecov.yml b/.codecov.yml index 8b65567..d8eb751 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -1,5 +1,7 @@ codecov: bot: jayvdb + max_report_age: 48 + strict_yaml_branch: master coverage: round: up @@ -8,6 +10,15 @@ project: default: enabled: yes + framework: + flags: + - framework + tests: + flags: + - tests + scripts: + flags: + - scripts patch: default: enabled: yes -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778672
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: Ie88bf9d067aabe00a2264862ed87c91b7ea83323 Gerrit-Change-Number: 778672 Gerrit-PatchSet: 1 Gerrit-Owner: Xqt <info(a)gno.de> Gerrit-Reviewer: Xqt <info(a)gno.de> Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...core[master]: Revert "[tests] add flags to codecov.yml"
by Xqt (Code Review)
Xqt has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778670
) Change subject: Revert "[tests] add flags to codecov.yml" ...................................................................... Revert "[tests] add flags to codecov.yml" This reverts commit b43a112454dc4a203ed5d20dc70d69693ecb8f6c. Change-Id: I2a83bc9ed46f195e5d719e6da384566be398d244 --- M .codecov.yml 1 file changed, 1 insertion(+), 31 deletions(-) Approvals: Xqt: Verified; Looks good to me, approved diff --git a/.codecov.yml b/.codecov.yml index 44a9e2a..8b65567 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -1,5 +1,5 @@ codecov: - bot: xqt + bot: jayvdb coverage: round: up @@ -8,19 +8,6 @@ project: default: enabled: yes - range: 75..95 - framework: - range: 75..95 - flags: - - framework - tests: - range: 75..95 - flags: - - tests - scripts: - range: 75..95 - flags: - - scripts patch: default: enabled: yes @@ -52,20 +39,3 @@ gitter: default: url:
https://webhooks.gitter.im/e/f312b840da1c40d9f4be
- -flags: - framework: - carryforward: true - paths: - - pywikibot - - tests: - carryforward: true - paths: - - tests - - scripts: - carryforward: true - paths: - - scripts - \ No newline at end of file -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778670
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: I2a83bc9ed46f195e5d719e6da384566be398d244 Gerrit-Change-Number: 778670 Gerrit-PatchSet: 1 Gerrit-Owner: Xqt <info(a)gno.de> Gerrit-Reviewer: Xqt <info(a)gno.de> Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...core[master]: [tests] add flags to codecov.yml
by Xqt (Code Review)
Xqt has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778668
) Change subject: [tests] add flags to codecov.yml ...................................................................... [tests] add flags to codecov.yml Change-Id: Ib004bcab3071f54a6c599903b3934d141413a010 --- M .codecov.yml 1 file changed, 30 insertions(+), 0 deletions(-) Approvals: Xqt: Verified; Looks good to me, approved diff --git a/.codecov.yml b/.codecov.yml index a9c9253..44a9e2a 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -8,6 +8,19 @@ project: default: enabled: yes + range: 75..95 + framework: + range: 75..95 + flags: + - framework + tests: + range: 75..95 + flags: + - tests + scripts: + range: 75..95 + flags: + - scripts patch: default: enabled: yes @@ -39,3 +52,20 @@ gitter: default: url:
https://webhooks.gitter.im/e/f312b840da1c40d9f4be
+ +flags: + framework: + carryforward: true + paths: + - pywikibot + + tests: + carryforward: true + paths: + - tests + + scripts: + carryforward: true + paths: + - scripts + \ No newline at end of file -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778668
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: Ib004bcab3071f54a6c599903b3934d141413a010 Gerrit-Change-Number: 778668 Gerrit-PatchSet: 1 Gerrit-Owner: Xqt <info(a)gno.de> Gerrit-Reviewer: Xqt <info(a)gno.de> Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...core[master]: [L10N] Update languages_by_size
by jenkins-bot (Code Review)
jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778633
) Change subject: [L10N] Update languages_by_size ...................................................................... [L10N] Update languages_by_size Change-Id: Ifdf1762c5f9e5e97b92b1afeaf05da171d279f86 --- M pywikibot/families/wikipedia_family.py M pywikibot/families/wikiquote_family.py M pywikibot/families/wikisource_family.py M pywikibot/families/wiktionary_family.py 4 files changed, 24 insertions(+), 24 deletions(-) Approvals: Meno25: Looks good to me, approved jenkins-bot: Verified diff --git a/pywikibot/families/wikipedia_family.py b/pywikibot/families/wikipedia_family.py index 84c5c91..d32c943 100644 --- a/pywikibot/families/wikipedia_family.py +++ b/pywikibot/families/wikipedia_family.py @@ -27,7 +27,7 @@ languages_by_size = [ 'en', 'ceb', 'de', 'sv', 'fr', 'nl', 'ru', 'es', 'it', 'arz', 'pl', - 'ja', 'vi', 'war', 'zh', 'ar', 'uk', 'pt', 'fa', 'ca', 'sr', 'id', + 'ja', 'vi', 'zh', 'war', 'ar', 'uk', 'pt', 'fa', 'ca', 'sr', 'id', 'ko', 'no', 'fi', 'hu', 'cs', 'tr', 'ce', 'sh', 'zh-min-nan', 'ro', 'tt', 'eu', 'ms', 'eo', 'he', 'hy', 'bg', 'da', 'azb', 'sk', 'kk', 'et', 'min', 'be', 'hr', 'el', 'simple', 'lt', 'az', 'gl', 'sl', 'ur', @@ -37,26 +37,26 @@ 'pms', 'pnb', 'ht', 'su', 'lb', 'ba', 'ga', 'szl', 'is', 'lmo', 'ku', 'cv', 'fy', 'tl', 'wuu', 'an', 'ckb', 'sco', 'diq', 'pa', 'yo', 'ne', 'bar', 'io', 'gu', 'als', 'kn', 'scn', 'bpy', 'ia', 'qu', 'avk', 'mn', - 'nv', 'xmf', 'crh', 'si', 'bat-smg', 'lld', 'or', 'gd', 'frr', 'cdo', - 'os', 'ilo', 'yi', 'sd', 'am', 'ha', 'bug', 'nap', 'sah', 'hsb', 'ps', - 'map-bms', 'fo', 'mai', 'li', 'mzn', 'eml', 'ban', 'gor', 'ace', 'bcl', + 'nv', 'xmf', 'crh', 'si', 'lld', 'bat-smg', 'or', 'gd', 'frr', 'cdo', + 'os', 'ilo', 'yi', 'sd', 'am', 'ha', 'bug', 'nap', 'sah', 'ps', 'hsb', + 'map-bms', 'fo', 'mai', 'li', 'mzn', 'ban', 'eml', 'gor', 'ace', 'bcl', 'sa', 'wa', 'zh-classical', 'lij', 'shn', 'zu', 'mrj', 'mhr', 'as', 'hif', 'mni', 'hyw', 'hak', 'roa-tara', 'km', 'pam', 'ie', 'nso', - 'rue', 'so', 'sn', 'bh', 'se', 'sat', 'vls', 'nds-nl', 'myv', 'mi', - 'nah', 'sc', 'vep', 'gan', 'glk', 'kab', 'tk', 'fiu-vro', 'co', 'bo', - 'ab', 'kv', 'frp', 'csb', 'pcd', 'kw', 'ug', 'gv', 'udm', 'ary', 'ay', + 'rue', 'so', 'sn', 'bh', 'se', 'vls', 'nds-nl', 'myv', 'sat', 'nah', + 'mi', 'sc', 'vep', 'gan', 'kab', 'glk', 'tk', 'fiu-vro', 'co', 'bo', + 'ab', 'frp', 'kv', 'csb', 'pcd', 'kw', 'gv', 'ug', 'udm', 'ary', 'ay', 'nrm', 'zea', 'gn', 'skr', 'mt', 'bjn', 'lez', 'lfn', 'smn', 'stq', - 'lo', 'mwl', 'olo', 'rm', 'fur', 'ig', 'lad', 'gom', 'ang', 'koi', + 'lo', 'mwl', 'olo', 'ig', 'rm', 'fur', 'lad', 'gom', 'ang', 'koi', 'ext', 'tyv', 'dsb', 'dty', 'ln', 'cbk-zam', 'dv', 'rw', 'ksh', 'gag', 'bxr', 'pfl', 'av', 'pag', 'pi', 'haw', 'awa', 'tay', 'pap', 'krc', - 'xal', 'szy', 'za', 'inh', 'kaa', 'pdc', 'atj', 'to', 'arc', 'dag', - 'tpi', 'kbp', 'tw', 'jam', 'na', 'wo', 'mdf', 'kbd', 'tcy', 'nov', - 'nia', 'ki', 'tet', 'lg', 'bi', 'tum', 'jbo', 'roa-rup', 'fj', 'kg', - 'xh', 'lbe', 'ty', 'nqo', 'mnw', 'ks', 'cu', 'shi', 'trv', 'srn', 'om', + 'xal', 'szy', 'inh', 'za', 'kaa', 'pdc', 'atj', 'to', 'tum', 'arc', + 'dag', 'tw', 'tpi', 'kbp', 'jam', 'na', 'wo', 'mdf', 'kbd', 'tcy', + 'nov', 'nia', 'ki', 'tet', 'lg', 'bi', 'jbo', 'roa-rup', 'fj', 'kg', + 'lbe', 'xh', 'ty', 'nqo', 'mnw', 'ks', 'cu', 'shi', 'trv', 'srn', 'om', 'sm', 'gcr', 'alt', 'ltg', 'chr', 'pih', 'ny', 'got', 'mad', 'st', - 'ami', 'kl', 'rmy', 'tn', 'bm', 'ts', 'chy', 've', 'rn', 'iu', 'ak', - 'ss', 'ch', 'pnt', 'guw', 'ady', 'ik', 'ee', 'ff', 'din', 'sg', 'ti', - 'dz', 'pwn', 'cr', + 'ami', 'rmy', 'tn', 'bm', 'ts', 'chy', 've', 'rn', 'guw', 'iu', 'ak', + 'ss', 'ch', 'pnt', 'ady', 'ik', 'ff', 'ee', 'din', 'sg', 'kl', 'pwn', + 'ti', 'dz', 'cr', ] # Sites we want to edit but not count as real languages diff --git a/pywikibot/families/wikiquote_family.py b/pywikibot/families/wikiquote_family.py index 92a6cdb..9116098 100644 --- a/pywikibot/families/wikiquote_family.py +++ b/pywikibot/families/wikiquote_family.py @@ -28,11 +28,11 @@ languages_by_size = [ 'it', 'en', 'pl', 'ru', 'cs', 'et', 'fa', 'pt', 'de', 'uk', 'fr', 'he', - 'es', 'tr', 'sk', 'bs', 'eo', 'ca', 'az', 'fi', 'sl', 'lt', 'zh', 'ar', + 'es', 'tr', 'sk', 'eo', 'bs', 'ca', 'az', 'fi', 'sl', 'lt', 'zh', 'ar', 'bg', 'hy', 'hr', 'el', 'su', 'nn', 'id', 'sv', 'li', 'hu', 'ko', 'nl', 'ja', 'la', 'sah', 'ta', 'sr', 'gu', 'gl', 'ur', 'te', 'be', 'cy', - 'no', 'vi', 'ml', 'sq', 'kn', 'eu', 'ro', 'hi', 'ku', 'uz', 'ka', 'da', - 'th', 'sa', 'is', 'br', 'mr', 'af', 'wo', 'ky', + 'no', 'vi', 'ml', 'sq', 'kn', 'eu', 'hi', 'ro', 'ku', 'uz', 'ka', 'da', + 'sa', 'is', 'th', 'br', 'mr', 'af', 'wo', 'ky', ] category_redirect_templates = { diff --git a/pywikibot/families/wikisource_family.py b/pywikibot/families/wikisource_family.py index 41883ec..cca2b72 100644 --- a/pywikibot/families/wikisource_family.py +++ b/pywikibot/families/wikisource_family.py @@ -30,7 +30,7 @@ 'ta', 'te', 'sl', 'tr', 'hy', 'el', 'la', 'vi', 'ja', 'ro', 'fi', 'nap', 'nl', 'az', 'ca', 'br', 'kn', 'hr', 'no', 'th', 'be', 'hi', 'eo', 'is', 'vec', 'id', 'pms', 'ban', 'da', 'lij', 'et', 'mk', 'yi', - 'mr', 'cy', 'as', 'bg', 'li', 'lt', 'wa', 'pa', 'or', 'jv', 'eu', 'gl', + 'mr', 'cy', 'as', 'bg', 'li', 'lt', 'wa', 'pa', 'jv', 'or', 'eu', 'gl', 'bs', 'sah', 'sk', 'zh-min-nan', 'fo', ] diff --git a/pywikibot/families/wiktionary_family.py b/pywikibot/families/wiktionary_family.py index fc2687d..87c9f8d 100644 --- a/pywikibot/families/wiktionary_family.py +++ b/pywikibot/families/wiktionary_family.py @@ -32,15 +32,15 @@ 'pt', 'kn', 'vi', 'sr', 'th', 'hi', 'ro', 'no', 'et', 'id', 'cs', 'ml', 'my', 'uz', 'li', 'or', 'te', 'eo', 'fa', 'gl', 'ar', 'oc', 'jv', 'skr', 'az', 'eu', 'uk', 'br', 'ast', 'da', 'lo', 'simple', 'is', 'bn', - 'la', 'hr', 'fj', 'tg', 'sk', 'ky', 'wa', 'bg', 'ur', 'ps', 'shn', - 'cy', 'vo', 'sl', 'om', 'he', 'af', 'zh-min-nan', 'scn', 'sg', 'mnw', + 'la', 'hr', 'fj', 'tg', 'sk', 'ky', 'wa', 'bg', 'ur', 'shn', 'ps', + 'cy', 'vo', 'sl', 'om', 'he', 'af', 'zh-min-nan', 'sg', 'scn', 'mnw', 'tl', 'pa', 'sw', 'fy', 'lmo', 'nn', 'ka', 'lv', 'ms', 'min', 'sq', 'nds', 'co', 'mn', 'pnb', 'lb', 'bs', 'nah', 'yue', 'sa', 'kk', 'km', 'diq', 'vec', 'be', 'tk', 'mk', 'sm', 'hsb', 'nia', 'shy', 'ks', 'su', - 'gd', 'ga', 'mr', 'gom', 'an', 'wo', 'mni', 'ia', 'ang', 'mt', 'bcl', + 'gd', 'ga', 'mr', 'gom', 'an', 'wo', 'mni', 'bcl', 'ia', 'ang', 'mt', 'fo', 'sd', 'tt', 'gn', 'so', 'ie', 'csb', 'ug', 'si', 'st', 'roa-rup', - 'tpi', 'kl', 'hif', 'zu', 'mi', 'ay', 'ha', 'jbo', 'yi', 'ln', 'gu', - 'na', 'gv', 'kw', 'am', 'rw', 'ne', 'ts', 'qu', 'iu', 'ss', 'chr', + 'tpi', 'kl', 'hif', 'zu', 'ha', 'mi', 'ay', 'jbo', 'yi', 'ln', 'gu', + 'na', 'gv', 'kw', 'am', 'ne', 'rw', 'ts', 'qu', 'iu', 'ss', 'chr', 'dv', 'ti', 'tn', ] -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778633
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: Ifdf1762c5f9e5e97b92b1afeaf05da171d279f86 Gerrit-Change-Number: 778633 Gerrit-PatchSet: 2 Gerrit-Owner: Meno25 <meno25mail(a)gmail.com> Gerrit-Reviewer: Meno25 <meno25mail(a)gmail.com> Gerrit-Reviewer: jenkins-bot Gerrit-MessageType: merged
2 years
1
0
0
0
[Gerrit] ...core[master]: [tests] enable coverage for script_tests and update codecov.yml
by jenkins-bot (Code Review)
jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778663
) Change subject: [tests] enable coverage for script_tests and update codecov.yml ...................................................................... [tests] enable coverage for script_tests and update codecov.yml Change-Id: I3149d1edde7df06d1a9a82b2a1b828e8b55c0b48 --- M .codecov.yml M tests/script_tests.py 2 files changed, 18 insertions(+), 1 deletion(-) Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified diff --git a/.codecov.yml b/.codecov.yml index 984987a..a9c9253 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -1,7 +1,9 @@ codecov: - bot: jayvdb + bot: xqt coverage: + round: up + range: 75..95 status: project: default: diff --git a/tests/script_tests.py b/tests/script_tests.py index 5669603..2ab29cd 100755 --- a/tests/script_tests.py +++ b/tests/script_tests.py @@ -9,6 +9,7 @@ import sys import unittest from contextlib import suppress +from importlib import import_module from pywikibot.tools import has_module from tests import join_root_path, unittest_print @@ -16,6 +17,7 @@ from tests.utils import execute_pwb +ci_test_run = os.environ.get('PYWIKIBOT_TESTS_RUNNING', '0') == '1' scripts_path = join_root_path('scripts') framework_scripts = ['shell'] @@ -193,6 +195,17 @@ return collector(loader) +def import_script(script_name: str): + """Import script for coverage only (T305795).""" + if not ci_test_run: + return + if script_name in framework_scripts: + prefix = 'pywikibot.scripts.' + else: + prefix = 'scripts.' + import_module(prefix + script_name) + + class TestScriptMeta(MetaTestCaseClass): """Test meta class.""" @@ -307,6 +320,8 @@ arguments = dct['_arguments'] for script_name in script_list: + import_script(script_name) + # force login to be the first, alphabetically, so the login # message does not unexpectedly occur during execution of # another script. -- To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/778663
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Change-Id: I3149d1edde7df06d1a9a82b2a1b828e8b55c0b48 Gerrit-Change-Number: 778663 Gerrit-PatchSet: 2 Gerrit-Owner: Xqt <info(a)gno.de> Gerrit-Reviewer: Xqt <info(a)gno.de> Gerrit-Reviewer: jenkins-bot Gerrit-MessageType: merged
2 years
1
0
0
0
← Newer
1
...
6
7
8
9
10
11
12
13
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
Results per page:
10
25
50
100
200