.gear/python3-module-cheroot.spec | 147 +++++++++++++++++++++ .gear/rules | 3 + .../tags/6174855d9d0ad09be0c372420c01114be7c0426b | 10 ++ .gear/tags/list | 1 + .gear/upstream/remotes | 3 + .gitignore | 1 - cheroot/test/test_ssl.py | 2 +- cheroot/testing.py | 2 +- cheroot/workers/threadpool.py | 2 +- setup.cfg | 2 +- tox.ini | 2 +- 11 files changed, 169 insertions(+), 6 deletions(-) diff --git a/.gear/python3-module-cheroot.spec b/.gear/python3-module-cheroot.spec new file mode 100644 index 00000000..0b58be77 --- /dev/null +++ b/.gear/python3-module-cheroot.spec @@ -0,0 +1,147 @@ +%define modulename cheroot + +# there is no ipv6 support on our build system and cheroot tests do not support this configuration +# ERROR: Could not find a version that satisfies the requirement pytest-cov==2.10.1 +%def_disable check +%def_without tests + +Name: python3-module-%modulename +Version: 10.0.0 +Release: alt1 + +Summary: Cheroot is the high-performance, pure-Python HTTP server used by CherryPy +License: BSD +Group: Development/Python +URL: https://github.com/cherrypy/cheroot + +Source: %name-%version.tar +Patch0: %name-%version-%release.patch + +BuildRequires(pre): rpm-build-python3 +BuildRequires: python3-devel python3-module-setuptools_scm +BuildRequires: python3-devel python3-module-setuptools +BuildRequires: python3-module-pytest +BuildRequires: python3-module-pytest-testmon +BuildRequires: python3-module-pytest-cov +BuildRequires: python3-module-pytest-mock +BuildRequires: python3-module-pytest-xdist +BuildRequires: python3-module-pytest-sugar +BuildRequires: python3-module-pytest-watch +BuildRequires: python3-module-jaraco.functools +BuildRequires: python3-module-trustme +BuildRequires: python3-module-requests-unixsocket +BuildRequires: python3-module-urllib3 +BuildRequires: python3-module-OpenSSL +%if_enabled check +BuildRequires: python3-module-jaraco.text +BuildRequires: python3-module-jaraco.context +BuildRequires: python3-module-portend +BuildRequires: python3-module-requests_toolbelt +BuildRequires: python3-module-pytest-cov +%endif +BuildArch: noarch + +%description +Cheroot is the high-performance, pure-Python HTTP server used by CherryPy. + +%package tests +Summary: Tests for Cheroot +Group: Development/Python +Requires: %name = %EVR + +%description tests +This package contains tests for Cheroot + +%prep +%setup +%patch0 -p1 + +%build +export SETUPTOOLS_SCM_PRETEND_VERSION=%version +%python3_build + +%install +export SETUPTOOLS_SCM_PRETEND_VERSION=%version +%python3_install +%if_without tests +rm -rf %python3_sitelibdir/%{modulename}/test +rm -f %python3_sitelibdir/%{modulename}/testing.py +%endif + +%check +rm -f pyproject.toml +export SETUPTOOLS_SCM_PRETEND_VERSION=%version +export PIP_NO_INDEX=YES +export TOXENV=py%{python_version_nodots python3} +tox.py3 --sitepackages -v + +%files +%_bindir/cheroot +%python3_sitelibdir/*.egg-info +%python3_sitelibdir/%{modulename}* +%exclude %python3_sitelibdir/%{modulename}/test +%exclude %python3_sitelibdir/%{modulename}/testing.py + +%if_with tests +%files tests +%python3_sitelibdir/%{modulename}/test +%python3_sitelibdir/%{modulename}/testing.py +%endif + +%changelog +* Sun May 21 2023 Andrey Cherepanov 10.0.0-alt1 +- New version. + +* Sun Nov 20 2022 Andrey Cherepanov 9.0.0-alt1 +- New version. +- Disabled tests packaging. + +* Tue Jan 04 2022 Andrey Cherepanov 8.6.0-alt1 +- New version. + +* Tue Jul 13 2021 Andrey Cherepanov 8.5.2-alt1 +- New version. +- Disable %%check for all architectures (ALT #40332). + +* Tue Dec 03 2019 Anton Farygin 8.2.1-alt1 +- 8.2.1 + +* Fri Oct 04 2019 Anton Farygin 7.0.0-alt1 +- removed python-2.7 support +- added tests + +* Thu Sep 05 2019 Andrey Cherepanov 6.5.8-alt1 +- New version. + +* Wed Sep 04 2019 Andrey Cherepanov 6.5.7-alt1 +- New version. + +* Tue Aug 20 2019 Andrey Cherepanov 6.5.6-alt1 +- New version. + +* Tue Apr 30 2019 Andrey Cherepanov 6.5.5-alt1 +- New version. + +* Thu Jan 03 2019 Andrey Cherepanov 6.5.4-alt1 +- New version. + +* Fri Dec 28 2018 Andrey Cherepanov 6.5.3-alt1 +- New version. + +* Mon Sep 17 2018 Andrey Cherepanov 6.5.2-alt1 +- New version. + +* Thu Aug 23 2018 Andrey Cherepanov 6.4.0-alt1 +- New version. + +* Wed Jul 11 2018 Andrey Cherepanov 6.3.3-alt1 +- New version. + +* Mon Jun 18 2018 Andrey Cherepanov 6.3.2-alt1 +- New version. + +* Thu Jun 14 2018 Andrey Cherepanov 6.3.1-alt2 +- Require module instead of package. + +* Fri May 25 2018 Andrey Cherepanov 6.3.1-alt1 +- Initial build for Sisyphus diff --git a/.gear/rules b/.gear/rules new file mode 100644 index 00000000..10ce588b --- /dev/null +++ b/.gear/rules @@ -0,0 +1,3 @@ +tar: v@version@:. +spec: .gear/python3-module-cheroot.spec +diff: v@version@:. . diff --git a/.gear/tags/6174855d9d0ad09be0c372420c01114be7c0426b b/.gear/tags/6174855d9d0ad09be0c372420c01114be7c0426b new file mode 100644 index 00000000..11c0c212 --- /dev/null +++ b/.gear/tags/6174855d9d0ad09be0c372420c01114be7c0426b @@ -0,0 +1,10 @@ +object 2b3b3eb4df3868ac59a783a54e83eb55db57b241 +type commit +tag v10.0.0 +tagger github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> 1684596909 +0000 + +v10.0.0 + +Published at https://pypi.org/project/cheroot/10.0.0 + +This release has been produced by the following workflow run: https://github.com/cherrypy/cheroot/actions/runs/5032474797 diff --git a/.gear/tags/list b/.gear/tags/list new file mode 100644 index 00000000..bf2feb38 --- /dev/null +++ b/.gear/tags/list @@ -0,0 +1 @@ +6174855d9d0ad09be0c372420c01114be7c0426b v10.0.0 diff --git a/.gear/upstream/remotes b/.gear/upstream/remotes new file mode 100644 index 00000000..e339cc6b --- /dev/null +++ b/.gear/upstream/remotes @@ -0,0 +1,3 @@ +[remote "upstream"] + url = https://github.com/cherrypy/cheroot + fetch = +refs/heads/*:refs/remotes/upstream/* diff --git a/.gitignore b/.gitignore index b475287b..254ec353 100644 --- a/.gitignore +++ b/.gitignore @@ -96,7 +96,6 @@ wheels/ # Usually these files are written by a python script from a template # before PyInstaller builds the exe, so as to inject date/other infos into it. *.manifest -*.spec # Installer logs pip-log.txt diff --git a/cheroot/test/test_ssl.py b/cheroot/test/test_ssl.py index 1900e20d..40a23954 100644 --- a/cheroot/test/test_ssl.py +++ b/cheroot/test/test_ssl.py @@ -360,7 +360,7 @@ def test_tls_client_auth( # noqa: C901, WPS213 # FIXME make_https_request().close() try: - err_text = ssl_err.value.args[0].reason.args[0].args[0] + err_text = ssl_err.value.args[0].reason.args[0].args[1] except AttributeError: if IS_WINDOWS or IS_GITHUB_ACTIONS_WORKFLOW: err_text = str(ssl_err.value) diff --git a/cheroot/testing.py b/cheroot/testing.py index 3e404e59..eb59215f 100644 --- a/cheroot/testing.py +++ b/cheroot/testing.py @@ -48,7 +48,7 @@ def cheroot_server(server_factory): else: break - httpserver.shutdown_timeout = 0 # Speed-up tests teardown + httpserver.shutdown_timeout = 10 # Speed-up tests teardown threading.Thread(target=httpserver.safe_start).start() # spawn it while not httpserver.ready: # wait until fully initialized and bound diff --git a/cheroot/workers/threadpool.py b/cheroot/workers/threadpool.py index 3437d9bd..f577fbb7 100644 --- a/cheroot/workers/threadpool.py +++ b/cheroot/workers/threadpool.py @@ -262,7 +262,7 @@ class ThreadPool: self._pending_shutdowns.append(None) self._queue.put(_SHUTDOWNREQUEST) - def stop(self, timeout=5): + def stop(self, timeout=7): """Terminate all worker threads. Args: diff --git a/setup.cfg b/setup.cfg index 1f2b08f4..be3930c0 100644 --- a/setup.cfg +++ b/setup.cfg @@ -65,7 +65,6 @@ include_package_data = True # These are required during `setup.py` run: setup_requires = setuptools_scm>=1.15.0 - setuptools_scm_git_archive>=1.0 # These are required in actual runtime: install_requires = @@ -75,6 +74,7 @@ install_requires = [options.extras_require] docs = + # upstream sphinx>=1.8.2 jaraco.packaging>=3.2 diff --git a/tox.ini b/tox.ini index ec43e7b2..abc27222 100644 --- a/tox.ini +++ b/tox.ini @@ -185,7 +185,7 @@ deps = -rrequirements{/}tox-docs-linkcheck.in [testenv:watch] -commands = ptw --runner=pytest +commands = ptw --runner=py.test3 [testenv:pre-commit] deps =