Commit b112de8
committed
fix: normalize CRLF to LF in agent file parser
On Windows, .lines() strips \n but keeps \r, causing byte offset
miscalculation in frontmatter closing --- detection. The extracted YAML
content gets corrupted and serde_yaml parsing fails silently.
Normalize line endings before parsing to fix all 5 failing tests:
- test_all_built_in_agents_parseable
- test_explore_agent_disallows_write_tools
- test_general_purpose_has_all_tools
- test_scan_agents_no_dir
- test_scan_agents_with_extra_dirs_dedup1 parent 2ce72b4 commit b112de8
1 file changed
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
| 165 | + | |
| 166 | + | |
165 | 167 | | |
166 | 168 | | |
167 | 169 | | |
| |||
180 | 182 | | |
181 | 183 | | |
182 | 184 | | |
183 | | - | |
| 185 | + | |
184 | 186 | | |
185 | 187 | | |
186 | 188 | | |
| |||
0 commit comments