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

[BUG] description should not be used next to $ref #275

Closed
canvural opened this issue Nov 2, 2020 · 0 comments · Fixed by #295
Closed

[BUG] description should not be used next to $ref #275

canvural opened this issue Nov 2, 2020 · 0 comments · Fixed by #295
Assignees
Labels
WT1 To be discussed at the next meeting
Projects

Comments

@canvural
Copy link
Contributor

canvural commented Nov 2, 2020

API Version

1.0

Summary

This is issue is about a technical point in regards to OpenAPI spec. $ref values should not have any siblings. More information can be found here and here.

Couple of examples of this usage in TOMP-API can be seen here and here.

This usage causes errors with some tools.

Expected Behavior

$ref values should not have any sibling.

Current Behavior

Writing siblings next to $ref causes some tools to throw error when parsing TOMP-API spec.

Possible Solution

As described here, one possible solution is to allOf keyword.

So this example can be converted to:

from:
    description: The departure location of this leg, using this asset type
    allOf:
        - $ref: "#/components/schemas/place"

I can create a PR that fixes this, if you agree.

@edwinvandenbelt edwinvandenbelt added the WT1 To be discussed at the next meeting label Nov 2, 2020
@edwinvandenbelt edwinvandenbelt changed the title [BUG] or [CHANGE REQUEST] description should not be used next to $ref [BUG] description should not be used next to $ref Nov 3, 2020
@edwinvandenbelt edwinvandenbelt added this to the Dragonfly - v1.1.0 milestone Nov 4, 2020
@edwinvandenbelt edwinvandenbelt added this to To do in WT1 Kanban Nov 4, 2020
@edwinvandenbelt edwinvandenbelt moved this from To do to In progress in WT1 Kanban Nov 11, 2020
@edwinvandenbelt edwinvandenbelt self-assigned this Nov 11, 2020
edwinvandenbelt added a commit to edwinvandenbelt/TOMP-API that referenced this issue Nov 11, 2020
@edwinvandenbelt edwinvandenbelt moved this from In progress to In review in WT1 Kanban Nov 11, 2020
@edwinvandenbelt edwinvandenbelt linked a pull request Nov 12, 2020 that will close this issue
@edwinvandenbelt edwinvandenbelt moved this from In review to Done in WT1 Kanban Nov 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
WT1 To be discussed at the next meeting
Projects
WT1 Kanban
  
Done
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants