-
Notifications
You must be signed in to change notification settings - Fork 42
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
Move entry schemas to separate submodule #511
Conversation
Codecov Report
@@ Coverage Diff @@
## master #511 +/- ##
=======================================
Coverage 91.59% 91.59%
=======================================
Files 61 62 +1
Lines 3118 3119 +1
=======================================
+ Hits 2856 2857 +1
Misses 262 262
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, thanks @ml-evs
On another note, are you sure we don't need to take allOf
, anyOf
, etc. into account in the recursive function?
I'm sure for now... I think the problem we were having was also providing a schema for the links endpoint, which was running into the multiple allowed response types. We don't have that anywhere in our structure/reference models so this should be useful as is. |
This PR is a shortcut version of #277 whilst retaining most of its features. The
ENTRY_INFO_SCHEMA
constant dict has been moved to a new submodule and new extension fields ("support" and "queryable") are now made available so they can also be used by the validator more cleanly in #503, and eventually in the server code in #504.All that is missing to enable #277 is to wrap this in a class to provide a nicer interface for implementations to use their own models in
ENTRY_INFO_SCHEMAS
rather than the hardcodedStructureResource
etc. I think this is a less important point than the other bits though.