Display metric units in web UI, make seed idempotent, simplify code

- Load m.unit in get_domain() so MetricBound carries units from DB
- Add Unit column to domains list template
- Make load_transport_seed() idempotent with IntegrityError handling
  and metric unit backfill for existing DBs
- Remove unused imports (json, sqlite3, Entity)
- Simplify combinator loop to list comprehension
- Merge duplicate conditional/valid branches in pipeline
- Consolidate duplicated SQL in get_all_results()
- Expand CLAUDE.md with fuller architecture docs and conventions

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-18 16:18:50 -06:00
parent d2028a642b
commit f1b3c75190
9 changed files with 63 additions and 53 deletions

View File

@@ -2,8 +2,6 @@
from __future__ import annotations
import sqlite3
import pytest
from physcom.db.schema import init_db