-
Notifications
You must be signed in to change notification settings - Fork 771
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
Auto-indent behavior as before / jumping to beginning of line #3781
Comments
I believe this is on purpose. Until the function has a This works: def f(a):<newline> But this doesn't: def f(a)<newline> |
please note that there is no closing parenthesis in my example, meaning the next token would be a second argument for the function, not the function body. |
This does seem silly. Why would it not indent to the parens. PEP 8 seems to indicate a different default than jumping to the https://peps.python.org/pep-0008/#indentation Maybe that's just an example though. If we were to implement this would it need settings? |
This issue has been fixed in prerelease version 2023.1.21, which we've just released. You can find the changelog here: CHANGELOG.md |
Filing as requrested in microsoft/vscode-python#481
Environment data
[Info - 5:13:28 PM] (8596) Pylance language server 2022.12.20 (pyright 621d886b) starting
Code Snippet
jumps to the beginning of the next line, instead of to the opening parenthesis indentation.
Same in similar settings (calling a function, in an if clause, ...), and also if the parenthesis is closed.
I added the
languageServer
line and the"editor.formatOnType": true,
but still see the linebreak behavior issues.Is there a way to confirm I set it up correctly?
The text was updated successfully, but these errors were encountered: