Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema description update should be considered as a metadata change #694

Open
stefknumias opened this issue Aug 13, 2024 · 0 comments
Open

Comments

@stefknumias
Copy link

stefknumias commented Aug 13, 2024

Hello,

When diffing this spec:

openapi: 3.0.3
info:
  title: Test
paths:
  /foo:
    post:
      requestBody:
        content:
          application/json:
            schema:
              type: string
              description: desc v1

with this one:

openapi: 3.0.3
info:
  title: Test
paths:
  /foo:
    post:
      requestBody:
        content:
          application/json:
            schema:
              type: string
              description: desc v2

I get the following output:

==========================================================================
==                            API CHANGE LOG                            ==
==========================================================================
                                   Test                                   
--------------------------------------------------------------------------
--                            What's Changed                            --
--------------------------------------------------------------------------
- POST   /foo
  Request:
        - Changed application/json
          Schema: Backward compatible
--------------------------------------------------------------------------
--                                Result                                --
--------------------------------------------------------------------------
                   API changes are backward compatible                    
--------------------------------------------------------------------------

Since only the description field changed, I would expect a "metadata" change instead of a "compatible" one.

Changes to the description are correctly marked as metadata ones internally (see here and here) but I suspect the final value that is picked up to be the default one returned here. I don't have the time or means to debug it further however.

Tested version: 2.1.0-beta.11

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

No branches or pull requests

1 participant