Added the options --outfile
and --inplace
, along with --help
.
Bug fixes:
- Fixed a bug where comments in function return hints that contain both newlines
and comments cause syntax error when the
--strip-nl
option is used. - Fixed a bug in multiline annotated expressions with comments on the lines.
Added the options --strip-nl
and --no-equal-move
. Fixing annotated
assignments with newlines in type hints by moving the line with =
was
added.
Added a new Python interface function strip_string_to_string
which works
just the same as strip_file_to_string
except it takes a code string
argument instead of a file name.
Added an importlib stripper for strip-on-import for Python 3.
Fixed strip-on-import for Python 2.
Fixed a unicode decoding bug when running under Python 2 on a file containing a unicode string.
Consolidated the functional interface function strip_file_to_string
so it
now accepts only_test_for_changes
as an argument.
Now handles annotated expressions of the form d["key"]: int
and d["key"]: int == 4
.
Add an option --only-test-for-changes
to just test for changes.
Fixed a nasty bug introduced in last version, keywords like "try" mistaken for annotated variables.
Now handles annotated dotted-access assignments (a simple form of annotated
expressions). For example, x.y.z : int
.
New Features:
- The new
strip_on_import
function allows stripping Python 2 files on import.
Bug Fixes: None.
Other changes:
- Expanded README documentation.
Initial release.