Skip to content

migration: the CLI writes nothing until the last row, so a long copy is indistinguishable from a hang #1327

Done

Description

@chappie-daemon

Found by job 045's ux lens (row 5 of #868) at 8488bf13.

crates/nostream-cli/src/commands/migrate.rs:212-273: the first stdout after the loop is "Migrated {total} rows in {ms} ms", and per-batch progress exists only inside migration-manifest.json. A multi-minute or multi-hour run is indistinguishable from a hang, and a resumed run prints only the rows this invocation wrote as though that were the migration's size. ADR 0013 D8 defines the two closing lines and says nothing about progress.

Evidence

sed -n '270p' crates/nostream-cli/src/commands/migrate.rs → writeln!(out, "Migrated {total} rows in {ms} ms").map_err(write_failed)?;

What a fix changes

One line per table/batch (table, rows so far, the cursor), a "resuming

from ..." line on a resumed run, and the manifest's total beside the invocation's.

Acceptance

  • A copy over two tables prints progress before the closing line.
  • A resumed run names the table and cursor it resumed from.

Record: docs/rewrite/reviews/2026-11-30-relay-storage.md — finding F35, lens ux, tree 8488bf13.

Activity

  1. added
    bug
    rewrite
    rust
    factory
    on Nov 30, 2026
  2. chappie-daemon commented on Dec 5, 2026

    @chappie-daemon
    CollaboratorAuthor

    Factory day 2026-12-05, row 3 (plan: cameri/phoenix-server#122; queue row 0afb68d1). Job 054-migration-progress, base e13d99b5 (= rewrite/main after #1403's merge), stage recon.

  3. chappie-daemon commented on Dec 5, 2026

    @chappie-daemon
    CollaboratorAuthor

    Review complete: code PASS, security PASS, ux PASS, architecture PASS. Round 1 found one structural defect (the redaction guard's fallback would print a future table's key) and three operator-facing strings; both closed at 342b59fc by MigratedTable::key_is_credential() as an exhaustive match beside name(), and C9 now runs the literal 18-line resumed scenario with no staged flags. Approver stage now.

  4. chappie-daemon commented on Dec 5, 2026

    @chappie-daemon
    CollaboratorAuthor

    Merged as 53fec58e271c627ea0f0cad8a29af744d88b7c1c (PR #1407, merge commit; six commits f186ca7e..342b59fc). Three gate findings discharged as measured false positives; record correction: the test file holds 51 → 54 attributes, and the acceptance count quoted is the run's 53 passed.

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

    bugfactoryrewriterust

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions