Skip to content

修复浏览器代理 OTA 竞态并发布 0.5.1 - #36

Merged
massif-01 merged 1 commit into
mainfrom
fix/browser-ota-recovery-0.5.1
Jun 11, 2026
Merged

修复浏览器代理 OTA 竞态并发布 0.5.1#36
massif-01 merged 1 commit into
mainfrom
fix/browser-ota-recovery-0.5.1

Conversation

@massif-01

@massif-01 massif-01 commented Jun 11, 2026

Copy link
Copy Markdown
Member

概要

  • 修复浏览器代理 OTA 的 WebUI 写入竞态:/api/v1/ota/www 只有在保存 www.bin 且同步刷写 www 分区完成后才返回 success。
  • 增加 recovery manifest 的 armed 语义:浏览器代理路径保留 recovery 素材但写入 armed:false,避免重启后误触发 SD recovery。
  • 增加上传完整性校验和 OTA busy guard,避免半包上传擦写分区或覆盖 recovery 文件。
  • 将版本提升到 0.5.1,并更新本地构建产物。

关键行为

  • 固件代理上传仍使用 auto_reboot=false,WebUI 上传成功后前端再调用 system.reboot。
  • /api/v1/ota/firmware?auto_reboot=true 恢复为 success 响应发送后再延迟重启。
  • 旧 SD 卡/URL WebUI OTA 继续保留异步任务模型和 progress 轮询。
  • 旧 manifest 缺省 armed:true,兼容已有 SD 卡 recovery 包。

验证

  • git diff --check HEAD
  • node --check components/ts_webui/web/js/app.js
  • python3 -m py_compile OTA_Server/server.py
  • ./tools/build.sh --fresh,生成版本 0.5.1+e62c99e.06111755
  • 串口刷写本地固件,设备启动到 0.5.1,WebUI 挂载成功,/index.html 返回 TS_ASSET_VERSION = '20260611-ota-path'

Release / Actions

@massif-01
massif-01 merged commit 04e2bdb into main Jun 11, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant