From ffc9e3fb44e2fcc3fb2c22a521f9df0c6a6417c4ae9b2a8a9a02bd3e5d555e3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrian=20Schr=C3=B6ter?= Date: Fri, 13 Sep 2024 16:18:02 +0200 Subject: [PATCH] Sync from SUSE:SLFO:Main python-annotated-types revision 851d54162463a2d65f9a0c98f5a68296 --- .gitattributes | 23 +++++++++++++ annotated_types-0.7.0.tar.gz | 3 ++ python-annotated-types.changes | 21 ++++++++++++ python-annotated-types.spec | 63 ++++++++++++++++++++++++++++++++++ 4 files changed, 110 insertions(+) create mode 100644 .gitattributes create mode 100644 annotated_types-0.7.0.tar.gz create mode 100644 python-annotated-types.changes create mode 100644 python-annotated-types.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/annotated_types-0.7.0.tar.gz b/annotated_types-0.7.0.tar.gz new file mode 100644 index 0000000..241d91c --- /dev/null +++ b/annotated_types-0.7.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aff07c09a53a08bc8cfccb9c85b05f1aa9a2a6f23728d790723543408344ce89 +size 16081 diff --git a/python-annotated-types.changes b/python-annotated-types.changes new file mode 100644 index 0000000..4c617fb --- /dev/null +++ b/python-annotated-types.changes @@ -0,0 +1,21 @@ +------------------------------------------------------------------- +Mon Jun 17 05:48:32 UTC 2024 - Dirk Müller + +- update to 0.7.0: + * Allow `tzinfo` objects for `Timezone` + * add URLs to `pyproject.toml` + * suggested fix on typo + * Correct misstatement in README + * Fix IsDigit -> IsDigits + * Add `Unit` type + * Improve handling of GroupedMetadata (First try) + +------------------------------------------------------------------- +Sat Mar 9 13:13:15 UTC 2024 - ecsos + +- Add %{?sle15_python_module_pythons} + +------------------------------------------------------------------- +Thu Mar 7 00:46:14 UTC 2024 - Steve Kowalik + +- Initial release of 0.6.0 diff --git a/python-annotated-types.spec b/python-annotated-types.spec new file mode 100644 index 0000000..a53ab8a --- /dev/null +++ b/python-annotated-types.spec @@ -0,0 +1,63 @@ +# +# spec file for package python-annotated-types +# +# 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-annotated-types +Version: 0.7.0 +Release: 0 +Summary: Reusable constraint types to use with typing.Annotated +License: MIT +URL: https://github.com/annotated-types/annotated-types/ +Source: https://files.pythonhosted.org/packages/source/a/annotated-types/annotated_types-%{version}.tar.gz +BuildRequires: %{python_module hatchling} +BuildRequires: %{python_module pip} +BuildRequires: %{python_module pytest} +BuildRequires: fdupes +BuildRequires: python-rpm-macros +BuildArch: noarch +%python_subpackages + +%description +PEP-593 added `typing.Annotated` as a way of adding context-specific metadata to +existing types, and specifies that `Annotated[T, x]` _should_ be treated as `T` by +any tool or library without special logic for `x`. + +This package provides metadata objects which can be used to represent common +constraints such as upper and lower bounds on scalar values and collection sizes, +a `Predicate` marker for runtime checks, and +descriptions of how we intend these metadata to be interpreted. In some cases, +we also note alternative representations which do not require this package. + +%prep +%autosetup -p1 -n annotated_types-%{version} + +%build +%pyproject_wheel + +%install +%pyproject_install +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%check +%pytest + +%files %{python_files} +%{python_sitelib}/annotated_types +%{python_sitelib}/annotated_types-%{version}.dist-info + +%changelog