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

stacklok / toolhive / 24408864584
66%

Build:
DEFAULT BRANCH: main
Ran 14 Apr 2026 03:54PM UTC
Jobs 1
Files 618
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

14 Apr 2026 03:49PM UTC coverage: 65.594% (-0.06%) from 65.649%
24408864584

push

github

web-flow
Change GroupRef from bare string to typed MCPGroupRef struct (#4809)

* Change GroupRef from bare string to typed MCPGroupRef struct

GroupRef was a bare string while every other cross-CRD reference
(ExternalAuthConfigRef, ToolConfigRef, AuthServerRef, EmbeddingServerRef)
uses a typed struct. This inconsistency prevented extending GroupRef
with additional fields (like namespace) without a breaking change.

Define MCPGroupRef struct with Name field and nil-safe GetName() helper.
Replace GroupRef string with *MCPGroupRef on MCPServerSpec,
MCPRemoteProxySpec, MCPServerEntrySpec, and add a new top-level GroupRef
field on VirtualMCPServerSpec that takes precedence over the deprecated
config.groupRef string path.

Internal types (vmcpserver.Config, StatusResponse, BackendReconciler,
config.Config) remain as strings since they are not CRD API types.

This is a breaking wire-format change (groupRef: "name" becomes
groupRef: {name: "name"}) that must happen before v1beta1.

Closes #4634

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Address review feedback on MCPGroupRef refactoring

- Add nil guard to MCPServerEntry validateGroupRef using GetName()
  instead of direct .Name access to prevent potential panic
- Add unit tests for MCPGroupRef.GetName() and
  VirtualMCPServer.ResolveGroupName() covering precedence logic
- Normalize nil-check pattern across all field index extractors to
  use GetName() == "" (handles both nil and empty name)
- Mark config.Config.Group as optional and deprecated since
  spec.groupRef is now the preferred path
- Improve Validate() error message to mention both spec.groupRef
  and config.groupRef paths

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

* Update missed example and docs for MCPGroupRef wire format

- Fix vmcp_with_telemetry_ref.yaml (missed in initial pass)
- Update virtualmcpserver-api.md to document spec.groupRef as primary
  field and update all YAML examples to struct f... (continued)

71 of 113 new or added lines in 12 files covered. (62.83%)

53 existing lines in 9 files now uncovered.

57073 of 87010 relevant lines covered (65.59%)

62.37 hits per line

Uncovered Changes

Lines Coverage ∆ File
14
42.07
0.14% cmd/thv-operator/api/v1alpha1/zz_generated.deepcopy.go
9
8.15
-0.09% cmd/thv-operator/main.go
6
46.26
0.0% pkg/vmcp/k8s/backend_reconciler.go
5
64.12
0.02% cmd/thv-operator/controllers/mcpgroup_controller.go
5
60.79
-0.05% cmd/thv-operator/controllers/mcpremoteproxy_controller.go
2
59.88
0.0% cmd/thv-operator/controllers/virtualmcpserver_controller.go
1
71.65
1.16% cmd/thv-operator/api/v1alpha1/virtualmcpserver_types.go

Coverage Regressions

Lines Coverage ∆ File
14
74.44
-5.19% pkg/client/config.go
11
68.83
-14.29% pkg/client/discovery.go
8
20.11
-2.87% pkg/client/manager.go
6
72.35
-1.93% pkg/runner/config.go
6
76.15
-5.5% pkg/secrets/keyring/keyctl_linux.go
3
79.38
-0.77% pkg/transport/proxy/httpsse/http_proxy.go
2
71.43
-1.68% pkg/vmcp/k8s/manager.go
2
51.71
-0.19% pkg/workloads/manager.go
1
71.65
1.16% cmd/thv-operator/api/v1alpha1/virtualmcpserver_types.go
Jobs
ID Job ID Ran Files Coverage
1 24408864584.1 14 Apr 2026 03:54PM UTC 618
65.59
GitHub Action Run
Source Files on build 24408864584
  • Tree
  • List 618
  • Changed 24
  • Source Changed 15
  • Coverage Changed 19
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #24408864584
  • 0c5213e3 on github
  • Prev Build on main (#24406369705)
  • Next Build on main (#24410505212)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc