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 optional types serializer to be null-safe #203

Merged
merged 1 commit into from
Dec 21, 2017

Conversation

dahlia
Copy link
Member

@dahlia dahlia commented Dec 21, 2017

This fixes a bug that PR #201 introduced.

When a record or a union tag has an optional field, the generated Python serializers had been able to unexpectedly crash if the field contains None.

See also the added test case.

@dahlia dahlia added cmp:compiler Component: Compiler backend (e.g., annotation processors, code generators) target:python typ:bug Type: Bug/defect labels Dec 21, 2017
@dahlia dahlia self-assigned this Dec 21, 2017
@dahlia dahlia requested a review from kanghyojun December 21, 2017 13:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cmp:compiler Component: Compiler backend (e.g., annotation processors, code generators) target:python typ:bug Type: Bug/defect
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants