From e3ed91f7a987115a37905e013e2219a9f71f9ff18f1dba4246a248e66d2ba5ff Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Mon, 3 Jul 2023 07:16:42 +0000 Subject: [PATCH 1/2] Accepting request 1096296 from home:mcalabkova:branches:devel:languages:python - update to 3.1.0 * API ENHANCEMENT: `Optional(expr)` may now be written as `expr | ""` * Added new class property `identifier` to all Unicode set classes in `pyparsing.unicode`, using the class's values for `cls.identchars` and `cls.identbodychars`. * ParseResults` now has a new method `deepcopy()`, in addition to the current `copy()` method. * Reworked `delimited_list` function into the new `DelimitedList` class. * Added new class method `ParserElement.using_each` * Added new builtin `python_quoted_string`, which will match any form of single-line or multiline quoted strings defined in Python. * `ParserElement.validate()` is deprecated. * Added bool `embed` argument to `ParserElement.create_diagram()`. * Added support for Python 3.12. * Updated `create_diagram()` code to be compatible with railroad-diagrams package version 3.0. * Many other changes, see upstream CHANGES OBS-URL: https://build.opensuse.org/request/show/1096296 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pyparsing?expand=0&rev=95 --- pyparsing-3.0.9.tar.gz | 3 --- pyparsing-3.1.0.tar.gz | 3 +++ python-pyparsing.changes | 21 +++++++++++++++++++++ python-pyparsing.spec | 2 +- 4 files changed, 25 insertions(+), 4 deletions(-) delete mode 100644 pyparsing-3.0.9.tar.gz create mode 100644 pyparsing-3.1.0.tar.gz diff --git a/pyparsing-3.0.9.tar.gz b/pyparsing-3.0.9.tar.gz deleted file mode 100644 index 3792ec9..0000000 --- a/pyparsing-3.0.9.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb -size 1999906 diff --git a/pyparsing-3.1.0.tar.gz b/pyparsing-3.1.0.tar.gz new file mode 100644 index 0000000..26793d3 --- /dev/null +++ b/pyparsing-3.1.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:edb662d6fe322d6e990b1594b5feaeadf806803359e3d4d42f11e295e588f0ea +size 882565 diff --git a/python-pyparsing.changes b/python-pyparsing.changes index cb49038..a264678 100644 --- a/python-pyparsing.changes +++ b/python-pyparsing.changes @@ -1,3 +1,24 @@ +------------------------------------------------------------------- +Sat Jul 1 13:52:01 UTC 2023 - Markéta Machová + +- update to 3.1.0 + * API ENHANCEMENT: `Optional(expr)` may now be written as `expr | ""` + * Added new class property `identifier` to all Unicode set classes in + `pyparsing.unicode`, using the class's values for `cls.identchars` + and `cls.identbodychars`. + * ParseResults` now has a new method `deepcopy()`, in addition to the + current `copy()` method. + * Reworked `delimited_list` function into the new `DelimitedList` class. + * Added new class method `ParserElement.using_each` + * Added new builtin `python_quoted_string`, which will match any form + of single-line or multiline quoted strings defined in Python. + * `ParserElement.validate()` is deprecated. + * Added bool `embed` argument to `ParserElement.create_diagram()`. + * Added support for Python 3.12. + * Updated `create_diagram()` code to be compatible with + railroad-diagrams package version 3.0. + * Many other changes, see upstream CHANGES + ------------------------------------------------------------------- Fri Apr 21 12:31:03 UTC 2023 - Dirk Müller diff --git a/python-pyparsing.spec b/python-pyparsing.spec index dfa49de..9aeb962 100644 --- a/python-pyparsing.spec +++ b/python-pyparsing.spec @@ -56,7 +56,7 @@ ExclusiveArch: do-not-build %endif %{?sle15_python_module_pythons} Name: %{pprefix}-pyparsing%{?psuffix} -Version: 3.0.9 +Version: 3.1.0 Release: 0 Summary: Grammar Parser Library for Python License: GPL-2.0-or-later AND MIT AND GPL-3.0-or-later From 74909f534d6b34b3492d297c9768add0feba4a571542fb96909ca8fa1b5853a6 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Wed, 12 Jul 2023 08:26:26 +0000 Subject: [PATCH 2/2] Accepting request 1098099 from home:mcalabkova:branches:devel:languages:python:numeric - Add upstream patch limit-error-messages.patch as a part of a workaround for boo#1213007 Should go together with matplotlib OBS-URL: https://build.opensuse.org/request/show/1098099 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pyparsing?expand=0&rev=96 --- limit-error-messages.patch | 23 +++++++++++++++++++++++ python-pyparsing.changes | 6 ++++++ python-pyparsing.spec | 3 +++ 3 files changed, 32 insertions(+) create mode 100644 limit-error-messages.patch diff --git a/limit-error-messages.patch b/limit-error-messages.patch new file mode 100644 index 0000000..b6446ca --- /dev/null +++ b/limit-error-messages.patch @@ -0,0 +1,23 @@ +From e0826a2ec69bc3cf71ba7ca7945774d9213d7d5e Mon Sep 17 00:00:00 2001 +From: Kyle Sunden +Date: Wed, 5 Jul 2023 14:16:50 -0500 +Subject: [PATCH] Limit error message overriding when + +--- + pyparsing/core.py | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/pyparsing/core.py b/pyparsing/core.py +index 8233f72c..bfbb391c 100644 +--- a/pyparsing/core.py ++++ b/pyparsing/core.py +@@ -4547,7 +4547,8 @@ def parseImpl(self, instring, loc, doActions=True): + try: + return self.expr._parse(instring, loc, doActions, callPreParse=False) + except ParseBaseException as pbe: +- pbe.msg = self.errmsg ++ if not isinstance(self, Forward) or self.customName is not None: ++ pbe.msg = self.errmsg + raise + else: + raise ParseException(instring, loc, "No expression defined", self) diff --git a/python-pyparsing.changes b/python-pyparsing.changes index a264678..2853152 100644 --- a/python-pyparsing.changes +++ b/python-pyparsing.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Jul 11 11:01:42 UTC 2023 - Markéta Machová + +- Add upstream patch limit-error-messages.patch as a part of + a workaround for boo#1213007 + ------------------------------------------------------------------- Sat Jul 1 13:52:01 UTC 2023 - Markéta Machová diff --git a/python-pyparsing.spec b/python-pyparsing.spec index 9aeb962..0fad56b 100644 --- a/python-pyparsing.spec +++ b/python-pyparsing.spec @@ -62,6 +62,8 @@ Summary: Grammar Parser Library for Python License: GPL-2.0-or-later AND MIT AND GPL-3.0-or-later URL: https://github.com/pyparsing/pyparsing/ Source: https://files.pythonhosted.org/packages/source/p/pyparsing/pyparsing-%{version}.tar.gz +#PATCH-FIX-UPSTREAM https://github.com/pyparsing/pyparsing/pull/493 Limit error message overriding +Patch: limit-error-messages.patch BuildRequires: %{python_module base} BuildRequires: %{python_module flit-core} BuildRequires: fdupes @@ -91,6 +93,7 @@ code uses to construct the grammar directly in Python code. %prep %setup -q -n %{modname}-%{version} +%autopatch -p1 %if !%{with test} %build