-
-
Notifications
You must be signed in to change notification settings - Fork 12
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
Ref v2 Spec #3
Comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
I've just been thinking about the problem of following $id declarations during ref resolution and came across this issue. I don't think that we should recursively dereference schemas. Whilst it's certainly a simpler approach (at least, conceptually), I think the extra cost should be avoided (especially if there are schemas with lazy reference paths (though I'm not sure if currently jsonschema does this, as even in the case of oneOf we need to ensure only one subschema validates (and hence we have to dereference it anyway)). I think a better approach would be to follow the $id uri from within the resolution process, such as the approach taken here. I'm not convinced that we could (or should) just use this repository (for a start, it doesn't support the newer $id keyword, but the approach is valid enough (we already use context managers to track the current scope). I'll give it some thought. |
This is some random notes on a new version of the ref resolution API. Feel free to leave comments, although some of the below might be overly terse chicken scratch
Resolver().resolve(ref)
+Resolver().for_scope(url)
?yarl.URL
s, not strsextend
The text was updated successfully, but these errors were encountered: