Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-zeroconf for openSUSE:Factory 
checked in at 2021-04-22 18:03:55
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-zeroconf (Old)
 and      /work/SRC/openSUSE:Factory/.python-zeroconf.new.12324 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-zeroconf"

Thu Apr 22 18:03:55 2021 rev:19 rq:887379 version:0.29.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-zeroconf/python-zeroconf.changes  
2021-01-08 17:40:40.217065048 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-zeroconf.new.12324/python-zeroconf.changes   
    2021-04-22 18:04:43.182575933 +0200
@@ -1,0 +2,7 @@
+Wed Apr 21 21:27:04 UTC 2021 - Dirk M??ller <dmuel...@suse.com>
+
+- update to 0.29.0:
+  * A single socket is used for listening on responding when 
`InterfaceChoice.Default` is chosen.
+  * Dropped Python 3.5 support
+
+-------------------------------------------------------------------

Old:
----
  python-zeroconf-0.28.8.tar.gz

New:
----
  python-zeroconf-0.29.0.tar.gz

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

Other differences:
------------------
++++++ python-zeroconf.spec ++++++
--- /var/tmp/diff_new_pack.VkUaLb/_old  2021-04-22 18:04:43.618576599 +0200
+++ /var/tmp/diff_new_pack.VkUaLb/_new  2021-04-22 18:04:43.622576604 +0200
@@ -19,7 +19,7 @@
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 %define skip_python2 1
 Name:           python-zeroconf
-Version:        0.28.8
+Version:        0.29.0
 Release:        0
 Summary:        Pure Python Multicast DNS Service Discovery Library 
(Bonjour/Avahi compatible)
 License:        LGPL-2.0-only

++++++ python-zeroconf-0.28.8.tar.gz -> python-zeroconf-0.29.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/.github/workflows/ci.yml 
new/python-zeroconf-0.29.0/.github/workflows/ci.yml
--- old/python-zeroconf-0.28.8/.github/workflows/ci.yml 1970-01-01 
01:00:00.000000000 +0100
+++ new/python-zeroconf-0.29.0/.github/workflows/ci.yml 2021-03-25 
00:15:34.000000000 +0100
@@ -0,0 +1,33 @@
+name: CI
+
+on:
+  push:
+    branches:
+      - master
+  pull_request:
+    branches:
+      - "**"
+
+jobs:
+  build:
+    runs-on: ${{ matrix.os }}
+    strategy:
+      matrix:
+        os: [ubuntu-latest, macos-latest, windows-latest]
+        python-version: [3.6, 3.7, 3.8, 3.9, pypy3]
+    steps:
+    - uses: actions/checkout@v2
+    - name: Set up Python ${{ matrix.python-version }}
+      uses: actions/setup-python@v2
+      with:
+        python-version: ${{ matrix.python-version }}
+    - name: Install dependencies
+      run: |
+        pip install --upgrade -r requirements-dev.txt
+        pip install .
+    - name: Run tests
+      run: make ci
+      env:
+        SKIP_IPV6: 1
+    - name: Report coverage to Codecov
+      uses: codecov/codecov-action@v1
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/.travis.yml 
new/python-zeroconf-0.29.0/.travis.yml
--- old/python-zeroconf-0.28.8/.travis.yml      2021-01-04 19:47:33.000000000 
+0100
+++ new/python-zeroconf-0.29.0/.travis.yml      1970-01-01 01:00:00.000000000 
+0100
@@ -1,23 +0,0 @@
-language: python
-python:
-    - "3.5"
-    - "3.6"
-    - "3.7"
-    - "3.8"
-    - "3.9-dev"
-    - "pypy3.5"
-    - "pypy3"
-matrix:
-  allow_failures:
-    - python: "3.9-dev"
-install:
-    - pip install --upgrade -r requirements-dev.txt
-    # mypy can't be installed on pypy
-    - if [[ "${TRAVIS_PYTHON_VERSION}" != "pypy"* ]] ; then pip install mypy ; 
fi
-    - if [[ "${TRAVIS_PYTHON_VERSION}" != *"3.5"* && 
"${TRAVIS_PYTHON_VERSION}" != "pypy"* ]] ; then
-        pip install black ; fi
-script:
-    # no IPv6 support in Travis :(
-    - SKIP_IPV6=1 make ci
-after_success:
-    - coveralls
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/Makefile 
new/python-zeroconf-0.29.0/Makefile
--- old/python-zeroconf-0.28.8/Makefile 2021-01-04 19:47:33.000000000 +0100
+++ new/python-zeroconf-0.29.0/Makefile 2021-03-25 00:15:34.000000000 +0100
@@ -6,10 +6,7 @@
 LINT_TARGETS:=flake8
 
 ifneq ($(findstring PyPy,$(PYTHON_IMPLEMENTATION)),PyPy)
-       LINT_TARGETS:=$(LINT_TARGETS) mypy
-endif
-ifeq ($(or $(findstring 3.5,$(PYTHON_VERSION)),$(findstring 
PyPy,$(PYTHON_IMPLEMENTATION))),)
-       LINT_TARGETS:=$(LINT_TARGETS) black_check
+       LINT_TARGETS:=$(LINT_TARGETS) mypy black_check
 endif
 
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/README.rst 
new/python-zeroconf-0.29.0/README.rst
--- old/python-zeroconf-0.28.8/README.rst       2021-01-04 19:47:33.000000000 
+0100
+++ new/python-zeroconf-0.29.0/README.rst       2021-03-25 00:15:34.000000000 
+0100
@@ -1,14 +1,14 @@
 python-zeroconf
 ===============
 
-.. image:: https://travis-ci.org/jstasiak/python-zeroconf.svg?branch=master
-    :target: https://travis-ci.org/jstasiak/python-zeroconf
-    
+.. image:: https://github.com/jstasiak/python-zeroconf/workflows/CI/badge.svg
+   :target: 
https://github.com/jstasiak/python-zeroconf?query=workflow%3ACI+branch%3Amaster
+
 .. image:: https://img.shields.io/pypi/v/zeroconf.svg
     :target: https://pypi.python.org/pypi/zeroconf
 
-.. image:: https://img.shields.io/coveralls/jstasiak/python-zeroconf.svg
-    :target: https://coveralls.io/r/jstasiak/python-zeroconf
+.. image:: 
https://codecov.io/gh/jstasiak/python-zeroconf/branch/master/graph/badge.svg
+   :target: https://codecov.io/gh/jstasiak/python-zeroconf
 
 `Documentation <https://python-zeroconf.readthedocs.io/en/latest/>`_.
     
@@ -44,7 +44,7 @@
 Python compatibility
 --------------------
 
-* CPython 3.5+
+* CPython 3.6+
 * PyPy3 5.8+
 
 Versioning
@@ -134,6 +134,16 @@
 Changelog
 =========
 
+0.29.0
+======
+
+* A single socket is used for listening on responding when 
`InterfaceChoice.Default` is chosen.
+  Thanks to J. Nick Koston.
+
+Backwards incompatible:
+
+* Dropped Python 3.5 support
+
 0.28.8
 ======
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/docs/index.rst 
new/python-zeroconf-0.29.0/docs/index.rst
--- old/python-zeroconf-0.28.8/docs/index.rst   2021-01-04 19:47:33.000000000 
+0100
+++ new/python-zeroconf-0.29.0/docs/index.rst   2021-03-25 00:15:34.000000000 
+0100
@@ -1,16 +1,14 @@
 Welcome to python-zeroconf documentation!
 =========================================
 
-.. image:: https://travis-ci.org/jstasiak/python-zeroconf.svg?branch=master
-   :alt: Build status
-   :target: https://travis-ci.org/jstasiak/python-zeroconf
+.. image:: https://github.com/jstasiak/python-zeroconf/workflows/CI/badge.svg
+   :target: 
https://github.com/jstasiak/python-zeroconf?query=workflow%3ACI+branch%3Amaster
 
 .. image:: https://img.shields.io/pypi/v/zeroconf.svg
     :target: https://pypi.python.org/pypi/zeroconf
-   
-.. image:: 
https://coveralls.io/repos/github/jstasiak/python-zeroconf/badge.svg?branch=master
-   :alt: Covergage status
-   :target: https://coveralls.io/github/jstasiak/python-zeroconf?branch=master
+
+.. image:: 
https://codecov.io/gh/jstasiak/python-zeroconf/branch/master/graph/badge.svg
+   :target: https://codecov.io/gh/jstasiak/python-zeroconf
 
 GitHub (code repository, issues): https://github.com/jstasiak/python-zeroconf
 
@@ -28,4 +26,4 @@
 
    api
 
-See `the project's README 
<https://github.com/jstasiak/python-zeroconf/blob/master/README.md>`_ for more 
information.
+See `the project's README 
<https://github.com/jstasiak/python-zeroconf/blob/master/README.rst>`_ for more 
information.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/requirements-dev.txt 
new/python-zeroconf-0.29.0/requirements-dev.txt
--- old/python-zeroconf-0.28.8/requirements-dev.txt     2021-01-04 
19:47:33.000000000 +0100
+++ new/python-zeroconf-0.29.0/requirements-dev.txt     2021-03-25 
00:15:34.000000000 +0100
@@ -1,10 +1,12 @@
 autopep8
+black;implementation_name=="cpython"
 coveralls
 coverage
 # Version restricted because of https://github.com/PyCQA/pycodestyle/issues/741
 flake8>=3.6.0
 flake8-import-order
 ifaddr
+mypy;implementation_name=="cpython"
 # 0.11.0 breaks things https://github.com/PyCQA/pep8-naming/issues/152
 pep8-naming!=0.6.0,!=0.11.0
 pytest
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/setup.cfg 
new/python-zeroconf-0.29.0/setup.cfg
--- old/python-zeroconf-0.28.8/setup.cfg        2021-01-04 19:47:33.000000000 
+0100
+++ new/python-zeroconf-0.29.0/setup.cfg        2021-03-25 00:15:34.000000000 
+0100
@@ -6,7 +6,7 @@
 
 [mypy]
 ignore_missing_imports = true
-follow_imports = error
+follow_imports = ignore
 check_untyped_defs = true
 no_implicit_optional = true
 warn_incomplete_stub = true
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/zeroconf/__init__.py 
new/python-zeroconf-0.29.0/zeroconf/__init__.py
--- old/python-zeroconf-0.28.8/zeroconf/__init__.py     2021-01-04 
19:47:33.000000000 +0100
+++ new/python-zeroconf-0.29.0/zeroconf/__init__.py     2021-03-25 
00:15:34.000000000 +0100
@@ -42,7 +42,7 @@
 
 __author__ = 'Paul Scott-Murphy, William McBrine'
 __maintainer__ = 'Jakub Stasiak <ja...@stasiak.at>'
-__version__ = '0.28.8'
+__version__ = '0.29.0'
 __license__ = 'LGPL'
 
 
@@ -880,7 +880,7 @@
                 break
             t = length & 0xC0
             if t == 0x00:
-                result = ''.join((result, self.read_utf(off, length) + '.'))
+                result += self.read_utf(off, length) + '.'
                 off += length
             elif t == 0xC0:
                 if next_ < 0:
@@ -2255,13 +2255,13 @@
 def add_multicast_member(
     listen_socket: socket.socket,
     interface: Union[str, Tuple[Tuple[str, int, int], int]],
-    apple_p2p: bool = False,
-) -> Optional[socket.socket]:
+) -> None:
     # This is based on assumptions in normalize_interface_choice
     is_v6 = isinstance(interface, tuple)
     err_einval = {errno.EINVAL}
     if sys.platform == 'win32':
-        err_einval |= {errno.WSAEINVAL}
+        # No WSAEINVAL definition in typeshed
+        err_einval |= {cast(Any, errno).WSAEINVAL}
     log.debug('Adding %r (socket %d) to multicast group', interface, 
listen_socket.fileno())
     try:
         if is_v6:
@@ -2293,6 +2293,12 @@
         else:
             raise
 
+
+def new_respond_socket(
+    interface: Union[str, Tuple[Tuple[str, int, int], int]],
+    apple_p2p: bool = False,
+) -> Optional[socket.socket]:
+    is_v6 = isinstance(interface, tuple)
     respond_socket = new_socket(
         ip_version=(IPVersion.V6Only if is_v6 else IPVersion.V4Only),
         apple_p2p=apple_p2p,
@@ -2300,6 +2306,7 @@
     )
     log.debug('Configuring socket %s with multicast interface %s', 
respond_socket, interface)
     if is_v6:
+        iface_bin = struct.pack('@I', cast(int, interface[1]))
         respond_socket.setsockopt(_IPPROTO_IPV6, socket.IPV6_MULTICAST_IF, 
iface_bin)
     else:
         respond_socket.setsockopt(
@@ -2321,11 +2328,19 @@
 
     normalized_interfaces = normalize_interface_choice(interfaces, ip_version)
 
+    # If we are using InterfaceChoice.Default we can use
+    # a single socket to listen and respond.
+    if not unicast and interfaces is InterfaceChoice.Default:
+        for i in normalized_interfaces:
+            add_multicast_member(cast(socket.socket, listen_socket), i)
+        return listen_socket, [cast(socket.socket, listen_socket)]
+
     respond_sockets = []
 
     for i in normalized_interfaces:
         if not unicast:
-            respond_socket = add_multicast_member(cast(socket.socket, 
listen_socket), i, apple_p2p=apple_p2p)
+            add_multicast_member(cast(socket.socket, listen_socket), i)
+            respond_socket = new_respond_socket(i, apple_p2p=apple_p2p)
         else:
             respond_socket = new_socket(
                 port=0,
@@ -2494,6 +2509,7 @@
             interfaces, unicast, ip_version, apple_p2p=apple_p2p
         )
         log.debug('Listen socket %s, respond sockets %s', self._listen_socket, 
self._respond_sockets)
+        self.multi_socket = unicast or interfaces is not 
InterfaceChoice.Default
 
         self.listeners = []  # type: List[RecordUpdateListener]
         self.browsers = {}  # type: Dict[ServiceListener, ServiceBrowser]
@@ -2513,8 +2529,9 @@
         self.listener = Listener(self)
         if not unicast:
             self.engine.add_reader(self.listener, cast(socket.socket, 
self._listen_socket))
-        for s in self._respond_sockets:
-            self.engine.add_reader(self.listener, s)
+        if self.multi_socket:
+            for s in self._respond_sockets:
+                self.engine.add_reader(self.listener, s)
         self.reaper = Reaper(self)
 
         self.debug = None  # type: Optional[DNSOutgoing]
@@ -2978,8 +2995,9 @@
             if not self.unicast:
                 self.engine.del_reader(cast(socket.socket, 
self._listen_socket))
                 cast(socket.socket, self._listen_socket).close()
-            for s in self._respond_sockets:
-                self.engine.del_reader(s)
+            if self.multi_socket:
+                for s in self._respond_sockets:
+                    self.engine.del_reader(s)
             self.engine.join()
 
             # shutdown the rest
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-zeroconf-0.28.8/zeroconf/test.py 
new/python-zeroconf-0.29.0/zeroconf/test.py
--- old/python-zeroconf-0.28.8/zeroconf/test.py 2021-01-04 19:47:33.000000000 
+0100
+++ new/python-zeroconf-0.29.0/zeroconf/test.py 2021-03-25 00:15:34.000000000 
+0100
@@ -7,6 +7,7 @@
 import copy
 import logging
 import os
+import platform
 import socket
 import struct
 import threading
@@ -17,6 +18,8 @@
 from typing import Dict, Optional  # noqa # used in type hints
 from typing import cast
 
+import pytest
+
 import zeroconf as r
 from zeroconf import (
     DNSHinfo,
@@ -1126,6 +1129,7 @@
 
 
 class ListenerTest(unittest.TestCase):
+    @pytest.mark.skipif(platform.python_implementation() == 'PyPy', 
reason="Flaky on PyPy")
     def test_integration_with_listener_class(self):
 
         service_added = Event()

Reply via email to