Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump pyparsing from 2.4.7 to 3.2.0 in /tools/deps #5339

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Oct 14, 2024

Bumps pyparsing from 2.4.7 to 3.2.0.

Release notes

Sourced from pyparsing's releases.

Pyparsing 3.1.0a1

NOTE: In the future release 3.2.0, use of many of the pre-PEP8 methods (such as ParserElement.parseString) will start to raise DeprecationWarnings. 3.2.0 should get released some time later in 2023. I currently plan to completely drop the pre-PEP8 methods in pyparsing 4.0, though we won't see that release until at least late 2023 if not 2024. So there is plenty of time to convert existing parsers to the new function names before the old functions are completely removed. (Big help from Devin J. Pohly in structuring the code to enable this peaceful transition.)

Version 3.2.0 will also discontinue support for Python versions 3.6 and 3.7.

  • API ENHANCEMENT: Optional(expr) may now be written as expr | ""

    This will make this code:

    "{" + Optional(Literal("A") | Literal("a")) + "}"
    

    writable as:

    "{" + (Literal("A") | Literal("a") | "") + "}"
    

    Some related changes implemented as part of this work:

    • Literal("") now internally generates an Empty() (and no longer raises an exception)
    • Empty is now a subclass of Literal

    Suggested by Antony Lee (issue #412), PR (#413) by Devin J. Pohly.

  • Added new class property identifier to all Unicode set classes in pyparsing.unicode, using the class's values for cls.identchars and cls.identbodychars. Now Unicode-aware parsers that formerly wrote:

    ppu = pyparsing.unicode
    ident = Word(ppu.Greek.identchars, ppu.Greek.identbodychars)
    

    can now write:

    ident = ppu.Greek.identifier
    # or
    # ident = ppu.Ελληνικά.identifier
    
  • Reworked delimited_list function into the new DelimitedList class. DelimitedList has the same constructor interface as delimited_list, and in this release, delimited_list changes from a function to a synonym for DelimitedList. delimited_list and the older delimitedList method will be deprecated in a future release, in favor of DelimitedList.

  • Added new class method ParserElement.using_each, to simplify code that creates a sequence of Literals, Keywords, or other ParserElement subclasses.

    For instance, to define suppressable punctuation, you would previously write:

    LPAR, RPAR, LBRACE, RBRACE, SEMI = map(Suppress, "(){};")
    

    You can now write:

    LPAR, RPAR, LBRACE, RBRACE, SEMI = Suppress.using_each("(){};")
    

    using_each will also accept optional keyword args, which it will pass through to the class initializer. Here is an expression for single-letter variable names that might be used in an algebraic expression:

    algebra_var = MatchFirst(
        Char.using_each(string.ascii_lowercase, as_keyword=True)
    )
    

... (truncated)

Changelog

Sourced from pyparsing's changelog.

Version 3.2.0 - October, 2024

  • Discontinued support for Python 3.6, 3.7, and 3.8. Adopted new Python features from Python versions 3.7-3.9:

    • Updated type annotations to use built-in container types instead of names imported from the typing module (e.g., list[str] vs List[str]).
    • Reworked portions of the packrat cache to leverage insertion-preserving ordering in dicts (including removal of uses of OrderedDict).
    • Changed pdb.set_trace() call in ParserElement.set_break() to breakpoint().
    • Converted typing.NamedTuple to dataclasses.dataclass in railroad diagramming code.
    • Added from __future__ import annotations to clean up some type annotations. (with assistance from ISyncWithFoo, issue #535, thanks for the help!)
  • POSSIBLE BREAKING CHANGES

    The following bugfixes may result in subtle changes in the results returned or exceptions raised by pyparsing.

    • Fixed code in ParseElementEnhance subclasses that replaced detailed exception messages raised in contained expressions with a less-specific and less-informative generic exception message and location.

      If your code has conditional logic based on the message content in raised ParseExceptions, this bugfix may require changes in your code.

    • Fixed bug in transform_string() where whitespace in the input string was not properly preserved in the output string.

      If your code uses transform_string, this bugfix may require changes in your code.

    • Fixed bug where an IndexError raised in a parse action was incorrectly handled as an IndexError raised as part of the ParserElement parsing methods, and reraised as a ParseException. Now an IndexError that raises inside a parse action will properly propagate out as an IndexError. (Issue #573, reported by August Karlstedt, thanks!)

      If your code raises IndexErrors in parse actions, this bugfix may require changes in your code.

  • FIXES AND NEW FEATURES

    • Added type annotations to remainder of pyparsing package, and added mypy run to tox.ini, so that type annotations are now run as part of pyparsing's CI. Addresses Issue #373, raised by Iwan Aucamp, thanks!

    • Exception message format can now be customized, by overriding ParseBaseException.format_message:

... (truncated)

Commits
  • 36fc04b Fix docstring with invalid esc sequence
  • a46066d Prep for 3.2.0 release
  • a0c219b Docs cleanup; added new whats_new_* docs for 3.1 and 3.2
  • d9b1f14 Rewrite _collapse_string_to_ranges to use _GroupConsecutive class instead of ...
  • 0d3c2d7 Fix minor internal bug in one_of building regex when all choices are single c...
  • 2165ab2 Cleanup ambiguous "contains" vs "in" usage in mongodb_query_expression.py
  • 25ddb02 Prep for dev before final release
  • 08846ae Prep for release
  • 9ee042b Remove deprecated utcnow()
  • a2b2f25 Final cleanup on mongodb_query_expression.py and mongodb_query_expression_ste...
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [pyparsing](https://github.com/pyparsing/pyparsing) from 2.4.7 to 3.2.0.
- [Release notes](https://github.com/pyparsing/pyparsing/releases)
- [Changelog](https://github.com/pyparsing/pyparsing/blob/master/CHANGES)
- [Commits](pyparsing/pyparsing@pyparsing_2.4.7...3.2.0)

---
updated-dependencies:
- dependency-name: pyparsing
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
Copy link
Contributor

sourcery-ai bot commented Oct 14, 2024

🧙 Sourcery has finished reviewing your pull request!


Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time. You can also use
    this command to specify where the summary should be inserted.

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have skipped reviewing this pull request. It seems to have been created by a bot (hey, dependabot[bot]!). We assume it knows what it's doing!

Copy link

codecov bot commented Oct 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 38.91%. Comparing base (74fc14e) to head (06f3122).
Report is 36 commits behind head on master.

❗ There is a different number of reports uploaded between BASE (74fc14e) and HEAD (06f3122). Click for more details.

HEAD has 10 uploads less than BASE
Flag BASE (74fc14e) HEAD (06f3122)
unit 3 0
functional 6 1
integration 2 0
Additional details and impacted files
@@             Coverage Diff             @@
##           master    #5339       +/-   ##
===========================================
- Coverage   49.24%   38.91%   -10.34%     
===========================================
  Files          94       92        -2     
  Lines       15699    14749      -950     
===========================================
- Hits         7731     5739     -1992     
- Misses       7968     9010     +1042     
Flag Coverage Δ
functional 38.91% <ø> (+0.83%) ⬆️
integration ?
unit ?

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant