Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ and vendored drift cannot happen:
- id: ruff-config

If a consumer's Python lives in a subdirectory, add `args: [<dir>]` to both
hooks — Tower-Finder, whose backend is not at repo root, needs exactly that.
hooks — retina-server, whose backend is not at repo root, needs exactly that.

| Hook | Script | Requires |
| --- | --- | --- |
Expand Down
2 changes: 1 addition & 1 deletion check-dead-code.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
set -euo pipefail

# Scan the current directory by default; pre-commit sets CWD to the consumer
# repo root. An optional positional argument scopes it (Tower-Finder passes
# repo root. An optional positional argument scopes it (retina-server passes
# "backend"). This replaces a cd relative to the script's own location, which
# is meaningless now the script lives in a pre-commit cache.
LIST_ONLY=0
Expand Down
2 changes: 1 addition & 1 deletion check-ruff-config.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

Comparison is SEMANTIC, not textual. `select`, `ignore` and the values inside
`per-file-ignores` are compared as sets, so comment whitespace and ordering are
irrelevant. This matters concretely: Tower-Finder's config is semantically
irrelevant. This matters concretely: retina-server's config is semantically
identical to the baseline but pads its comments differently, and a text diff
would report false drift.

Expand Down
4 changes: 2 additions & 2 deletions tests/test-check-dead-code.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ mkbroken() {
}

# A decorated, otherwise-unreferenced handler — the Flask/FastAPI dispatch
# pattern --ignore-decorators exists for (Tower-Finder's backend is exactly
# pattern --ignore-decorators exists for (retina-server's backend is exactly
# this shape). vulture can't see the framework's dispatch wiring, so without
# the flag this reads as dead.
mkdirty_decorated() {
Expand Down Expand Up @@ -210,7 +210,7 @@ t_whitelist_suppresses_finding() {
}

# --ignore-decorators (check-dead-code.sh:63) is what stops every Flask/
# FastAPI route handler reading as dead — Tower-Finder's backend is exactly
# FastAPI route handler reading as dead — retina-server's backend is exactly
# this shape and depends on it directly. The script has no flag to disable
# its own --ignore-decorators, so the first half calls vulture directly
# with the script's other options (same EXCLUDE, same --min-confidence, no
Expand Down
4 changes: 2 additions & 2 deletions tests/test-check-ruff-config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ PY
rm -rf "$dir"
}

# Whitespace and ordering must not matter — Tower-Finder is semantically
# Whitespace and ordering must not matter — retina-server is semantically
# identical to the baseline but formats its comments differently.
t_whitespace_and_order_ignored() {
local dir out rc
Expand All @@ -145,7 +145,7 @@ PY
rm -rf "$dir"
}

# Tower-Finder's shape: config lives in a subdirectory.
# retina-server's shape: config lives in a subdirectory.
t_subdirectory_argument() {
local root dir out rc
root="$(mktemp -d)"; mkdir -p "$root/backend"
Expand Down
Loading