CodeBrew

Troubleshooting & FAQ

Common issues and how to resolve them.

"Missing ANTHROPIC_API_KEY"

CodeBrew couldn't find your API key. Set it as an environment variable, or add a .env file to the directory you're running codebrew from (not the folder where the package is installed).

export ANTHROPIC_API_KEY=your_key
# or, in the current directory:
echo "ANTHROPIC_API_KEY=your_key" > .env

Run codebrew doctor afterward to confirm it's picked up correctly.

Node version errors

CodeBrew requires Node.js 18 or higher. Check your version with node -v, and upgrade if it's below that.

"command not found: codebrew"

This usually means the global npm bin directory isn't on your PATH, or the install didn't complete. Reinstall globally and confirm the install location is on your PATH:

npm install -g @buildwithatul/codebrew
npm config get prefix

Registry basics

CodeBrew is published on the public npm registry as @buildwithatul/codebrew. If npm install can't find it, make sure your npm registry configuration points at the default public registry (registry.npmjs.org) and that you're not shadowed by a private registry scope.

npm config get registry

A session stopped before finishing

Every session is capped at 25 turns and $1.00 USD by default. If a task needs more than that, break it into a fresh session or a more targeted prompt.