avro-kotlin / avro4k

Avro format support for Kotlin
Apache License 2.0
197 stars 37 forks source link

fix: Allow value classes and primitive schemas generation #132

Closed Chuckame closed 1 year ago

Chuckame commented 2 years ago

I detected a bug while using a field Map<MyStringValueClass, NestedObject>. It is not handling well value classes everywhere. By the way I also added tests for primitive schema generation with also primitive schema that are coming from value classes. It was because of the value class descriptor has not the STRING kind, while the elementDescriptor at index 0 is of STRING kind.

Chuckame commented 1 year ago

Thanks @thake, BTW when should you deploy the new version including those changes?

thake commented 1 year ago

I'll deploy it today. I'm currently working on making it possible to directly serialize primitives, enums, collections, and maps without having to wrap them in a record. @Chuckame, your contribution helped here a lot! Thanks!

Chuckame commented 1 year ago

Ah ok, super! Do you need help to deserialize primitives ?