Skip to content

bug: closed issue #21 still reproduces on current main (prompt/repl raw missing-model-dir error) #32

@devswha

Description

@devswha

Summary

I reran the no-model startup smoke test from the isolated dogfood checkout on current main and the behavior from closed issue #21 is still reproducible.

Bare zipcode shows friendly setup guidance, but explicit prompt and repl still fail with a raw Failed to read model directory / os error 2 message.

This looks like either:

Environment

  • Dogfood workspace: /home/devswha/workspace/zipcode-dogfood
  • Read-only source/build reference: /home/devswha/workspace/zipcode
  • Commit tested: 03b3be5aefa542b06132562fd764cace0ac900d0
  • Binary: ./target/release/zipcode

Commands run

export RUSTUP_HOME=/home/devswha/.rustup CARGO_HOME=/home/devswha/.cargo
cargo build --release
./target/release/zipcode --help
./target/release/zipcode --version
./target/release/zipcode doctor
HOME=/tmp/zipcode-test-no-model-bare ./target/release/zipcode
HOME=/tmp/zipcode-test-no-model-prompt ./target/release/zipcode prompt "hello"
HOME=/tmp/zipcode-test-no-model-repl ./target/release/zipcode --ui plain repl

Actual behavior

Bare startup with isolated HOME:

zipcode

Setup needed before zipcode can start.

What zipcode found:
  • No local AI model was found yet.

Next:
  1. Copy a .gguf AI model into /tmp/zipcode-test-no-model-bare/.zipcode/models or rerun with `--model <PATH>`.
  2. Copy the matching tokenizer.json next to that model file.
  3. Run `zipcode setup --skip-smoke`, then run `zipcode` again.

But prompt:

Error: Failed to read model directory: /tmp/zipcode-test-no-model-prompt/.zipcode/models

Caused by:
    No such file or directory (os error 2)

And repl:

zipcode v0.1.0 — type /help for commands, Ctrl+D to exit
Error: Failed to read model directory: /tmp/zipcode-test-no-model-repl/.zipcode/models

Caused by:
    No such file or directory (os error 2)

Expected behavior

zipcode prompt ... and zipcode repl ... should surface the same setup-needed guidance path as bare zipcode, or at minimum convert the missing-model-directory case into a clear setup message instead of a raw filesystem error.

Why this matters

This is still a bad first-run air-gapped UX. Users who explicitly try prompt or repl during setup get contradictory behavior for the same underlying state.

Related

Suggested follow-up

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingux

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions