Home

mweinbach / agent-coworker

publicmweinbach/agent-coworker
Overview Code History Branches Pull requestsIssuesInsights
main
HomeOverview Code PRsIssues

fix(plugins): pin install/update to one commit to end marketplace hash races

2 months ago

5e52cd6
Authored
mweinbach7/6/2026, 9:29:10 PM
Plugin install/update downloaded the plugin files and the marketplace
manifest in separate branch-ref fetches. GitHub caches those paths
independently, so right after a push one fetch could see the new commit
while the other served the previous one, failing the update with
"Marketplace source hash mismatch" until the caches converged.

Resolve the source ref to its commit SHA once per operation, download
the plugin tree at that immutable commit, and read the same-repo
marketplace manifest at it too (still parsed against the branch ref so
plugin sourceInputs keep matching recorded install metadata). Any
resolution failure falls back to the previous branch-ref behavior, and
a hash mismatch that survives pinning now names the commit so a truly
stale manifest is actionable.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

Parentab1ad55

7 files changed
  • src/extensions/github.ts+25−0
  • src/plugins/marketplaceRegistry.ts+14−10
  • src/plugins/operations.ts+62−5
  • src/plugins/remoteMarketplace.ts+13−2
  • src/plugins/sourceResolver.ts+49−0
  • test/plugins.catalog.test.ts+270−1
  • test/plugins.sourceResolver.test.ts+69−0