You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
<details open> in safe-output bodies renders as escaped text since v1.0.1 #75115
<details open> in safe-output bodies renders as escaped text since v1.0.1
Analysis
Since #72415 (v1.0.1), create_issue, add_comment and the other publishers parse agent bodies with parseReportMarkdown. The parser only recognizes a literal <details>, so <details open> falls through to paragraphs, and the output shows <details open>…</details> as text. In v1.0.0 the body only went through sanitizeContent, which deliberately keeps open (sanitize_content.test.cjs:870).
Repro:
<details open>
<summary>Open</summary>
body
</details>
This currently renders as escaped text. A plain <details> renders correctly.
Implementation plan
actions/setup/js/report_markdown.cjs
In the block-start regex (around L401), accept <details(?:\s+open)?>.
In the two details branches (around L505 and L508), accept the same form and set open: true.
actions/setup/js/report_ast.cjs
Add open?: boolean to the details typedef (L23).
Carry open through when the details node is normalized (around L405).
Have the renderer (around L671) emit <details open> when open is set.
Tests: add cases to report_html_fidelity.test.cjs for both the inline (<details open><summary>) and two-line forms. Assert that the tree has open: true and that rendering round-trips. Keep <details> with any other attribute rejected as it is today.
Add a patch changeset and run make agent-finish.
Acceptance:<details open> in an agent body publishes as an expanded details block, and existing <details> output is unchanged.
Activity