Prevent double indenting when splitting function parameters in if or with
Open
- Dominant language
- Python
- Stars
- 14k
- Forks
- 904
- PR merge metrics
- No merged PRs in 30d
Description
Hi, is this supported by yapf configuration if I want to prevent the function parameters from being indented twice in this case:
```python
if func(
a,
b,
):
pass
```
Output:
```python
if func(
a,
b,
):
pass
```
Desired output:
```python
if func(
a,
b,
):
pass
```
I can get the output that I want by changing https://github.com/google/yapf/blob/main/yapf/yapflib/format_decision_state.py#L980 from
```python
return token_indent + style.Get('CONTINUATION_INDENT_WIDTH')
```
to
```python
return token_indent
```
But I wonder if this is configurable.
Contributor guide
Assessment
This issue has not been assessed yet.