Open beauxq opened 5 months ago
Just tried this out and the auto-indent issue seems fixed for me. Edit: no it doesn't work, it just worked because I had https://github.com/kbrose/vsc-python-indent installed :)
it just worked because I had https://github.com/kbrose/vsc-python-indent installed :)
Thank you for this information. I didn't know about this extension. This helps lower the priority of this issue for basedpyright.
another workaround is to use a formatter like ruff and configure it to format on-save, which makes issues like this less annoying because they get automatically fixed
This is a feature that both Pycharm and Pylance have, but it is missing from basedpyright in vscodium.
The editor can help follow PEP8 indentation standards when pressing enter inside brackets -
() [] {}
(
|
represents the cursor)If I press enter from this cursor position, this should be the new state after pressing enter:
current behavior:
The following scenario is currently working correctly. I'm just mentioning it to make sure it doesn't break when someone implements this. (a recommended regression test)
goes to:
^ This behavior should not change. The difference is whether the line ends with an open bracket or not -
( [ {
- The linedef foo(a, b,
does not end with an open bracket (but the line end is inside brackets).