3 %bcond_without doc # Sphinx documentation
4 %bcond_with tests # unit tests (disable for bootstrap: tests need ipykernel which requires jupyter_client; as of 5.3.3 two test_session tests fail)
5 %bcond_without python2 # CPython 2.x module
6 %bcond_without python3 # CPython 3.x module
8 Summary: Reference implementation of the Jupyter protocol
9 Summary(pl.UTF-8): Referencyjna implementacja protokołu Jupyter
10 Name: python-jupyter_client
14 Group: Libraries/Python
15 #Source0Download: https://pypi.org/simple/jupyter_client/
16 Source0: https://files.pythonhosted.org/packages/source/j/jupyter_client/jupyter_client-%{version}.tar.gz
17 # Source0-md5: d99103c24cae3cf07a25296a2ef12d72
18 URL: https://pypi.org/project/jupyter_client/
20 BuildRequires: python-modules >= 1:2.7
21 BuildRequires: python-setuptools
23 BuildRequires: python-dateutil >= 2.1
24 BuildRequires: python-ipykernel
25 BuildRequires: python-ipython
26 BuildRequires: python-jupyter_core >= 4.6.0
27 BuildRequires: python-mock
28 BuildRequires: python-msgpack
29 BuildRequires: python-pytest
30 BuildRequires: python-traitlets
31 BuildRequires: python-tornado >= 4.1
32 BuildRequires: python-zmq >= 13
36 BuildRequires: python3-modules >= 1:3.5
37 BuildRequires: python3-setuptools
39 BuildRequires: python3-dateutil >= 2.1
40 BuildRequires: python3-ipykernel
41 BuildRequires: python3-ipython
42 BuildRequires: python3-jupyter_core >= 4.6.0
43 BuildRequires: python3-msgpack
44 BuildRequires: python3-pytest
45 BuildRequires: python3-traitlets
46 BuildRequires: python3-tornado >= 4.1
47 BuildRequires: python3-zmq >= 13
50 BuildRequires: rpm-pythonprov
51 BuildRequires: rpmbuild(macros) >= 1.714
53 #BuildRequires: python3-ipykernel
54 BuildRequires: python3-sphinxcontrib_github_alt
55 BuildRequires: python3-zmq >= 2.1
56 BuildRequires: sphinx-pdg-3
58 Requires: python-modules >= 1:2.7
60 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
63 jupyter_client contains the reference implementation of the Jupyter
64 protocol. It also provides client and kernel management APIs for
67 %description -l pl.UTF-8
68 jupyter_client zawiera referencyjną implementację protokołu Jupyter.
69 Zawiera także API klienckie i zarządzania jądrami.
71 %package -n python3-jupyter_client
72 Summary: Reference implementation of the Jupyter protocol
73 Summary(pl.UTF-8): Referencyjna implementacja protokołu Jupyter
74 Group: Libraries/Python
75 Requires: python3-modules >= 1:3.5
77 %description -n python3-jupyter_client
78 jupyter_client contains the reference implementation of the Jupyter
79 protocol. It also provides client and kernel management APIs for
82 %description -n python3-jupyter_client -l pl.UTF-8
83 jupyter_client zawiera referencyjną implementację protokołu Jupyter.
84 Zawiera także API klienckie i zarządzania jądrami.
87 Summary: API documentation for Python jupyter_client module
88 Summary(pl.UTF-8): Dokumentacja API modułu Pythona jupyter_client
92 API documentation for Python jupyter_client module.
94 %description apidocs -l pl.UTF-8
95 Dokumentacja API modułu Pythona jupyter_client.
98 %setup -q -n jupyter_client-%{version}
102 %py_build %{?with_tests:test}
104 # test_datetimes_msgpack (jupyter_client.tests.test_session.TestSession)
105 # test_tracking (jupyter_client.tests.test_session.TestSession)
109 %py3_build %{?with_tests:test}
114 %{__make} -C docs html \
115 SPHINXBUILD=sphinx-build-3
119 rm -rf $RPM_BUILD_ROOT
124 for f in $RPM_BUILD_ROOT%{_bindir}/jupyter-* ; do
125 %{__mv} "$f" "${f}-2"
129 %{__rm} -r $RPM_BUILD_ROOT%{py_sitescriptdir}/jupyter_client/tests
135 for f in $RPM_BUILD_ROOT%{_bindir}/jupyter-*[!2] ; do
136 %{__mv} "$f" "${f}-3"
139 %{__rm} -r $RPM_BUILD_ROOT%{py3_sitescriptdir}/jupyter_client/tests
143 rm -rf $RPM_BUILD_ROOT
147 %defattr(644,root,root,755)
148 %doc COPYING.md README.md
149 %attr(755,root,root) %{_bindir}/jupyter-kernel-2
150 %attr(755,root,root) %{_bindir}/jupyter-kernelspec-2
151 %attr(755,root,root) %{_bindir}/jupyter-run-2
152 %{py_sitescriptdir}/jupyter_client
153 %{py_sitescriptdir}/jupyter_client-%{version}-py*.egg-info
157 %files -n python3-jupyter_client
158 %defattr(644,root,root,755)
159 %doc COPYING.md README.md
160 %attr(755,root,root) %{_bindir}/jupyter-kernel-3
161 %attr(755,root,root) %{_bindir}/jupyter-kernelspec-3
162 %attr(755,root,root) %{_bindir}/jupyter-run-3
163 %{py3_sitescriptdir}/jupyter_client
164 %{py3_sitescriptdir}/jupyter_client-%{version}-py*.egg-info
169 %defattr(644,root,root,755)
170 %doc docs/_build/html/{_images,_static,api,*.html,*.js}