Skip to content

Conversation

@peppescg
Copy link
Contributor

@peppescg peppescg commented Nov 17, 2025

The Swagger/OpenAPI documentation generated by swaggo/swag was creating schema definitions with names derived from the Go package structure, specifically using types.* as the schema prefix (e.g., types.ImageMetadata, types.RemoteServerMetadata, types.EnvVar, types.Header, etc.).

This naming convention was problematic for the toolhive-studio cause typescript will use types.EnvVar rather than Registry.EnvVar

Fixed move up the type files

@codecov
Copy link

codecov bot commented Nov 17, 2025

Codecov Report

❌ Patch coverage is 23.52941% with 26 lines in your changes missing coverage. Please review.
✅ Project coverage is 55.23%. Comparing base (c4a0c65) to head (32984bd).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
pkg/auth/remote/config.go 0.00% 14 Missing ⚠️
pkg/api/v1/registry.go 14.28% 6 Missing ⚠️
pkg/container/verifier/verifier.go 0.00% 4 Missing ⚠️
pkg/runner/env.go 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2615      +/-   ##
==========================================
+ Coverage   55.20%   55.23%   +0.02%     
==========================================
  Files         315      315              
  Lines       30123    30123              
==========================================
+ Hits        16630    16638       +8     
+ Misses      12049    12036      -13     
- Partials     1444     1449       +5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@peppescg peppescg self-assigned this Nov 17, 2025
@peppescg peppescg force-pushed the rename-registry-type branch 4 times, most recently from e8657cc to 32b6328 Compare November 18, 2025 17:15
@peppescg peppescg marked this pull request as ready for review November 18, 2025 17:22
@peppescg peppescg force-pushed the rename-registry-type branch from 891cc51 to 32984bd Compare November 19, 2025 11:25
@peppescg peppescg merged commit 2585128 into main Nov 19, 2025
33 checks passed
@peppescg peppescg deleted the rename-registry-type branch November 19, 2025 11:38
@dmartinol
Copy link
Collaborator

@peppescg @dmjb FYI, this broke some code in the toolhive-registry-server dependant repo, maybe we need some coordination before updating exported pkg names. Fixed in stacklok/toolhive-registry-server#139

@peppescg
Copy link
Contributor Author

@peppescg @dmjb FYI, this broke some code in the toolhive-registry-server dependant repo, maybe we need some coordination before updating exported pkg names. Fixed in stacklok/toolhive-registry-server#139

@dmartinol sorry for that and thanks for the fix. You're right that we need to coordinate, our fault sorry.

@blkt
Copy link
Contributor

blkt commented Nov 19, 2025

@peppescg @dmjb FYI, this broke some code in the toolhive-registry-server dependant repo, maybe we need some coordination before updating exported pkg names. Fixed in stacklok/toolhive-registry-server#139

@dmartinol that's our fault, we were aware this was coming (and actually helped making it land). The underlying problem is that swag, the tool we use to generate openapi specs, uses package names to produce names reported in the spec. This is a major problem because we originally moved this under /regisry/types and this broke @peppescg's work, so we moved it under a package that (a) reverted the breaking changes for @peppescg, and (b) solved a circular dependency in that package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants