Repository navigation
Expand file tree
/
Copy pathpython3-typing_extensions.spec
More file actions
71 lines (61 loc) · 2.25 KB
/
Copy pathpython3-typing_extensions.spec
File metadata and controls
71 lines (61 loc) · 2.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#
# Conditional build:
%bcond_without tests # unit tests
Summary: Backported and Experimental Type Hints for Python 3.7+
Summary(pl.UTF-8): Backportowane i eksperymentalne podpowiedzi typów dla Pythona 3.7+
Name: python3-typing_extensions
Version: 4.16.0
Release: 1
License: PSF
Group: Libraries/Python
#Source0Download: https://pypi.org/simple/typing-extensions/
Source0: https://files.pythonhosted.org/packages/source/t/typing-extensions/typing_extensions-%{version}.tar.gz
# Source0-md5: 7758284b826ec6ca6b722e7891bbd10d
Patch0: typing_extensions-literal-dedup-test.patch
URL: https://pypi.org/project/typing-extensions/
BuildRequires: python3-build
BuildRequires: python3-flit_core >= 3.11
BuildRequires: python3-flit_core < 4
BuildRequires: python3-installer
BuildRequires: python3-modules >= 1:3.9
BuildRequires: rpm-pythonprov
BuildRequires: rpmbuild(macros) >= 2.044
Requires: python3-modules >= 1:3.9
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
The typing_extensions module serves two related purposes:
- Enable use of new type system features on older Python versions. For
example, typing.TypeGuard is new in Python 3.10, but
typing_extensions allows users on previous Python versions to use it
too.
- Enable experimentation with new type system PEPs before they are
accepted and added to the typing module.
%description -l pl.UTF-8
Moduł typing_extensions służy dwóm celom:
- umożlwia korzystanie z nowych cech systemu typów w starszych
wersjach Pythona - np. typing.TypeGuard pojawił się w Pythonie 3.10,
ale typing_extensions pozwala na korzystanie z niego użytkownikom
starszych wersji;
- pozwala na eksperymentowanie z nowymi PEP systemu typów zanim
zostaną zaakceptowane i dodane do moduły typing.
%prep
%setup -q -n typing_extensions-%{version}
%patch -P0 -p1
%build
%py3_build_pyproject
%if %{with tests}
PYTHONPATH=$(pwd)/src \
%{__python3} -m unittest discover -s src
%endif
%install
rm -rf $RPM_BUILD_ROOT
%py3_install_pyproject
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
%doc CHANGELOG.md LICENSE README.md
%{py3_sitescriptdir}/typing_extensions.py
%{py3_sitescriptdir}/__pycache__/typing_extensions.cpython-*.py[co]
%{py3_sitescriptdir}/typing_extensions-%{version}.dist-info