Skip to content
This repository has been archived by the owner on Nov 8, 2024. It is now read-only.

JSON Schema generator fails on ExtendElement in enum #217

Closed
w-vi opened this issue Jan 20, 2016 · 4 comments · Fixed by #247
Closed

JSON Schema generator fails on ExtendElement in enum #217

w-vi opened this issue Jan 20, 2016 · 4 comments · Fixed by #247
Labels

Comments

@w-vi
Copy link
Contributor

w-vi commented Jan 20, 2016

curl -s https://raw.githubusercontent.com/hassansin/foxycart-api-
blueprint/master/apiary.apib | drafter -l


error: (4)  ExtendElement must be composed from Elements of same type

I can't reproduce using latest drafter but getting different error

curl -s https://raw.githubusercontent.com/hassansin/foxycart-api-
blueprint/master/apiary.apib | drafter -l


error: (4)  ExtendElement serialization Not Implemented

At least part of the problem is that JSON Schema generator is not expanding elements if in enum, that's where the second error is coming from.

@w-vi w-vi changed the title ExtendElement serialize issue JSON Schema generator fails on ExtendElement in enum Jan 20, 2016
@zdne
Copy link
Contributor

zdne commented Feb 16, 2016

@w-vi any updates on this? I am still getting

yt:~ z$ curl -s https://raw.githubusercontent.com/hassansin/foxycart-api-blueprint/mas
ter/apiary.apib | drafter -l


OK.
warning: (4)  ExtendElement must be composed from Elements of same type

@w-vi
Copy link
Contributor Author

w-vi commented Feb 16, 2016

@zdne haven't had a time to dig deeper yet. It's not an issue in JSON Schema generator anymore, it is deeper in MSON hadnling code.

@zdne zdne added the bug label Feb 17, 2016
@pksunkara
Copy link
Contributor

I was running into this issue earlier but I wasn't able to dig deeper without the source maps on drafter. I know this issue is happening because of an enum based Named type but wasn't able to understand why this is happening.

@Baggz
Copy link

Baggz commented Feb 26, 2016

@z @pksunkara @w-vi

We have quite a few Apiary users running into this issue as well.

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

Successfully merging a pull request may close this issue.

4 participants