refactor: 为小白用户规划一套手把手部署视频教程脚本和可选配套文档更新 (#1267) - #1268
Conversation
🤖 自动审查报告
📁 修改的文件
🧠 AI 代码审查意见结论: Ready to Merge 结构化结果:
必改项 (无) 建议项:
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: dabb379c4a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| ```bash | ||
| docker-compose -f ./docker/docker-compose.yml ps | ||
| docker-compose -f ./docker/docker-compose.yml logs -f --tail=80 | ||
| docker-compose -f ./docker/docker-compose.yml exec -u dsa stock-analyzer python main.py --help |
There was a problem hiding this comment.
Use the Compose service name for exec commands
When a beginner follows the Docker Compose path, this exec command will target stock-analyzer, but Docker Compose exec expects a service name (docker compose exec [OPTIONS] SERVICE COMMAND [ARGS...], per Docker's CLI reference). In docker/docker-compose.yml the service is analyzer; stock-analyzer is only container_name, so these copied commands (including the later --no-notify and ss examples) will fail with no such service instead of validating or running the analysis.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Pull request overview
该 PR 面向首次部署的新手用户,新增“一条龙”部署录屏脚本,并在文档中心与部署指南中补充入口,同时在变更记录里登记对应文档更新,帮助用户更快完成从 0 到可运行的部署路径。
Changes:
- 新增新手向的部署视频教程脚本文档(含操作清单与排障段落)。
- 在
docs/DEPLOY.md与docs/INDEX.md增加新手入口链接,提升可发现性。 - 在
docs/CHANGELOG.md的[Unreleased]中补充文档变更记录。
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
| docs/INDEX.md | 在文档中心新增“新手首次部署”与脚本入口,提升导航可达性 |
| docs/DEPLOY.md | 在部署指南开头新增新手推荐路线入口,降低首次部署门槛 |
| docs/deploy-beginner-video-script.md | 新增面向录屏的视频脚本与实操 checklist |
| docs/CHANGELOG.md | 在 [Unreleased] 中记录新增新手部署脚本文档与入口变更 |
| - [修复] Pytdx 股票名称查询在全部服务器不可达时会短暂冷却,并在冷却期内跳过重复探测,减少无效拨号与告警噪音。 | ||
| - [修复] 调度模式未显式设置 `SCHEDULE_RUN_IMMEDIATELY` 时,会继续继承 `RUN_IMMEDIATELY` 的运行时覆盖语义,避免被持久化 `.env` 别名反向覆盖。 | ||
| - [文档] 补充 Longbridge 冷却开关与调度启动兼容语义说明。 | ||
| - [文档] 新增“面向新手的部署手把手视频教程”脚本文档,并补充文档中心/部署指南入口。 |
| ```bash | ||
| docker-compose -f ./docker/docker-compose.yml ps | ||
| docker-compose -f ./docker/docker-compose.yml logs -f --tail=80 | ||
| docker-compose -f ./docker/docker-compose.yml exec -u dsa stock-analyzer python main.py --help |
| **方式 A:容器内执行一次** | ||
|
|
||
| ```bash | ||
| docker-compose -f ./docker/docker-compose.yml exec -u dsa stock-analyzer python main.py --no-notify |
| #### 症状 3:端口访问失败 | ||
|
|
||
| ```bash | ||
| docker-compose -f ./docker/docker-compose.yml exec stock-analyzer ss -lntp | grep 8000 |
| ## 🎬 小白推荐路线:手把手视频脚本 | ||
|
|
||
| 如果你是第一次部署,建议优先按本视频教程先完成: | ||
| [【小白手把手部署脚本】](deploy-beginner-video-script.md) |
| | --- | --- | --- | | ||
| | 快速了解项目能做什么 | [README](../README.md) | [完整配置与部署指南](full-guide.md) | | ||
| | 第一次把项目跑起来 | [README](../README.md) | [完整配置与部署指南](full-guide.md) | | ||
| | 第一次部署(小白友好) | [部署指南](DEPLOY.md) | [小白手把手部署视频脚本](deploy-beginner-video-script.md) | |
| | 文档 | 内容 | | ||
| | --- | --- | | ||
| | [部署指南](DEPLOY.md) | 服务器部署、Docker、systemd、Supervisor 等部署方式 | | ||
| | [小白手把手部署视频脚本](deploy-beginner-video-script.md) | 从零到会跑的录屏版流程,含环境准备、启动验证和排障 | |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 44c872bf94
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| #### 症状 3:端口访问失败 | ||
|
|
||
| ```bash | ||
| docker-compose -f ./docker/docker-compose.yml exec server ss -lntp | grep ${API_PORT:-8000} |
There was a problem hiding this comment.
Use a listener check available in the image
When a beginner reaches the port-access troubleshooting path for the shipped Docker image, this command runs ss inside the server container, but docker/Dockerfile only installs gcc/curl/gosu/wkhtmltopdf/font libraries and does not install iproute2, which provides ss. The copied check will therefore fail with ss: not found and won't tell the user whether ${API_PORT:-8000} is listening; use an available health/curl/Python check or add iproute2 to the image.
Useful? React with 👍 / 👎.
196614e to
350b8ef
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 350b8ef2ff
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| #### 症状 3:端口访问失败 | ||
|
|
||
| ```bash | ||
| docker-compose -f ./docker/docker-compose.yml exec server sh -lc "curl -sS -o /dev/null -w 'HTTP %{http_code}\n' http://127.0.0.1:${API_PORT:-8000}/" |
There was a problem hiding this comment.
Defer API_PORT expansion to the container shell
When a user customizes API_PORT only in .env (the documented path), this troubleshooting command expands ${API_PORT:-8000} in the host shell before docker-compose exec runs. Because .env values are not normally exported into the host shell, the check curls port 8000 even though the Compose server service may be listening on the .env port, producing a false failure during port-access debugging; quote or escape the $ so sh -lc expands it inside the container.
Useful? React with 👍 / 👎.
ZhuLinsen
left a comment
There was a problem hiding this comment.
评审结论
- 必要性:通过。新增面向首次部署用户的视频教程脚本和入口,符合 Issue #1267 的用户价值。
- 是否有对应 issue:有,Closes #1267。
- PR 类型:docs。实际改动均为
docs/*文档与变更记录,PR 描述勾选为refactor不准确。 - description 完整性:不完整。背景、范围、验证、风险、回滚基本齐全,但 PR Type 与实际改动不一致。
- 是否可直接合入:不可。需先修正新手教程中的容器服务名示例,避免用户按文档执行时直接失败。
主要问题
- [Correctness blocker]
docs/deploy-beginner-video-script.md新增的 Docker Compose 示例使用了analyzer服务执行python main.py --help和python main.py --no-notify,但现有docs/DEPLOY.md中同类手动执行命令使用的是stock-analyzer服务。该 PR 的目标用户是“小白用户”,错误服务名会导致教程关键验收步骤不可执行,建议统一为仓库当前 Compose 文档中的服务名,或补充确认实际docker/docker-compose.yml中确实存在对应服务。
🤖 此回复由 OpenReview Bot 自动生成,仅供参考。如有疑问请 @维护者。
PR Type
Background And Problem
+236 / -0。Scope Of Change
docs/CHANGELOG.mddocs/DEPLOY.mddocs/DEPLOY_EN.mddocs/INDEX.mddocs/INDEX_EN.mddocs/deploy-beginner-video-script.mdDocumentation And Changelog
docs/CHANGELOG.md,docs/DEPLOY.md,docs/DEPLOY_EN.md,docs/INDEX.md,docs/INDEX_EN.md,docs/deploy-beginner-video-script.md。Issue Link
Closes #1267
Verification Commands And Results
关键输出/结论 / Key output & conclusion:
Compatibility And Risk
docs/CHANGELOG.md,docs/DEPLOY.md,docs/DEPLOY_EN.md,docs/INDEX.md,docs/INDEX_EN.md,docs/deploy-beginner-video-script.md,未识别额外兼容性风险。Rollback Plan
git revert <merge-commit>回滚本 PR 提交,重点确认docs/CHANGELOG.md,docs/DEPLOY.md,docs/DEPLOY_EN.md,docs/INDEX.md恢复正常。Acceptance Criteria
Checklist
docs/CHANGELOG.md,并在 PR 描述中说明文档落点 / Relevant docs anddocs/CHANGELOG.mdare updated, and the documentation location is stated in this PR