Skip to content

fix(ai): SqliteStepStore raises a bare AssertionError after close() #1374

Closed as not planned

Description

@dan-petty

Out of scope in #709 (its 'Out of scope' list) and not yet filed.

src/devops_cli/ai/durable.py:134,153,177 use assert self._conn is not None after close(). A use after close raises a bare AssertionError, and the assert disappears entirely under python -O.

Proposed: raise a typed DevOpsCLIError subclass naming the closed store. Do not reopen lazily: a lazy reopen would silently return an empty :memory: store.


Found on 2026-10-08 while implementing #709. Filed directly with no priority; the roadmap service's intake sets Priority, Value and Effort.

Activity

  1. added
    type/bug
    scope/ai
    source/agent
    on Oct 8, 2026
  2. dan-petty-bot commented on Oct 8, 2026

    @dan-petty-bot
    Collaborator

    Intake placed this item to the backlog: at intake only a critical fix goes into a release; a release start pulls Ready items in, P0 features first.

    • Priority: P2-Medium. It produces a confusing, non-actionable error and silently disappears under python -O, but it is not a data-loss or security issue.
    • Effort: Low. The fix is replacing three assert statements with a typed DevOpsCLIError subclass raise at the same call sites.
  3. dan-petty commented on Oct 8, 2026

    @dan-petty
    OwnerAuthor

    Linked: #1121 and #1331. Nothing in production reaches SqliteStepStore (ai/durable.py:484, :509), and #1331's Q22 rule deletes such code; if the store goes first, this closes as not planned. Found by the 2026-10-08 backlog review.

  4. dan-petty commented on Oct 23, 2026

    @dan-petty
    OwnerAuthor

    Not planned: ai/durable.py and SqliteStepStore no longer exist on main, so the defect has no code left.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    scope/aisource/agenttype/bug

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions