Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[Bounty proposal] fix(cli): support single conversation object and empty envelopes in conversations_to_sqlite ( proposed)

Closed Beginner friendly
#19,463 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
88/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
python, sqlite
Domain
cli, database

Research direction

Start in sdks/python-cli/examples/conversations_to_sqlite.py and compare its input handling with the sibling exporters named in the issue. Run the hermetic tests in tests/test_conversations_to_sqlite.py, covering a single conversation object and empty conversations, items, and data wrappers. Done means valid inputs load successfully and empty wrappers produce zero SQLite rows.

Written by the indexing model from the issue text.

Description

Summary

This issue proposes a $25 bounty for fixing single conversation object support and empty wrapper resilience in sdks/python-cli/examples/conversations_to_sqlite.py.

Problem Statement

In conversations_to_sqlite.py:

if isinstance(items, dict):
    for key in ("conversations", "items", "data"):
        if isinstance(items.get(key), list):
            items = items[key]
            break
if not isinstance(items, list):
    raise ValueError(f"{path}: expected a JSON array or wrapped object")

When a user exports an individual conversation (for instance via omi conversation get <id> --json > conversation.json), the file contains a single JSON object ({"id": "conv_...", "structured": {...}}). Because the dictionary does not contain "conversations", "items", or "data" as a list, the loop does not break, and items remains a dict.
The subsequent assertion if not isinstance(items, list): immediately raises:
ValueError: <path>: expected a JSON array or wrapped object.

In contrast, sibling exporters (action_items_to_sqlite.py, conversations_to_markdown.py, memories_to_markdown.py) support individual object exports cleanly via [items] fallback.

Proposed Solution
  1. Add else: items = [items] to the dictionary unwrapping loop so individual conversation objects are loaded cleanly into SQLite.
  2. Ensure empty wrappers like {"conversations": []}, {"items": []}, and {"data": []} produce 0 rows without error.
  3. Add hermetic unit tests in tests/test_conversations_to_sqlite.py.
Payout Coordinates
  • EVM Address: 0xbB9686b9684421A8e326AC0F8B3eCf88Df975120
  • Preferred Network: Base Mainnet (USDC)
Dominant language
Python
Stars
13.6k
Forks
2.5k
Avg merge
8h 7m
Merged PRs (30d)
391

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from BasedHardware/omi

All issues in BasedHardware/omi

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.