17
0

6 Commits

Author SHA256 Message Date
519e2a727c Accepting request 1284626 from devel:languages:python
- Switch to pyproject macros.
- No more greedy globs in %files.

OBS-URL: https://build.opensuse.org/request/show/1284626
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-ptyprocess?expand=0&rev=12
2025-06-11 14:18:59 +00:00
a3404fc171 - Switch to pyproject macros.
- No more greedy globs in %files.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ptyprocess?expand=0&rev=23
2025-06-11 06:15:19 +00:00
1f87533b79 Accepting request 1202970 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1202970
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-ptyprocess?expand=0&rev=11
2024-09-25 19:52:56 +00:00
fc78f7a5ba Accepting request 1202958 from home:ecsos:python
- Fix build error under Leap.

OBS-URL: https://build.opensuse.org/request/show/1202958
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ptyprocess?expand=0&rev=21
2024-09-24 13:01:11 +00:00
19acf4f3cf Accepting request 1190529 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1190529
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-ptyprocess?expand=0&rev=10
2024-08-01 20:03:18 +00:00
eefc7222d4 Accepting request 1190468 from home:glaubitz:branches:devel:languages:python
- Cherry-pick upstream patch to fix tests with Python 3.13.
  * remove-old-unittest-functions.patch

OBS-URL: https://build.opensuse.org/request/show/1190468
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ptyprocess?expand=0&rev=19
2024-07-30 20:06:11 +00:00
3 changed files with 65 additions and 9 deletions

View File

@@ -1,3 +1,20 @@
-------------------------------------------------------------------
Wed Jun 11 05:51:48 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
- Switch to pyproject macros.
- No more greedy globs in %files.
-------------------------------------------------------------------
Tue Sep 24 12:20:37 UTC 2024 - ecsos <ecsos@opensuse.org>
- Fix build error under Leap.
-------------------------------------------------------------------
Tue Jul 30 12:03:04 UTC 2024 - John Paul Adrian Glaubitz <adrian.glaubitz@suse.com>
- Cherry-pick upstream patch to fix tests with Python 3.13.
* remove-old-unittest-functions.patch
-------------------------------------------------------------------
Fri Apr 21 12:30:03 UTC 2023 - Dirk Müller <dmueller@suse.com>

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-ptyprocess
#
# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -16,17 +16,18 @@
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%{?sle15_python_module_pythons}
Name: python-ptyprocess
Version: 0.7.0
Release: 0
Summary: Run a subprocess in a pseudo terminal
License: ISC
Group: Development/Languages/Python
URL: https://github.com/pexpect/ptyprocess
Source: https://files.pythonhosted.org/packages/source/p/ptyprocess/ptyprocess-%{version}.tar.gz
BuildRequires: %{python_module setuptools}
# PATCH-FIX-UPSTREAM - gh/pexpect/ptyprocess#75 - Remove unittest.makeSuite, gone from Python 3.13
Patch1: https://github.com/pexpect/ptyprocess/pull/75.patch#/remove-old-unittest-functions.patch
BuildRequires: %{python_module flit-core}
BuildRequires: %{python_module pip}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildArch: noarch
@@ -43,21 +44,27 @@ If you need to automate these things, running the process in a pseudo terminal
(pty) is the answer.
%prep
%setup -q -n ptyprocess-%{version}
%autosetup -p1 -n ptyprocess-%{version}
%build
%python_build
%pyproject_wheel
%install
%python_install
%pyproject_install
# Fix python-bytecode-inconsistent-mtime
pushd %{buildroot}%{python_sitelib}
find . -name '*.pyc' -exec rm -f '{}' ';'
python%python_bin_suffix -m compileall *.py ';'
popd
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
%python_exec -m unittest discover
%pyunittest discover
%files %{python_files}
%doc README.rst
%license LICENSE
%{python_sitelib}/*
%{python_sitelib}/ptyprocess
%{python_sitelib}/ptyprocess-%{version}.dist-info
%changelog

View File

@@ -0,0 +1,32 @@
From a44312974bd9084aa568d2e18ce5b2a7e0e45983 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= <miro@hroncok.cz>
Date: Mon, 23 Oct 2023 15:18:02 +0200
Subject: [PATCH] Remove unittest.makeSuite, gone from Python 3.13
See https://docs.python.org/3.13/whatsnew/3.13.html
"""
Removed the following unittest functions, deprecated in Python 3.11:
unittest.findTestCases()
unittest.makeSuite()
unittest.getTestCaseNames()
"""
The removed call does not seem to have any effect when the file is executed
directly, run trough unittest discover or pytest.
---
tests/test_invalid_binary.py | 3 ---
1 file changed, 3 deletions(-)
diff --git a/tests/test_invalid_binary.py b/tests/test_invalid_binary.py
index cf28098..545f9f7 100755
--- a/tests/test_invalid_binary.py
+++ b/tests/test_invalid_binary.py
@@ -69,6 +69,3 @@ def test_invalid_binary(self):
if __name__ == '__main__':
unittest.main()
-
-suite = unittest.makeSuite(InvalidBinaryChars,'test')
-