Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-aiosmtpd for openSUSE:Factory 
checked in at 2026-11-25 16:13:12
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-aiosmtpd (Old)
 and      /work/SRC/openSUSE:Factory/.python-aiosmtpd.new.1340718 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-aiosmtpd"

Wed Nov 25 16:13:12 2026 rev:21 rq:1400439 version:1.4.6

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-aiosmtpd/python-aiosmtpd.changes  
2026-09-02 17:02:51.621562062 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-aiosmtpd.new.1340718/python-aiosmtpd.changes 
    2026-11-25 16:14:56.264431293 +0100
@@ -1,0 +2,6 @@
+Wed Nov 18 02:37:14 UTC 2026 - Steve Kowalik <[email protected]>
+
+- Replace patch support-python-313.patch with disable-socket-cleanup.patch,
+  which solves the same problem in a better way.
+
+-------------------------------------------------------------------

Old:
----
  support-python-313.patch

New:
----
  disable-socket-cleanup.patch

----------(Old B)----------
  Old:
- Replace patch support-python-313.patch with disable-socket-cleanup.patch,
  which solves the same problem in a better way.
----------(Old E)----------

----------(New B)----------
  New:
- Replace patch support-python-313.patch with disable-socket-cleanup.patch,
  which solves the same problem in a better way.
----------(New E)----------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-aiosmtpd.spec ++++++
--- /var/tmp/diff_new_pack.DfqFnI/_old  2026-11-25 16:14:59.607573366 +0100
+++ /var/tmp/diff_new_pack.DfqFnI/_new  2026-11-25 16:14:59.608573408 +0100
@@ -25,14 +25,14 @@
 License:        Apache-2.0
 URL:            https://aiosmtpd.readthedocs.io/
 Source:         
https://github.com/aio-libs/aiosmtpd/archive/v%{version}.tar.gz#/aiosmtpd-%{version}.tar.gz
-# PATCH-FIX-UPSTREAM Based on gh#aio-libs/aiosmtpd#473
-Patch0:         support-python-313.patch
 # PATCH-FIX-OPENSUSE Use inspect.iscorountine
-Patch1:         support-python-314.patch
+Patch0:         support-python-314.patch
 # PATCH-FIX-UPSTREAM aiosmtpd-pr557-pkg_resources.patch 
gh#aio-libs/aiosmtpd#557
-Patch2:         aiosmtpd-pr557-pkg_resources.patch
+Patch1:         aiosmtpd-pr557-pkg_resources.patch
 # PATCH-FIX-UPSTREAM gh#aio-libs/aiosmtpd#575
-Patch3:         do-not-use-typing-bytestring.patch
+Patch2:         do-not-use-typing-bytestring.patch
+# PATCH-FIX-UPSTREAM Based on gh#aio-libs/aiosmtpd#592
+Patch3:         disable-socket-cleanup.patch
 BuildRequires:  %{python_module pip}
 BuildRequires:  %{python_module setuptools}
 BuildRequires:  %{python_module wheel}

++++++ disable-socket-cleanup.patch ++++++
>From 3ed6df07b61d0b120d34a7d06748d8c8df430bda Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?P=C4=93teris=20Caune?= <[email protected]>
Date: Sat, 9 May 2026 13:37:48 +0300
Subject: [PATCH 1/5] Update UnixSocketMixin to disable socket cleanup on Py >=
 3.13

Starting from Python 3.13, the unix listener automatically cleans up
its socket from the filesystem on shutdown. This can be disabled by
passing in cleanup_socket=False. I think it makes sense for aiosmtpd
to do that, to keep the shutdown behavior consistent between Python versions.

This change fixes the only failing test on Python 3.13:

aiosmtpd/tests/test_server.py::TestUnthreaded::test_unixsocket
---
 aiosmtpd/controller.py | 9 +++++++++
 1 file changed, 9 insertions(+)

Index: aiosmtpd-1.4.6/aiosmtpd/controller.py
===================================================================
--- aiosmtpd-1.4.6.orig/aiosmtpd/controller.py
+++ aiosmtpd-1.4.6/aiosmtpd/controller.py
@@ -5,6 +5,7 @@ import asyncio
 import errno
 import os
 import ssl
+import sys
 import threading
 import time
 from abc import ABCMeta, abstractmethod
@@ -450,6 +451,20 @@ class UnixSocketMixin(BaseController, me
         Does NOT actually start the protocol object itself;
         _factory_invoker() is only called upon fist connection attempt.
         """
+        if sys.version_info >= (3, 13, 0):
+            # Starting from python 3.13, the unix listener automatically
+            # cleans up its socket from the filesystem on shutdown. This can
+            # be disabled by passing in cleanup_socket=False. We do that here 
to keep
+            # the shutdown behavior consistent between Python versions.
+            return self.loop.create_unix_server(
+                self._factory_invoker,
+                path=self.unix_socket,
+                ssl=self.ssl_context,
+                # Silence mypy warning as cleanup_socket is not yet annotated 
in
+                # typeshed: https://github.com/python/typeshed/issues/15742
+                cleanup_socket=False,  # type: ignore[call-arg]
+            )
+
         return self.loop.create_unix_server(
             self._factory_invoker,
             path=self.unix_socket,
Index: aiosmtpd-1.4.6/aiosmtpd/tests/test_server.py
===================================================================
--- aiosmtpd-1.4.6.orig/aiosmtpd/tests/test_server.py
+++ aiosmtpd-1.4.6/aiosmtpd/tests/test_server.py
@@ -300,7 +300,10 @@ class TestController:
             cont.stop()
 
     def test_testconn_raises(self, mocker: MockFixture):
-        mocker.patch("socket.socket.recv", 
side_effect=RuntimeError("MockError"))
+        mocker.patch(
+            "aiosmtpd.controller.create_connection",
+            side_effect=RuntimeError("MockError"),
+        )
         cont = Controller(Sink(), hostname="")
         try:
             with pytest.raises(RuntimeError, match="MockError"):

Reply via email to