fix: the schema dump must not match the HACS *manifest.json glob (#33)

repo-hygiene caught it: HACS globs *manifest.json over the whole clone
and rejects a repository with two. The dump is scripts/config-schema.json.

User-Visible: no
Issue: #33
This commit is contained in:
Codex
2026-08-30 12:45:17 +03:00
parent 867f476289
commit f43187218f
8 changed files with 15 additions and 14 deletions
+3 -3
View File
@@ -3,7 +3,7 @@
The Voluptuous schema in custom_components/houseplan/validation.py is the
single owner of the persisted config/layout shape. This walker turns it into
scripts/config-schema-manifest.json — the machine-readable manifest the
scripts/config-schema.json — the machine-readable manifest the
frontend parity test and the field registry completeness test consume.
Determinism contract: two runs on the same tree produce byte-identical
@@ -25,7 +25,7 @@ import types
from pathlib import Path
REPO = Path(__file__).resolve().parent.parent
OUT = REPO / "scripts" / "config-schema-manifest.json"
OUT = REPO / "scripts" / "config-schema.json"
def _safe_repr(value) -> str:
@@ -271,7 +271,7 @@ def main() -> int:
current = OUT.read_text(encoding="utf-8") if OUT.exists() else ""
if current != rendered:
sys.stderr.write(
"config-schema-manifest.json is stale: run python3 scripts/dump-config-schema.py\n")
"config-schema.json is stale: run python3 scripts/dump-config-schema.py\n")
return 1
print(f"manifest fresh: {len(manifest['fields'])} paths")
return 0
+1 -1
View File
@@ -742,7 +742,7 @@ const MUTANT_DEFINITIONS = [
+ 'bless) is exactly the schema drift #33 exists to catch — the manifest mutation '
+ 'simulates the backend change without the frontend pair',
patches: [{
file: 'scripts/config-schema-manifest.json',
file: 'scripts/config-schema.json',
find: " \"config.spaces[].settings.fill_mode\": {\n \"enum\": [\n \"custom\",",
replace: " \"config.spaces[].settings.fill_mode\": {\n \"enum\": [\n \"phantom-33\",\n \"custom\",",
}],
+1 -1
View File
@@ -1,6 +1,6 @@
/**
* #33: the machine-readable list of LEGITIMISED enum divergences between the
* backend schema manifest (scripts/config-schema-manifest.json) and the
* backend schema manifest (scripts/config-schema.json) and the
* frontend const declarations.
*
* The parity test fails on any divergence that is not listed here — and on