Skip to content

Conversation

@daveshanley
Copy link
Member

@daveshanley daveshanley commented Sep 20, 2025

Full and complete OpenAPI 3.2 support.

https://learn.openapis.org/upgrading/v3.1-to-v3.2.html
https://github.com/OAI/OpenAPI-Specification/releases/tag/3.2.0

This is a breaking change

Issue #117 has been implemented which means BuildV3Model() will return an error instead of []error as we're now using errors.Join.

@daveshanley daveshanley requested a review from Copilot September 20, 2025 13:58
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR implements full and complete OpenAPI 3.2 support for libopenapi, adding all new OpenAPI 3.2 features while maintaining backward compatibility. The changes span across low-level data models, high-level APIs, change detection, and schema validation.

Key changes include:

  • Addition of OpenAPI 3.2-specific fields across various objects (Server name, Response summary, XML nodeType, etc.)
  • Support for new OpenAPI 3.2 features like additional operations, device OAuth flows, and mediaTypes components
  • Implementation of change detection for all new 3.2 fields with appropriate breaking change classifications
  • Updated schema validation to use the official OpenAPI 3.2 schema

Reviewed Changes

Copilot reviewed 68 out of 68 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
datamodel/schemas/oas32-schema.json Updated to official OpenAPI 3.2 schema with proper versioning
datamodel/spec_info.go Added $self field extraction for OpenAPI 3.2+ documents
datamodel/low/v3/*.go Extended low-level models with OpenAPI 3.2 fields and proper hash computation
datamodel/high/v3/*.go Added high-level wrappers for new OpenAPI 3.2 features
what-changed/model/*.go Implemented change detection for all new 3.2 fields with breaking change analysis

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@codecov
Copy link

codecov bot commented Sep 20, 2025

Codecov Report

❌ Patch coverage is 99.01961% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 99.68%. Comparing base (891836c) to head (63a748b).
⚠️ Report is 23 commits behind head on main.

Files with missing lines Patch % Lines
datamodel/low/v3/path_item.go 96.66% 5 Missing ⚠️
document.go 96.77% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##             main     #472    +/-   ##
========================================
  Coverage   99.67%   99.68%            
========================================
  Files         171      171            
  Lines       24987    25472   +485     
========================================
+ Hits        24906    25391   +485     
  Misses         76       76            
  Partials        5        5            
Flag Coverage Δ
unittests 99.68% <99.01%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ 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.

tests shows code was not working as required, it is now.
additional operations were not being handled properly, now they are! use the raw key, or dump custom operation methods in with the known ones and libopenapi will pull them all out for you.
not sure why it’s failing. but anyway
Finally did it! and now we have a clean path to 1.0!
works on my machine bro.
@daveshanley daveshanley merged commit a946f44 into main Sep 22, 2025
3 of 4 checks passed
@daveshanley daveshanley deleted the v0.27.3 branch September 22, 2025 11:25
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.

2 participants