google / google/yapf

split_complex_comprehension in v0.33.0 is not consistent with v0.32.0

Open
#1,104 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
14k
Forks
904
PR merge metrics
No merged PRs in 30d

Description

Attempting to format code with v0.33.0
```
def test():
test = {
key_long_var: [i
for i in val_long_var]
for key_long_var, val_long_var in data.items()
}
```

However, using v0.32.0
```
def test():
test = {
key_long_var: [i for i in val_long_var]
for key_long_var, val_long_var in data.items()
}
```

I am expecting the results in v0.32.0.

This is the yapf arguments that I am using:
```
yapf --recursive --verbose --in-place --no-local-style --style="{dedent_closing_brackets: True, continuation_indent_width: 8, split_complex_comprehension: True}" .
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.