-g agent scan + rollback silently unpatch a hosted NuGet project's install
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
调研方向
Start with the hosted NuGet ownership handling described around NuGetCrawler::global_roots_shared_with, commands::vendor_owned_keys, and the hosted_wiring_retained warning, then inspect the e2e_nuget_dotnet_build fixture. Reproduce with hosted scan, locked restore, global agent scan, and global rollback using NUGET_PACKAGES set to the restore folder. Done means the global workflow preserves the hosted pin's patched bytes and reports the ownership outcome consistently; the issue leaves the CLI contract decision open.
由索引模型根据 Issue 内容生成。
描述
[agent] Split out of #489 (the hosted-mode variant from https://github.com/SocketDev/socket-patch/issues/489#issuecomment-5937178049, reported 2026-10-01).
Summary
A hosted NuGet project's locked restore extracts the Socket-feed nupkg into the global packages folder (~/.nuget/packages or NUGET_PACKAGES). A global agent run started in that project treats the copy as a separate global install. scan -g --mode agent --yes reports applied: 1 and writes an agent record. rollback -g --yes then restores upstream bytes into it with rolledBack: 1. The next dotnet restore --locked-mode says "up-to-date" and keeps the pristine bytes, so the project builds unpatched with exit 0 everywhere.
This predates #446: -g never consulted the project's hosted pins. #1790 fixes the vendored half of #489. It treats the project's vendored NuGet packages as ledger-owned when the global folder is one the project restores into (NuGetCrawler::global_roots_shared_with, commands::vendor_owned_keys).
Why it's separate
Hosted mode has no ownership skip even in project scope. Agent scan over a hosted pin warns (hosted_wiring_retained) and proceeds, and project-scope rollback unwinds the pin through its hosted leg. Under -g neither the hosted leg nor the warning runs. Fixing this needs a contract decision: either a new skip reason/code for "hosted pin owns this copy" in scan/apply/rollback under -g, or running discovery under -g and reusing hosted_wiring_retained plus a rollback skip. That's new CLI surface, not the vendored ownership rule #1790 restores.
Repro
As in #489's hosted comment: the e2e_nuget_dotnet_build hosted fixture, scan --mode hosted, a locked restore, then scan -g --mode agent --yes and rollback -g --yes with NUGET_PACKAGES set to the restore's folder.
Generated by Claude Code
- 主要语言
- Rust
- 星标
- 9
- 派生
- 2
- 平均合并
- 20 小时 47 分钟
- 30 天内合并 PR
- 681
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
SocketDev/socket-patch 的其他 Issue
-
agent:triaged arch-audit priority:p3 refactor
难度 2/5 1-3 小时 新手友好度 83/100
SocketDev/socket-patch#1860 ·
维护者通常 1 天内回复
-
agent:triaged arch-audit priority:p3 refactor
难度 2/5 1-3 小时 新手友好度 78/100
SocketDev/socket-patch#1838 ·
维护者通常 1 天内回复
-
arch-audit refactor
难度 4/5 3-5 天 新手友好度 54/100
SocketDev/socket-patch#1993 ·
维护者通常 1 天内回复
-
arch-audit refactor
难度 3/5 1-2 天 新手友好度 66/100
SocketDev/socket-patch#1992 ·
维护者通常 1 天内回复
-
agent:triaged arch-audit priority:p3 refactor
难度 4/5 3-5 天 新手友好度 35/100
SocketDev/socket-patch#1987 · 1 条评论 ·
维护者通常 1 天内回复
查看 SocketDev/socket-patch 的全部 Issue
相似的 Issue
-
难度 1/5 1 小时以内 新手友好度 82/100
saltnpepper97/halley#271 ·
维护者通常 1 天内回复
-
Remove the unused gh-aw agentic workflow setup可能已有人在做 @AviAvni 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 3 天内回复
-
bug stdlib
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
enhancement good first issue
难度 1/5 1-3 小时 新手友好度 83/100
Sh1n1230/PunctuationToggle#308 ·
维护者通常 1 天内回复
-
Perl - Readme Drift可能已有人在做 @Omnideth 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 76/100
CommunityToolkit/Aspire#2375 ·
维护者通常 2 天内回复