Skip to content

Respect export type in SQLite conversation exports#1493

Merged
rlundeen2 merged 5 commits intomicrosoft:mainfrom
biefan:respect-sqlite-conversation-export-type
Apr 11, 2026
Merged

Respect export type in SQLite conversation exports#1493
rlundeen2 merged 5 commits intomicrosoft:mainfrom
biefan:respect-sqlite-conversation-export-type

Conversation

@biefan
Copy link
Copy Markdown
Contributor

@biefan biefan commented Mar 17, 2026

Summary

  • make SQLiteMemory.export_conversations() honor the requested export_type
  • route non-JSON exports through the shared MemoryExporter instead of always writing JSON
  • add regression coverage for CSV and Markdown conversation exports

Problem

SQLiteMemory.export_conversations() accepts an export_type argument, but the current implementation ignores it and always writes JSON directly.

That means calls such as:

  • export_conversations(..., export_type="csv")
  • export_conversations(..., export_type="md")

still produce JSON content, even though the exporter infrastructure already supports those formats.

This makes the SQLite backend behave differently from the rest of the export stack and breaks callers that rely on the requested file format.

Testing

  • .venv/bin/pytest tests/unit/memory/memory_interface/test_interface_export.py -q

rlundeen2 and others added 4 commits April 10, 2026 19:37
Combine separate CSV and Markdown test functions into a single
parametrized test covering json, csv, and md export types.
Move inline imports to file top.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add ValueError to export_conversations docstring (DOC501).
Use cast for _ExportableConversationPiece list to satisfy mypy arg-type check.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@rlundeen2 rlundeen2 merged commit bd484a0 into microsoft:main Apr 11, 2026
35 checks passed
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.

3 participants