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

Make JSON schemas enter Object and Variant fields. #45

Merged
merged 2 commits into from Oct 10, 2018
Merged

Conversation

jamadden
Copy link
Member

No description provided.

@jamadden jamadden requested a review from jzuech3 October 10, 2018 15:17
Copy link
Contributor

@jzuech3 jzuech3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@jamadden
Copy link
Member Author

OK, cool.

Just be aware that we're traversing through a lot of things we didn't in the past. That means the schemas will get bigger, and I can't help but wonder if there may be some chance of disclosing data we don't actually expect to (though I haven't been able to come up with a specific scenario). It may be necessary to define the TAG_HIDDEN_IN_UI more often...in fact, I think we should probably query that field before we output key_type and value_type or the fields of a variant (right now it's only queried for the top level). Thoughts?

@jzuech3
Copy link
Contributor

jzuech3 commented Oct 10, 2018

I think we do need to worry about the schemas getting bigger, but I believe it is necessary to give accurate info on the required types of underling sequence fields.

Agreed on making sure we also check hidden within variant. Do we need to make sure post_process_field is called in variant as well?

@jamadden
Copy link
Member Author

Agreed on making sure we also check hidden within variant. Do we need to make sure post_process_field is called in variant as well?

I have no idea what it's used for (there's no implementation, docstring, or testing of it here), so since it is currently only called for top-level fields, my instinct would be to say "no, don't start suddenly calling it for nested fields."

@jamadden jamadden mentioned this pull request Oct 10, 2018
@jzuech3
Copy link
Contributor

jzuech3 commented Oct 10, 2018

I'm not sure of the intended use-case either; so we can probably ignore it for now. Yesterday, I did override post_process_field to get the title/description defs in for a client.

This PR looks good to me.

@jamadden jamadden merged commit a2cb97c into master Oct 10, 2018
@jamadden jamadden deleted the issue42-redux branch October 10, 2018 16:50
@jamadden
Copy link
Member Author

Thanks!

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.

None yet

2 participants