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

fix issue with oneOf with sub schemas with same key but different type #8034

Merged
merged 1 commit into from
Nov 18, 2021

Conversation

cgardens
Copy link
Contributor

@cgardens cgardens commented Nov 17, 2021

closes #5907

the issue is described in-line and in the new test case.

@lmossman and I debugged this one together. brutal.

@cgardens cgardens temporarily deployed to more-secrets November 17, 2021 01:22 Inactive
Copy link
Contributor

@lmossman lmossman left a comment

Choose a reason for hiding this comment

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

LGTM (paired with Charles on this)

@@ -62,6 +62,97 @@
+ " }\n"
+ " }");

private static final JsonNode ONE_OF_WITH_SAME_KEY_IN_SUB_SCHEMAS = Jsons.deserialize(
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
private static final JsonNode ONE_OF_WITH_SAME_KEY_IN_SUB_SCHEMAS = Jsons.deserialize(
private static final JsonNode ONE_OF_WITH_SAME_KEY_IN_SUB_SCHEMAS = Jsons.deserialize(

Generally we prefer to stick json files like this for testing in a resource so it's easier to read and edit compared to the escaped Java string.

@jrhizor
Copy link
Contributor

jrhizor commented Nov 18, 2021

It would also be pretty useful to add a test case for this in SecretsHelpersTest to make sure that the non-oauth secrets parsing won't break on it as well.

@cgardens cgardens merged commit 6fb79cc into master Nov 18, 2021
@cgardens cgardens deleted the cgardens/fix-one-of-secrets-copy branch November 18, 2021 19:39
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.

Saving changes not working when changing destination output format-format type from Avro to Parquet
3 participants