Closed indietyp closed 6 months ago
I just found out that schemars = false
works on a container level, but something similar would be great on a per field level.
The macro should handle such conflicts. There is a test, but it might only work for schemars(with = ...)
and not schemars(schema_with = ...)
.
You should be able to work around this for now, by using a type and with
instead of schema_with
.
The schema_with
seems to have an identical functionality to with
, but with different syntax. That in that case, the macro should detect both. I will check how to update the serde_as
macro here.
A fix for this is released in v3.7.0
I am trying to properly encode
Base64
encoded data using schemars, but I am failing while theschemars_0_8
feature is enabled.Base64
does not implementJsonSchemaAs
, so I went ahead and tried to implement it myself using theschema_with
annotation.This fails with the error: schemars attribute cannot contain both
with
andschema_with
any help would be immensely appreciated. Thank you so much for the great library and overall integration of
schemars
into it!