Replace kin-openapi with pb33f/libopenapi for OpenAPI parsing#2299
Open
dgageot wants to merge 1 commit intodocker:mainfrom
Open
Replace kin-openapi with pb33f/libopenapi for OpenAPI parsing#2299dgageot wants to merge 1 commit intodocker:mainfrom
dgageot wants to merge 1 commit intodocker:mainfrom
Conversation
kin-openapi versions above v0.132.0 lack a valid license, making it a dead-end dependency. Replace it with pb33f/libopenapi (Apache 2.0), which provides full OpenAPI 3.0/3.1 support and is actively maintained. Key changes: - Rewrite pkg/tools/builtin/openapi.go to use libopenapi's high-level V3 data model (Document, PathItem, Operation, SchemaProxy, etc.) - Remove kin-openapi and its transitive dependencies from go.mod - Remove the "never bump kin-openapi" warning from the bump-go-dependencies skill since the dependency no longer exists Assisted-By: docker-agent
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Replace
github.com/getkin/kin-openapiwithgithub.com/pb33f/libopenapi(Apache 2.0).kin-openapi versions above v0.132.0 lack a valid license, making it a dead-end dependency. libopenapi provides full OpenAPI 3.0/3.1 support and is actively maintained.
Changes
pkg/tools/builtin/openapi.go— Rewrite OpenAPI parsing to use libopenapi's high-level V3 data model (Document,PathItem,Operation,SchemaProxy, etc.). AddyamlNodeToValue()helper to preserve native types (int, float, bool) for enum and default values.pkg/tools/builtin/openapi_test.go— AddTestOpenAPITool_EnumAndDefaultTypesto verify type preservation for enum and default schema values.go.mod/go.sum— Remove kin-openapi and its transitive deps, add libopenapi..agents/skills/bump-go-dependencies/SKILL.md— Remove the "never bump kin-openapi" warning.Security
External reference resolution remains disabled by default (libopenapi sets
AllowFileReferences=falseandAllowRemoteReferences=false), matching the previous kin-openapi behavior.