Add problem matchers to highlight errors in Github PRs code diff#376
Add problem matchers to highlight errors in Github PRs code diff#376
Conversation
79e18c9 to
0cda4e1
Compare
0cda4e1 to
87ba9ee
Compare
| ~/.cache/pip | ||
| .tox | ||
| key: ${{ runner.os }}-v1-python-3.8-${{ hashFiles('requirements.txt', 'test-requirements.txt', 'pyproject.toml', 'tox.ini') }} | ||
| key: ${{ runner.os }}-v1-python-3.8-black-${{ hashFiles('test-requirements.txt', 'pyproject.toml', 'tox.ini') }} |
There was a problem hiding this comment.
test-requirements.txt -> requirements.txt
There was a problem hiding this comment.
No that's as expected. back depends only on the test-requirements.txt, - that's where we define it as a test/dev dependency.
There was a problem hiding this comment.
pylint (below) also needs requirements.txt as it does more in-depth code analysis for the project, including its pip dependencies.
scripts/plugins/install_plugins.py
Outdated
| import os | ||
| import git | ||
| import yaml | ||
| import non_existent_module |
There was a problem hiding this comment.
Is this just to illustrate that the UI formatting works?
Either way this should be removed before merge
There was a problem hiding this comment.
Right, that's for illustration for you folks to get an idea of how it looks like in the PR code diff.
Will remove it before merging and also plan to squash all the commits as there's a lot of commit noise in this PR.
Based on the previous PRs, sometimes the linting error messages are not clear enough.
Add problem matches to Github Actions so we can highlight the warnings and errors directly in the PR code diff for specific
file:linefrompylintandblackCI runs.See: https://github.com/actions/toolkit/blob/master/docs/commands.md#problem-matchers
See: https://github.com/actions/toolkit/blob/master/docs/problem-matchers.md
The Result
Pylint:

Black:

So there's no need to go into the GH Action Details URL, as the result is just ^^ there.
This PR also splits

blackvspylintin the GH Actions so the failure is more clear: