-
Notifications
You must be signed in to change notification settings - Fork 144
Closed
Description
Currently we punt on this and just wrap the raw contents in a plaintext codeblock:
https://github.com/astral-sh/ruff/blob/6de84ed56eac4f1f3efe9d8a9d47c9b30a445707/crates/ty_ide/src/docstring.rs#L65-L73
The format looks like this:
This is a function description.
Args:
param1 (str): The first parameter description
param2 (int): The second parameter description
This is a continuation of param2 description.
param3: A parameter without type annotation
Returns:
str: The return value description
This is an interesting case where doing a partial job can often be worse than doing nothing at all, as the current output is readable but ugly. A partial job may end up being unreadable. I've also received warning that these formats tend to be un(der)specified, and even if they weren't, you need to handle malformed inputs gracefully.
HowRuck
Metadata
Metadata
Assignees
Labels
serverRelated to the LSP serverRelated to the LSP server