Skip to content

tech-debt: warn users about orphaned containers when upgrading from pre-0.1.10 naming scheme #75

@egouilliard-leyton

Description

@egouilliard-leyton

Context

Discovered during implementation of fix for container name collision (#18).

Description

Before 0.1.10, containers were named cognitx-codegraph-{repo_name} (no hash). After upgrading, re-running codegraph init generates a new container name with the hash suffix and starts a new container — but the old one keeps running. Users end up with both containers alive, wasting memory, and the old one still holds ports 7687/7474 so the new one fails to bind.

Suggested approach

  • At the start of run_init, check docker ps for any container whose name matches cognitx-codegraph-{repo_name} but lacks the expected 8-hex suffix. If found, print a clear warning with the old name and suggest docker rm -f <old_name>.
  • Or: document the migration step in the 0.1.10 changelog / ROADMAP.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions