CI: run typechecks only once, not for each Django/Python version
While working on #271/#272/#273, I noticed mypy/pyright typechecks were being run for all matrix combinations, which doesn't really make sense IMO.
This splits the typecheck parts out of the test CI job.
Codecov Report
:white_check_mark: All modified and coverable lines are covered by tests.
:white_check_mark: Project coverage is 100.00%. Comparing base (7cc1121) to head (58ed5a2).
:warning: Report is 9 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #274 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 1 1
Lines 130 130
Branches 14 14
=========================================
Hits 130 130
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
So the current master branch of this project runs mypy against each version of python. This change only runs mypy against a fixed version - giving less coverage.
What advantage does this new way give the project. In the past we have had a type issue which affected an older version of the project but not newer versions. In that instance having a thorough typing check was useful.
In the past we have had a type issue which affected an older version of the project but not newer versions. In that instance having a thorough typing check was useful.
Given type checks aren't being run at runtime, that shouldn't be a thing.
A typing syntax issue like using new types (dict[list], say) without deferred annotations enabled will show up in regular tests, which are still being run on every supported version.