-
-
Notifications
You must be signed in to change notification settings - Fork 310
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug.
asyncapi bundle creates invalid documents.
main.yaml
asyncapi: 3.0.0
info:
title: demo
version: '1'
operations:
A:
$ref: "./_sub.yaml#/components/operations/A"
channels:
A:
$ref: "./_sub.yaml#/components/channels/A"_sub.yaml
components:
operations:
A:
action: send
channel:
$ref: '#/components/channels/A'
messages:
- $ref: '#/components/channels/A/messages/A'
channels:
A:
messages:
A:
$ref: '#/components/messages/A'
messages:
A:
payload:
type: objectasyncapi validate main.yaml
asyncapi bundle ./main.yaml --output final.yml
asyncapi validate final.ymlproduced invalid output:
asyncapi: 3.0.0
info:
title: demo
version: '1'
channels:
A:
messages:
A:
payload:
type: object
operations:
A:
action: send
channel:
$ref: '#/components/channels/A'
messages:
- $ref: '#/components/channels/A/messages/A'Expected behavior
It should've either updated the refs to root or moved the channels/ops/messages to components (if allowed).
Screenshots
How to Reproduce
see above
🖥️ Device Information [optional]
- Operating System (OS): macOS latest
- Browser: WF
- Browser Version: latest
👀 Have you checked for similar open issues?
- I checked and didn't find similar issue
🏢 Have you read the Contributing Guidelines?
- I have read the Contributing Guidelines
Are you willing to work on this issue ?
No, someone else can work on it
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Type
Projects
Status
To Triage