Skip to content

Preserve Markdown headings and code comments in restored chat history - #6048

Open
bug-origin wants to merge 1 commit into
Aider-AI:mainfrom
bug-origin:fix/restore-markdown-headings
Open

bug-origin wants to merge 1 commit into
Aider-AI:mainfrom
bug-origin:fix/restore-markdown-headings

Conversation

@bug-origin

Copy link
Copy Markdown

Restoring a chat with --restore-chat-history drops Markdown headings and Python comments at the start of a line. For example, a reply containing # Summary and a fenced Python snippet with # Keep this comment loses both lines.

Skip the session heading written by InputOutput while keeping other lines beginning with # in the restored reply. The regression test checks the restored user and assistant messages together. It fails on main; both tests in tests/basic/test_utils.py pass with the change.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant