Issues with tests should be on the pywikibot-tests
<https://phabricator.wikimedia.org/project/view/107/> workboard if they are
known.
Feel free to file tasks or work on them. I was able to reproduce
the make_dist_tests failures but not some of the others.
test_follow_redirects has been around
<https://gerrit.wikimedia.org/r/c/pywikibot/core/+/178789> since 2014 -
something to do with a redirect hack
<https://github.com/wikimedia/pywikibot/commit/35936a7abfdd9531073215994f5376d3ed2004df#diff-ba616a2a9d0b826dbbf9b5141159c0d44a02abe13c74a887acc7cf71781b0f26R217>
.
On Thu, May 11, 2023 at 12:03 PM Roy Smith <roy(a)panix.com> wrote:
I've checked out /pywikibot/core.git. When I run
the tests, I get a
number of failures:
FAILED tests/http_tests.py::TestHttpStatus::test_follow_redirects -
AssertionError: '//en.wikipedia.org/wiki/Main_Page' not found in '
https://en.wikipedia.org/wiki/Main%20Page'
FAILED tests/make_dist_tests.py::TestMakeDist::test_handle_args -
AssertionError:
'/Users/roy/dev/pywikibot/pywikibot-git/tests/make_dist_tests.py' !=
'/Users/roy/dev/pywikibot/venv/bin/pytest'
FAILED tests/make_dist_tests.py::TestMakeDist::test_handle_args_empty -
AssertionError:
'/Users/roy/dev/pywikibot/pywikibot-git/tests/make_dist_tests.py' !=
'/Users/roy/dev/pywikibot/venv/bin/pytest'
FAILED tests/page_tests.py::TestShortLink::test_create_short_link -
pywikibot.exceptions.NoUsernameError: ERROR: username for meta:meta is
undefined.
FAILED tests/script_tests.py::TestScriptSimulate::test_category -
AssertionError: 'Traceback (most recent call last)' unexpectedly found in
'ERROR: An error occurred for uri
https://en.wikipedia.org/w/api.php\nERROR: Traceback (most recent call
last...
FAILED tests/script_tests.py::TestScriptSimulate::test_category_redirect -
AssertionError: 'Traceback (most recent call last)' unexpectedly found in
'Checking hard-redirect category pages.\nERROR: An error occurred for uri
https://en.wikipedia.org/w/api.php\...
FAILED
tests/site_detect_tests.py::MediaWikiSiteTestCase::test_proofreadwiki -
pywikibot.exceptions.ClientError: (403) Request forbidden -- authorization
will not help
I'm trying to get up to speed on the pywikibot project culture. How many
of these are known issues? Are they being worked on? Should I work on
them?
I took a look in more detail at the first one
(TestHttpStatus::test_follow_redirects). I'm not sure what this test is
trying to do. It depends on how the requests library processes redirects
and/or how
en.wikipedia.org responds to escaped spaces in URLs, neither
of which seem like anything that has to do with the pywikibot codebase, so
I don't understand what value this test is adding.
_______________________________________________
pywikibot mailing list -- pywikibot(a)lists.wikimedia.org
Public archives at
https://lists.wikimedia.org/hyperkitty/list/pywikibot@lists.wikimedia.org/m…
To unsubscribe send an email to pywikibot-leave(a)lists.wikimedia.org