• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

stacklok / toolhive / 30082959484
69%

Build:
DEFAULT BRANCH: main
Ran 24 Jul 2026 09:39AM UTC
Jobs 1
Files 829
Run time 2min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

24 Jul 2026 09:32AM UTC coverage: 69.231% (-0.1%) from 69.336%
30082959484

push

github

web-flow
Add thv skill sync: restore project skills from the lock file (#5895)

* Add thv skill sync: restore project skills from the lock file

RFC THV-0080 needs a way to restore a project's pinned skill set on
any machine (a fresh clone, CI, a teammate's laptop) and to verify
on-disk content still matches the lock file without installing
anything. This adds the full sync vertical slice: service logic,
HTTP endpoint, client, and CLI command.

- Sync reconciles installed skills against toolhive.lock.yaml:
  missing/drifted entries reinstall at the pinned reference (never
  re-resolving source, see buildPinnedReference), --check reports
  drift read-only, --adopt/--prune handle unlocked installs
- Fixes a real bug this surfaced: reinstalling at an unchanged
  pinned digest hit both the OCI and git install paths' "same
  digest means content is already correct" fast path, silently
  skipping re-extraction — exactly the drift sync exists to repair.
  A new internal SyncRestore option bypasses that fast path.
- POST /api/v1beta/skills/sync via a narrow skillSyncer interface
  (pkg/api/v1), so this PR doesn't need to ship an Upgrade stub
- `thv skill sync` CLI (--check/--adopt/--prune/--clients/
  --project-root, auto-detected via .git when omitted)

Part of the production stack for #5715 (RFC THV-0080). Stack: 4/6.

* Preserve ResolvedReference across sync drift repair

reinstallPinned reinstalls at a pinned reference derived from the
lock entry, and that pinned string was flowing straight into
ResolvedReference via the install path — a drift repair overwrote
it with an internal restore form instead of preserving what Source
had actually resolved to, which later corrupts upgrade's ref-change
detection. Add a LockResolvedReference override on InstallOptions,
mirroring the existing LockSource one.

* Regenerate swagger docs for SyncResult field changes

Picks up the AlreadyCurrent JSON tag rename and Drifted doc comment
fix from the PR2 review pass.

* Report missi... (continued)

199 of 336 new or added lines in 9 files covered. (59.23%)

86 existing lines in 8 files now uncovered.

78271 of 113058 relevant lines covered (69.23%)

80.61 hits per line

Uncovered Changes

Lines Coverage ∆ File
59
20.27
cmd/thv/app/skill_sync.go
49
66.67
pkg/skills/skillsvc/sync.go
14
74.27
-5.42% pkg/skills/client/client.go
9
9.76
-2.74% cmd/thv/app/skill_helpers.go
6
85.71
pkg/skills/skillsvc/pin.go

Coverage Regressions

Lines Coverage ∆ File
62
62.04
-5.35% pkg/workloads/manager.go
6
76.15
-5.5% pkg/secrets/keyring/keyctl_linux.go
5
0.0
-100.0% pkg/workloads/sysproc_unix.go
3
96.36
-0.47% pkg/authz/authorizers/cedar/core.go
3
71.85
-1.11% pkg/ignore/processor.go
3
80.56
-0.7% pkg/transport/proxy/httpsse/http_proxy.go
2
96.05
0.0% pkg/authserver/storage/memory.go
2
93.94
-6.06% pkg/foreach/foreach.go
Jobs
ID Job ID Ran Files Coverage
1 30082959484.1 24 Jul 2026 09:39AM UTC 829
69.23
GitHub Action Run
Source Files on build 30082959484
  • Tree
  • List 829
  • Changed 17
  • Source Changed 8
  • Coverage Changed 16
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #30082959484
  • 52bc0638 on github
  • Prev Build on main (#30081604025)
  • Next Build on main (#30085604672)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc