Page MenuHomePhabricator

pywikibot-core-tox-docker test is failing with flake8 3.7.X
Closed, ResolvedPublic

Event Timeline

Xqt triaged this task as High priority.Jan 30 2019, 8:30 AM

Change 487118 had a related patch set uploaded (by Xqt; owner: Xqt):
[pywikibot/core@master] [tests] Set flake8 release 3.6.0 mandatory

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

Xqt lowered the priority of this task from High to Low.Jan 31 2019, 12:17 AM
This comment was removed by Xqt.
Xqt renamed this task from pywikibot-core-tox-docker test is failing with flake8 3.7.0 and 3.7.1 to pywikibot-core-tox-docker test is failing with flake8 3.7.X.Jan 31 2019, 12:19 AM
Xqt raised the priority of this task from Low to High.

The old problem with 3.7.0-3.7.2 is solved with 3.7.3 which was:
optparse.OptionConflictError: option --per-file-ignores: conflicting option string(s): --per-file-ignores
08:03:40 ERROR: InvocationError: '/src/.tox/flake8/bin/flake8 --version'
08:03:40 pyflakes-py3 create:

But now doctests need 15 minutes and more

But now doctests need 15 minutes and more

If I'm not mistaken, flake8 uses pyflakes for --doctests. My guess is that this is probably a pyflakes problem (flake8 3.7 requires Pyflakes >= 2.1.0, < 2.2.0, while flake8 3.6 used to require Pyflakes >= 2.0.0, < 2.1.0).

Note that, according the log, the test passes eventually, it just takes almost 15 minutes to finish which means the rest of the tests won't have enough time to complete.

I also thought about this but look at this test with flake8 3.7.1:
https://integration.wikimedia.org/ci/job/pywikibot-core-tox-docker/5714/console
be have following log entries:

15:18:25 flake8 runtests: commands[1] | flake8 --version
15:18:25   /src$ /src/.tox/flake8/bin/flake8 --version 
15:18:25 3.7.1 (ProxyChecker: 0.0.1, flake8-comprehensions: 1.4.1, flake8-docstrings: 1.3.0, pydocstyle: 3.0.0, flake8-future-import: 0.4.5, flake8-mock: 0.3, flake8-no-u-prefixed-strings: 0.2, flake8-print: 3.1.0, flake8-string-format: 0.2.3, flake8-tuple: 0.2.13, flake8_coding: 1.3.1, flake8_quotes: 1.0.0, hacking.core: 0.0.1, mccabe: 0.6.1, naming: 0.8.0, pycodestyle: 2.5.0, pyflakes: 2.1.0) CPython 2.7.13 on Linux
15:18:25 flake8 runtests: commands[2] | flake8 --doctests
15:18:25   /src$ /src/.tox/flake8/bin/flake8 --doctests 
15:32:11 pyflakes-py3 create: /src/.tox/pyflakes-py3

which means imho that `flake8 --doctests needs 14 minutes (15:18:25 - 15:32:11) before pyflakes can start and pyflakes-py3 is done at 15:32:27 after few seconds.

Sure we can also increase the test time to 20 minutes or so but 3.6.0 Needs few seconds too and there must be a problem which has to to with flake8 3.7
`

Change 487118 merged by jenkins-bot:
[pywikibot/core@master] [tests] Require flake8 release 3.6.0

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

Xqt lowered the priority of this task from High to Low.Jan 31 2019, 3:25 PM

Lowered prio after patch was merged

This was a problem with python 2.7 and was solved upstream in 3.7.4. Thanks to the flake8 team.

Change 487463 had a related patch set uploaded (by Xqt; owner: Xqt):
[pywikibot/core@master] [tests] Use flake8 release >= 3.7.4

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

Change 487463 merged by jenkins-bot:
[pywikibot/core@master] [tests] Use flake8 release >= 3.7.5

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