Closed Wassasin closed 4 months ago
I like this PR. We would like to use yaserde
to deserialize CSL files with citationberg
. Many CSL fields are mandatory and have no sane default so the parsing should fail for them.
@Wassasin I have updated the project, and now this feature is supported. Fell free to comment, test the version 0.10.
Feature seems to be working OK, returns err on missing fields
Implements #144.
Not happy yet with how some of the error handling is taking place. Most notably optional structs are set to
None
if they do not parse successfully.Secondly this change is a major move from the current semantics of the crate. There should be a discussion on whether this is acceptable at all, and how to communicate clearly to users that whilst their code may still compile, input data will be rejected unless
#[yaserde(default)]
is added here and there.