-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
CI: run mypy in full env #4929
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
Merged
Merged
CI: run mypy in full env #4929
Changes from 9 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
2ff12a1
CI: run mypy in full env
mathause 08ed48a
mypy: show_error_codes
mathause 5bc4cf1
[skip-ci] add skip ci option & version comment
mathause b9ae449
Apply suggestions from code review
mathause 8a50a40
Update .github/workflows/ci-additional.yaml
mathause 2ba4e98
Update .github/workflows/ci-additional.yaml
mathause 2623a37
Merge branch 'master' into mypy_full_env
mathause 9b53189
Merge branch 'mypy_full_env' of https://github.com/mathause/xarray in…
mathause 358df23
update mypy version
mathause dbd9aa2
Update .pre-commit-config.yaml
mathause c82ab55
[skip-ci] install mypy from file
mathause 92854f4
Merge branch 'mypy_full_env' of https://github.com/mathause/xarray in…
mathause File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
---|---|---|
|
@@ -157,6 +157,51 @@ jobs: | |
run: | | ||
python -m pytest --doctest-modules xarray --ignore xarray/tests | ||
|
||
typing: | ||
name: Type checking (mypy) | ||
runs-on: "ubuntu-latest" | ||
needs: detect-ci-trigger | ||
if: false && needs.detect-ci-trigger.outputs.triggered == 'false' | ||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
steps: | ||
- name: Cancel previous runs | ||
uses: styfle/[email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 # Fetch all history for all branches and tags. | ||
- uses: conda-incubator/setup-miniconda@v2 | ||
with: | ||
channels: conda-forge | ||
channel-priority: strict | ||
mamba-version: "*" | ||
activate-environment: xarray-tests | ||
auto-update-conda: false | ||
python-version: "3.8" | ||
|
||
- name: Install conda dependencies | ||
run: | | ||
mamba env update -f ci/requirements/environment.yml | ||
- name: Install mypy | ||
run: | | ||
# version must correspond to the one in .pre-commit-config.yaml | ||
mamba install mypy=0.812 | ||
- name: Install xarray | ||
run: | | ||
python -m pip install --no-deps -e . | ||
- name: Version info | ||
run: | | ||
conda info -a | ||
conda list | ||
python xarray/util/print_versions.py | ||
- name: Run mypy | ||
run: | | ||
python -m mypy xarray | ||
|
||
min-version-policy: | ||
name: Minimum Version Policy | ||
runs-on: "ubuntu-latest" | ||
|
This file contains hidden or 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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.