Skip to content

Fix multi-file bundling of OpenAPI 3.0 schemas - #924

Merged
jviotti merged 3 commits into
mainfrom
oas-3-0-fix
Oct 27, 2026
Merged

jviotti merged 3 commits into
mainfrom
oas-3-0-fix

Conversation

@jviotti

@jviotti jviotti commented Oct 27, 2026

Copy link
Copy Markdown
Member

Signed-off-by: Juan Cruz Viotti jv@jviotti.com

Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
@augmentcode

augmentcode Bot commented Oct 27, 2026

Copy link
Copy Markdown
🤖 Augment PR Summary

Summary: Makes imported schemas respect their dialect's keyword vocabulary.
Targets multi-file OpenAPI 3.0 bundling without adding unsupported metadata.
Changes:

  • Adds a vocabulary-aware dialect_defines helper.
  • Only injects $schema when the dialect defines it.
  • Only rewrites identifiers when their keyword is supported.
  • Leaves imported boolean schemas unchanged.
  • Adds OpenAPI 3.0 bundling, compilation, and validation tests.
  • Covers mixed OpenAPI 3.0/2020-12 resources and boolean imports.
  • Registers all six new CLI tests with CMake.

🤖 Was this summary useful? React with 👍 or 👎

@augmentcode augmentcode Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Review completed. 1 suggestion posted.

Fix All in Augment

Comment augment review to trigger a new review at any time.

1> "type": "object",
1> "properties": {
1> "name": {
1> "$ref": "[CWD_URI]/nested.json"

@augmentcode augmentcode Bot Oct 27, 2026 •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

At test/bundle/pass_resolve_boolean_schema.clitest:30, this $ref still points to the external file: a $defs key does not give its boolean value an $id. Could you check this case's standalone behavior, since the expected bundle cannot resolve this reference after nested.json is removed?

Severity: medium

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.

Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
@jviotti
jviotti merged commit 47de6b0 into main Oct 27, 2026
16 checks passed
@jviotti
jviotti deleted the oas-3-0-fix branch October 27, 2026 19:22
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.

1 participant