Repository navigation
fix(waveform): load preview windows by acquisition time - #23
Merged
Merged
Conversation
cuimmm
previously approved these changes
Nov 16, 2026
yangdekun2026
previously approved these changes
Nov 16, 2026
There was a problem hiding this comment.
AI 代码审查(claude-opus-5-5)
总体:这次改动方向合理。用块头建立“采集时间 → 样本位置”的映射,再把读取限制在命中的范围内,同时保留了空档和 WAV_ONLY 原子提交的语义;新增的单元测试也覆盖了空档、增长尾块、缓存和回放穿越空档等主要场景。合并前主要有以下几点需要处理:
- 索引失败没有回退:时间索引现在是历史波形加载的必经步骤。任一文件校验失败,例如时间戳递减、混合时钟,或单个文件 I/O 出错,都会让整个序列无法加载,而之前这些记录可以正常显示。PR 描述说“递减或重叠时间戳不进入曲线”,但实测文档写的是“主波形样本数为 0”,两者不一致。建议在索引失败时降级到原有索引,并补充失败路径的测试。
- 制品是否完整:
package.json改为引用vendor/crychart/crychart-1.0.1-opentest.31.tgz,但本次 diff 中看不到该 tgz、vendor/crychart/manifest.json或锁文件的变更(也可能是二进制文件未展示)。请确认它们已一并提交,否则安装或构建会失败。另外,该制品来自 CRYChart #5 分支上的提交bd21e08。若该 PR 尚未合入上游,请在 manifest 中写明其状态,便于之后追溯和替换。 - 增长文件性能:增长中的文件不进入缓存,每次索引刷新都会从文件头重新扫描全部块头。长时间录制时,这部分开销会随文件大小线性增长。
- 流程事项:PR 描述中“贡献授权”一项没有勾选,按仓库流程需要提交者确认。全仓类型检查仍有既有错误,文档中已如实说明,这里不作为本 PR 的阻塞项。
以下逐行意见中,有几处依赖图表实例或 worker 管理器的实际行为,我无法从 diff 中确认,已在对应位置说明理由。
跳过 5 个文件(锁文件、生成文件、二进制或无文本 diff)
由 AI 自动生成,仅供参考,不作为合并依据。审查提交:
69215c0。维护者可评论/review重新审查。
KyleHuangFromHZ
dismissed stale reviews from yangdekun2026 and cuimmm
via
November 16, 2026 06:13
9830833
added 2 commits
November 17, 2026 19:33
Keep the npm distribution and use CRYChart 1.0.2 for the high-precision waveform interval cap.
Contributor
Author
|
已合入最新 main(d61c5693),更新提交为 3ac84a5。分支无冲突;未执行将本 PR 合入 main 的操作。 本轮逐项核对原有 9 条 AI 意见:索引失败提示与拒绝倒序、公共时间原点、活动文件增量扫描、未写入前沿、块头读取上限、worker 取消、不可达缓存分支、fake timer 清理均保留对应修复/回归;制品意见已随 npm 依赖接入重新核验。目前没有未解决的 review thread。 验证:250 项相关回归和 24 项制品/打包检查通过。通过 opentest-run 确认 windows-huang 的独立实例运行后,CDP 的 58 项窗口、历史、回放、单位和 Scope 检查全部通过,运行中的前端模块和 worker 与本次功能分支的构建记录匹配。此次 main 更新没有改变前端源码;Windows 实例仍使用原有配套后端和原生库,不能据此宣称新后端整体验收通过。 当前检查状态:
|
mingtaojin
approved these changes
Nov 18, 2026
cuimmm
approved these changes
Nov 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
改了什么,为什么 / What changed and why
有预览的历史波形切到
h:m:s时,高精度 X 轴可能放开 15 秒上限;有采集空档的记录也可能按名义时长选错分片。现在细节窗口最多 15 秒,文件 worker 从块头建立实际采集时间到样本位置的映射,只读取命中的样本范围。跨文件和文件内空档保留,回放按时钟穿过空档,递减或重叠时间戳不进入曲线。回到已淘汰的窗口会重新读取,WAV_ONLY保留分片齐备后再提交的行为。配套图表修复:CRYChart #5。本 PR 固定消费可独立构建的
1.0.1-opentest.31,制品清单记录图表提交bd21e08、源码补丁和 SHA-256。怎么验证的 / How it was verified
单元测试或集成测试 / Unit or integration tests
真机验证 / Verified on real hardware(采集设备 / capture device)
不涉及设备 / Does not affect devices
更新到最新
main后,宿主波形相关测试 195 项、制品检查 8 项、文档检查均通过。更新基线前,在
windows-huang完整产品实例中用 CDP 通过 81 项检查,覆盖历史数据、空档回放、退回已淘汰窗口、单位切换、递减时间戳和 Monitor Scope。120 秒请求由读取约 46 MB 限制到约 17 MB;普通窗口就绪中位数为 289 ms,对照为 293 ms。实测记录注明了实测基线和首屏耗时波动;当时全仓类型检查仍有本次改动之外的错误。
影响 / Impact
回滚 / Door: 可回退。回退宿主提交即可恢复原有读取逻辑和包版本,不涉及历史文件迁移。
范围 / Blast radius: 历史波形窗口加载和回放。
贡献授权 / Contribution license