You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have AsyncAPI document with broken message reference in line 39:
asyncapi: 3.0.0info:
title: Account Serviceversion: 1.0.0description: This service is in charge of processing user signupsservers:
development:
host: loca{dupa}lhost:5672description: Development AMQP broker.protocol: amqpprotocolVersion: 0-9-1staging:
host: rabbitmq-staging.in.mycompany.com:5672description: RabbitMQ broker for the staging environment.protocol: amqpprotocolVersion: 0-9-1production:
host: rabbitmq.in.mycompany.com:5672description: RabbitMQ broker for the production environment.protocol: amqpprotocolVersion: 0-9-1channels:
userSignedup:
address: user/signedupmessages:
UserSignedUp:
$ref: '#/components/messages/UserSignedUp'operations:
sendUserSignedup:
action: sendchannel:
$ref: '#/channels/userSignedup'messages:
- $ref: '#/components/messages/UserSignedUp'components:
messages:
UserSignedUp:
payload:
type: objectproperties:
displayName:
type: stringdescription: Name of the useremail:
type: stringformat: emaildescription: Email of the user
When I run: asyncapi optimize ./asyncapi-client.yaml I get error like
[
{
code: 'asyncapi3-operation-messages-from-referred-channel',
message: 'Operation message does not belong to the specified channel.',
path: [ 'operations', 'sendUserSignedup', 'messages', '0' ],
severity: 0,
range: { start: [Object], end: [Object] }
}
]
ValidationError: There is no file or context with name "./asyncapi-client.yaml".
The array with validation error info is correct. I mean, maybe object should be rendered instead of [Object] but in general it is ok.
The problem is with the last line: ValidationError: There is no file or context with name "./asyncapi-client.yaml".
This error just doesn't make sense, the path reference was correct, otherwise validation would not catch the error with the message
Describe the bug.
I have AsyncAPI document with broken message reference in line 39:
When I run:
asyncapi optimize ./asyncapi-client.yaml
I get error likeThe array with validation error info is correct. I mean, maybe object should be rendered instead of
[Object]
but in general it is ok.The problem is with the last line:
ValidationError: There is no file or context with name "./asyncapi-client.yaml".
This error just doesn't make sense, the path reference was correct, otherwise validation would not catch the error with the message
Expected behavior
Remove the misleading error message
Screenshots
no
How to Reproduce
already described in description
🥦 Browser
None
👀 Have you checked for similar open issues?
🏢 Have you read the Contributing Guidelines?
Are you willing to work on this issue ?
No, someone else can work on it
The text was updated successfully, but these errors were encountered: