Skip to content

Add Spectral schemas to the Registry #146

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

Open
kinlane opened this issue Feb 23, 2025 · 12 comments
Open

Add Spectral schemas to the Registry #146

kinlane opened this issue Feb 23, 2025 · 12 comments

Comments

@kinlane
Copy link

kinlane commented Feb 23, 2025

May I suggest adding the following API schema to the registry by default -- selfishly so I can link to your version of them when talking about the schema registry.

@jviotti
Copy link
Member

jviotti commented Feb 24, 2025

Absolutely! I'll aim to connect them all today and let you know

@jviotti
Copy link
Member

jviotti commented Feb 24, 2025

@kinlane Here you have APIs.json (pretty easy to integrate, well done!)

https://schemas.sourcemeta.com/apis-json

Image

And the latest version of Vacuum. I'll add the previous version throughout the day:

https://schemas.sourcemeta.com/pb33f/vacuum

Image

@jviotti
Copy link
Member

jviotti commented Feb 24, 2025

The Spectral ones are a bit more tricky. Their schemas seems to have some issues that choke my (pretty strict) tooling. A good stress test nevertheless. I'll aim to make them work today.

@jviotti
Copy link
Member

jviotti commented Feb 24, 2025

@kinlane Also, completely aside, but I might send a couple of PRs to the APIs.json schema for bumping up the quality of schemas, integrate linting, etc. In the short-term future, I will be extending the registry to perform automatic health analysis of all the ingested schemas and score them. The scoring will be public and will affect i.e. the search result priority, etc so will make sure you get a 100% score ;)

@kinlane
Copy link
Author

kinlane commented Feb 24, 2025

You are the best. An understood on the challenges with Spectral -- I've had same. I also agree on low quality of APIs.json schema, but also repo. On my list to improve and invest in. Any help is always appreciated. Thankful for this work.

@jviotti
Copy link
Member

jviotti commented Feb 24, 2025

@kinlane Any time! As a minor update, ALL versions of Vacuum are up: https://schemas.sourcemeta.com/pb33f/vacuum. I'll be looking more into Spectral next.

Image

@jviotti
Copy link
Member

jviotti commented Feb 25, 2025

As another update, looks like there are indeed various problems with the Spectral schemas and are not valid Draft 7 schemas. I'll file an issue, as I don't think there is any reasonable way to coerce them to work as-is.

@kinlane
Copy link
Author

kinlane commented Feb 25, 2025

I am glad you hit the same wall with it. I found it was a very complex, weird, and difficult to work with.

@jviotti
Copy link
Member

jviotti commented Feb 25, 2025

@kinlane Here is the upstream issue: stoplightio/spectral#2787. Nothing unfixable. Just minor things! Hopefully we get it fixed soon. Thanks for raising this!

@jviotti
Copy link
Member

jviotti commented Feb 25, 2025

I sent a PR: stoplightio/spectral#2788

@bavulapati
Copy link

@jviotti I sent a PR to fix the CI failures on your spectral PR.
PTAL.

@jviotti
Copy link
Member

jviotti commented Mar 31, 2025

Awesome! Thanks! Please send it over upstream (to Spectral) rather than my fork, so we can properly fix it there!

@jviotti jviotti changed the title Suggestions for Additional Default Schema in Registry Add Spectral schemas to the Registry Apr 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants