Compare code semantically across a force push in review bundles

未关闭
#606 0 条评论 0 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 1 天内回复

@Alan52254 已经在做这个了。

开始于 2026年11月6日。

评估

这个 Issue 还没有评估数据。

描述

Problem

After a force push, review-bundle.sh --since points a reviewer to a tree diff or a git range-diff. Both compare lines. When an author reworks a commit, the range-diff reads almost as long as the whole diff: 925 of 1200 lines on #586, 624 of 1284 on #584.

Current behavior

diffmodel.py pairs moved units by indentation, which workbench.md calls a guess at syntax and not a parse. since.range-diff.txt shows a reworked commit as removed and added lines, so a rename or a moved function reads as new code.

Desired outcome

A reviewer reading a rewritten pull request sees which functions or blocks changed in meaning, and which only moved or were renamed, without rereading the whole commit.

Scope

  • A comparison that builds on diffmodel.py's unit pairing.
  • The rewrites of #585, #584 and #586 as its cases.
  • No code from or call to OmniDiff, whose license is incompatible with CodeTrial.

Out of scope

Replacing since.diff and since.range-diff.txt; they stay the fallback.

Related

#605 adds those two files for #587.

主要语言
Rust
星标
223
派生
148
平均合并
1 天 10 小时
30 天内合并 PR
227

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

sysprog21/codetrial 的其他 Issue

查看 sysprog21/codetrial 的全部 Issue

相似的 Issue

更多 Rust Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。