|
9 | 9 | - **Key Dependencies:** `portalocker`, `watchdog` (optional: `pymongo`, `sqlalchemy`, `redis`) |
10 | 10 | - **Test Framework:** `pytest` with backend-specific markers |
11 | 11 | - **Linting:** `ruff` (replaces black/flake8) |
12 | | -- **Type Checking:** `mypy` |
13 | 12 | - **CI:** GitHub Actions (matrix for backends/OS with Dockerized services) |
14 | 13 | - **Issue Tracking:** GitHub Issues |
15 | 14 | - **Additional Docs:** `.github/copilot-instructions.md` for contributor guidelines |
@@ -65,11 +64,10 @@ ______________________________________________________________________ |
65 | 64 | pytest -m "not (mongo or sql)" # Exclude external service backends |
66 | 65 | ``` |
67 | 66 |
|
68 | | -3. **Lint and type-check:** |
| 67 | +3. **Lint:** |
69 | 68 |
|
70 | 69 | ```bash |
71 | 70 | ruff check . |
72 | | - mypy src/cachier/ |
73 | 71 | ``` |
74 | 72 |
|
75 | 73 | 4. **Try an example:** |
@@ -102,7 +100,6 @@ ______________________________________________________________________ |
102 | 100 | - **Type annotations** required for all new code. |
103 | 101 | - **Docstrings:** Use numpy style, multi-line, no single-line docstrings. |
104 | 102 | - **Lint:** Run `ruff` before PRs. Use per-line/file ignores only for justified cases. |
105 | | -- **Type check:** Run `mypy` before PRs. |
106 | 103 | - **Testing:** All public methods must have at least one test. Use `pytest.mark.<backend>` for backend-specific tests. |
107 | 104 | - **No warnings/errors for missing optional dependencies at import time.** Only raise when backend is used. |
108 | 105 |
|
@@ -415,7 +412,6 @@ ______________________________________________________________________ |
415 | 412 | - **Run multiple backends:** `pytest -m "redis or sql"` |
416 | 413 | - **Exclude backends:** `pytest -m "not mongo"` |
417 | 414 | - **Lint:** `ruff check .` |
418 | | -- **Type check:** `mypy src/cachier/` |
419 | 415 | - **Format:** `ruff format .` |
420 | 416 | - **Pre-commit:** `pre-commit run --all-files` |
421 | 417 | - **Build package:** `python -m build` |
@@ -505,7 +501,6 @@ ______________________________________________________________________ |
505 | 501 | - **If adding new dependencies, use context7 MCP to get latest versions.** |
506 | 502 | - **Always check GitHub Issues before starting new features/PRs.** |
507 | 503 | - **Create a relevant issue for every new PR.** |
508 | | -- **Use per-file or per-line ignores for mypy/ruff only when justified.** |
509 | 504 | - **All new code must have full type annotations and numpy-style docstrings.** |
510 | 505 |
|
511 | 506 | ______________________________________________________________________ |
@@ -557,7 +552,6 @@ ______________________________________________________________________ |
557 | 552 | | Test multiple backends | `pytest -m "redis or sql"` | |
558 | 553 | | Exclude backends | `pytest -m "not mongo"` | |
559 | 554 | | Lint | `ruff check .` | |
560 | | -| Type check | `mypy src/cachier/` | |
561 | 555 | | Format code | `ruff format .` | |
562 | 556 | | Build package | `python -m build` | |
563 | 557 | | Check docs | `python setup.py checkdocs` | |
|
0 commit comments