-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add MyPy type checking to our CI process (#180)
* Start adding mypy * Add mypy to github actions. * Add mypy workflow to gh actions. * Use future annotations instead of string annotations. * Temporarily pin `markupsafe` for breaking change. - Temporarily solves pallets/markupsafe#284 - Remove `markupsafe` entry once `jinja2` has been upgraded. * Temporarily exclude some files from mypy checks. Co-authored-by: Tim DiLauro <[email protected]>
- Loading branch information
1 parent
a54bb16
commit 532b7c7
Showing
60 changed files
with
1,600 additions
and
986 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: Mypy (Type check) | ||
on: [push, pull_request] | ||
env: | ||
PYTHON_VERSION: 3.9 | ||
|
||
jobs: | ||
mypy: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up Python 🐍 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ env.PYTHON_VERSION }} | ||
|
||
- name: Install Poetry 🎸 | ||
uses: ./.github/actions/poetry | ||
|
||
- name: Install OS Packages 🧰 | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install --yes libxmlsec1-dev libxml2-dev | ||
- name: Install Python Packages 📦 | ||
run: poetry install | ||
|
||
- name: Run MyPy 🪄 | ||
run: poetry run mypy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.