-
-
Notifications
You must be signed in to change notification settings - Fork 230
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
Schemars omit serde(flatten) BTreeMap #259
Comments
JakkuSakura
changed the title
Schemars omit serde(flatten) BTreeMap
Schemars omit serde(flatten) BTreeMap/Vec
Dec 16, 2023
That schema doesn't seem to correspond to those type definitions at all. |
Sorry. I pasted the wrong rust type. I've updated the example |
Fwiw, it looks like a workaround for now is to add |
JakkuSakura
changed the title
Schemars omit serde(flatten) BTreeMap/Vec
Schemars omit serde(flatten) BTreeMap
Mar 22, 2024
This is fixed in schemars 1.0.0-alpha.6 (and I think earlier alphas) - the output from the repro is now: {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "MyStruct",
"type": "object",
"properties": {
"values": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"additionalProperties": {
"type": "string"
},
"required": [
"values"
]
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The text was updated successfully, but these errors were encountered: