Skip to content

Commit 0f7ddac

Browse files
committed
few manual fixes
1 parent 5cd12af commit 0f7ddac

6 files changed

Lines changed: 13 additions & 17 deletions

File tree

.github/workflows/ci.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ jobs:
157157
- name: Check Alembic metadata does not drift (db/schema.py)
158158
run: uv run python scripts/check_db_schema_drift.py
159159

160-
import_lint:
160+
python_lint_import_dependency_boundaries:
161161
runs-on: ubuntu-latest
162162
timeout-minutes: 15
163163
steps:
@@ -175,9 +175,9 @@ jobs:
175175
path: |
176176
~/.cache/uv
177177
uv.lock
178-
key: ${{ runner.os }}-uv-import-lint-3.12-${{ hashFiles('pyproject.toml', 'uv.lock') }}
178+
key: ${{ runner.os }}-uv-python-lint-import-dependency-boundaries-3.12-${{ hashFiles('pyproject.toml', 'uv.lock') }}
179179
restore-keys: |
180-
${{ runner.os }}-uv-import-lint-3.12-
180+
${{ runner.os }}-uv-python-lint-import-dependency-boundaries-3.12-
181181
182182
- name: Install uv
183183
uses: astral-sh/setup-uv@v4
@@ -193,7 +193,7 @@ jobs:
193193
- name: Add project directory to PYTHONPATH
194194
run: echo "PYTHONPATH=${{ github.workspace }}" >> $GITHUB_ENV
195195

196-
- name: Run import-linter (PY-1)
196+
- name: python_lint_import_dependency_boundaries
197197
run: uv run lint-imports --config pyproject.toml
198198

199199
test:

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ repos:
4040
entry: bash -lc "root=$(git rev-parse --show-toplevel) && cd \"$root\" && PYTHONPATH=\"$root\" uv run --extra test pyright ."
4141
language: system
4242
pass_filenames: false
43-
- id: import-linter
44-
name: import-linter (PY-1)
43+
- id: python_lint_import_dependency_boundaries
44+
name: python_lint_import_dependency_boundaries
4545
entry: bash -lc "root=$(git rev-parse --show-toplevel) && cd \"$root\" && PYTHONPATH=\"$root\" uv run --extra test lint-imports --config pyproject.toml"
4646
language: system
4747
pass_filenames: false

pyproject.toml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ typeCheckingMode = "basic"
110110
reportMissingTypeStubs = false
111111

112112
[tool.importlinter]
113-
root_packages = ["simulation", "db", "lib", "feeds", "ai", "jobs", "ml_tooling", "ai_tools"]
113+
root_packages = ["simulation", "db", "lib", "feeds", "ai", "jobs", "ml_tooling"]
114114
include_external_packages = false
115115
exclude_type_checking_imports = true
116116

117117
[[tool.importlinter.contracts]]
118-
name = "PY-1 domain purity: simulation.core.models"
118+
name = "Domain purity: simulation.core.models"
119119
type = "forbidden"
120120
source_modules = ["simulation.core.models"]
121121
forbidden_modules = [
@@ -141,19 +141,19 @@ forbidden_modules = [
141141
]
142142

143143
[[tool.importlinter.contracts]]
144-
name = "PY-1 lib is leaf"
144+
name = "lib is leaf"
145145
type = "forbidden"
146146
source_modules = ["lib"]
147147
forbidden_modules = ["simulation", "db", "feeds", "ai", "jobs", "ml_tooling"]
148148

149149
[[tool.importlinter.contracts]]
150-
name = "PY-1 ml_tooling constraints"
150+
name = "ml_tooling constraints"
151151
type = "forbidden"
152152
source_modules = ["ml_tooling"]
153153
forbidden_modules = ["simulation", "db", "feeds", "ai", "jobs"]
154154

155155
[[tool.importlinter.contracts]]
156-
name = "PY-1 API routes boundary: simulation.api.routes"
156+
name = "API routes boundary: simulation.api.routes"
157157
type = "forbidden"
158158
source_modules = ["simulation.api.routes"]
159159
forbidden_modules = ["simulation.core", "db", "feeds", "ai", "jobs", "ml_tooling"]

simulation/core/agent_actions.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
1-
"""Action generation helpers for simulation agents.
2-
3-
This module intentionally lives outside `simulation.core.models` to keep domain models
4-
pure per PY-1 import contracts.
5-
"""
1+
"""Action generation helpers for simulation agents."""
62

73
from __future__ import annotations
84

simulation/core/models/runs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class RunConfig(BaseModel):
2525
def validate_metric_keys_config(cls, v: list[str] | None) -> list[str] | None:
2626
"""Validate that metric_keys, when provided, is non-empty and contains non-empty strings.
2727
28-
Note: registry-level validation belongs outside the domain models layer (PY-1).
28+
Note: registry-level validation belongs outside the domain models layer.
2929
"""
3030
if v is None:
3131
return None
File renamed without changes.

0 commit comments

Comments
 (0)