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

fix: make traits an array of traits or refs #339

Merged
merged 7 commits into from
Mar 9, 2023
Merged

fix: make traits an array of traits or refs #339

merged 7 commits into from
Mar 9, 2023

Conversation

AceTheCreator
Copy link
Member

@AceTheCreator AceTheCreator commented Feb 15, 2023

Currently, the traits can be defined as an array of arrays of traits and refs, but in the spec, it says it should be an array of traits or refs.

cc @jonaslagoni @derberg @fmvilas

resolves #273 and #81

@magicmatatjahu
Copy link
Member

@AceTheCreator You should fix that in all 2.x.x versions.

@jonaslagoni
Copy link
Member

@AceTheCreator you can actually close #81 as well with these changes 🙂

jonaslagoni added a commit to jonaslagoni/spec-json-schemas that referenced this pull request Feb 20, 2023
@@ -134,29 +128,10 @@
"items": {
"oneOf": [
{
"$ref": "http://asyncapi.com/definitions/2.6.0/Reference.json"
"$ref": "http://asyncapi.com/definitions/2.5.0/Reference.json"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wrong version

@AceTheCreator
Copy link
Member Author

AceTheCreator commented Mar 1, 2023

Any additional thoughts on this PR @jonaslagoni @derberg @magicmatatjahu

"additionalItems": true
}
]
"$ref": "http://asyncapi.com/definitions/2.5.0/messageTrait.json"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wrong version

Copy link
Member

@derberg derberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how did you make changes to schemas, did you do some manual stuff there?

@AceTheCreator
Copy link
Member Author

how did you make changes to schemas, did you do some manual stuff there?

Yes, I did. In the traits object

@smoya
Copy link
Member

smoya commented Mar 9, 2023

how did you make changes to schemas, did you do some manual stuff there?

Yes, I did. In the traits object

You should generate schemas by following https://github.com/asyncapi/spec-json-schemas#schema-bundling

@sonarcloud
Copy link

sonarcloud bot commented Mar 9, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@AceTheCreator
Copy link
Member Author

Updated this PR cc @derberg @smoya

Copy link
Member

@derberg derberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link
Member

@smoya smoya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 🚀🌔

@AceTheCreator
Copy link
Member Author

/rtm

@asyncapi-bot asyncapi-bot merged commit 8de66a8 into asyncapi:master Mar 9, 2023
@AceTheCreator AceTheCreator deleted the fix-traits-object branch March 9, 2023 13:00
@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 4.1.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 5.0.0-next-major-spec.18 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

Traits can be defined as double arrays
6 participants