# # spec file for package python-portend # # Copyright (c) 2023 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/ # %define skip_python2 1 %define skip_python36 1 %define skip_python38 1 %define skip_python39 1 %define skip_python311 1 %{?!python_module:%define python_module() python-%{**} python3-%{**}} %{?sle15_python_module_pythons} Name: python-portend Version: 3.1.0 Release: 2.2 Summary: TCP port monitoring utilities License: MIT Group: Development/Languages/Python URL: https://github.com/jaraco/portend Source: https://files.pythonhosted.org/packages/source/p/portend/portend-%{version}.tar.gz BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools_scm >= 1.15.0} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module tempora >= 1.8} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-tempora >= 1.8 BuildArch: noarch %python_subpackages %description Use portend to monitor TCP ports for bound or unbound states. The portend may also be executed directly. If the function succeeds, it returns nothing and exits with a status of 0. If it fails, it prints a message and exits with a status of 1. For example:: Portend also exposes a ``find_available_local_port`` for identifying a suitable port for binding locally:: %prep %setup -q -n portend-%{version} # do not require cov/xdist/etc sed -i -e '/addopts/d' pytest.ini %build %python_build %install %python_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check %python_exec -m pytest test_portend.py %files %{python_files} %license LICENSE %doc CHANGES.rst README.rst %{python_sitelib}/* %changelog * Fri Apr 21 2023 Dirk Müller - add sle15_python_module_pythons (jsc#PED-68) * Thu Apr 13 2023 Matej Cepl - Make calling of %%{sle15modernpython} optional. * Tue Oct 4 2022 Yogalakshmi Arunachalam - Update to version v3.1.0 Require Python 3.7 or later. - Update to version v3.0.0 Removed legacy aliases wait_for_occupied_port and wait_for_free_port. - Update to version v2.7.2 Packaging refresh. - Update to version v2.7.1 [#14]: Fix host/port order. - Update to version v2.7.0 Refresh package. Require Python 3.6 or later. * Wed Mar 18 2020 Marketa Calabkova - Update to 2.6 * Package refresh. * Mon Feb 24 2020 Tomáš Chvátal - Fix up dependencies to match requirements * Tue Jun 18 2019 pgajdos@suse.com - version update to 2.5 * #10: Fix race condition in ``occupied`` and ``free`` * Fri Apr 5 2019 Tomáš Chvátal - Update to 2.4: * find_available_local_port now relies on socket.getaddrinfo to find a suitable address family. * Tue Mar 5 2019 Tomáš Chvátal - Update to 2.3: * Fix README rendering. * Merge with skeleton, including embedded license file. * #1: Removed portend._getaddrinfo and its usage in Checker.assert_free. * #5: Restored use of portend.client_host during assert_free check on Windows, fixing check when the bind address is *ADDR_ANY. * Fri Mar 31 2017 jmatejek@suse.com - initial commit