Troubleshooting
Solutions for common issues.
Installation
"command not found" after global install
Cause: npm global bin not in PATH
Solution: Add npm global bin to PATH or use npm exec
# Add to PATH (zsh)
echo 'export PATH="$PATH:$(npm config get prefix)/bin"' >> ~/.zshrc
source ~/.zshrc
# Or use npm exec instead
npm exec @codeteck/rte -- --version
npx shows "command not found"
Cause: npx resolves binary differently
Solution: Use npm exec instead
npm exec @codeteck/rte -- --help
npm install -g @codeteck/rte
CLI Execution
"Error: missing required argument"
Cause: Required argument not provided
Fix: Provide required argument
"Error: Session file not found"
Cause: File path doesn't exist
Fix: Check file path is correct
"Error: Invalid session file: unable to parse JSON"
Cause: Session file is corrupted or not valid JSON
Fix: Ensure valid JSON, re-generate session with rte dev --save-session
"Error: Unknown option"
Cause: Using invalid flag
Fix: Check valid flags with --help
Debug Mode
Enable debug mode to see stack traces:
rte --debug dev myfile.tsx
rte --debug diff a.json b.json
NPM vs NPX vs Direct
# npm exec (recommended)
npm exec @codeteck/rte -- benchmark
# npx
npx @codeteck/rte benchmark
# Global install (requires PATH)
npm install -g @codeteck/rte
rte benchmark
Performance
Benchmark runs slow
Cause: Large component trees or many frames
Fix: Use smaller scenarios
rte benchmark --scenario small # 50 frames
rte benchmark --scenario medium # 100 frames
Getting Help
- Enable debug mode:
rte --debug <command> - GitHub issues: https://github.com/Nom-nom-hub/rte/issues
- CLI reference:
rte --help