Skip to content

.gitattributes 未钉 *.py 致 journey 驱动脚本全文 CRLF 漂移(多轮 CR 评审噪音源)——#904 CR 观察 #905

Closed

Description

@caomengxuan666

来源:PR #904 CR 评审观察(非该 PR 引入)。

形态

scripts/journey/ 下的 journey 驱动 .py 文件在 master 上全文 CRLF(.gitattributes 未钉 *.py,仓库级工具链漂移)——多轮 CR 评审均触碰过此面(#443/#444 的 journey 脚本、probe 脚本),Windows 编辑器/工具链会持续在 LF/CRLF 间抖动制造 diff 噪音。

修法

.gitattributes 补 *.py text eol=lf(或按需 scripts/**/*.py),全仓 .py renormalize 一次(git add --renormalize .),确认无行为面依赖 CRLF 的 .py(grep 极少)。

验收

renormalize 后 git diff 干净收敛;跨编辑器往返不再产生行尾 diff;CI 全绿。

Activity

  1. arookieofc commented on Oct 20, 2026

    @arookieofc
    Member

    Fixed by PR #907 (branch arookieofc/fix-905-gitattributes-py). .gitattributes pins *.py eol=lf; scripts/audit/nested-context-probes.py renormalized (its HEAD blob carried 129 CRLFs). Staged diff is 129+/129- and empty under --ignore-cr-at-eol, so pure convergence, no content change. Note: a bare full-tree renormalize staged ~750 unrelated files (pre-existing CRLF worktree smudge across vendored trees got exposed by the index touch) - I reset that back and scoped the PR to the 2 files. This clone was also missing core.autocrlf=true (repo assumes it); set it locally. third_party/oil *.py deliberately untouched (vendored ownership). No repo .py references CR bytes, so nothing depends on CRLF.

  2. added a commit that references this issue on Oct 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions