Page MenuHomePhabricator

timestripper fails for vi-wiki
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

pwb timestripper_tests -v TestTimeStripperLanguage.test_timestripper_match_viwiki

What happens?:

tests: max_retries reduced from 15 to 1
test_timestripper_match_viwiki (__main__.TestTimeStripperLanguage.test_timestripper_match_viwiki)
Test that correct date is matched on wikipedia:vi ... FAIL

======================================================================
FAIL: test_timestripper_match_viwiki (__main__.TestTimeStripperLanguage.test_timestripper_match_viwiki)
Test that correct date is matched on wikipedia:vi
----------------------------------------------------------------------
Traceback (most recent call last):
  File "D:\pwb\GIT\core\tests\aspects.py", line 727, in wrapped_method
    func(self, key)
  File "D:\pwb\GIT\core\tests\timestripper_tests.py", line 235, in test_timestripper_match
    self.assertEqual(self.ts.timestripper(txt_match), res)
AssertionError: None != datetime.datetime(2010, 2, 7, 19, 48, tzinfo=TZoneFixedOffset(0, UTC))

----------------------------------------------------------------------
Ran 1 test in 5.899s

FAILED (failures=1)

Software version :
Pywikibot 8.0.0.dev.0

>>> s = pywikibot.Site('vi')
>>> s.version()
'1.40.0-wmf.12'

Other information:
Seems month names was changed:
https://translatewiki.net/w/i.php?title=MediaWiki%3AJanuary%2Fvi&type=revision&diff=11256610&oldid=625944

Event Timeline

Xqt triaged this task as High priority.Dec 2 2022, 7:48 AM

Change 863230 had a related patch set uploaded (by Xqt; author: Xqt):

[pywikibot/core@master] [bugfix] Timestripper find month with first letter uppercase or lowercase

https://gerrit.wikimedia.org/r/863230

Change 863230 merged by jenkins-bot:

[pywikibot/core@master] [bugfix] Timestripper find month with first letter uppercase or lowercase

https://gerrit.wikimedia.org/r/863230

Change 863436 had a related patch set uploaded (by Xqt; author: Xqt):

[pywikibot/core@stable] [7.7.2] Backport T324310 changes to stable

https://gerrit.wikimedia.org/r/863436

Change 863436 merged by jenkins-bot:

[pywikibot/core@stable] [7.7.2] Backport T324310 changes to stable

https://gerrit.wikimedia.org/r/863436

Change 866253 had a related patch set uploaded (by Xqt; author: Xqt):

[pywikibot/core@tests] Backport T324310 changes to tests

https://gerrit.wikimedia.org/r/866253

Change 866253 merged by jenkins-bot:

[pywikibot/core@tests] Backport T324310 changes to tests

https://gerrit.wikimedia.org/r/866253