Releases: Instagram/LibCST
Releases · Instagram/LibCST
v0.4.7
New Contributors
- @Chenguang-Zhu made their first contribution in #720
Fixed
Added
- Implement lazy loading mechanism for expensive metadata providers by @Chenguang-Zhu in #720
Full Changelog: v0.4.6...v0.4.7
v0.4.6
New Contributors
- @superbobry made their first contribution in #702
Fixed
v0.4.5
New Contributors
Fixes
- Only skip supported escaped characters in f-strings by @zsol in #700
- Escaping quote characters in raw string literals causes a tokenizer error by @zsol in #668
- Corrected a code example in the documentation by @zzl0 in #703
- Handle multiline strings that start with quotes by @zzl0 in #704
- Fixed a performance regression in libcst.metadata.ScopeProvider by @lpetre in #698
Full Changelog: v0.4.4...v0.4.5
v0.4.4
New Contributors
- @adamchainz made their first contribution in #688
Added
- Add package links to PyPI by @adamchainz in #688
- native: add overall benchmark by @zsol in #692
- Add support for PEP-646 by @zsol in #696
Updated
Full Changelog: v0.4.3...v0.4.4
v0.4.3
v0.4.2
New Contributors
- @stanislavlevin made their first contribution in #650
- @dmitryvinn made their first contribution in #655
- @wiyr made their first contribution in #669
- @toofar made their first contribution in #675
Fixed
- native: Avoid crashing by making IntoPy conversion fallible by @zsol in #639
- native: make sure ParserError's line is zero-indexed by @zsol in #681
- Fix space validation for AsName and Await by @zsol in #641
- Qualified Name Provider: Fix returned qname for symbols that are prefixes of each other by @wiyr in #669
- Rename Codemod: Correct last renamed import from by @toofar in #675
- Many changes to the Apply Type Comments codemod:
- Allow for skipping quotes when applying type comments by @stroxler in #644
- Port pyre fixes by @stroxler in #651
- Preserve as-imports when merging type annotations. by @martindemello in #664
- Qualify imported symbols when the dequalified form would cause a conflict by @martindemello in #674
- Add an argument to always qualify imported type annotations. by @martindemello in #676
Added
- Create an AddTrailingCommas codemod by @stroxler in #643
- Define gather global names visitor by @shannonzhu in #657
Updated
- Support module and package names in the codemod context by @lpetre in #662
- Drop support for running libcst using a python 3.6 interpreter by @lpetre in #663
- Update relative import logic to match cpython by @lpetre in #660
- Scope Provider: Consider access information when computing qualified names for nodes by @lpetre in #682
Full Changelog: v0.4.1...v0.4.2
LibCST 0.4.1 Release - 2022-01-28
New Contributors
- @ariebovenberg made their first contribution in #605
- @sehz made their first contribution in #598
Added
- Add docs about the native parts by @zsol in #601
- Specify minimum rust toolchain version by @zsol in #614
- build wheels on main branch for linux/arm64 by @zsol in #630
Updated
- ApplyTypeAnnotationVisitor changes
- Add support for methods with func type comment excluding self/cls by @stroxler in #622
- Merge in TypeVars and Generic base classes in ApplyTypeAnnotationVisitor by @martindemello in #596
- Full handling for applying type comments to Assign by @stroxler in #599
- Add support for For and With by @stroxler in #607
- Support FunctionDef transformations by @stroxler in #610
- add slots to base classes, @add_slots takes bases into account by @ariebovenberg in #605
- change pyo3 as optional dependency in native Python Parser by @sehz in #598
- [native] Box most enums by @zsol in #632
- [native] Return tuples instead of lists in CST nodes by @zsol in #631
Fixed
- Allow trailing whitespace without newline at EOF by @zsol in #611
- Handle ast.parse failures when converting function type comments by @stroxler in #616
- [native] Don't redundantly nest StarredElement inside another Element by @isidentical in #624
- [native] Allow unparenthesized tuples inside f-strings by @isidentical in #621
- Don't require whitespace right after match by @isidentical in #628
- Proxy both parentheses in some pattern matching nodes by @isidentical in #626
LibCST 0.4.0 Release - 2022-01-12
This release contains a new parsing infrastructure that is turned off by default. You
can enable it by setting the LIBCST_PARSER_TYPE
environment variable to native
before parsing an input with the usual LibCST APIs. Parsing Python 3.10 documents is
only supported in this new mode.
Note: the new parser is built as a native extension, so LibCST will ship with binary
wheels from now on.
Added
- Implement a Python PEG parser in Rust by @zsol in #566
- implement PEP-654: except* by @zsol in #571
- Implement PEP-634 - Match statement by @zsol in #568
- Add instructions to codegen test failures by @stroxler in #582
- Support Parenthesized With Statements by @stroxler in #584
- Support relative imports in AddImportsVisitor by @martindemello in #585
- Codemod for PEP 484 Assign w / type comments -> PEP 526 AnnAssign by @stroxler in #594
Updated
- Update license headers by @zsol in #560
- Use precise signature matching when inserting function type annotations by @martindemello in #591
LibCST 0.3.23 Release - 2021-11-23
What's Changed
Full Changelog: v0.3.22...v0.3.23
LibCST 0.3.22 Release - 2021-11-22
Notable changes
All changes
- Add --indent-string option to
libcst.tool print
by @jreese in #525 - Fix documentation typos by @MapleCCC in #527
- Fix incorrect
m.OneOf()
docs by @Zac-HD in #529 - Remove a dead method in ApplyTypeAnnotationsVisitor by @stroxler in #533
- Count the information we add in ApplyTypeAnnotationsVisitor by @stroxler in #537
- Use QualifiedNameProvider to handle stub types by @stroxler in #536
- Use
from __future__ import annotations
in ATAV by @stroxler in #540 - Fix typing errors on ATAV by @stroxler in #542
- Don't gather metadata if the wrapper already contains it by @lpetre in #545
- Support relative imports in ATAV qualifier handling by @stroxler in #538
- Upgrade black to fix errors in 3.9.8 by @lpetre in #547
- Pass absolute path to codemod test by @lpetre in #549
- Swallow parsing errors in string annotations. by @lpetre in #548
- Stop parsing string annotations when no longer in a typing call by @lpetre in #546
- Publish test packages by @lpetre in #550
- disable setuptools local scheme when env var is set by @zsol in #551
- Test overwriting imports w/ global and nonlocal stmts by @lpetre in #553
- Pin accesses to import alias node by @giomeg in #554
- Correct and simplify logic of recording assignments by @giomeg in #556
- Move find_qualified_names_for in the Assignment class. by @giomeg in #557
- Remove remnants of circleci by @lpetre in #552
- bump version to 0.3.22 by @zsol in #559
New Contributors
- @jreese made their first contribution in #525
- @MapleCCC made their first contribution in #527
- @giomeg made their first contribution in #554
Full Changelog: 0.3.21...v0.3.22