Fix page helper results being quoted as string literals in defpage slots

Page helpers return SX source strings from render_to_sx(), but _aser's
serialize() was wrapping them in double quotes. In async_eval_slot_to_sx,
pass string results through directly since they're already SX source.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-04 01:43:00 +00:00
parent bd314a0be7
commit 50b33ab08e

View File

@@ -943,6 +943,10 @@ async def async_eval_slot_to_sx(
return result.source
if result is None or result is NIL:
return ""
# Page helpers return SX source strings from render_to_sx() —
# pass through directly instead of quoting via serialize().
if isinstance(result, str):
return result
return serialize(result)