yapf v0.29.0 Release Notes

Release Date: 2019-11-28 // over 4 years ago
  • โž• Added

    • โž• Add the --quiet flag to suppress output. The return code is 1 if there are changes, similarly to the --diff flag.
    • Add the indent_closing_brackets option. This is the same as the dedent_closing_brackets option except the brackets are indented the same as the previous line. ### ๐Ÿ”„ Changed
    • Collect a parameter list into a single object. This allows us to track how a parameter list is formatted, keeping state along the way. This helps when supporting Python 3 type annotations.
    • Catch and report UnicodeDecodeError exceptions.
    • ๐Ÿ‘Œ Improved description of .yapfignore syntax. ### ๐Ÿ›  Fixed
    • ๐Ÿ†“ Format subscript lists so that splits are essentially free after a comma.
    • Don't add a space between a string and its subscript.
    • ๐Ÿ’… Extend discovery of '.style.yapf' & 'setup.cfg' files to search the root directory as well.
    • ๐Ÿ‘‰ Make sure we have parameters before we start calculating penalties for splitting them.
    • Indicate if a class/function is nested to ensure blank lines when needed.
    • ๐Ÿ›  Fix extra indentation in async-for else statement.
    • A parameter list with no elements shouldn't count as exceeding the column limit.
    • When splitting all comma separated values, don't treat the ending bracket as special.
    • The "no blank lines between nested classes or functions" knob should only apply to the first nested class or function, not all of them.