./devel/py-yapf, Python files formatter

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]


Branch: CURRENT, Version: 0.40.2nb1, Package name: py311-yapf-0.40.2nb1, Maintainer: nils

YAPF - Yet Another Python Formatter - is a python formatting
tool based based off of 'clang-format'.
In essence, the algorithm takes the code and reformats it to
the best formatting that conforms to the style guide, even if
the original code didn't violate the style guide.
The idea is also similar to the 'gofmt' tool for the Go
programming language: end all holy wars about formatting -
if the whole code base of a project is simply piped through
YAPF whenever modifications are made, the style remains consistent
throughout the project and there's no point arguing about style
in every code review.


Required to run:
[devel/py-setuptools] [lang/python37]

Required to build:
[pkgtools/cwrappers]

Master sites:

Filesize: 246.16 KB

Version history: (Expand)


CVS history: (Expand)


   2023-10-28 21:57:26 by Thomas Klausner | Files touched by this commit (516) | Package updated
Log message:
python/wheel.mk: simplify a lot, and switch to 'installer' for installation

This follows the recommended bootstrap method (flit_core, build, installer).

However, installer installs different files than pip, so update PLISTs
for all packages using wheel.mk and bump their PKGREVISIONs.
   2023-09-27 11:40:15 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-yapf: updated to 0.40.2

0.40.2
Changes
- The verification module has been removed. NOTE: this changes the public APIs
  by removing the "verify" parameter.
- Changed FORCE_MULTILINE_DICT to override \ 
SPLIT_ALL_TOP_LEVEL_COMMA_SEPARATED_VALUES.
- Adopt pyproject.toml (PEP 517) for build system
Fixed
- Do not treat variables named `match` as the match keyword.
- Fix SPLIT_ARGUMENTS_WHEN_COMMA_TERMINATED for one-item argument lists.
- Fix trailing backslash-newline on Windows when using stdin.
   2023-06-26 17:27:14 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-yapf: updated to 0.40.1

0.40.1
Fixed
- Corrected bad distribution v0.40.0 package.

0.40.0
Added
- Support for Python 3.11
- Add the `--print-modified` flag to print out file names of modified files when
  running in in-place mode.
Changes
- Replace the outdated and no-longer-supported lib2to3 with a fork of blib2to3,
  Black's version of lib2to3.
Removed
- Support for Python versions < 3.7 are no longer supported.
   2023-04-23 02:04:35 by David H. Gutteridge | Files touched by this commit (1)
Log message:
py-yapf: now Python 3 only due to py-tomli
   2023-04-21 11:26:30 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-yapf: updated to 0.33.0

0.33.0
Added
- Add a new Python parser to generate logical lines.
- Added support for `# fmt: on` and `# fmt: off` pragmas.
Changes
- Moved 'pytree' parsing tools into its own subdirectory.
- Add support for Python 3.10.
- Format generated dicts with respect to same rules as regular dicts
- Generalized the ending comma heuristic to subscripts.
- Supports "pyproject.toml" by default.
Fixed
- Split line before all comparison operators.
   2022-01-05 16:41:32 by Thomas Klausner | Files touched by this commit (289)
Log message:
python: egg.mk: add USE_PKG_RESOURCES flag

This flag should be set for packages that import pkg_resources
and thus need setuptools after the build step.

Set this flag for packages that need it and bump PKGREVISION.
   2022-01-04 21:55:40 by Thomas Klausner | Files touched by this commit (1595)
Log message:
*: bump PKGREVISION for egg.mk users

They now have a tool dependency on py-setuptools instead of a DEPENDS
   2021-12-31 13:21:55 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-yapf: updated to 0.32.0

0.32.0
Added
- Look at the 'pyproject.toml' file to see if it contains ignore file information
  for YAPF.
- New entry point `yapf_api.FormatTree` for formatting lib2to3 concrete
  syntax trees.
- Add CI via GitHub Actions.
Changes
- Change tests to support "pytest".
- Reformat so that "flake8" is happy.
- Use GitHub Actions instead of Travis for CI.
- Clean up the FormatToken interface to limit how much it relies upon the
  pytree node object.
- Rename "unwrapped_line" module to "logical_line."
- Rename "UnwrappedLine" class to "LogicalLine."
Fixed
- Enable `BLANK_LINE_BEFORE_NESTED_CLASS_OR_DEF` knob for "pep8" style, so
  method definitions inside a class are surrounded by a single blank line as
  prescribed by PEP8.
- Fixed the '...' token to be spaced after a colon.