From 8ff9827d7b75c095ba609ed3de16369e5f26f848 Mon Sep 17 00:00:00 2001 From: giles Date: Fri, 6 Mar 2026 12:51:49 +0000 Subject: [PATCH] Skip boundary.sx in component loader MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit boundary.sx files use define-page-helper which isn't an SX eval form — they're parsed by boundary_parser.py. Exclude them from load_sx_dir() to prevent EvalError on startup. Co-Authored-By: Claude Opus 4.6 --- shared/sx/jinja_bridge.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/shared/sx/jinja_bridge.py b/shared/sx/jinja_bridge.py index 1e01009..71533d1 100644 --- a/shared/sx/jinja_bridge.py +++ b/shared/sx/jinja_bridge.py @@ -86,10 +86,15 @@ def _compute_component_hash() -> None: def load_sx_dir(directory: str) -> None: - """Load all .sx files from a directory and register components.""" + """Load all .sx files from a directory and register components. + + Skips boundary.sx — those are parsed separately by the boundary validator. + """ for filepath in sorted( glob.glob(os.path.join(directory, "*.sx")) ): + if os.path.basename(filepath) == "boundary.sx": + continue with open(filepath, encoding="utf-8") as f: register_components(f.read())