Bill Wendling

Results 83 comments of Bill Wendling

Hi @lizawang. I'll take a look at it soon. Thank you!

My initial thoughts on how to achieve this: 1. create a new knob called something like `DISABLE_ENDING_COMMA_HEURISTIC_FOR_IMPORTS`, 2. add a new "subtype" that identifies the list of imports as belonging...

Closed with 7c408b9d7750292760ed255f744211d1ef535668.

Agreed that this is gross. The knob needs to be relaxed a bit to avoid splitting in such cases...I'll see what can be done.

Could you try this patch to see if it helps and doesn't have any bad side effects? ``` $ git diff diff --git a/yapf/pytree/subtype_assigner.py b/yapf/pytree/subtype_assigner.py index 05d88b0fc603..e3b32777aee8 100644 --- a/yapf/pytree/subtype_assigner.py...

It's a design decision that yapf won't add or remove characters from the token stream[*]. I made this decision in order to ensure that no semantic changes would be introduced....

This technically should never happen because `_LineRangesToSet` returns a non-null set if and only if there are line ranges specified.

Closed with 7c408b9d7750292760ed255f744211d1ef535668.