GitHub Actions: Add mypy problem matcher (#37485)

pull/37497/head
Franck Nijhof 2020-07-05 02:04:39 +02:00 committed by GitHub
parent fa6bd786d2
commit 6d6188e34d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 19 additions and 0 deletions

View File

@ -669,6 +669,9 @@ jobs:
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Register mypy problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/mypy.json"
- name: Run mypy
run: |
. venv/bin/activate

16
.github/workflows/matchers/mypy.json vendored Normal file
View File

@ -0,0 +1,16 @@
{
"problemMatcher": [
{
"owner": "mypy",
"pattern": [
{
"regexp": "^(.+):(\\d+):\\s(error|warning):\\s(.+)$",
"file": 1,
"line": 2,
"severity": 3,
"message": 4
}
]
}
]
}