Skip to content

Releases: lark-parser/lark

1.3.1 - Bugfix + source build now contains complete project data

27 Oct 18:29

Choose a tag to compare

What's Changed

  • Bugfix: Restore support for custom input, alongside text and TextSlice by @erezsh in #1562
  • Keep sdist in sync with git (include all files in source build, including docs, tests and examples) by @chanicpanic in #1561

Full Changelog: 1.3.0...1.3.1

1.3.0 - Introduces text-slices, Earley fix, and various small improvements

22 Sep 13:48
e332c2d

Choose a tag to compare

New features

  • Lark can now parse in sections of strings, using TextSlice, as a faster alternative to creating a "copy-slice" with s[i:j]. Learn more
  • Added support to match on Tree instances
  • When serializing a Lark instance, added the option to include the grammar object (before compilation).
  • Added convenience method Tree.find_token()

Bugfixes

  • Bugfix of an edge case in Earley related to representation of ambiguity.
  • Bugfixes in the standalone parser related to imports
  • Bugfix in indenter - now dedents always contain line information
  • Various small bugfixes (see PR list below)

Full list of PRs

  • Docs: Rephrase v_args() documentation to underline it only applies to Transformer classes by @skepppy in #1458
  • Tiny refactor for PR #1451 by @erezsh in #1459
  • Earley: share nodes created by the scanner with the completer by @chanicpanic in #1451
  • Better error in Lark.parse when using on_error when parser!=lalr (issue #1311) by @erezsh in #1460
  • Fix Symbol.__eq__ to return false when comparing with None by @weaversam8 in #1481
  • Mention internal/external transformers in the documentation by @odanoburu in #1486
  • Add Tree.find_token() method by @makukha in #1467
  • Type Terminal.__init__ by @Liam-DeVoe in #1503
  • Add guidance on handling comments in languages with significant indentation by @nchammas in #1502
  • [docs] Small fix for PR 1507 by @erezsh in #1508
  • Add note on binding power of numeric quantifiers by @414owen in #1507
  • Wrap functools.partial in staticmethod() to add compatibility with Python 3.14 by @hrnciar in #1483
  • Fix generic type of Transformer_InPlaceRecursive by @lbhm in #1518
  • Added TextSlice; Lark can now parse/lex a text-slice by @erezsh in #1452
  • Support match on tree by @colmmurphyxyz in #1521
  • Docs: Updated link of DSL article to a new version by @erezsh in #1529
  • better error messages for shift/reduct conflicts by @skogsbaer in #1531
  • Serialize Lark.grammar (fixes issue #1472) by @NasalDaemon in #1506
  • Fixes for PR #1506, which adds the option to cache the grammar definition by @erezsh in #1540
  • Bugfix in indenter - now always creating dedents with line information by @erezsh in #1547
  • Bugfix: issue when unpickling in the standalone parser, due to lingering Token instances by @erezsh in #1553
  • Include missing import in standalone parser by @pdeibert in #1541
  • Version bump (1.3.0) by @erezsh in #1554

New Contributors

Full Changelog: 1.2.2...1.3.0

1.2.2 - Bugfix for 1.2.1 (Earley issues with ambiguity)

13 Aug 19:52

Choose a tag to compare

What's Changed

  • Bugfix: Earley now respects ambiguity='resolve' again. Bug was introd… by @erezsh in #1444

Full Changelog: 1.2.1...1.2.2

1.2.1 - Now only Python 3.8+; several bugfixes in Earley

13 Aug 09:41

Choose a tag to compare

Main Changes

  • Dropped support for Python versions lower than 3.8
  • Several bugfixes in the Earley algorithm, related to suppressed ambiguities
  • Improved performance in InteractiveParser.accepts()

What's Changed

New Contributors

Full Changelog: 1.1.9...1.2.1

1.1.9 - Patch for a breaking change in 3.11.7 re module

10 Jan 08:35

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 1.1.8...1.1.9

1.1.8 - Output-stable Earley; Interactive standalone; various improvements

23 Oct 08:18

Choose a tag to compare

What's Changed

  • Populate the Token.end_* fields for ignored tokens by @jtbraun in #1309
  • Include .lark files in package data by @ptrcnull in #1308
  • Add an error message when using Lark.save() when parser!='lalr' by @erezsh in #1328
  • Add and improve docstrings by @erezsh in #1326
  • Small update to PR #1338 by @erezsh in #1339
  • Fix 1345 attempt two by @MegaIng in #1347
  • Earley now uses OrderedSet for better output stability by @erezsh in #1327
  • ContextualLexer now uses self.basic_lexer for easy extensibility (iss… by @erezsh in #1342
  • Improved typing around LALR and ParserState by @erezsh in #1343
  • Typing fixes. Mypy now produces 0 type errors by @erezsh in #1354
  • Standalone: Added support for interactive parser. by @erezsh in #1356

New Contributors

Full Changelog: 1.1.7...1.1.8

1.1.7 - Bugfix for release 1.1.6 in propagate_positions

20 Jul 19:19
e795810

Choose a tag to compare

1.1.6 - Strict mode, Python-style comments, Bugfixes

17 Jul 20:22

Choose a tag to compare

What's Changed - main points

What's Changed - PRs

New Contributors

Full Changelog: 1.1.5...1.1.6

1.1.5 - Fix AmbiguousExpander; Fix line information in InteractiveParser

06 Dec 12:55

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 1.1.4...1.1.5

1.1.4 - Added support for using Token in match statements, and other small fixes

02 Nov 01:48
9e5bd90

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 1.1.3...1.1.4