[prev in list] [next in list] [prev in thread] [next in thread] 

List:       opensuse-commit
Subject:    commit python-pysnmp for openSUSE:Factory
From:       root <root () hilbert ! suse ! de>
Date:       2018-11-29 22:00:47
Message-ID: 20181129220047.B76209B882 () hilbert ! suse ! de
[Download RAW message or body]

Hello community,

here is the log from the commit of package python-pysnmp for openSUSE:Factory checked \
in at 2018-11-29 23:00:40 \
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing \
/work/SRC/openSUSE:Factory/python-pysnmp (Old)  and      \
/work/SRC/openSUSE:Factory/.python-pysnmp.new.19453 (New) \
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-pysnmp"

Thu Nov 29 23:00:40 2018 rev:9 rq:652439 version:4.4.6

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-pysnmp/python-pysnmp.changes	2018-11-02 \
                10:52:07.274271797 +0100
+++ /work/SRC/openSUSE:Factory/.python-pysnmp.new.19453/python-pysnmp.changes	2018-11-29 \
23:00:44.659480980 +0100 @@ -1,0 +2,19 @@
+Thu Nov 27 17:56:55 UTC 2018 - alexander_naumov@opensuse.org
+
+- Update to version 4.4.6 
+  * Improved package build and dependency tracking
+  * Fixed missing LICENSE from the tarball distribution
+  * Fixed CommandGeneratorLcdConfigurator.unconfigure() to fully
+    clean up internal caches, otherwise repetitive attempts to
+    configure the target would fail.
+  * Fix to tolerate possible duplicate enumerations in Bits and
+    IntegerSMI types.
+  * Fix to tolerate non-initialised entries in SNMP community table.
+    Once a bad entry sneaked into the SNMP community table, all
+    the subsequent SNMP v1/v2c operations failed. The fix ignores
+    incomplete SNMP community table entries in the course of
+    building indices.
+
+This is a bug fix release addressing a handful of accumulated bugs.
+
+-------------------------------------------------------------------

Old:
----
  pysnmp-4.4.5.tar.gz

New:
----
  pysnmp-4.4.6.tar.gz

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

Other differences:
------------------
++++++ python-pysnmp.spec ++++++
--- /var/tmp/diff_new_pack.9mYZmT/_old	2018-11-29 23:00:46.227479048 +0100
+++ /var/tmp/diff_new_pack.9mYZmT/_new	2018-11-29 23:00:46.263479003 +0100
@@ -12,13 +12,13 @@
 # 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/
+# Please submit bugfixes or comments via http://bugs.opensuse.org/
 #
 
 
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 Name:           python-pysnmp
-Version:        4.4.5
+Version:        4.4.6
 Release:        0
 Summary:        A pure-Python SNMPv1/v2c/v3 library
 License:        BSD-2-Clause

++++++ pysnmp-4.4.5.tar.gz -> pysnmp-4.4.6.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' \
                '--exclude=.svnignore' old/pysnmp-4.4.5/CHANGES.txt \
                new/pysnmp-4.4.6/CHANGES.txt
--- old/pysnmp-4.4.5/CHANGES.txt	2018-08-05 22:47:36.000000000 +0200
+++ new/pysnmp-4.4.6/CHANGES.txt	2018-09-13 23:47:22.000000000 +0200
@@ -1,4 +1,19 @@
 
+Revision 4.4.6, released 2018-09-13
+-----------------------------------
+
+- Improved package build and dependency tracking
+- Fixed missing LICENSE from the tarball distribution
+- Fixed `CommandGeneratorLcdConfigurator.unconfigure()` to fully clean up
+  internal caches, otherwise repetitive attempts to configure the target
+  would fail.
+- Fix to tolerate possible duplicate enumerations in `Bits` and `Integer`
+  SMI types.
+- Fix to tolerate non-initialised entries in SNMP community table. Once a
+  bad entry sneaked into the SNMP community table, all the subsequent
+  SNMP v1/v2c operations failed. The fix ignores incomplete SNMP community
+  table entries in the course of building indices.
+
 Revision 4.4.5, released 2018-08-05
 -----------------------------------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' \
                '--exclude=.svnignore' old/pysnmp-4.4.5/MANIFEST.in \
                new/pysnmp-4.4.6/MANIFEST.in
--- old/pysnmp-4.4.5/MANIFEST.in	2018-08-05 22:47:36.000000000 +0200
+++ new/pysnmp-4.4.6/MANIFEST.in	2018-09-13 23:47:22.000000000 +0200
@@ -1,4 +1,4 @@
-include *.txt *.md *.sh
+include *.rst *.txt *.md *.sh
 recursive-include examples *.py
 recursive-include docs/source *.rst *.svg *.py
 recursive-include docs/mibs *.txt
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' \
'--exclude=.svnignore' old/pysnmp-4.4.5/pysnmp/__init__.py \
                new/pysnmp-4.4.6/pysnmp/__init__.py
--- old/pysnmp-4.4.5/pysnmp/__init__.py	2018-08-05 22:47:36.000000000 +0200
+++ new/pysnmp-4.4.6/pysnmp/__init__.py	2018-09-13 23:47:22.000000000 +0200
@@ -1,5 +1,5 @@
 # http://www.python.org/dev/peps/pep-0396/
-__version__ = '4.4.5'
+__version__ = '4.4.6'
 # backward compatibility
 version = tuple([int(x) for x in __version__.split('.')])
 majorVersionId = version[0]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' \
'--exclude=.svnignore' old/pysnmp-4.4.5/pysnmp/hlapi/lcd.py \
                new/pysnmp-4.4.6/pysnmp/hlapi/lcd.py
--- old/pysnmp-4.4.5/pysnmp/hlapi/lcd.py	2018-08-05 22:47:36.000000000 +0200
+++ new/pysnmp-4.4.6/pysnmp/hlapi/lcd.py	2018-09-13 23:47:22.000000000 +0200
@@ -175,7 +175,7 @@
                     cache['addr'][addrKey] = addrName, useCount
                 else:
                     config.delTargetAddr(snmpEngine, addrName)
-
+                    del cache['addr'][addrKey]
                     addrNames.add(addrKey)
 
                     if addrKey[1] in cache['tran']:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' \
'--exclude=.svnignore' old/pysnmp-4.4.5/pysnmp/proto/rfc1902.py \
                new/pysnmp-4.4.6/pysnmp/proto/rfc1902.py
--- old/pysnmp-4.4.5/pysnmp/proto/rfc1902.py	2018-08-05 22:47:36.000000000 +0200
+++ new/pysnmp-4.4.6/pysnmp/proto/rfc1902.py	2018-09-13 23:47:22.000000000 +0200
@@ -128,12 +128,17 @@
 
     @classmethod
     def withNamedValues(cls, **values):
-        """Creates a subclass with discreet named values constraint.
+        """Create a subclass with discreet named values constraint.
+
+        Reduce fully duplicate enumerations along the way.
         """
+        enums = set(cls.namedValues.items())
+        enums.update(values.items())
 
         class X(cls):
-            namedValues = cls.namedValues + namedval.NamedValues(*values.items())
-            subtypeSpec = cls.subtypeSpec + \
constraint.SingleValueConstraint(*values.values()) +            namedValues = \
namedval.NamedValues(*enums) +            subtypeSpec = cls.subtypeSpec + \
constraint.SingleValueConstraint( +                *values.values())
 
         X.__name__ = cls.__name__
         return X
@@ -600,7 +605,7 @@
 
     def __new__(cls, *args, **kwargs):
         if 'namedValues' in kwargs:
-            Bits = cls.withNamedBits(**kwargs.pop('namedValues'))
+            Bits = cls.withNamedBits(**dict(kwargs.pop('namedValues')))
             return Bits(*args, **kwargs)
 
         return OctetString.__new__(cls)
@@ -637,10 +642,14 @@
     @classmethod
     def withNamedBits(cls, **values):
         """Creates a subclass with discreet named bits constraint.
+
+        Reduce fully duplicate enumerations along the way.
         """
+        enums = set(cls.namedValues.items())
+        enums.update(values.items())
 
         class X(cls):
-            namedValues = cls.namedValues + namedval.NamedValues(*values.items())
+            namedValues = namedval.NamedValues(*enums)
 
         X.__name__ = cls.__name__
         return X
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' \
'--exclude=.svnignore' old/pysnmp-4.4.5/pysnmp/proto/secmod/rfc2576.py \
                new/pysnmp-4.4.6/pysnmp/proto/secmod/rfc2576.py
--- old/pysnmp-4.4.5/pysnmp/proto/secmod/rfc2576.py	2018-08-05 22:47:36.000000000 \
                +0200
+++ new/pysnmp-4.4.6/pysnmp/proto/secmod/rfc2576.py	2018-09-13 23:47:22.000000000 \
+0200 @@ -38,7 +38,7 @@
 
             nextMibNode = snmpTargetParamsSecurityName
 
-            while 1:
+            while True:
                 try:
                     nextMibNode = \
snmpTargetParamsSecurityName.getNextNode(nextMibNode.name)  
@@ -49,10 +49,18 @@
 
                 mibNode = \
snmpTargetParamsSecurityModel.getNode(snmpTargetParamsSecurityModel.name + instId)  
-                if mibNode.syntax not in self.__nameToModelMap:
-                    self.__nameToModelMap[nextMibNode.syntax] = set()
+                try:
+                    if mibNode.syntax not in self.__nameToModelMap:
+                        self.__nameToModelMap[nextMibNode.syntax] = set()
+
+                    self.__nameToModelMap[nextMibNode.syntax].add(mibNode.syntax)
 
-                self.__nameToModelMap[nextMibNode.syntax].add(mibNode.syntax)
+                except PyAsn1Error:
+                    debug.logger & debug.flagSM and debug.logger(
+                        '_sec2com: table entries %r/%r hashing failed' % (
+                            nextMibNode.syntax, mibNode.syntax)
+                    )
+                    continue
 
             self.__paramsBranchId = snmpTargetParamsSecurityName.branchVersionId
 
@@ -72,7 +80,8 @@
             self.__securityMap = {}
 
             nextMibNode = snmpCommunityName
-            while 1:
+
+            while True:
                 try:
                     nextMibNode = snmpCommunityName.getNextNode(nextMibNode.name)
 
@@ -88,9 +97,17 @@
 
                 _contextName = \
snmpCommunityContextName.getNode(snmpCommunityContextName.name + instId).syntax  
-                self.__securityMap[(_securityName,
-                                    _contextEngineId,
-                                    _contextName)] = nextMibNode.syntax
+                try:
+                    self.__securityMap[(_securityName,
+                                        _contextEngineId,
+                                        _contextName)] = nextMibNode.syntax
+
+                except PyAsn1Error:
+                    debug.logger & debug.flagSM and debug.logger(
+                        '_sec2com: table entries %r/%r/%r hashing failed' % (
+                            _securityName, _contextEngineId, _contextName)
+                    )
+                    continue
 
             self.__securityBranchId = snmpCommunityName.branchVersionId
 
@@ -123,11 +140,14 @@
             self.__transportToTagMap = {}
 
             nextMibNode = snmpTargetAddrTagList
+
             while True:
                 try:
                     nextMibNode = \
snmpTargetAddrTagList.getNextNode(nextMibNode.name) +
                 except NoSuchInstanceError:
                     break
+
                 instId = nextMibNode.name[len(snmpTargetAddrTagList.name):]
                 targetAddrTDomain = \
                snmpTargetAddrTDomain.getNode(snmpTargetAddrTDomain.name + \
                instId).syntax
                 targetAddrTAddress = \
snmpTargetAddrTAddress.getNode(snmpTargetAddrTAddress.name + instId).syntax @@ \
                -144,17 +164,29 @@
                     targetAddrTAddress = \
                tuple(TransportAddressIPv6(targetAddrTAddress))
                 elif targetAddrTDomain[:len(unix.snmpLocalDomain)] == \
unix.snmpLocalDomain:  targetAddrTAddress = str(targetAddrTAddress)
+
                 targetAddr = targetAddrTDomain, targetAddrTAddress
                 targetAddrTagList = \
snmpTargetAddrTagList.getNode(snmpTargetAddrTagList.name + instId).syntax +
                 if targetAddr not in self.__transportToTagMap:
                     self.__transportToTagMap[targetAddr] = set()
-                if targetAddrTagList:
-                    self.__transportToTagMap[targetAddr].update(
-                        [SnmpTagValue(x)
-                         for x in targetAddrTagList.asOctets().split()]
+
+                try:
+                    if targetAddrTagList:
+                        self.__transportToTagMap[targetAddr].update(
+                            [SnmpTagValue(x)
+                             for x in targetAddrTagList.asOctets().split()]
+                        )
+
+                    else:
+                        self.__transportToTagMap[targetAddr].add(self.__emptyTag)
+
+                except PyAsn1Error:
+                    debug.logger & debug.flagSM and debug.logger(
+                        '_com2sec: table entries %r/%r hashing failed' % (
+                            targetAddr, targetAddrTagList)
                     )
-                else:
-                    self.__transportToTagMap[targetAddr].add(self.__emptyTag)
+                    continue
 
             self.__transportBranchId = snmpTargetAddrTAddress.branchVersionId
 
@@ -163,6 +195,7 @@
 
         snmpTargetParamsSecurityName, = \
snmpEngine.msgAndPduDsp.mibInstrumController.mibBuilder.importSymbols(  \
'SNMP-TARGET-MIB', 'snmpTargetParamsSecurityName') +
         if self.__paramsBranchId != snmpTargetParamsSecurityName.branchVersionId:
             snmpTargetParamsSecurityModel, = \
snmpEngine.msgAndPduDsp.mibInstrumController.mibBuilder.importSymbols(  \
'SNMP-TARGET-MIB', 'snmpTargetParamsSecurityModel') @@ -182,10 +215,18 @@
 
                 mibNode = \
snmpTargetParamsSecurityModel.getNode(snmpTargetParamsSecurityModel.name + instId)  
-                if nextMibNode.syntax not in self.__nameToModelMap:
-                    self.__nameToModelMap[nextMibNode.syntax] = set()
+                try:
+                    if nextMibNode.syntax not in self.__nameToModelMap:
+                        self.__nameToModelMap[nextMibNode.syntax] = set()
+
+                    self.__nameToModelMap[nextMibNode.syntax].add(mibNode.syntax)
 
-                self.__nameToModelMap[nextMibNode.syntax].add(mibNode.syntax)
+                except PyAsn1Error:
+                    debug.logger & debug.flagSM and debug.logger(
+                        '_com2sec: table entries %r/%r hashing failed' % (
+                            nextMibNode.syntax, mibNode.syntax)
+                    )
+                    continue
 
             self.__paramsBranchId = snmpTargetParamsSecurityName.branchVersionId
 
@@ -211,6 +252,7 @@
             self.__tagAndCommunityToSecurityMap = {}
 
             nextMibNode = snmpCommunityName
+
             while True:
                 try:
                     nextMibNode = snmpCommunityName.getNextNode(nextMibNode.name)
@@ -231,17 +273,25 @@
 
                 _tagAndCommunity = transportTag, nextMibNode.syntax
 
-                if _tagAndCommunity not in self.__tagAndCommunityToSecurityMap:
-                    self.__tagAndCommunityToSecurityMap[_tagAndCommunity] = set()
+                try:
+                    if _tagAndCommunity not in self.__tagAndCommunityToSecurityMap:
+                        self.__tagAndCommunityToSecurityMap[_tagAndCommunity] = \
set() +
+                    self.__tagAndCommunityToSecurityMap[_tagAndCommunity].add(
+                        (securityName, contextEngineId, contextName)
+                    )
 
-                self.__tagAndCommunityToSecurityMap[_tagAndCommunity].add(
-                    (securityName, contextEngineId, contextName)
-                )
+                    if nextMibNode.syntax not in self.__communityToTagMap:
+                        self.__communityToTagMap[nextMibNode.syntax] = set()
 
-                if nextMibNode.syntax not in self.__communityToTagMap:
-                    self.__communityToTagMap[nextMibNode.syntax] = set()
+                    self.__communityToTagMap[nextMibNode.syntax].add(transportTag)
 
-                self.__communityToTagMap[nextMibNode.syntax].add(transportTag)
+                except PyAsn1Error:
+                    debug.logger & debug.flagSM and debug.logger(
+                        '_com2sec: table entries %r/%r hashing failed' % (
+                            _tagAndCommunity, nextMibNode.syntax)
+                    )
+                    continue
 
             self.__communityBranchId = snmpCommunityName.branchVersionId
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' \
                '--exclude=.svnignore' old/pysnmp-4.4.5/setup.py \
                new/pysnmp-4.4.6/setup.py
--- old/pysnmp-4.4.5/setup.py	2018-08-05 22:47:36.000000000 +0200
+++ new/pysnmp-4.4.6/setup.py	2018-09-13 23:47:22.000000000 +0200
@@ -1,12 +1,13 @@
 #!/usr/bin/env python
 """SNMP library for Python
 
-   SNMP v1/v2c/v3 engine and apps written in pure-Python.
-   Supports Manager/Agent/Proxy roles, scriptable MIBs,
-   asynchronous operation and multiple transports.
+SNMP v1/v2c/v3 engine and Standard Applications suite written in pure-Python.
+Supports Manager/Agent/Proxy roles, Manager/Agent-side MIBs, asynchronous
+operation and multiple network transports.
 """
 import sys
 import os
+import re
 
 classifiers = """\
 Development Status :: 5 - Production/Stable
@@ -55,33 +56,52 @@
     print("ERROR: this package requires Python 2.4 or later!")
     sys.exit(1)
 
+requires = [ln.strip() for ln in open('requirements.txt').readlines()]
+
 try:
-    from setuptools import setup
+    import setuptools
+
+    setup, Command = setuptools.setup, setuptools.Command
+
+    observed_version = [int(x) for x in setuptools.__version__.split('.')]
+    required_version = [36, 2, 0]
+
+    # NOTE(etingof): require fresh setuptools to build proper wheels
+    # See also: https://hynek.me/articles/conditional-python-dependencies/
+    if ('bdist_wheel' in sys.argv and
+            observed_version < required_version):
+        print("ERROR: your wheels won't come out round with setuptools %s! "
+              "Upgrade to %s and try again." % (
+                '.'.join([str(x) for x in observed_version]),
+                '.'.join([str(x) for x in required_version])))
+        sys.exit(1)
 
     params = {
-        'install_requires': ['pyasn1>=0.2.3', 'pysmi', 'pycryptodomex'],
+        'install_requires': requires,
         'zip_safe': True
     }
 
 except ImportError:
-    for arg in sys.argv:
-        if 'egg' in arg:
-            howto_install_setuptools()
-            sys.exit(1)
+    if 'bdist_wheel' in sys.argv or 'bdist_egg' in sys.argv:
+        howto_install_setuptools()
+        sys.exit(1)
 
     from distutils.core import setup
 
     params = {}
+
     if sys.version_info[:2] > (2, 4):
-        params['requires'] = ['pyasn1(>=0.2.3)', 'pysmi', 'pycryptodomex']
+        params['requires'] = [
+            re.sub(r'(.*?)([<>=!~]+)(.*)', r'\g<1>\g<2>(\g<3>)', r) for r in \
requires +        ]
 
-doclines = [x.strip() for x in (__doc__ or '').split('\n') if x]
+doclines = [x.strip() for x in (__doc__ or '').split('\n')]
 
 params.update({
     'name': 'pysnmp',
     'version': open(os.path.join('pysnmp', '__init__.py')).read().split('\'')[1],
     'description': doclines[0],
-    'long_description': ' '.join(doclines[1:]),
+    'long_description': '\n'.join(doclines[1:]),
     'maintainer': 'Ilya Etingof <etingof@gmail.com>',
     'author': 'Ilya Etingof',
     'author_email': 'etingof@gmail.com',


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic