Compare commits
9 Commits
| Author | SHA256 | Date | |
|---|---|---|---|
| d303048030 | |||
| acdee83874 | |||
| e521be1f45 | |||
| 6e8eb26b59 | |||
| a452fab99c | |||
| 205216e442 | |||
| 9566074006 | |||
| 323ff77cc1 | |||
| 7fc70b44a5 |
46
py314.patch
Normal file
46
py314.patch
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
From d90297a181c8edd8ffe5c08ba03866845e9a3493 Mon Sep 17 00:00:00 2001
|
||||||
|
From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= <miro@hroncok.cz>
|
||||||
|
Date: Fri, 22 Nov 2024 22:20:13 +0100
|
||||||
|
Subject: [PATCH] Avoid the multiprocessing forkserver method (#656)
|
||||||
|
|
||||||
|
Python 3.14 changed the default multiprocessing method for POSIX (sans macOS)
|
||||||
|
from fork to forkserver. This causes errors like:
|
||||||
|
|
||||||
|
TypeError: cannot pickle 'select.epoll' object
|
||||||
|
when serializing dict item '_poller'
|
||||||
|
when serializing pyftpdlib.ioloop.Epoll state
|
||||||
|
when serializing pyftpdlib.ioloop.Epoll object
|
||||||
|
when serializing dict item 'ioloop'
|
||||||
|
when serializing pyftpdlib.servers.MultiprocessFTPServer state
|
||||||
|
when serializing pyftpdlib.servers.MultiprocessFTPServer object
|
||||||
|
when serializing tuple item 0
|
||||||
|
when serializing method reconstructor arguments
|
||||||
|
when serializing method object
|
||||||
|
when serializing dict item '_target'
|
||||||
|
when serializing multiprocessing.context.Process state
|
||||||
|
when serializing multiprocessing.context.Process object
|
||||||
|
|
||||||
|
See https://github.com/python/cpython/issues/125714
|
||||||
|
---
|
||||||
|
pyftpdlib/servers.py | 9 ++++++++-
|
||||||
|
1 file changed, 8 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/pyftpdlib/servers.py b/pyftpdlib/servers.py
|
||||||
|
index 32c0db02..3dfc39c6 100644
|
||||||
|
--- a/pyftpdlib/servers.py
|
||||||
|
+++ b/pyftpdlib/servers.py
|
||||||
|
@@ -579,6 +579,13 @@ class MultiprocessFTPServer(_SpawnerBase):
|
||||||
|
|
||||||
|
_lock = multiprocessing.Lock()
|
||||||
|
_exit = multiprocessing.Event()
|
||||||
|
+ # Python 3.14 changed the non-macOS POSIX default to forkserver
|
||||||
|
+ # but the code in this module does not work with it
|
||||||
|
+ # See https://github.com/python/cpython/issues/125714
|
||||||
|
+ if multiprocessing.get_start_method() == 'forkserver':
|
||||||
|
+ _mp_context = multiprocessing.get_context(method='fork')
|
||||||
|
+ else:
|
||||||
|
+ _mp_context = multiprocessing.get_context()
|
||||||
|
|
||||||
|
def _start_task(self, *args, **kwargs):
|
||||||
|
- return multiprocessing.Process(*args, **kwargs)
|
||||||
|
+ return self._mp_context.Process(*args, **kwargs)
|
||||||
BIN
pyftpdlib-1.5.10.tar.gz
LFS
BIN
pyftpdlib-1.5.10.tar.gz
LFS
Binary file not shown.
3
pyftpdlib-2.0.1.tar.gz
Normal file
3
pyftpdlib-2.0.1.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:ef0d172a82bfae10e2dec222e87533514609d41bf4b0fd0f07e29d4380fb96bf
|
||||||
|
size 202285
|
||||||
@@ -1,3 +1,33 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Sep 11 12:40:28 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||||
|
|
||||||
|
- Update to 2.0.1
|
||||||
|
* exposed a new FTPHandler.encoding attribute defaulting to 'utf-8'.
|
||||||
|
* removed Python 2.7 support.
|
||||||
|
* remove copies of asyncore.py and asynchat.py. Use backports from
|
||||||
|
PYPI instead.
|
||||||
|
* set default SSL version from deprecated SSLv23_METHOD to newer
|
||||||
|
TLS_SERVER_METHOD.
|
||||||
|
* pysendfile module is no longer a required dependency.
|
||||||
|
* SSLv2 and SSLv3 connections are no longer accepted when client
|
||||||
|
connects.
|
||||||
|
- Add py314.patch to add compatibility with Python 3.14
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Aug 19 14:26:32 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||||
|
|
||||||
|
- Convert to libalternatives on SLE-16-based and newer systems only
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Jul 10 08:53:50 UTC 2025 - Andreas Schwab <schwab@suse.de>
|
||||||
|
|
||||||
|
- Set CIBUILDWHEEL to avoid spurious test failures
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Jul 8 13:56:26 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||||
|
|
||||||
|
- Convert to libalternatives
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Sat Aug 31 12:04:37 UTC 2024 - Dirk Müller <dmueller@suse.com>
|
Sat Aug 31 12:04:37 UTC 2024 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-pyftpdlib
|
# spec file for package python-pyftpdlib
|
||||||
#
|
#
|
||||||
# Copyright (c) 2024 SUSE LLC
|
# Copyright (c) 2025 SUSE LLC and contributors
|
||||||
# Copyright (c) 2016 LISA GmbH, Bingen, Germany.
|
# Copyright (c) 2016 LISA GmbH, Bingen, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
@@ -17,29 +17,42 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
|
%if 0%{?suse_version} > 1500
|
||||||
|
%bcond_without libalternatives
|
||||||
|
%else
|
||||||
|
%bcond_with libalternatives
|
||||||
|
%endif
|
||||||
%{?sle15_python_module_pythons}
|
%{?sle15_python_module_pythons}
|
||||||
Name: python-pyftpdlib
|
Name: python-pyftpdlib
|
||||||
Version: 1.5.10
|
Version: 2.0.1
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: Asynchronous FTP server library for Python
|
Summary: Asynchronous FTP server library for Python
|
||||||
License: MIT
|
License: MIT
|
||||||
URL: https://github.com/giampaolo/pyftpdlib/
|
URL: https://github.com/giampaolo/pyftpdlib/
|
||||||
Source: https://files.pythonhosted.org/packages/source/p/pyftpdlib/pyftpdlib-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/p/pyftpdlib/pyftpdlib-%{version}.tar.gz
|
||||||
Source1: keycert.pem
|
Source1: keycert.pem
|
||||||
|
# PATCH-FIX-UPSTREAM https://github.com/giampaolo/pyftpdlib/pull/656 Avoid the multiprocessing forkserver method
|
||||||
|
Patch0: py314.patch
|
||||||
BuildRequires: %{python_module pip}
|
BuildRequires: %{python_module pip}
|
||||||
BuildRequires: %{python_module psutil}
|
BuildRequires: %{python_module psutil}
|
||||||
BuildRequires: %{python_module pyOpenSSL}
|
BuildRequires: %{python_module pyOpenSSL}
|
||||||
BuildRequires: %{python_module pysendfile}
|
BuildRequires: %{python_module pyasynchat}
|
||||||
BuildRequires: %{python_module pytest}
|
BuildRequires: %{python_module pytest}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: %{python_module wheel}
|
BuildRequires: %{python_module wheel}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
Requires: python-pyOpenSSL
|
Requires: python-pyOpenSSL
|
||||||
|
Requires: python-pyasynchat
|
||||||
|
Requires: python-pyasyncore
|
||||||
|
BuildArch: noarch
|
||||||
|
%if %{with libalternatives}
|
||||||
|
BuildRequires: alts
|
||||||
|
Requires: alts
|
||||||
|
%else
|
||||||
Requires(post): update-alternatives
|
Requires(post): update-alternatives
|
||||||
Requires(postun): update-alternatives
|
Requires(postun): update-alternatives
|
||||||
Recommends: python-pysendfile
|
%endif
|
||||||
BuildArch: noarch
|
|
||||||
%python_subpackages
|
%python_subpackages
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@@ -48,7 +61,7 @@ write very asynchronous FTP servers with Python.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup -p1 -n pyftpdlib-%{version}
|
%autosetup -p1 -n pyftpdlib-%{version}
|
||||||
sed -i '1 {/env python/ d}' pyftpdlib/test/*.py pyftpdlib/_compat.py
|
sed -i '1 {/env python/ d}' pyftpdlib/test/*.py
|
||||||
cp %{SOURCE1} pyftpdlib/test
|
cp %{SOURCE1} pyftpdlib/test
|
||||||
|
|
||||||
%build
|
%build
|
||||||
@@ -61,6 +74,7 @@ cp %{SOURCE1} pyftpdlib/test
|
|||||||
# Note: Do not remove tests. Other packages import them
|
# Note: Do not remove tests. Other packages import them
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
export CIBUILDWHEEL=1
|
||||||
ignorebuild="--ignore build"
|
ignorebuild="--ignore build"
|
||||||
%{python_expand # expand to python flavor, not to the binary name, then strip the trailing _
|
%{python_expand # expand to python flavor, not to the binary name, then strip the trailing _
|
||||||
builddir=_build.$python_
|
builddir=_build.$python_
|
||||||
@@ -88,6 +102,9 @@ $python -m pytest
|
|||||||
%postun
|
%postun
|
||||||
%python_uninstall_alternative ftpbench
|
%python_uninstall_alternative ftpbench
|
||||||
|
|
||||||
|
%pre
|
||||||
|
%python_libalternatives_reset_alternative ftpbench
|
||||||
|
|
||||||
%files %{python_files}
|
%files %{python_files}
|
||||||
%license LICENSE
|
%license LICENSE
|
||||||
%doc README.rst
|
%doc README.rst
|
||||||
|
|||||||
Reference in New Issue
Block a user