Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MAINT] Improve reporting of failed flake8 errors in test workflow #454

Open
rbavery opened this issue Mar 15, 2022 · 0 comments
Open

[MAINT] Improve reporting of failed flake8 errors in test workflow #454

rbavery opened this issue Mar 15, 2022 · 0 comments

Comments

@rbavery
Copy link
Contributor

rbavery commented Mar 15, 2022

Maintenance request summary

When flake8 fails during the tox -e lint step, an unintuitive error message shows up in the action logs

tox -e lintroot@rave-desktop:/home/rave/solaris# tox -e lint
lint installed: flake8==4.0.1,mccabe==0.6.1,pycodestyle==2.8.0,pyflakes==2.4.0
lint run-test-pre: PYTHONHASHSEED='657686712'
lint run-test: commands[0] | flake8 .
./solaris/__init__.py:1:1: F401 '.data' imported but unused
./solaris/__init__.py:1:1: F401 '.utils' imported but unused
./solaris/__init__.py:1:1: F401 '.vector' imported but unused
./solaris/__init__.py:1:1: F401 '.tile' imported but unused
./solaris/tile/raster_tile.py:515:54: W291 trailing whitespace
5
ERROR: InvocationError for command /home/rave/solaris/.tox/lint/bin/flake8 . (exited with code 1)
_________________________________________________________________________________________________ summary __________________________________________________________________________________________________
ERROR:   lint: commands failed

apparently this is the intended behavior according to the tox and flake8 maintainer
https://stackoverflow.com/questions/68743112/invocationerror-while-running-flake8-in-tox-ini

Task detail and notes

I think we can improve how flake8 errors are reported, but I'm not sure how.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant