Closed davehelmuth closed 1 month ago
Thanks for the issue. You're likely in the experiment for the new restructured text support. You can disable this and go back to the old rendering with:
"python.analysis.supportRestructuredText": false
Thank you so much. Unselecting that check box did indeed solve the problem described in the above ticket. I left a screenshot here for anyone else that comes across this thread.
I came to report another issue with RST support. It seems like it might not be related. Let me know if you would like me to create a distinct issue for it.
With RST support true:
With RST support false:
Code:
import asyncio
asyncio.TaskGroup()
Thank you so much. Unselecting that check box did indeed solve the problem described in the above ticket. I left a screenshot here for anyone else that comes across this thread.
You can also just put the full path of the param in the search to only get 1 result.
Thanks I'll create another issue. That's a separate problem. asyncio.TaskGroup
should be parsed as just plain text and we're not detecting it. It doesn't have REST or google doc strings in it.
This issue has been fixed in prerelease version 2024.7.101, which we've just released. You can find the changelog here: CHANGELOG.md
Google Style Docstrings with multiple arguments and exceptions are no longer rendered correctly by Pylance. When there are two or more parameters or exceptions documented in the docstring, each should be rendered on a separate line. This stopped working correctly when version
2024.8.0
of "Python extension for Visual Studio Code" was installed. (More details provided in the environment section.)Environment Data
2024.8.0
,2024.8.1
,2024.10.0
(Older versions function as expected)Visual Studio code Version: Version: 1.91.1 (user setup) Commit: f1e16e1e6214d7c44d078b1f0607b2388f29d729 Date: 2024-07-09T22:06:49.809Z Electron: 29.4.0 ElectronBuildId: 9728852 Chromium: 122.0.6261.156 Node.js: 20.9.0 V8: 12.2.281.27-electron.0
Repro Steps
Python: Language Server
is set toPylance
.Expected Behavior:
Each parameter in the
Args
section and each exception in theRaises
section should be displayed on a separate line.Actual Behavior:
Raises
section are still not rendered correctly.Example Code: Both examples follow the Google Style Guide. (Screenshots for how Pylance renders these docstrings are provided below)
Example 1: Produced Fully Incorrect rendering of standard Google Style Docstring
Attached Images:
Fully Incorrect rendering of standard Google Style Docstring:
Partially correct rendering wit
h alternative format (only exceptions still incorrect): [Second Image]