From 7a79993560ed589e48a88736f7a08b1c8953e8ee Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 6 Nov 2026 22:14:53 +0000 Subject: [PATCH 1/2] Bump pinned ruff from 0.15.20 to 0.17.4 The repo already passes ruff 0.17.4 (and 0.16.9) with zero findings, so the bump is free now; staying on 0.15.20 let local and CI ruff drift apart, which broke CI on PR #38 (PLR0917 is enabled in newer ruff, not in 0.15.20). Updated together: the CI lint job, the pre-commit hook rev, and the notes in pyproject.toml and docs/ruff_fix_plan.md. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_012k19dCKBK4J2UdDMJd5gLv --- .github/workflows/ci.yml | 2 +- .pre-commit-config.yaml | 2 +- docs/ruff_fix_plan.md | 1 + pyproject.toml | 3 ++- 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b8ad266..d9673a0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -20,7 +20,7 @@ jobs: # Keep in sync with the rev in .pre-commit-config.yaml - name: Install ruff - run: python -m pip install ruff==0.15.20 + run: python -m pip install ruff==0.17.4 - name: Ruff check run: ruff check . diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 58158ec..2a0282f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -2,6 +2,6 @@ repos: - repo: https://github.com/astral-sh/ruff-pre-commit # Keep in sync with the version in .github/workflows/ci.yml - rev: v0.15.20 + rev: v0.17.4 hooks: - id: ruff diff --git a/docs/ruff_fix_plan.md b/docs/ruff_fix_plan.md index a97b1a6..edaf049 100644 --- a/docs/ruff_fix_plan.md +++ b/docs/ruff_fix_plan.md @@ -79,6 +79,7 @@ lint.per-file-ignores = { "tests/*" = [ > (`.github/workflows/ci.yml`), and `.pre-commit-config.yaml` provides a > local hook (`pip install pre-commit && pre-commit install` to enable). > Ruff is pinned to 0.15.20 in both places — bump them together. +> (Bumped to 0.17.4 on 2026-11-06; still zero findings.) > Step 3 delivered: S113 timeout in log_poster, `utcnow()` → > `datetime.now(UTC).replace(tzinfo=None)` in auth.py + notesync/service.py > (kept naive-UTC storage semantics), tz-aware `now()` in weekly_metrics, diff --git a/pyproject.toml b/pyproject.toml index d1fb7da..315aad3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,7 @@ [tool.ruff] # Explicit linter list (was `ALL`, frozen 2026-07-12 at ruff 0.15.20 with a -# clean `ruff check .`). New linters added by future ruff versions won't +# clean `ruff check .`; still clean at ruff 0.17.4, the version pinned in CI +# and pre-commit since 2026-11-06). New linters added by future ruff versions won't # auto-enable; add them here deliberately. Framework linters that don't apply # (AIR airflow, DJ django, FAST fastapi) and preview-only ones (CPY, DOC) # are intentionally left out. From 25e4492b6c440f10b5b3aae275fc9e170aa98d8f Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 7 Nov 2026 01:16:33 +0000 Subject: [PATCH 2/2] Fix Store Accounting calculator layout broken by lotto styles The lotto pages styled a .lotto-row class (display: flex) for their button rows, but the Store Accounting calculator already uses class="lotto-row" on its rows (and its JS selects them by it). The flex rule turned every calculator table row into a flex box and broke the column layout. The lotto pages now use .lotto-actions instead; the calculator is untouched. A test guards against styling .lotto-row again. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_012k19dCKBK4J2UdDMJd5gLv --- src/safe_family/static/css/styles.css | 2 +- src/safe_family/templates/lotto/lotto.html | 6 +++--- src/safe_family/templates/lotto/lotto_label.html | 6 +++--- tests/test_lotto.py | 14 ++++++++++++++ 4 files changed, 21 insertions(+), 7 deletions(-) diff --git a/src/safe_family/static/css/styles.css b/src/safe_family/static/css/styles.css index 252aac7..ffff6c0 100644 --- a/src/safe_family/static/css/styles.css +++ b/src/safe_family/static/css/styles.css @@ -1623,7 +1623,7 @@ td form button { } .lotto-toolbar, -.lotto-row { +.lotto-actions { display: flex; flex-wrap: wrap; align-items: center; diff --git a/src/safe_family/templates/lotto/lotto.html b/src/safe_family/templates/lotto/lotto.html index 2635d93..fce712d 100644 --- a/src/safe_family/templates/lotto/lotto.html +++ b/src/safe_family/templates/lotto/lotto.html @@ -16,7 +16,7 @@ from straight above, the tray filling the frame, full resolution. Tilt the phone a little if a ceiling light reflects on the glass. You can pick several photos at once. Upload whenever you like: photos wait in To label until you have time, even for weeks.

-
+
No photos chosen @@ -77,11 +77,11 @@
3 · Train on the Mac  ·  4 · Bring predictions back
-
+ -
+ No file chosen diff --git a/src/safe_family/templates/lotto/lotto_label.html b/src/safe_family/templates/lotto/lotto_label.html index b1f9d1b..09c9c7d 100644 --- a/src/safe_family/templates/lotto/lotto_label.html +++ b/src/safe_family/templates/lotto/lotto_label.html @@ -22,7 +22,7 @@
-
+