___________________ TestFlowLockTopic.test_lock_unlock_topic ___________________
self = <tests.flow_edit_tests.TestFlowLockTopic testMethod=test_lock_unlock_topic>
def test_lock_unlock_topic(self):
"""Lock and unlock a test topic."""
# Setup
topic = Topic(self.site, 'Topic:Sn12rdih4iducjsd')
if topic.is_locked:
> topic.unlock(MODERATION_REASON)
tests/flow_edit_tests.py:191:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pywikibot/flow.py:288: in unlock
self.site.lock_topic(self, False, reason)
pywikibot/site/_decorators.py:93: in callee
return fn(self, *args, **kwargs)
pywikibot/site/_decorators.py:62: in callee
return fn(self, *args, **kwargs)
pywikibot/site/_extensions.py:546: in lock_topic
data = req.submit()
pywikibot/data/api/_requests.py:1059: in submit
if self._internal_api_error(code, error.copy(), result):
pywikibot/data/api/_requests.py:917: in _internal_api_error
self.wait()
pywikibot/data/api/_requests.py:960: in wait
super().wait(delay)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = pywikibot.data.api._requests.Request<wikipedia:test->'/w/api.php?action=flow&page=Topic:Sn12rdih4iducjsd&submodule=loc...reason=Pywikibot+test&cotmoderationState=unlock&maxlag=5&format=json&token=80aa646da02e9ad5da36330d0ea71e33666936fb+\'>
delay = None
def wait(self, delay: int | None = None) -> None:
"""Determine how long to wait after a failed request.
:param delay: Minimum time in seconds to wait. Overwrites
``retry_wait`` variable if given. The delay doubles each
retry until ``retry_max`` seconds is reached.
"""
if not hasattr(self, 'max_retries'):
self.max_retries = pywikibot.config.max_retries
if not hasattr(self, 'retry_wait'):
self.retry_wait = pywikibot.config.retry_wait
if not hasattr(self, 'current_retries'):
self.current_retries = 1
else:
self.current_retries += 1
if self.current_retries > self.max_retries:
raise pywikibot.exceptions.TimeoutError(
> 'Maximum retries attempted without success.')
E pywikibot.exceptions.TimeoutError: Maximum retries attempted without success.
pywikibot/data/__init__.py:48: TimeoutErrorDescription
Description
| Status | Subtype | Assigned | Task | ||
|---|---|---|---|---|---|
| Open | None | T129368 Usages of unittest.expectedFailure or unittest.skip should be solved (goal) | |||
| Open | None | T367260 Write test CI github action has ~ 22 failing tests or errors | |||
| Declined | None | T367301 TestFlowLockTopic.test_lock_unlock_topic() of flow_edit_tests fails with timeout |