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

Error handling #231

Open
wants to merge 42 commits into
base: main
Choose a base branch
from
Open

Error handling #231

wants to merge 42 commits into from

Conversation

NikkiBytes
Copy link
Contributor

Upgraded with comprehensive error catching in the validation endpoint and schema metadata endpoint.
Added a a test file that tests scenarios in the validation endpoint.

@NikkiBytes
Copy link
Contributor Author

@newgene just pushed a fourmat check update, this has been reviewed and is ready to merge.

@newgene
Copy link
Member

newgene commented Aug 23, 2023

@NikkiBytes just to make sure we (you, @marcodarko and I) are on the same page about the error-handling behavior, can you please document all handled cases in this PR. A table looks like this might be an option:

is schema.org class class exists class contains validation ... /schema/<id> status code /schema/<id>/validation status code
200 404

@marcodarko
Copy link
Collaborator

@NikkiBytes can you review this PR? is this still relevant or has this been addressed?

@NikkiBytes
Copy link
Contributor Author

@marco are you able to see where the codacy failed?

@NikkiBytes
Copy link
Contributor Author

NikkiBytes commented Nov 25, 2024

for class/property, e.g. schema:Dataset, n3c:Dataset

schema.org class/property exists has_validation /api/schema/<curie> status /api/schema/validation status
No no no 404 404
No yes no 200 404
No yes yes 200 200
Yes yes no 200 404

for ns:

schema.org namespace exists /api/schema/<ns> status
no no 404
no yes 200
yes yes 200 [with special returned JSON]

400 for any other input value issue

  • a:b:c invalid curie
  • a,b:dataset invalid.

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

Successfully merging this pull request may close these issues.

3 participants