File tree 4 files changed +17
-7
lines changed 4 files changed +17
-7
lines changed Original file line number Diff line number Diff line change @@ -40,11 +40,11 @@ jobs:
40
40
working-directory : native
41
41
- name : Build LibCST
42
42
run : hatch env create
43
- - name : Pure Tests
43
+ - name : Tests
44
44
run : hatch run test
45
- - name : Native Tests
45
+ - name : Pure Parser Tests
46
46
env :
47
- LIBCST_PARSER_TYPE : ${{ matrix.parser }}
47
+ LIBCST_PARSER_TYPE : pure
48
48
run : hatch run test
49
49
50
50
# Run linters
Original file line number Diff line number Diff line change
1
+ # 1.0.0 - 2023-05-25
2
+
3
+ The first major release of LibCST is essentially the same as 0.4.10, but using the
4
+ newer, Rust-based parser implementation by default. The old, pure Python parser is
5
+ scheduled for removal in the next (non-patch) release. Until then, it is available with
6
+ the ` LIBCST_PARSER_TYPE ` environment variable set to ` pure ` .
7
+
8
+ ## Updated
9
+
10
+ * Switch the default parser implementation to native by @zsol in https://github.com/Instagram/LibCST/pull/929
11
+
1
12
# 0.4.10 - 2023-05-23
2
13
3
14
## New Contributors
Original file line number Diff line number Diff line change 27
27
28
28
def is_native () -> bool :
29
29
typ = os .environ .get ("LIBCST_PARSER_TYPE" )
30
- return typ == "native "
30
+ return typ != "pure "
31
31
32
32
33
33
def _parse (
Original file line number Diff line number Diff line change 3
3
A native extension to enable parsing of new Python grammar in LibCST.
4
4
5
5
The extension is written in Rust, and exposed to Python using [ PyO3] ( https://pyo3.rs/ ) .
6
- This is packaged together with libcst, and can be imported from ` libcst.native ` . When
7
- the ` LIBCST_PARSER_TYPE ` environment variable is set to ` native ` , the LibCST APIs use
8
- this module for all parsing.
6
+ This is packaged together with libcst, and can be imported from ` libcst.native ` . By default
7
+ the LibCST APIs use this module for all parsing.
9
8
10
9
Later on, the parser library might be packaged separately as
11
10
[ a Rust crate] ( https://crates.io ) . Pull requests towards this are much appreciated.
You can’t perform that action at this time.
0 commit comments