From 2a30a834173b0ff848b9ce305941b428efa42e3094dc43759e393a74dca085e0 Mon Sep 17 00:00:00 2001 From: Richard Rahl Date: Fri, 8 Mar 2024 02:36:32 +0000 Subject: [PATCH] Accepting request 1156207 from home:rrahl0:upgrades - add script get-tests.sh to fetch tests - update to 3.0.1: * technical update (deps) - update to 3.0.0: * = field field declarations replaced with Annotated hinting * Removed @message decorator in favour of BaseMessage * Re-written the core * Typing changes (see also: https://eigenein.github.io/protobuf/migration/) OBS-URL: https://build.opensuse.org/request/show/1156207 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pure-protobuf?expand=0&rev=3 --- get-tests.sh | 17 ++++++++++++++++ pure_protobuf-2.3.0.tar.gz | 3 --- pure_protobuf-3.0.1.tar.gz | 3 +++ pure_protobuf-tests-2.3.0.tar.gz | 3 --- python-pure-protobuf-tests-3.0.1.tar.gz | 3 +++ python-pure-protobuf.changes | 13 ++++++++++++ python-pure-protobuf.spec | 27 ++++++++++++++++--------- 7 files changed, 54 insertions(+), 15 deletions(-) create mode 100644 get-tests.sh delete mode 100644 pure_protobuf-2.3.0.tar.gz create mode 100644 pure_protobuf-3.0.1.tar.gz delete mode 100644 pure_protobuf-tests-2.3.0.tar.gz create mode 100644 python-pure-protobuf-tests-3.0.1.tar.gz diff --git a/get-tests.sh b/get-tests.sh new file mode 100644 index 0000000..0f15b83 --- /dev/null +++ b/get-tests.sh @@ -0,0 +1,17 @@ +#!/usr/bin/sh + +set -e + +if [ -z $1 ]; then +echo "Please input a version for which we should download the tests for" +else +VERSION=$1 +curl -LO https://github.com/eigenein/protobuf/archive/refs/tags/$VERSION.tar.gz +mkdir -p tmp +tar xf $VERSION.tar.gz -C tmp +cd tmp/protobuf-$VERSION +tar cf python-pure-protobuf-tests-$VERSION.tar.gz tests +mv python-pure-protobuf-tests-$VERSION.tar.gz ../.. +cd ../.. +rm -rf tmp $VERSION.tar.gz +fi diff --git a/pure_protobuf-2.3.0.tar.gz b/pure_protobuf-2.3.0.tar.gz deleted file mode 100644 index 42dfc58..0000000 --- a/pure_protobuf-2.3.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:08e497d46876ff7f78e8bf703c42788a7e8521be4a6540f7fe37e5259f6ffea2 -size 16481 diff --git a/pure_protobuf-3.0.1.tar.gz b/pure_protobuf-3.0.1.tar.gz new file mode 100644 index 0000000..8f7a7f7 --- /dev/null +++ b/pure_protobuf-3.0.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:64340554ae99cf075d6e2f23b34e5b6ce4a90251c0b03ae29d5d1f24091f5424 +size 18228 diff --git a/pure_protobuf-tests-2.3.0.tar.gz b/pure_protobuf-tests-2.3.0.tar.gz deleted file mode 100644 index 60df2bc..0000000 --- a/pure_protobuf-tests-2.3.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a8019df38da4e20bf0d37278d878c2eb502a76cbf0616c8d6aa15bc06e73814b -size 51200 diff --git a/python-pure-protobuf-tests-3.0.1.tar.gz b/python-pure-protobuf-tests-3.0.1.tar.gz new file mode 100644 index 0000000..7c3d4a3 --- /dev/null +++ b/python-pure-protobuf-tests-3.0.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8dcc2aa8f2501eb1b620d8d2c537fc4291486393fc34358a4995974497ded271 +size 71680 diff --git a/python-pure-protobuf.changes b/python-pure-protobuf.changes index f726fe3..7b423ee 100644 --- a/python-pure-protobuf.changes +++ b/python-pure-protobuf.changes @@ -1,3 +1,16 @@ +------------------------------------------------------------------- +Fri Mar 8 00:46:53 UTC 2024 - Richard Rahl + +- add script get-tests.sh to fetch tests +- update to 3.0.1: + * technical update (deps) + +- update to 3.0.0: + * = field field declarations replaced with Annotated hinting + * Removed @message decorator in favour of BaseMessage + * Re-written the core + * Typing changes (see also: https://eigenein.github.io/protobuf/migration/) + ------------------------------------------------------------------- Sat Dec 16 07:45:47 UTC 2023 - Richard Rahl diff --git a/python-pure-protobuf.spec b/python-pure-protobuf.spec index 452ad12..01b8056 100644 --- a/python-pure-protobuf.spec +++ b/python-pure-protobuf.spec @@ -1,7 +1,7 @@ # # spec file for package python-pure-protobuf # -# Copyright (c) 2023 SUSE LLC +# 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 @@ -15,26 +15,36 @@ # Please submit bugfixes or comments via https://bugs.opensuse.org/ # + %{?sle15_python_module_pythons} Name: python-pure-protobuf -Version: 2.3.0 +Version: 3.0.1 Release: 0 Summary: Protocol Buffers using Python type annotations -Group: Development/Libraries/Python License: MIT Group: Development/Libraries/Python URL: https://github.com/eigenein/protobuf Source: https://files.pythonhosted.org/packages/source/p/pure-protobuf/pure_protobuf-%{version}.tar.gz -Source1: pure_protobuf-tests-%{version}.tar.gz -BuildRequires: python-rpm-macros +Source1: %{name}-tests-%{version}.tar.gz +Source99: get-tests.sh +BuildRequires: %{python_module get-annotations} +BuildRequires: %{python_module hatch_vcs} +BuildRequires: %{python_module hatchling} BuildRequires: %{python_module pip} BuildRequires: %{python_module poetry-core} -BuildRequires: %{python_module hatchling} -BuildRequires: %{python_module hatch_vcs} +BuildRequires: %{python_module poetry-dynamic-versioning} +BuildRequires: %{python_module pydantic} +BuildRequires: %{python_module typing-extensions} BuildRequires: fdupes +BuildRequires: git-core +BuildRequires: python-rpm-macros ## needed for tests BuildRequires: %{python_module pytest} +BuildRequires: %{python_module pytest-benchmark} +BuildRequires: %{python_module pytest-cov} BuildArch: noarch +Requires: python-get-annotations +Requires: python-typing-extensions %python_subpackages %description @@ -51,8 +61,7 @@ BuildArch: noarch %python_expand %fdupes %{buildroot}%{$python_sitelib} %check -donttest="serializer" -%pytest -k "not $donttest" +%pytest %files %{python_files} %{python_sitelib}/pure_protobuf