Skip to content

chore: add local mypy checking - #46

Merged
michalmaj merged 1 commit into
mainfrom
chore/add-mypy
Sep 26, 2026
Merged

michalmaj merged 1 commit into
mainfrom
chore/add-mypy

Conversation

@michalmaj

Copy link
Copy Markdown
Owner

Summary

Add strict local type checking with mypy and introduce static typing as the first topic after the original project foundation.

Why

The example code already uses type hints, but annotations do not check themselves. This change gives readers a focused explanation of static type checking before it becomes part of the automated CI workflow.

Changes

  • add mypy as a locked development dependency
  • configure strict Python 3.12 checking for src/ and tests/
  • add a type-checking chapter and connect it to the main learning path
  • update project configuration, glossary, common questions, and roadmap references

Type of change

Select the most relevant option.

  • Documentation
  • Project configuration
  • New feature
  • Tests
  • CI/CD
  • Refactoring
  • Bug fix

Checklist

  • The change is small and focused
  • The pull request title is clear
  • I updated documentation if needed
  • I added or updated tests if needed
  • I ran local checks if applicable

Notes

The mypy configuration uses strict = true. The current codebase passes without
ignores or per-module exceptions.

CI integration is intentionally left for the follow-up 7B pull request so this
change can focus on the tool, configuration, and learning material.

Local checks passed:

  • uv run mypy
  • uv run ruff check .
  • uv run ruff format --check .
  • uv run pytest
  • uv build --no-sources
  • git diff --check

@michalmaj
michalmaj merged commit 48cf866 into main Sep 26, 2026
1 check passed
@michalmaj
michalmaj deleted the chore/add-mypy branch September 26, 2026 10:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant