Repository navigation
refactor: 統一產品目錄與命名,按責任分類下載模組 - #764
Merged
Merged
Conversation
crazysmile-PhD
marked this pull request as ready for review
November 16, 2026 06:41
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
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.
產品原始碼原本分散在根目錄與
src/,ViewModel 同時使用View前綴和ViewModel後綴,下載模組的準備、傳輸、產物與 UI 投影則混在同一層。查找一項責任時,需要先排除大量無關檔案;掃描、測試與打包入口也各自維護多個來源根目錄。本次將產品專案統一到
src/、簡化重複命名,並按既有責任整理下載目錄。驗收聚焦於分類一致、來源內容保留、依賴方向與行為相容。改動
DownKyi與DownKyi.Core移入src/,更新 solution、ProjectReference、圖示/notice/FFmpeg 資源、建置、macOS 打包及 API audit 路徑。舊版本重建使用舊 checkout,保留其歷史路徑。View…ViewModel型別改為…ViewModel,同步調整 43 個含 partial 的來源檔、XAML binding、DI、導航 factory 與測試。保留能區分領域與用途的名稱。Planning、Transfer、Artifacts、Presentation、Runtime。根目錄保留DownloadComposition與DownloadRuntimeFactory。83 個搬移檔案在搬移前後逐位元組相同,沿用 namespace、型別與 assembly。Directory.Build.targets、兩行失效的註解程式碼,以及重複列舉產品來源根目錄的設定;來源統計從實體src/推導。artifacts/ignore 限定為根目錄/artifacts/:原規則在 Windows 上會連來源目錄Artifacts一起忽略。已確認所有搬移檔案均納入 Git,根目錄產物仍被排除。整個 diff 有 301 個搬移/更名;檔案數量主要來自路徑與型別名稱傳播。
論文與實際專案的交叉對照
以下「採用方式」是對 DownKyi 的設計取捨。外部原始碼連結固定在所檢查的提交。
DownloadViewModel;Parabolic 用 RecoverableDownload 表達恢復資料的用途。View前綴,保留ViewModel、Download等有意義的角色/領域詞。不同協定 DTO 與 UI projection 仍是不同概念,這次保留其既有名稱與 namespace。適用差異與實際踩坑
DownloadMediaContract和既有 Requested/Available/Finalized/Result 語義。這些案例是取捨的參考;外部專案的修正不代表 DownKyi 存在相同缺陷。研究與比較集中在本 PR 描述,儲存庫文件只同步目前分類、命名與路徑。
驗證
Windows x64,.NET SDK
11.0.100;提交a50aa450123b1794bb625ab9238d218da2f884e6的 tree 與完成本機驗證的 index 完全相同,提交後 worktree clean。--no-incremental、all analyzers、warnings-as-errors、禁用 shared compilation;0 warnings / 0 errors。script/test-solution.ps1 -Configuration Release -NoRestore -NoBuild:8 個 Windows 適用專案,2,000 passed、0 failed。另有 1 個既有 explicit 子程序探針為 NotRunnable,由父測試另行呼叫。正式命令依 repository 規定在同一 worktree 順序執行。macOS/Linux 原生執行、打包與遠端 CodeQL 由本 PR CI 驗證。
回滾
整體 revert 本次整理提交,讓來源、測試、建置與打包引用一起恢復。設定、SQLite schema 與續傳格式均未遷移。