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

Respect use defaults #424

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

s-nel
Copy link

@s-nel s-nel commented Oct 3, 2022

Currently the useDefaults parameter does nothing and defaults are always taken when the key is not present or is null in the Json. This PR changes the behavior so that when useDefaults is false, defaults are ignored, and an error will be raised for non-optional fields, or None will be used for optional fields.

Fixes: #297

@s-nel
Copy link
Author

s-nel commented Dec 18, 2024

@scala-steward @travisbrown sorry to ping you on this old PR, and I understand this project is pretty inactive, but any chance we could get this reviewed? We've been using my fork of circe-derivation in prod for a couple years and would love to switch to depending on an official release 😁

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.

useDefaults parameter is ignored in deriveDecoder
1 participant