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

STAC API spec validity? #8

Closed
bdelliott opened this issue Mar 31, 2020 · 8 comments · Fixed by #11
Closed

STAC API spec validity? #8

bdelliott opened this issue Mar 31, 2020 · 8 comments · Fixed by #11
Assignees
Labels
bug Something isn't working
Milestone

Comments

@bdelliott
Copy link

bdelliott commented Mar 31, 2020

The STAC API OpenAPI definition references an external JSON schema document for the GeoJSON definitions, which is disallowed by the OpenAPI v3 spec:

From section 4.7.24.1 (http://spec.openapis.org/oas/v3.0.3#properties)

properties - Property definitions MUST be a Schema Object and not a standard JSON Schema (inline or referenced).

The problem lines are:

I will submit a PR to add validation to the CircleCI to enforce spec validation unless someone is already doing this.

@m-mohr
Copy link
Collaborator

m-mohr commented Mar 31, 2020

I'm currently working on spectral validation for the OpenAPI file, but the API spec repo is pretty new so thinks are just starting and the CI is not even activated yet...

Regarding the OpenAPI link issue... I agree that linking JSON Schema is not allowed as $ref, but I don't see which relation this has with the quoted definition for "pattern"?!

@m-mohr
Copy link
Collaborator

m-mohr commented Mar 31, 2020

@bdelliott Which tool would you use? It seems that Spectral doesn't check external references...

@bdelliott
Copy link
Author

bdelliott commented Mar 31, 2020

@m-mohr Sorry, I pasted the wrong snippet. Should make more sense now. I was able to get validation working using swagger-cli (https://www.npmjs.com/package/swagger-cli)

Will post a PR when I get a few mins.

@m-mohr m-mohr mentioned this issue Mar 31, 2020
8 tasks
@m-mohr
Copy link
Collaborator

m-mohr commented Mar 31, 2020

Thanks! Let's see how #10 works out and then we may add swagger-cli in addition. :-)

@bdelliott
Copy link
Author

Sounds good - my laptop just died so happy to let that one back for a bit

@m-mohr
Copy link
Collaborator

m-mohr commented Apr 1, 2020

There are actually even more invalid things in the OpenAPI file :-(

This was referenced Jun 19, 2020
@cholmes cholmes added this to the 1.0.0-beta.1 milestone Jul 29, 2020
@matthewhanson
Copy link
Collaborator

Discussed in sprint, goal is to

  • remove external links to JSON schema
  • fix minor issues

To get a basic version working, then we wait for #31

@m-mohr m-mohr added the bug Something isn't working label Aug 19, 2020
@cholmes
Copy link
Collaborator

cholmes commented Nov 12, 2020

@matthewhanson - can you take this one soon? Hoping for beta.1 release soon.

m-mohr added a commit that referenced this issue Nov 13, 2020
m-mohr added a commit that referenced this issue Nov 16, 2020
m-mohr added a commit that referenced this issue Nov 16, 2020
m-mohr added a commit that referenced this issue Nov 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants