From b25e90beb49b7130c12165efae4a845b07da0d58 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Jan 2025 05:59:33 +0000 Subject: [PATCH 1/2] Bump ASFHyP3/actions from 0.13.2 to 0.14.0 Bumps [ASFHyP3/actions](https://github.com/asfhyp3/actions) from 0.13.2 to 0.14.0. - [Release notes](https://github.com/asfhyp3/actions/releases) - [Changelog](https://github.com/ASFHyP3/actions/blob/develop/CHANGELOG.md) - [Commits](https://github.com/asfhyp3/actions/compare/v0.13.2...v0.14.0) --- updated-dependencies: - dependency-name: ASFHyP3/actions dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/changelog.yml | 2 +- .github/workflows/create-jira-issue.yml | 2 +- .github/workflows/labeled-pr.yml | 2 +- .github/workflows/release-checklist-comment.yml | 2 +- .github/workflows/release.yml | 2 +- .github/workflows/static-analysis.yml | 2 +- .github/workflows/tag-version.yml | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index 72e2657..56a2da0 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -14,4 +14,4 @@ on: jobs: call-changelog-check-workflow: # Docs: https://github.com/ASFHyP3/actions - uses: ASFHyP3/actions/.github/workflows/reusable-changelog-check.yml@v0.13.2 + uses: ASFHyP3/actions/.github/workflows/reusable-changelog-check.yml@v0.14.0 diff --git a/.github/workflows/create-jira-issue.yml b/.github/workflows/create-jira-issue.yml index 7646baa..c4e970a 100644 --- a/.github/workflows/create-jira-issue.yml +++ b/.github/workflows/create-jira-issue.yml @@ -6,7 +6,7 @@ on: jobs: call-create-jira-issue-workflow: - uses: ASFHyP3/actions/.github/workflows/reusable-create-jira-issue.yml@v0.13.2 + uses: ASFHyP3/actions/.github/workflows/reusable-create-jira-issue.yml@v0.14.0 secrets: JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }} JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }} diff --git a/.github/workflows/labeled-pr.yml b/.github/workflows/labeled-pr.yml index c549b2c..2f4549a 100644 --- a/.github/workflows/labeled-pr.yml +++ b/.github/workflows/labeled-pr.yml @@ -13,4 +13,4 @@ on: jobs: call-labeled-pr-check-workflow: # Docs: https://github.com/ASFHyP3/actions - uses: ASFHyP3/actions/.github/workflows/reusable-labeled-pr-check.yml@v0.13.2 + uses: ASFHyP3/actions/.github/workflows/reusable-labeled-pr-check.yml@v0.14.0 diff --git a/.github/workflows/release-checklist-comment.yml b/.github/workflows/release-checklist-comment.yml index 174418b..cc7d289 100644 --- a/.github/workflows/release-checklist-comment.yml +++ b/.github/workflows/release-checklist-comment.yml @@ -10,7 +10,7 @@ on: jobs: call-release-workflow: # Docs: https://github.com/ASFHyP3/actions - uses: ASFHyP3/actions/.github/workflows/reusable-release-checklist-comment.yml@v0.13.2 + uses: ASFHyP3/actions/.github/workflows/reusable-release-checklist-comment.yml@v0.14.0 permissions: pull-requests: write secrets: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5753b55..895e28f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -7,7 +7,7 @@ on: jobs: call-release-workflow: - uses: ASFHyP3/actions/.github/workflows/reusable-release.yml@v0.13.2 + uses: ASFHyP3/actions/.github/workflows/reusable-release.yml@v0.14.0 with: release_prefix: GRFN Distribution release_branch: prod diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index f8b4efd..907aff7 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -5,7 +5,7 @@ on: push jobs: call-ruff-workflow: - uses: ASFHyP3/actions/.github/workflows/reusable-ruff.yml@v0.13.2 + uses: ASFHyP3/actions/.github/workflows/reusable-ruff.yml@v0.14.0 cfn-lint: runs-on: ubuntu-latest diff --git a/.github/workflows/tag-version.yml b/.github/workflows/tag-version.yml index 6afa9a8..5afa737 100644 --- a/.github/workflows/tag-version.yml +++ b/.github/workflows/tag-version.yml @@ -8,7 +8,7 @@ on: jobs: call-bump-version-workflow: # Docs: https://github.com/ASFHyP3/actions - uses: ASFHyP3/actions/.github/workflows/reusable-bump-version.yml@v0.13.2 + uses: ASFHyP3/actions/.github/workflows/reusable-bump-version.yml@v0.14.0 with: user: tools-bot email: UAF-asf-apd@alaska.edu From 0872d264593a5338ef787d25a051d99fe2430746 Mon Sep 17 00:00:00 2001 From: Jake Herrmann Date: Mon, 13 Jan 2025 10:39:31 -0900 Subject: [PATCH 2/2] add mypy --- .github/workflows/static-analysis.yml | 3 +++ CHANGELOG.md | 2 ++ environment.yml | 9 +++++++++ pyproject.toml | 8 ++++++++ requirements-all.txt | 4 ++++ 5 files changed, 26 insertions(+) create mode 100644 environment.yml create mode 100644 requirements-all.txt diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index f8b4efd..be5e168 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -7,6 +7,9 @@ jobs: call-ruff-workflow: uses: ASFHyP3/actions/.github/workflows/reusable-ruff.yml@v0.13.2 + call-mypy-workflow: + uses: ASFHyP3/actions/.github/workflows/reusable-mypy.yml@v0.14.0 + cfn-lint: runs-on: ubuntu-latest diff --git a/CHANGELOG.md b/CHANGELOG.md index e814c96..0b70f98 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,8 @@ and this project adheres to [PEP 440](https://www.python.org/dev/peps/pep-0440/) and uses [Semantic Versioning](https://semver.org/spec/v2.0.0.html). ## [1.0.3] +### Added +- Added `mypy` to static analysis workflow. ### Changed - Replaced `flake8` with `ruff`. diff --git a/environment.yml b/environment.yml new file mode 100644 index 0000000..2e128d5 --- /dev/null +++ b/environment.yml @@ -0,0 +1,9 @@ +name: grfn-distribution +channels: + - conda-forge + - nodefaults +dependencies: + - python=3.12 + - pip + - pip: + - -r requirements-all.txt diff --git a/pyproject.toml b/pyproject.toml index bbb16f3..9f6dddf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -29,3 +29,11 @@ convention = "google" [tool.ruff.lint.isort] case-sensitive = true lines-after-imports = 2 + +[tool.mypy] +python_version = "3.12" +warn_redundant_casts = true +warn_unused_ignores = true +warn_unreachable = true +strict_equality = true +check_untyped_defs = true diff --git a/requirements-all.txt b/requirements-all.txt new file mode 100644 index 0000000..7a1c12e --- /dev/null +++ b/requirements-all.txt @@ -0,0 +1,4 @@ +-r requirements-door.txt +-r requirements-door-binary.txt +ruff +mypy