https://github.com/asottile/pyupgrade
> A tool to automatically upgrade syntax for newer versions of the
> language.
- Drop u str prefix
- Drop base object inheritance
- Drop args to super()
- Use set literals
- Use dict comprehension
- Use set comprehension
In Python 3, the default encoding of source files is utf-8. The encoding
cookie is now unnecessary and redundant so remove it. For more details,
see the docs:
https://docs.python.org/3/howto/unicode.html#the-string-type
> The default encoding for Python source code is UTF-8, so you can
> simply include a Unicode character in a string literal ...
Includes a fix for the flake8 header checks to stop expecting an
encoding cookie.
This avoids warnings when find_catalog_source_files returns files
found in .git/ like:
WARNING: Start of line didn't match any expected keyword./refs/heads/freezed-library/colorsys.mo
WARNING: Problem on line 1: 0000000000000000000000000000000000000000 032a00a7391ec8a155bbc54d66ba72fb1b7bdbf1 Julien Palard <julien@palard.fr> 1521582790 +0100 branch: Created from freezed/library/colorsys.po
`.po` files can typically reside in .git/refs/heads/ if some branches
name end with .po, in which case they contain a SHA1, not
translations, leading to warnings.
`html_last_updated_fmt` is commonly used for non date formatting. But
LDML is difficult to represent them from its characteristics.
Now we moved to strftime format again (ref: #2394).
* rename a few test modules to make the names more consistent
* do not copy/use Sphinx from build/ (unnecessary without 2to3)
* use a temporary dir for *all* test projects, the source tree
will stay pristine that way (default is tests/build)
* speed up tests by ~3x by splitting up test projects and avoiding
rebuilds