Skip to content

Server exited before becoming ready (1) when starting t1code #6

@eddiearc

Description

@eddiearc

Bug Description

When running bunx @maria_rcks/t1code, the TUI interface starts but the backend server crashes immediately with:

Error: Server exited before becoming ready (1).
    at waitForServerPort (/private/tmp/bunx-501-@maria_rcks/t1code@latest/node_modules/@maria_rcks/t1code/dist/index.mjs:4140:50)
    at async startServerSupervisor (/private/tmp/bunx-501-@maria_rcks/t1code@latest/node_modules/@maria_rcks/t1code/dist/index.mjs:4259:8)
    at async <anonymous> (/private/tmp/bunx-501-@maria_rcks/t1code@latest/node_modules/@maria_rcks/t1code/dist/index.mjs:6515:14)

The TUI renders but becomes unresponsive because the server process it manages has exited.

Environment

  • macOS (Darwin 25.4.0)
  • Bun 1.3.5
  • t1code v0.0.15

Steps to Reproduce

  1. Set environment variables:
    export ANTHROPIC_API_KEY="<key>"
    export ANTHROPIC_BASE_URL="https://api.minimaxi.com/anthropic"
    export ANTHROPIC_MODEL="MiniMax-M2.7-highspeed"
  2. Run bunx @maria_rcks/t1code
  3. Observe: TUI appears but immediately shows the error

Additional Notes

  • API key and model are valid (tested with curl, returns successful responses)
  • The error occurs even with valid API credentials
  • Port 3939/3940 appear available (no process conflict)
  • The server supervisor seems to exit with code 1 before the server becomes ready

Expected Behavior

t1code should start the backend server successfully and connect to the configured LLM API.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions