Skip to content

Commit f4c409e

Browse files
authored
refactor: centralize optional-dependency typing shims (#719)
## Summary Centralizes every optional-dependency feature flag and stub type into a single canonical module, and stops internal code from reaching into private `_typing` modules. ## Changes - Make `advanced_alchemy/_typing.py` the single source of truth for all `*_INSTALLED` flags and optional-dependency stub types (pydantic, msgspec, attrs, cattrs, litestar, sqlmodel, numpy, orjson). - Re-export the full surface from the public `advanced_alchemy/typing.py`. - Delete `advanced_alchemy/service/_typing.py` — its contents were generic shims with nothing service-specific. - Update internal callers (`service/__init__.py`, `service/_util.py`, `service/typing.py`, `repository/_typing.py`) to import from `advanced_alchemy.typing` instead of reaching into private `_typing` modules.
1 parent 437d56e commit f4c409e

14 files changed

Lines changed: 2412 additions & 1701 deletions

File tree

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ repos:
2222
- id: unasyncd
2323
additional_dependencies: ["ruff"]
2424
- repo: https://github.com/charliermarsh/ruff-pre-commit
25-
rev: "v0.15.9"
25+
rev: "v0.15.12"
2626
hooks:
2727
# Run the linter.
2828
- id: ruff

0 commit comments

Comments
 (0)