feat(ledger): the consumer map surfaces — every css row carries used_by on list_shapes, flag="unused-css" (the map's negative space, surfaced never deleted), derive groups and the write-path family carry consumers, the derive line says "used by N template(s)", coverage payload unused_css + the standing block; docs, SKILL, plugin 0.1.44; the two step-2 tests expected 5 edges where fan-out makes 6 (milestone 302 step 3, #2936)
CI & Build / Plugin hooks (push) Successful in 9s
CI & Build / Python lint (push) Successful in 4s
CI & Build / TypeScript typecheck (push) Successful in 38s
CI & Build / integration (push) Failing after 44s
CI & Build / Python tests (push) Successful in 1m26s
CI & Build / Build & push image (push) Successful in 31s
CI & Build / Plugin hooks (push) Successful in 9s
CI & Build / Python lint (push) Successful in 4s
CI & Build / TypeScript typecheck (push) Successful in 38s
CI & Build / integration (push) Failing after 44s
CI & Build / Python tests (push) Successful in 1m26s
CI & Build / Build & push image (push) Successful in 31s
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -1073,6 +1073,18 @@ def _derive_line(path: str, derive: list[dict]) -> str:
|
||||
# files. CSS is only ever grouped this way (note 2917) — a class
|
||||
# is a recipe, and the recipe is what gets derived or dismissed.
|
||||
what = f"is a repeated name with no canon — defined in {n} other file(s)"
|
||||
# What renders a css family (milestone 302): the consumer count is
|
||||
# the datum that separates a shared recipe from a scoped convention.
|
||||
cons = f.get("consumers")
|
||||
if cons is not None:
|
||||
n_t = cons.get("count", 0)
|
||||
used = f"; used by {n_t} template{'s' if n_t != 1 else ''}"
|
||||
if cons.get("paths"):
|
||||
used += ": " + ", ".join(f"`{x}`" for x in cons["paths"])
|
||||
extra = n_t - len(cons["paths"])
|
||||
if extra > 0:
|
||||
used += f" +{extra} more"
|
||||
files += used
|
||||
# The dismissal reason the family most likely earns: a class name
|
||||
# reused for different purposes is scoped styling; a code name reused
|
||||
# across modules is convention plumbing.
|
||||
|
||||
Reference in New Issue
Block a user