From b6ffb932ffaa3ca4acc68633c6f57f214fba7f26a4498451718291214fde040e Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Tue, 29 Oct 2024 21:38:21 +0000 Subject: [PATCH] - update to 1.7.0: * Allow raw numeric values to be used as keys * Add `wherenot` * Added EZRegex pattern for the split extension regex * Added negative and * indecies and quotes to `Split` parameters * Typo: duplicate line removed. * Added `path` extension that exposes datum's path from the jsonpath expression itself. * Remove Python 3.7 support * Only construct the parse table once * updated test for `jsonpath.py` changes * fix for Updating a json object fails if the value of a key is boolean #73 * Add Codespaces configuration * Add `.editorconfig` * Fix a GitHub workflow schema issue OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-jsonpath-ng?expand=0&rev=10 --- .gitattributes | 23 +++++++ .gitignore | 1 + jsonpath-ng-1.6.1.tar.gz | 3 + jsonpath-ng-1.7.0.tar.gz | 3 + python-jsonpath-ng.changes | 136 +++++++++++++++++++++++++++++++++++++ python-jsonpath-ng.spec | 78 +++++++++++++++++++++ 6 files changed, 244 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 jsonpath-ng-1.6.1.tar.gz create mode 100644 jsonpath-ng-1.7.0.tar.gz create mode 100644 python-jsonpath-ng.changes create mode 100644 python-jsonpath-ng.spec diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/jsonpath-ng-1.6.1.tar.gz b/jsonpath-ng-1.6.1.tar.gz new file mode 100644 index 0000000..42f5fe3 --- /dev/null +++ b/jsonpath-ng-1.6.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ff39f87b5a43a284306e6839de9122c1d4d586d0deaa262ea95018c530f3956 +size 33427 diff --git a/jsonpath-ng-1.7.0.tar.gz b/jsonpath-ng-1.7.0.tar.gz new file mode 100644 index 0000000..ca31ea8 --- /dev/null +++ b/jsonpath-ng-1.7.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e29658261512813009551c0ac228a9d9523a10503a46ce243fc63e3f28752c40 +size 34943 diff --git a/python-jsonpath-ng.changes b/python-jsonpath-ng.changes new file mode 100644 index 0000000..639c4a2 --- /dev/null +++ b/python-jsonpath-ng.changes @@ -0,0 +1,136 @@ +------------------------------------------------------------------- +Tue Oct 29 21:38:03 UTC 2024 - Dirk Müller + +- update to 1.7.0: + * Allow raw numeric values to be used as keys + * Add `wherenot` + * Added EZRegex pattern for the split extension regex + * Added negative and * indecies and quotes to `Split` + parameters + * Typo: duplicate line removed. + * Added `path` extension that exposes datum's path from the + jsonpath expression itself. + * Remove Python 3.7 support + * Only construct the parse table once + * updated test for `jsonpath.py` changes + * fix for Updating a json object fails if the value of a key is + boolean #73 + * Add Codespaces configuration + * Add `.editorconfig` + * Fix a GitHub workflow schema issue + +------------------------------------------------------------------- +Fri Feb 09 14:50:00 UTC 2024 - Christian Keil + +- Switch to Python 3.11 build. +- Remove build dependency oslotest (pull request #137). + +------------------------------------------------------------------- +Mon Jan 22 23:44:48 UTC 2024 - Dirk Müller + +- update to 1.6.1: + * Fix issue with lambda based updates + * Remove unused code from the test suite + * De-duplicate the parser test cases + * Remove a test that merely checks exception inheritance + * Add pytest-randomly to shake out auto_id side effects + * Include the test suite in coverage reports + * Remove tests that don't affect coverage and contribute + nothing + * Reformat `tests/test_create.py` + * Remove `test_doctests`, which is a no-op + * Demonstrate that there are no doctests + * Remove the `coveralls` dependency + * Migrate `tests/bin/test_jsonpath.py` to use pytest + * remove Python2 crumbs + * Add CodeQL analysis + * Remove the `oslotest` dependency + * Fix running CI against incoming PRs + * Support, and test against, Python 3.12 + * Update the currently-tested CPython versions in the README + * Remove an unused Travis CI config file + * Add a Dependabot config to keep GitHub action versions + updated + * add a test for the case when root element is a list + * Fix issue with assignment in case root element is a list. + * Fix typo in README + * Fix test commands in Makefile + * Fix .coveragerc path + * Simplify clean in Makefile + * Refactor unit tests for better errors + * test case for existing auto id + * Add more examples to README (thanks @baynes) + * Don't fail when regex match is attempted on non-strings + * Add additional tests + * Add `keys` keyword + +------------------------------------------------------------------- +Fri Sep 15 08:51:59 UTC 2023 - pgajdos@suse.com + +- version update to 1.6.0 + 1.6.0 / 2023-09-13 + * Enclose field names containing literals in quotes + * Add note about extensions + * Remove documentation status link + * Update supported versions in setup.py + * Add LICENSE file + * Code cleanup + * Remove dependency on six + * Update build status badge + * (origin/github-actions, github-actions) Remove testscenarios dependency + * Remove pytest version constraints + * Add testing with GitHub actions + * Escape back slashes in tests to avoid DeprecationWarning. + * Use raw strings for regular expressions to avoid DeprecationWarning. + * refactor(package): remove dependency for decorator + * Merge pull request #128 from michaelmior/hashable + * (origin/hashable, hashable) Make path instances hashable + * Merge pull request #122 from snopoke/snopoke-patch-1 + * Add more detail to filter docs. + * remove incorrect parenthesis in filter examples + * Merge pull request #119 from snopoke/patch-1 + * add 'sub' line with function param names + * readme formatting fixes + * chore(history): update + * Update __init__.py + 1.5.3 / 2021-07-05 + * Update __init__.py + * Update setup.py + * Merge pull request #72 from kaapstorm/find_or_create + * Tests + * Add `update_or_create()` method + * Merge pull request #68 from kaapstorm/example_tests + * Merge pull request #70 from kaapstorm/exceptions + * Add/fix `__eq__()` + * Add tests based on Stefan Goessner's examples + * Tests + * Allow callers to catch JSONPathErrors +- six and decorator are not required + +------------------------------------------------------------------- +Wed Nov 3 08:28:31 UTC 2021 - pgajdos@suse.com + +- version update to 1.5.2 + * Merge pull request #41 from josephwhite13/allow-dictionary-filtering + * Merge pull request #48 from back2root/master + * Check for null value. + * Merge pull request #40 from memborsky/add-regular-expression-contains-support + * feat: support regular expression for performing contains (=~) filtering + * if datum.value is a dictionary, filter on the list of values +- %check: use python -m pytest instead of setup.py test + +------------------------------------------------------------------- +Thu Apr 29 19:50:19 UTC 2021 - John Vandenberg + +- Tidy spec +- Activate test suite + +------------------------------------------------------------------- +Sun Apr 25 13:23:04 UTC 2021 - Martin Hauke + +- Package cleanup + +------------------------------------------------------------------- +Sat May 23 07:54:17 PM UTC 2020 - John Vandenberg + +- Initial spec for v1.5.1 diff --git a/python-jsonpath-ng.spec b/python-jsonpath-ng.spec new file mode 100644 index 0000000..ebd1165 --- /dev/null +++ b/python-jsonpath-ng.spec @@ -0,0 +1,78 @@ +# +# spec file for package python-jsonpath-ng +# +# Copyright (c) 2024 SUSE LLC +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + + +%{?sle15_python_module_pythons} +Name: python-jsonpath-ng +Version: 1.7.0 +Release: 0 +Summary: JSONPath for Python +License: Apache-2.0 +Group: Development/Languages/Python +URL: https://github.com/h2non/jsonpath-ng +Source: https://github.com/h2non/jsonpath-ng/archive/refs/tags/v%{version}.tar.gz#/jsonpath-ng-%{version}.tar.gz +BuildRequires: %{python_module pip} +BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} +BuildRequires: fdupes +BuildRequires: python-rpm-macros +Requires: python-decorator +Requires: python-ply +Requires(post): update-alternatives +Requires(postun): update-alternatives +BuildArch: noarch +# SECTION test requirements +BuildRequires: %{python_module ply} +# +BuildRequires: %{python_module pytest} +# /SECTION +%python_subpackages + +%description +A final implementation of JSONPath for Python that aims to be +standard compliant, including arithmetic and binary comparison +operators and providing clear AST for metaprogramming. + +%prep +%setup -q -n jsonpath-ng-%{version} +sed -i '1{/^#!/d}' jsonpath_ng/bin/jsonpath.py + +%build +%pyproject_wheel + +%install +%pyproject_install +%python_clone -a %{buildroot}%{_bindir}/jsonpath_ng +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%post +%python_install_alternative jsonpath_ng + +%postun +%python_uninstall_alternative jsonpath_ng + +%check +%pytest + +%files %{python_files} +%license LICENSE +%doc README.rst History.md +%python_alternative %{_bindir}/jsonpath_ng +%{python_sitelib}/jsonpath_ng +%{python_sitelib}/jsonpath_ng-%{version}.dist-info + +%changelog