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

redoc-cli: "bundle" does not produce the same output as "serve" #547

Closed
mschefer opened this issue Jun 25, 2018 · 1 comment
Closed

redoc-cli: "bundle" does not produce the same output as "serve" #547

mschefer opened this issue Jun 25, 2018 · 1 comment

Comments

@mschefer
Copy link

The following example does not produce the same output for "bundle" and "serve":

openapi: 3.0.1
info:
  title: Test API
  description: Test API
  version: 1.0.0

tags:
  - name: Test

paths:
  /api/test:
    get:
      summary: example request
      tags:
        - Test
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Response'
components:
  schemas:
    PartA:
      type: object
      properties:
        propA:
          type: string
    PartB:
      type: object
      properties:
        propB:
          type: string
    Response:
      type: object
      allOf:
        - $ref: '#/components/schemas/BaseResponse'
      properties:
        propC:
          $ref: '#/components/schemas/PartB'
    BaseResponse:
      type: object
      properties:
        propD:
          $ref: '#/components/schemas/PartA'

The response schema of the example request seems to correct when using redoc-cli serve test.yaml:

example1

However, when using redoc-cli bundle test.yaml a recursion is detected:

example2

@RomanHotsiy
Copy link
Member

@mschefer thanks for the detailed issue report.
Will check it asap

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

No branches or pull requests

2 participants