Commit 93152df
fix(sessions): address review — verbatim export text + redact the filename
Two review findings on #65:
- toMarkdown trimmed each turn's text, which changes Markdown semantics: a
leading 4-space indent (indented code block) got de-indented and a trailing
" " (hard line break) was eaten. Turn text is now emitted verbatim aside from
redaction — the `**role**` blank line already supplies the blank an indented
block needs. Pinned by a new test (indented code + trailing hard-break survive).
- The default save-dialog filename was derived from the RAW entry.title, not the
scrubbed copy toMarkdown makes — and the filesystem sanitiser only strips
slashes/colons, so a credential's own characters survive it (ghp_ABC… →
ghp-abc…). entry.title now goes through redactSecrets before the stem, so a
token in a title can't leak into the save path. Pinned by a source invariant.
32 suites green.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>1 parent 49ab023 commit 93152df
4 files changed
Lines changed: 24 additions & 5 deletions
File tree
- extensions/levelcode-ai
- test
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
939 | 939 | | |
940 | 940 | | |
941 | 941 | | |
942 | | - | |
943 | | - | |
944 | | - | |
945 | | - | |
| 942 | + | |
| 943 | + | |
| 944 | + | |
| 945 | + | |
| 946 | + | |
| 947 | + | |
946 | 948 | | |
947 | 949 | | |
948 | 950 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
166 | 166 | | |
167 | 167 | | |
168 | 168 | | |
169 | | - | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
170 | 173 | | |
171 | 174 | | |
172 | 175 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
141 | 150 | | |
142 | 151 | | |
143 | 152 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
258 | 258 | | |
259 | 259 | | |
260 | 260 | | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
261 | 266 | | |
0 commit comments