You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Issue:
Found an issue where when I use theOpenAPIEncodedSchemaType.openAPISchema(using encoder: JSONEncoder) to create a JSONSchema with passing an encoder that has keyEncodingStrategy set to convertToSnakeCase, the JSONSchema's keys wasn't converting the keys to use convertToSnakeCase and returning as what the variable name is set to.
This is interesting. Fundamentally the JSONEncoder passed in is used as sparingly as possible during reflection, but I can see how you would want (and reasonably expect) the encoder's settings to be respected RE things like key encoding strategy.
This seems like a worthwhile thing to fix, though I am not sure when I will get the time to tackle it.
Issue:
Found an issue where when I use the
OpenAPIEncodedSchemaType.openAPISchema(using encoder: JSONEncoder)
to create aJSONSchema
with passing an encoder that haskeyEncodingStrategy
set toconvertToSnakeCase
, the JSONSchema's keys wasn't converting the keys to use convertToSnakeCase and returning as what the variable name is set to.How to reproduce:
openAPISchema(_:)
to generate the schema.sampleKey
andsampleValue
instead ofsample_key
andsample_value
.Expected:
The expected result should be having the keys as
sample_key
andsample_value
.The text was updated successfully, but these errors were encountered: