aiskillstore/marketplace / skills/0xdarkmatter/python-typing-patterns
python-typing-patterns
VerifiedPython type hints and type safety patterns. Triggers on: type hints, typing, TypeVar, Generic, Protocol, mypy, pyright, type annotation, overload, TypedDict.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 5.0 KB |
| assets/pyproject-typing.toml | config | 2.5 KB |
| references/generics-advanced.md | markdown | 5.6 KB |
| references/mypy-config.md | markdown | 5.9 KB |
| references/overloads.md | markdown | 6.3 KB |
| references/protocols-patterns.md | markdown | 6.1 KB |
| references/runtime-validation.md | markdown | 6.7 KB |
| references/type-narrowing.md | markdown | 6.0 KB |
| scripts/check-types.sh | script | 3.1 KB |
| skill-report.json | config | 69.6 KB |
assets/pyproject-typing.toml
View on GitHub# pyproject.toml - Type checker configuration
# Copy these sections to your pyproject.toml
# ============================================================
# mypy Configuration
# ============================================================
[tool.mypy]
# Python version to target
python_version = "3.11"
# Enable strict mode (recommended for new projects)
strict = true
# Additional strictness
warn_return_any = true
warn_unused_ignores = true
warn_unreachable = true
# Error reporting
show_error_codes = true
show_error_context = true
show_column_numbers = true
pretty = true
# Paths
files = ["src", "tests"]
exclude = [
"migrations/",
"venv/",
".venv/",
"__pycache__/",
"build/",
"dist/",
]
# Plugin support (uncomment as needed)
# plugins = [
# "pydantic.mypy",
# "sqlalchemy.ext.mypy.plugin",
# ]
# ============================================================
# Per-module overrides
# ============================================================
# Relax strictness for tests
[[tool.mypy.overrides]]
module = "tests.*"
disallow_untyped_defs = false
disallow_untyped_calls = false
# Ignore missing stubs for common libraries
[[tool.mypy.overrides]]
module = [
"requests.*",
"boto3.*",
"botocore.*",
"celery.*",
"redis.*",
]
ignore_missing_imports = true
# Legacy code - gradually add types
# [[tool.mypy.overrides]]
# module = "legacy.*"
# ignore_errors = true
# ============================================================
# pyright Configuration
# ============================================================
[tool.pyright]
# Python version
pythonVersion = "3.11"
# Paths
include = ["src"]
exclude = [
"**/node_modules",
"**/__pycache__",
"venv",
".venv",
"build",
"dist",
]
# Type checking mode: off, basic, standard, strict
typeCheckingMode = "strict"
# Report settings (strict mode enables all by default)
reportMissingTypeStubs = false
reportUnusedImport = "warning"
reportUnusedVariable = "warning"
reportUnusedFunction = "warning"
# Useful additional checks
reportUninitializedInstanceVariable = true
reportIncompatibleMethodOverride = true
reportIncompatibleVariableOverride = true
# ============================================================
# Recommended dev dependencies
# ============================================================
# [project.optional-dependencies]
# dev = [
# "mypy>=1.8.0",
# "pyright>=1.1.350",
# # Common type stubs
# "types-requests",
# "types-redis",
# "types-PyYAML",
# "types-python-dateutil",
# ]
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| receiving-code-reviewobra/superpowersUse when receiving code review feedback, before implementing suggestions, especially if feedback seems unclear or technically questionable - requires technical rigor and verification, not performative agreement or blind implementation | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| requesting-code-reviewobra/superpowersUse when completing tasks, implementing major features, or before merging to verify work meets requirements | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| using-git-worktreesobra/superpowersUse when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallback | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| verification-before-completionobra/superpowersUse when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |