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
Is your enhancement related to a problem? Please describe.
When using the language server feature and hovering over a property to get the documentation, I don't get the description of a property if using anyOf:
I have the same problem, but since I often don’t specify title in schemas (only markdownDescription), VS Codium shows me just || on hover. However, when I trigger auto-completion on the (YAML) key, it correctly renders the markdownDescription for the key.
Is your enhancement related to a problem? Please describe.
When using the language server feature and hovering over a property to get the documentation, I don't get the description of a property if using
anyOf
:The language server seems to infer the title for both possible types from the property title and show both possibilities.
Describe the solution you would like
Have the same behavior as if we use
"type": ["string", "null"]
instead of "anyOf"Describe alternatives you have considered
Alternative is to generate nullable values using
"type": ["string", "null"]
but it won't work for more complex type like the one with a pattern field.Additional context
This happens frequently when using pydantic generated schemas and Optional values. pydantic is using
anyOf
when generating the schema for python optional (nullable) valueshttps://github.com/pydantic/pydantic/blob/bbf0724722b44113bf8c8e3bd0cf41403a5913e9/pydantic/json_schema.py#L1030
The text was updated successfully, but these errors were encountered: