python / python/cpython

Composability of `difflib`

未關閉
#145,209 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

stdlib type-feature
主要語言
Python
星號
77.2k
分支
35.9k
PR 合併指標
PR 指標待擷取

描述

Feature or enhancement

Proposal:

I closed https://github.com/python/cpython/issues/144132 in favour to more gradual divide and conquer approach.

And this is the first part, which I think is the most valuable one.
It enables user to implement his own Matcher and Differ types to do all the nice things that difflib enables.

Given the current state of affairs, I don't think there were many ways to do it.
And in terms of nature of arguments provided to different functions, I only saw one.

Very much open to any suggestions / concerns.

Has this already been discussed elsewhere?

I have already discussed this feature proposal on Discourse

Links to previous discussion of this feature:

https://discuss.python.org/t/algorithmic-complexity-of-difflib/105844/98

Linked PRs
  • gh-145210

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

研究方向

先檢視連結的 PR gh-145210 以及 issue 中引用的 Discourse 討論,然後檢查 Python 的 difflib 實作與公開 API。當所提出的可組合性方法有了確定的設計,且連結的貢獻或因此產生的變更處理了該提案時,工作即告完成。

由索引模型根據 Issue 內容生成。

評估

技術堆疊
python
領域
tooling
Issue 類型
功能
難度
5/5
預估耗時
一週以上
活躍度
停滯
描述清晰度
需要釐清
新手友好度
25/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。