sort out pyflakes flake8 pycodestyle pep8
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-init |
Fix Released
|
Undecided
|
Unassigned | ||
curtin |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
I was again bit by this... tox works fine (running flake8)
but built of zesty failed.
In cloud-init, the Makefile that is run during build runs (currently) pep8 and pyflakes (either pyflakes2 or pyflakes3).
I think what we ultimately want is to run flake8 and let it run pyflakes and pep8.
However, given dependencies and versions in different distro releases, this is a bit of a pain.
One path to this is just to not run any code checking in the distro build, assuming that it is already run in trunk. I think that seems like a sane argument actually.
One thing to note, is that pep8 is now called pycodestyle.
Out of this, I'd like to have:
a.) a tox target that tracks upstream pypi versions (but doesn't fail c-i), and somethign that runs this fairly often to at least see how bad we are getting.
b.) a tox target that has pinned versions of checking tools, and runs checks both for python2 and python3.
I've struggled a bit to get all this sorted out in ubuntu-image, but I have a workable solution, at least for X, Y, and Z. I only use flake8, with `sitepackages=True` and a few little tricks and plugins to get it all passing. One other thing I did with pitti before he left was to hook up GH CI to autopkgtest, so the tests are all running on the ubuntu ci machinery, exactly as it would for -proposed promotion. That includes package build times and DEP-8 tests.
Check out ubuntu-image on GH and happy to chat about it more after the holidays. I think it would make a lot of sense, if possible, for these three projects to have some consistent CI set up (although our coding styles may be minorly different).