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

Incompatible types in allOf at "/properties/data/items" #1156

Closed
Stwissel opened this issue Jan 13, 2020 · 1 comment
Closed

Incompatible types in allOf at "/properties/data/items" #1156

Stwissel opened this issue Jan 13, 2020 · 1 comment

Comments

@Stwissel
Copy link

Just tried to render my schema online at https://redocly.github.io/ and the error:

Something went wrong...
Incompatible types in allOf at "/properties/data/items"
Stack trace
Error: Incompatible types in allOf at "/properties/data/items"
    at e.mergeAllOf (https://redocly.github.io/redoc/redoc-demo.bundle.js:1:44002)
    at e.mergeAllOf (https://redocly.github.io/redoc/redoc-demo.bundle.js:1:44362)
    at e.mergeAllOf (https://redocly.github.io/redoc/redoc-demo.bundle.js:1:44205)
    at new e (https://redocly.github.io/redoc/redoc-demo.bundle.js:1:47230)
    at new e (https://redocly.github.io/redoc/redoc-demo.bundle.js:1:54751)
    at https://redocly.github.io/redoc/redoc-demo.bundle.js:1:56121
    at Array.map (<anonymous>)
    at new e (https://redocly.github.io/redoc/redoc-demo.bundle.js:1:56069)
    at new e (https://redocly.github.io/redoc/redoc-demo.bundle.js:1:57051)
    at https://redocly.github.io/redoc/redoc-demo.bundle.js:1:60079

ReDoc Version: 2.0.0-rc.21
Commit: 45c337b

Loads fine in Swagger editor.
Schema is here: http://www.projectcastle.io/demo.yaml

Happy to adjust my schema if that helps. What do I miss?

@RomanHotsiy
Copy link
Member

You have different type for the same field in different allOf branches. Redoc doesn't know what to render in such a situation.

I will probably remove the hard crash and will use the first variant and show a warning and console as this comes up very often.

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

2 participants