base44-troubleshooter
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseTroubleshoot Production Issues
排查生产环境问题
Prerequisites
前提条件
Verify authentication before fetching logs:
bash
npx base44 whoamiIf not authenticated or token expired, instruct user to run .
npx base44 loginMust be run from the project directory (where exists):
base44/.app.jsoncbash
cat base44/.app.jsonc在获取日志前先验证身份:
bash
npx base44 whoami如果未认证或令牌已过期,请指导用户运行。
npx base44 login必须在项目目录(存在文件的目录)中运行:
base44/.app.jsoncbash
cat base44/.app.jsoncAvailable Commands
可用命令
| Command | Description | Reference |
|---|---|---|
| Fetch function logs for this app | project-logs.md |
| 命令 | 描述 | 参考文档 |
|---|---|---|
| 获取此应用的函数日志 | project-logs.md |
Troubleshooting Flow
排查流程
1. Check Recent Errors
1. 检查近期错误
Start by pulling the latest errors across all functions:
bash
npx base44 logs --level error首先拉取所有函数的最新错误:
bash
npx base44 logs --level error2. Drill Into a Specific Function
2. 深入排查特定函数
If you know which function is failing:
bash
npx base44 logs --function <function_name> --level error如果您知道哪个函数出现故障:
bash
npx base44 logs --function <function_name> --level error3. Inspect a Time Range
3. 检查特定时间范围
Correlate with user-reported issue timestamps:
bash
npx base44 logs --function <function_name> --since <start_time> --until <end_time>结合用户报告问题的时间戳:
bash
npx base44 logs --function <function_name> --since <start_time> --until <end_time>4. Analyze the Logs
4. 分析日志
- Look for stack traces and error messages in the output
- Check timestamps to correlate with user-reported issues
- Use to fetch more entries if the default 50 isn't enough
--limit
- 在输出中查找堆栈跟踪和错误信息
- 检查时间戳以关联用户报告的问题
- 如果默认的50条条目不够,使用参数获取更多条目
--limit