Skip to content

Commit 395160a

Browse files
committed
ci: run architecture validators via 'uv run python' so they use the venv
ci-arch-cqrs and ci-arch-clean invoked their scripts as bare ./script.py, which runs under the system Python via the shebang. validate_cqrs.py and check_architecture.py import PyYAML (a venv-only dependency), so they failed with ModuleNotFoundError once the dependency setup stopped leaving the venv active in the ambient environment. Invoke them with 'uv run python' (matching ci-arch-imports), which resolves the project venv. file-sizes aligned too.
1 parent 2e11997 commit 395160a

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

makefiles/ci.mk

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,21 +26,24 @@ ci-quality: ci-quality-ruff ci-quality-pyright ## Run all enforced code quality
2626
ci-quality-full: ci-quality-ruff ci-quality-ruff-optional ci-quality-pyright ## Run all code quality checks including optional
2727

2828
# Individual architecture quality targets (with tool names)
29+
# Run the validators via `uv run` so they use the project venv (which has
30+
# PyYAML etc.), not the ambient system Python. A bare `./script.py` relied on
31+
# the venv being pre-activated by an earlier step, which no longer holds.
2932
ci-arch-cqrs: ## Run CQRS pattern validation
3033
@echo "Running CQRS pattern validation..."
31-
./dev-tools/quality/validate_cqrs.py
34+
uv run python ./dev-tools/quality/validate_cqrs.py
3235

3336
ci-arch-clean: ## Run Clean Architecture dependency validation
3437
@echo "Running Clean Architecture validation..."
35-
./dev-tools/quality/check_architecture.py
38+
uv run python ./dev-tools/quality/check_architecture.py
3639

3740
ci-arch-imports: dev-install ## Run import validation
3841
@echo "Running import validation..."
3942
uv run python ./dev-tools/quality/validate_imports.py
4043

4144
ci-arch-file-sizes: ## Check file size compliance
4245
@echo "Running file size checks..."
43-
./dev-tools/quality/dev_tools_runner.py check-file-sizes --warn-only
46+
uv run python ./dev-tools/quality/dev_tools_runner.py check-file-sizes --warn-only
4447

4548
ci-arch-lint-imports: dev-install ## Run import-linter layer-boundary contracts
4649
@echo "Running import-linter layer-boundary checks..."

0 commit comments

Comments
 (0)