diff --git a/.python-websocket-client.metadata b/.python-websocket-client.metadata index 2d04da2..590874a 100644 --- a/.python-websocket-client.metadata +++ b/.python-websocket-client.metadata @@ -1 +1 @@ -02489d12626360e0b9b4be3d961355890ec4205c SOURCES/websocket_client-0.47.0.tar.gz +233998dd7f194432b68c5811486ac8bbce7e0d33 SOURCES/websocket-client-1.3.3.tar.gz diff --git a/SOURCES/.gitignore b/SOURCES/.gitignore new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/SOURCES/.gitignore diff --git a/SPECS/python-websocket-client.spec b/SPECS/python-websocket-client.spec index 2dd7877..fff3cad 100644 --- a/SPECS/python-websocket-client.spec +++ b/SPECS/python-websocket-client.spec @@ -1,158 +1,150 @@ -%if 0%{?fedora} || 0%{?rhel} > 7 -%global with_python3 1 -%endif - -%if 0%{?rhel} > 7 -# Disable python2 build by default -%bcond_with python2 -%else -%bcond_without python2 -%endif - -%global modname websocket -%global distname websocket-client -%global eggname websocket_client - -Name: python-websocket-client -Version: 0.47.0 +# what it's called on pypi +%global srcname websocket-client +# what it's imported as +%global libname websocket + +%global common_description %{expand: +websocket-client is a WebSocket client for Python. It provides access to low +level APIs for WebSockets. websocket-client implements version hybi-13 of the +WebSocket protocol. This client does not currently support the +permessage-deflate extension from RFC 7692.} + + +Name: python-%{srcname} +Version: 1.3.3 Release: 2%{?dist} Summary: WebSocket client for python -License: LGPLv2 +License: ASL 2.0 URL: https://github.com/websocket-client/websocket-client -Source0: https://files.pythonhosted.org/packages/source/w/%{distname}/%{eggname}-%{version}.tar.gz +Source0: %pypi_source BuildArch: noarch -%global _description\ -python-websocket-client module is WebSocket client for python. This\ -provides the low level APIs for WebSocket. All APIs are the synchronous\ -functions.\ -\ -python-websocket-client supports only hybi-13. +%description %{common_description} -%description %_description - -%if %{with python2} -%package -n python2-websocket-client -Summary: %{summary} -BuildRequires: python2-devel -BuildRequires: python2-setuptools -BuildRequires: python2-backports-ssl_match_hostname -BuildRequires: python2-six -%if 0%{?rhel} && 0%{?rhel} <= 6 -BuildRequires: python-unittest2 -BuildRequires: python-argparse -Requires: python-argparse -%endif -Requires: python-backports-ssl_match_hostname -Requires: python-six -%{?python_provide:%python_provide python2-websocket-client} - - -%description -n python2-websocket-client %_description -%endif # with python2 - - -%if 0%{?with_python3} -%package -n python3-websocket-client +%package -n python3-%{srcname} Summary: %{summary} BuildRequires: python3-devel -BuildRequires: python3-setuptools -BuildRequires: python3-six -Requires: python3-six -%{?python_provide:%python_provide python3-websocket-client} +BuildRequires: pyproject-rpm-macros +BuildRequires: %{py3_dist pytest} # https://fedoraproject.org/wiki/Packaging:Conflicts#Splitting_Packages # wsdump moved from py2 to py3 package Conflicts: python2-websocket-client <= 0.40.0-4 -%description -n python3-websocket-client %_description -%endif +%description -n python3-%{srcname} %{common_description} %prep -%setup -q -n %{eggname}-%{version} +%autosetup -n %{srcname}-%{version} -rm -r %{eggname}.egg-info +%generate_buildrequires +%pyproject_buildrequires -x test -%build -%if %{with python2} -%py2_build -%endif # with python2 -%if 0%{?with_python3} -%py3_build -%endif +%build +%pyproject_wheel %install -%if %{with python2} -# Must do the python2 install first because the scripts in /usr/bin are -# overwritten with every setup.py install, and in general we want the -# python3 version to be the default. -%py2_install +%pyproject_install +%pyproject_save_files %{libname} -# unbundle cacert and link in the mozilla ca -rm %{buildroot}%{python2_sitelib}/%{modname}/cacert.pem -ln -s /etc/pki/tls/cert.pem %{buildroot}%{python2_sitelib}/%{modname}/cacert.pem -# remove tests that got installed into the buildroot -rm -r %{buildroot}%{python2_sitelib}/%{modname}/tests -%endif # with python2 +%check +%pytest websocket/tests -%if 0%{?with_python3} -%py3_install -# unbundle cacert and link in the mozilla ca -rm %{buildroot}%{python3_sitelib}/%{modname}/cacert.pem -ln -s /etc/pki/tls/cert.pem %{buildroot}%{python3_sitelib}/%{modname}/cacert.pem +%files -n python3-%{srcname} -f %{pyproject_files} +%license LICENSE +%doc README.md ChangeLog +%{_bindir}/wsdump -# remove tests that got installed into the buildroot -rm -r %{buildroot}%{python3_sitelib}/%{modname}/tests -%endif -# https://fedoraproject.org/wiki/Packaging:Python#Executables_in_.2Fusr.2Fbin -# wsdump has the same functionality on py2 and py3, so only ship one version -mv %{buildroot}%{_bindir}/wsdump.py %{buildroot}%{_bindir}/wsdump +%changelog +* Fri Jul 22 2022 Fedora Release Engineering - 1.3.3-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild +* Thu Jun 30 2022 Major Hayden - 1.3.3-1 +- Update to 1.3.3 -%check -%if 0%{?with_python3} -%{__python3} setup.py test -%endif +* Thu Jun 16 2022 Python Maint - 1.3.2-2 +- Rebuilt for Python 3.11 -%if %{with python2} -%{__python2} setup.py test -%endif # with python2 +* Wed Apr 06 2022 Major Hayden - 1.3.2-1 +- Update to 1.3.2 -%if %{with python2} -%files -n python2-websocket-client -%license LICENSE -%doc README.rst -%{python2_sitelib}/%{modname}/ -%{python2_sitelib}/%{eggname}*%{version}* -%if ! 0%{?with_python3} -%{_bindir}/wsdump -%endif -%endif # with python2 +* Fri Jan 21 2022 Fedora Release Engineering - 1.2.3-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild +* Tue Dec 21 2021 Carl George - 1.2.3-1 +- Latest upstream +- Resolves: rhbz#1990682 -%if 0%{?with_python3} -%files -n python3-websocket-client -%license LICENSE -%doc README.rst -%{python3_sitelib}/%{modname}/ -%{python3_sitelib}/%{eggname}*%{version}* -%{_bindir}/wsdump -%endif +* Sun Aug 01 2021 Carl George - 1.1.0-1 +- Latest upstream +- Resolves: rhbz#1934343 +* Tue Jul 27 2021 Fedora Release Engineering - 0.57.0-4 +- Second attempt - Rebuilt for + https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild -%changelog -* Wed Jun 06 2018 Charalampos Stratakis - 0.47.0-2 -- Conditionalize the python2 subpackage +* Thu Jun 03 2021 Python Maint - 0.57.0-3 +- Rebuilt for Python 3.10 + +* Wed Jan 27 2021 Fedora Release Engineering - 0.57.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild + +* Thu Sep 10 2020 Joel Capitao - 0.57.0-1 +- Update to 0.57.0 +- Remove python2 subpackage + +* Wed Jul 29 2020 Fedora Release Engineering - 0.56.0-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* Sat May 23 2020 Miro Hrončok - 0.56.0-7 +- Rebuilt for Python 3.9 + +* Thu Jan 30 2020 Fedora Release Engineering - 0.56.0-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + +* Thu Oct 03 2019 Miro Hrončok - 0.56.0-5 +- Rebuilt for Python 3.8.0rc1 (#1748018) + +* Fri Aug 16 2019 Miro Hrončok - 0.56.0-4 +- Rebuilt for Python 3.8 + +* Wed Aug 07 2019 Carl George - 0.56.0-3 +- Disable python2 subpackage on F31+ rhbz#1738467 + +* Fri Jul 26 2019 Fedora Release Engineering - 0.56.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild + +* Mon Jun 10 2019 Carl George - 0.56.0-1 +- Latest upstream + +* Tue Feb 12 2019 Yatin Karel - 0.54.0-1 +- Update to 0.54.0 +- Change license to BSD as source has changed it. + +* Sat Feb 02 2019 Fedora Release Engineering - 0.53.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild + +* Sun Oct 28 2018 Peter Robinson 0.53.0-1 +- Update to 0.53.0 + +* Sat Jul 14 2018 Fedora Release Engineering - 0.47.0-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild + +* Sun Jun 17 2018 Miro Hrončok - 0.47.0-3 +- Rebuilt for Python 3.7 + +* Tue Mar 27 2018 Charalampos Stratakis - 0.47.0-2 +- Conditionalize the Python 2 subpackage +- Don't build the Python 2 subpackage on EL > 7 * Mon Mar 26 2018 Jan Beran - 0.47.0-1 - Latest upstream (rhbz# 1548228)