Hello community, here is the log from the commit of package python-pysmi for openSUSE:Factory checked in at 2016-08-10 19:55:40 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-pysmi (Old) and /work/SRC/openSUSE:Factory/.python-pysmi.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pysmi" Changes: -------- --- /work/SRC/openSUSE:Factory/python-pysmi/python-pysmi.changes 2015-12-03 13:30:17.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.python-pysmi.new/python-pysmi.changes 2016-08-10 19:55:43.000000000 +0200 @@ -1,0 +2,10 @@ +Mon Aug 1 20:59:32 UTC 2016 - mar...@gmx.de + +- Update to version 0.0.07 + * Crash on existing .py file handling fixed. + * Fix to __doc__ use in setup.py to make -O0 installation mode working. + * Fix to PyPackageSearcher not to fail on broken Python packages. + * Source code pep8'ed + * Copyright added to source files. + +------------------------------------------------------------------- Old: ---- pysmi-0.0.6.tar.gz New: ---- pysmi-0.0.7.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-pysmi.spec ++++++ --- /var/tmp/diff_new_pack.yxD3Gr/_old 2016-08-10 19:55:44.000000000 +0200 +++ /var/tmp/diff_new_pack.yxD3Gr/_new 2016-08-10 19:55:44.000000000 +0200 @@ -1,7 +1,7 @@ # # spec file for package python-pysmi # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,7 +17,7 @@ Name: python-pysmi -Version: 0.0.6 +Version: 0.0.7 Release: 0 Summary: SNMP SMI/MIB Parser License: BSD-2-Clause @@ -50,7 +50,7 @@ python setup.py install --prefix=%{_prefix} --root=%{buildroot} mv %{buildroot}%{_bindir}/mibdump.py %{buildroot}%{_bindir}/mibdump -#%check +#%%check #nosetests # cannot be run without pysmnp which needs this package %files ++++++ pysmi-0.0.6.tar.gz -> pysmi-0.0.7.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/CHANGES.txt new/pysmi-0.0.7/CHANGES.txt --- old/pysmi-0.0.6/CHANGES.txt 2015-10-01 19:18:55.000000000 +0200 +++ new/pysmi-0.0.7/CHANGES.txt 2016-02-13 19:12:05.000000000 +0100 @@ -1,3 +1,12 @@ +Revision 0.0.7, 12-02-2016 +-------------------------- + +* Crash on existing .py file handling fixed. +* Fix to __doc__ use in setup.py to make -O0 installation mode working. +* Fix to PyPackageSearcher not to fail on broken Python packages. +* Source code pep8'ed +* Copyright added to source files. + Revision 0.0.6, 01-10-2015 -------------------------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/LICENSE.txt new/pysmi-0.0.7/LICENSE.txt --- old/pysmi-0.0.6/LICENSE.txt 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/LICENSE.txt 2016-02-13 19:11:14.000000000 +0100 @@ -1,4 +1,4 @@ -Copyright (c) 2015 Ilya Etingof <i...@glas.net> +Copyright (c) 2015-2016 Ilya Etingof <i...@glas.net> All rights reserved. Redistribution and use in source and binary forms, with or without diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/PKG-INFO new/pysmi-0.0.7/PKG-INFO --- old/pysmi-0.0.6/PKG-INFO 2015-10-01 19:28:53.000000000 +0200 +++ new/pysmi-0.0.7/PKG-INFO 2016-02-13 19:25:39.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: pysmi -Version: 0.0.6 +Version: 0.0.7 Summary: SNMP SMI/MIB Parser Home-page: http://sourceforge.net/projects/pysmi/ Author: Ilya Etingof <i...@glas.net> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/examples/always-borrow-precompiled-pysnmp-files.py new/pysmi-0.0.7/examples/always-borrow-precompiled-pysnmp-files.py --- old/pysmi-0.0.6/examples/always-borrow-precompiled-pysnmp-files.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/examples/always-borrow-precompiled-pysnmp-files.py 2015-11-13 18:21:33.000000000 +0100 @@ -1,5 +1,5 @@ # -# Try to download (AKA borrow) precompiled pysnmp MIB file(s) +# Try to download (AKA borrow) precompiled pysnmp MIB file(s) # from a web-site. # In this example no attempt is made to find and compile ASN.1 # MIB source. @@ -15,9 +15,9 @@ from pysmi.compiler import MibCompiler from pysmi import debug -#debug.setLogger(debug.Debug('compiler')) +# debug.setLogger(debug.Debug('compiler')) -inputMibs = [ 'BORROWED-MIB' ] +inputMibs = ['BORROWED-MIB'] httpBorrowers = [ ('mibs.snmplabs.com', 80, '/pysnmp/notexts/@mib@') @@ -35,7 +35,7 @@ # search for precompiled MIBs at Web sites mibCompiler.addBorrowers( - *[ PyFileBorrower(HttpReader(*x)) for x in httpBorrowers ] + *[PyFileBorrower(HttpReader(*x)) for x in httpBorrowers] ) # run MIB compilation diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/examples/borrow-precompiled-pysnmp-files-on-failure.py new/pysmi-0.0.7/examples/borrow-precompiled-pysnmp-files-on-failure.py --- old/pysmi-0.0.6/examples/borrow-precompiled-pysnmp-files-on-failure.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/examples/borrow-precompiled-pysnmp-files-on-failure.py 2015-11-13 18:21:33.000000000 +0100 @@ -15,9 +15,9 @@ from pysmi.compiler import MibCompiler from pysmi import debug -#debug.setLogger(debug.Debug('borrower', 'reader', 'searcher')) +# debug.setLogger(debug.Debug('borrower', 'reader', 'searcher')) -inputMibs = [ 'BORROWED-MIB' ] +inputMibs = ['BORROWED-MIB'] httpSources = [ ('mibs.snmplabs.com', 80, '/asn1/@mib@') ] @@ -33,7 +33,7 @@ ) # search for source MIBs at Web sites -mibCompiler.addSources(*[ HttpReader(*x) for x in httpSources ]) +mibCompiler.addSources(*[HttpReader(*x) for x in httpSources]) # never recompile MIBs with MACROs mibCompiler.addSearchers(StubSearcher(*baseMibs)) @@ -42,7 +42,7 @@ mibCompiler.addSearchers(PyFileSearcher(dstDirectory)) # search for compiled MIBs at Web sites if source is not available or broken -mibCompiler.addBorrowers(*[ PyFileBorrower(HttpReader(*x)).setOptions(genTexts=False) for x in httpBorrowers ]) +mibCompiler.addBorrowers(*[PyFileBorrower(HttpReader(*x)).setOptions(genTexts=False) for x in httpBorrowers]) # run non-recursive MIB compilation results = mibCompiler.compile(*inputMibs) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/examples/compile-smistar-mibs-into-pysnmp-files-if-needed.py new/pysmi-0.0.7/examples/compile-smistar-mibs-into-pysnmp-files-if-needed.py --- old/pysmi-0.0.6/examples/compile-smistar-mibs-into-pysnmp-files-if-needed.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/examples/compile-smistar-mibs-into-pysnmp-files-if-needed.py 2015-11-13 18:21:33.000000000 +0100 @@ -3,7 +3,7 @@ # compile them into pysnmp form if not done yet and save Python # modules as plain-text files in a local directory. # -# Try to support both SMIv1 and SMIv2 flavors of SMI as well as +# Try to support both SMIv1 and SMIv2 flavors of SMI as well as # popular deviations from official syntax found in the wild. # # When figuring out if compilation is needed, check all known @@ -27,10 +27,10 @@ from pysmi.compiler import MibCompiler from pysmi import debug -#debug.setLogger(debug.Debug('reader', 'compiler')) +# debug.setLogger(debug.Debug('reader', 'compiler')) -inputMibs = [ 'IF-MIB', 'IP-MIB' ] -srcDirectories = [ '/usr/share/snmp/mibs' ] +inputMibs = ['IF-MIB', 'IP-MIB'] +srcDirectories = ['/usr/share/snmp/mibs'] dstDirectory = '.pysnmp-mibs' # Initialize compiler infrastructure @@ -40,12 +40,12 @@ PyFileWriter(dstDirectory)) # search for source MIBs here -mibCompiler.addSources(*[ FileReader(x) for x in srcDirectories ]) +mibCompiler.addSources(*[FileReader(x) for x in srcDirectories]) # check compiled MIBs in our own productions mibCompiler.addSearchers(PyFileSearcher(dstDirectory)) # ...and at default PySNMP MIBs packages -mibCompiler.addSearchers(*[ PyPackageSearcher(x) for x in defaultMibPackages ]) +mibCompiler.addSearchers(*[PyPackageSearcher(x) for x in defaultMibPackages]) # never recompile MIBs with MACROs mibCompiler.addSearchers(StubSearcher(*baseMibs)) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/examples/compile-smiv2-mibs-from-text-into-pysnmp-code.py new/pysmi-0.0.7/examples/compile-smiv2-mibs-from-text-into-pysnmp-code.py --- old/pysmi-0.0.6/examples/compile-smiv2-mibs-from-text-into-pysnmp-code.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/examples/compile-smiv2-mibs-from-text-into-pysnmp-code.py 2015-11-13 18:21:33.000000000 +0100 @@ -17,23 +17,23 @@ from pysmi.compiler import MibCompiler from pysmi import debug -#debug.setLogger(debug.Debug('compiler')) +# debug.setLogger(debug.Debug('compiler')) -inputMibs = [ 'IF-MIB', 'IP-MIB' ] +inputMibs = ['IF-MIB', 'IP-MIB'] srcDir = '/usr/share/snmp/mibs/' # we will read MIBs from here # Initialize compiler infrastructure mibCompiler = MibCompiler( parserFactory()(), - PySnmpCodeGen(), + PySnmpCodeGen(), # out own callback function stores results in its own way - CallbackWriter(lambda m,d,c: sys.stdout.write(d)) + CallbackWriter(lambda m, d, c: sys.stdout.write(d)) ) # our own callback function serves as a MIB source here mibCompiler.addSources( - CallbackReader(lambda m,c: open(srcDir+m+'.txt').read()) + CallbackReader(lambda m, c: open(srcDir+m+'.txt').read()) ) # never recompile MIBs with MACROs diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/examples/download-and-compile-smistar-mibs-into-pysnmp-files.py new/pysmi-0.0.7/examples/download-and-compile-smistar-mibs-into-pysnmp-files.py --- old/pysmi-0.0.6/examples/download-and-compile-smistar-mibs-into-pysnmp-files.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/examples/download-and-compile-smistar-mibs-into-pysnmp-files.py 2015-11-13 18:21:33.000000000 +0100 @@ -3,7 +3,7 @@ # compile them into pysnmp form and save Python modules as plain-text # files in a local directory. # -# Try to support both SMIv1 and SMIv2 flavors of SMI as well as +# Try to support both SMIv1 and SMIv2 flavors of SMI as well as # popular deviations from official syntax found in the wild. # # In this example we disable automatic dependency checking on MIB @@ -22,10 +22,10 @@ from pysmi.compiler import MibCompiler from pysmi import debug -#debug.setLogger(debug.Debug('all')) +# debug.setLogger(debug.Debug('all')) -inputMibs = [ 'IF-MIB', 'IP-MIB' ] -httpSources = [ +inputMibs = ['IF-MIB', 'IP-MIB'] +httpSources = [ ('mibs.snmplabs.com', 80, '/asn1/@mib@') ] ftpSources = [ @@ -40,8 +40,8 @@ ) # search for source MIBs at Web and FTP sites -mibCompiler.addSources(*[ HttpReader(*x) for x in httpSources ]) -mibCompiler.addSources(*[ FtpReader(*x) for x in ftpSources ]) +mibCompiler.addSources(*[HttpReader(*x) for x in httpSources]) +mibCompiler.addSources(*[FtpReader(*x) for x in ftpSources]) # never recompile MIBs with MACROs mibCompiler.addSearchers(StubSearcher(*baseMibs)) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/__init__.py new/pysmi-0.0.7/pysmi/__init__.py --- old/pysmi-0.0.6/pysmi/__init__.py 2015-10-01 19:19:03.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/__init__.py 2015-11-13 18:21:33.000000000 +0100 @@ -1,7 +1,7 @@ import sys # http://www.python.org/dev/peps/pep-0396/ -__version__ = '0.0.6' +__version__ = '0.0.7' if sys.version_info[:2] < (2, 4): raise RuntimeError('PySMI requires Python 2.4 or later') diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/borrower/base.py new/pysmi-0.0.7/pysmi/borrower/base.py --- old/pysmi-0.0.6/pysmi/borrower/base.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/borrower/base.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# from pysmi import error from pysmi import debug diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/borrower/pyfile.py new/pysmi-0.0.7/pysmi/borrower/pyfile.py --- old/pysmi-0.0.6/pysmi/borrower/pyfile.py 2015-10-01 10:17:11.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/borrower/pyfile.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import imp from pysmi.borrower.base import AbstractBorrower diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/codegen/base.py new/pysmi-0.0.7/pysmi/codegen/base.py --- old/pysmi-0.0.6/pysmi/codegen/base.py 2015-10-01 10:46:41.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/codegen/base.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,4 +1,9 @@ - +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# class AbstractCodeGen(object): def genCode(self, ast, symbolTable, **kwargs): raise NotImplementedError() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/codegen/null.py new/pysmi-0.0.7/pysmi/codegen/null.py --- old/pysmi-0.0.6/pysmi/codegen/null.py 2015-10-01 10:58:35.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/codegen/null.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# from pysmi.mibinfo import MibInfo from pysmi.codegen.base import AbstractCodeGen from pysmi import debug diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/codegen/pysnmp.py new/pysmi-0.0.7/pysmi/codegen/pysnmp.py --- old/pysmi-0.0.6/pysmi/codegen/pysnmp.py 2015-10-01 19:17:19.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/codegen/pysnmp.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys from time import strptime, strftime from keyword import iskeyword @@ -99,7 +105,7 @@ 'Gauge': [('SNMPv2-SMI', 'Gauge32')], 'TimeTicks': [('SNMPv2-SMI', 'TimeTicks')], 'Opaque': [('SNMPv2-SMI', 'Opaque')]}, - 'RFC1158-MIB/RFC1213-MIB': + 'RFC1158-MIB/RFC1213-MIB': {'mib-2': [('SNMPv2-SMI', 'mib-2')], 'DisplayString': [('SNMPv2-TC', 'DisplayString')], 'system': [('SNMPv2-MIB', 'system')], @@ -256,13 +262,12 @@ 'snmpOutSetRequests': [('SNMPv2-MIB', 'snmpOutSetRequests')], 'snmpOutGetResponses': [('SNMPv2-MIB', 'snmpOutGetResponses')], 'snmpOutTraps': [('SNMPv2-MIB', 'snmpOutTraps')], - 'snmpEnableAuthenTraps': [('SNMPv2-MIB', 'snmpEnableAuthenTraps')]} - } + 'snmpEnableAuthenTraps': [('SNMPv2-MIB', 'snmpEnableAuthenTraps')]}} convertImportv2 = { - 'RFC1065-SMI': commonSyms['RFC1155-SMI/RFC1065-SMI'], - 'RFC1155-SMI': commonSyms['RFC1155-SMI/RFC1065-SMI'], - 'RFC1158-MIB': updateDict(dict(commonSyms['RFC1155-SMI/RFC1065-SMI']), + 'RFC1065-SMI': commonSyms['RFC1155-SMI/RFC1065-SMI'], + 'RFC1155-SMI': commonSyms['RFC1155-SMI/RFC1065-SMI'], + 'RFC1158-MIB': updateDict(dict(commonSyms['RFC1155-SMI/RFC1065-SMI']), (('nullSpecific', [('SNMPv2-SMI', 'zeroDotZero')]), ('ipRoutingTable', [('RFC1213-MIB', 'ipRouteTable')]), ('ipRouteEntry', [('RFC1213-MIB', 'ipRouteEntry')]), @@ -299,23 +304,18 @@ ('egpNeighMode', [('RFC1213-MIB', 'egpNeighMode')]), ('egpNeighEventTrigger', [('RFC1213-MIB', 'egpNeighEventTrigger')]), ('egpAs', [('RFC1213-MIB', 'egpAs')]), - ('snmpEnableAuthTraps', [('SNMPv2-MIB', 'snmpEnableAuthenTraps')]), - )), - 'RFC-1212': {'OBJECT-TYPE': [('SNMPv2-SMI', 'OBJECT-TYPE')], + ('snmpEnableAuthTraps', [('SNMPv2-MIB', 'snmpEnableAuthenTraps')]))), + 'RFC-1212': {'OBJECT-TYPE': [('SNMPv2-SMI', 'OBJECT-TYPE')]}, # XXX 'IndexSyntax': ??? - }, - 'RFC1213-MIB': updateDict( dict(commonSyms['RFC1158-MIB/RFC1213-MIB']), - (('PhysAddress', [('SNMPv2-TC', 'PhysAddress')]), - )), - 'RFC-1215': {'TRAP-TYPE': [('SNMPv2-SMI', 'TRAP-TYPE')], - } + 'RFC1213-MIB': updateDict(dict(commonSyms['RFC1158-MIB/RFC1213-MIB']), (('PhysAddress', [('SNMPv2-TC', 'PhysAddress')]),)), + 'RFC-1215': {'TRAP-TYPE': [('SNMPv2-SMI', 'TRAP-TYPE')]} } typeClasses = { 'COUNTER32': 'Counter32', 'COUNTER64': 'Counter64', 'GAUGE32': 'Gauge32', - 'INTEGER': 'Integer32', # XXX + 'INTEGER': 'Integer32', # XXX 'INTEGER32': 'Integer32', 'IPADDRESS': 'IpAddress', 'NETWORKADDRESS': 'IpAddress', @@ -326,9 +326,9 @@ 'UNSIGNED32': 'Unsigned32', 'Counter': 'Counter32', 'Gauge': 'Gauge32', - 'NetworkAddress': 'IpAddress', # RFC1065-SMI, RFC1155-SMI -> SNMPv2-SMI - 'nullSpecific': 'zeroDotZero', # RFC1158-MIB -> SNMPv2-SMI - 'ipRoutingTable': 'ipRouteTable', # RFC1158-MIB -> RFC1213-MIB + 'NetworkAddress': 'IpAddress', # RFC1065-SMI, RFC1155-SMI -> SNMPv2-SMI + 'nullSpecific': 'zeroDotZero', # RFC1158-MIB -> SNMPv2-SMI + 'ipRoutingTable': 'ipRouteTable', # RFC1158-MIB -> RFC1213-MIB 'snmpEnableAuthTraps': 'snmpEnableAuthenTraps' # RFC1158-MIB -> SNMPv2-MIB } @@ -389,8 +389,7 @@ elif len(el) == 1: data.append(el[0]) else: - data.append(self.handlersTable[el[0]](self, self.prepData(el[1:], classmode=classmode), classmode=classmode) - ) + data.append(self.handlersTable[el[0]](self, self.prepData(el[1:], classmode=classmode), classmode=classmode)) return data def genImports(self, imports): @@ -424,9 +423,7 @@ if symbols: self._presentedSyms = self._presentedSyms.union([self.transOpers(s) for s in symbols]) self._importMap.update([(self.transOpers(s), module) for s in symbols]) - outStr += '( %s, ) = mibBuilder.importSymbols("%s")\n' % \ - (', '.join([self.transOpers(s) for s in symbols]), - '", "'.join((module,) + symbols)) + outStr += '( %s, ) = mibBuilder.importSymbols("%s")\n' % (', '.join([self.transOpers(s) for s in symbols]), '", "'.join((module,) + symbols)) return outStr, tuple(sorted(imports)) def genExports(self, ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/codegen/symtable.py new/pysmi-0.0.7/pysmi/codegen/symtable.py --- old/pysmi-0.0.6/pysmi/codegen/symtable.py 2015-10-01 19:11:08.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/codegen/symtable.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,4 +1,9 @@ # +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# # Build an internally used symbol table for each passed MIB. # import sys diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/compat.py new/pysmi-0.0.7/pysmi/compat.py --- old/pysmi-0.0.6/pysmi/compat.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/compat.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0] > 2: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/compiler.py new/pysmi-0.0.7/pysmi/compiler.py --- old/pysmi-0.0.6/pysmi/compiler.py 2015-10-01 10:04:05.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/compiler.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys import os import time @@ -58,7 +64,7 @@ Optional components could be set or modified at later phases of MibCompiler life. Unlike singular, required components, optional one can be present - in sequences to address many possible sources of data. They are + in sequences to address many possible sources of data. They are *readers*, *searchers* and *borrowers*. Examples: :: @@ -163,7 +169,7 @@ The *compile* method should be invoked when *MibCompiler* object is operational meaning at least *sources* are specified. - + Once called with a MIB module name, *compile* will: * fetch ASN.1 MIB module with given name by calling *sources* @@ -187,7 +193,10 @@ """ processed = {} - parsedMibs = {}; failedMibs = {}; borrowedMibs = {}; builtMibs = {} + parsedMibs = {} + failedMibs = {} + borrowedMibs = {} + builtMibs = {} symbolTableMap = {} mibsToParse = [x for x in mibnames] while mibsToParse: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/debug.py new/pysmi-0.0.7/pysmi/debug.py --- old/pysmi-0.0.6/pysmi/debug.py 2015-10-01 09:56:21.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/debug.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,18 +1,24 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import logging from pysmi import error from pysmi import __version__ -flagNone = 0x0000 +flagNone = 0x0000 flagSearcher = 0x0001 -flagReader = 0x0002 -flagLexer = 0x0004 -flagParser = 0x0008 -flagGrammar = 0x0010 -flagCodegen = 0x0020 -flagWriter = 0x0040 +flagReader = 0x0002 +flagLexer = 0x0004 +flagParser = 0x0008 +flagGrammar = 0x0010 +flagCodegen = 0x0020 +flagWriter = 0x0040 flagCompiler = 0x0080 flagBorrower = 0x0100 -flagAll = 0xffff +flagAll = 0xffff flagMap = { 'searcher': flagSearcher, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/error.py new/pysmi-0.0.7/pysmi/error.py --- old/pysmi-0.0.6/pysmi/error.py 2015-10-01 10:16:27.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/error.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# # Package exception model: # Here we subclass base Python exception overriding its constructor to # accomodate error message string as its first parameter and an open @@ -5,7 +11,7 @@ # While exception object is bubbling up the call stack, intermediate # exception handlers may insert their own attributes into exception # object. - +# class PySmiError(Exception): def __init__(self, *args, **kwargs): Exception.__init__(self, *args) @@ -24,18 +30,35 @@ def __str__(self): return self.msg + ', line %s' % self.lineno -class PySmiParserError(PySmiLexerError): pass -class PySmiSyntaxError(PySmiParserError): pass +class PySmiParserError(PySmiLexerError): + pass + +class PySmiSyntaxError(PySmiParserError): + pass + +class PySmiSearcherError(PySmiError): + pass + +class PySmiFileNotModifiedError(PySmiSearcherError): + pass + +class PySmiFileNotFoundError(PySmiSearcherError): + pass + +class PySmiReaderError(PySmiError): + pass + +class PySmiReaderFileNotModifiedError(PySmiReaderError): + pass -class PySmiSearcherError(PySmiError): pass -class PySmiFileNotModifiedError(PySmiSearcherError): pass -class PySmiFileNotFoundError(PySmiSearcherError): pass +class PySmiReaderFileNotFoundError(PySmiReaderError): + pass -class PySmiReaderError(PySmiError): pass -class PySmiReaderFileNotModifiedError(PySmiReaderError): pass -class PySmiReaderFileNotFoundError(PySmiReaderError): pass +class PySmiCodegenError(PySmiError): + pass -class PySmiCodegenError(PySmiError): pass -class PySmiSemanticError(PySmiCodegenError): pass +class PySmiSemanticError(PySmiCodegenError): + pass -class PySmiWriterError(PySmiError): pass +class PySmiWriterError(PySmiError): + pass diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/lexer/base.py new/pysmi-0.0.7/pysmi/lexer/base.py --- old/pysmi-0.0.6/pysmi/lexer/base.py 2015-10-01 11:17:40.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/lexer/base.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# class AbstractLexer(object): def reset(self): raise NotImplementedError() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/lexer/smi.py new/pysmi-0.0.7/pysmi/lexer/smi.py --- old/pysmi-0.0.6/pysmi/lexer/smi.py 2015-10-01 11:17:05.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/lexer/smi.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys import re import ply.lex as lex diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/mibinfo.py new/pysmi-0.0.7/pysmi/mibinfo.py --- old/pysmi-0.0.6/pysmi/mibinfo.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/mibinfo.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,5 +1,12 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# -# known attributes: +# +# Known attributes: # name -- actual MIB name # alias -- possible alternative to MIB name # path -- URL to MIB file diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/parser/base.py new/pysmi-0.0.7/pysmi/parser/base.py --- old/pysmi-0.0.6/pysmi/parser/base.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/parser/base.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,4 +1,9 @@ - +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# class AbstractParser(object): def reset(self): raise NotImplementedError() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/parser/dialect.py new/pysmi-0.0.7/pysmi/parser/dialect.py --- old/pysmi-0.0.6/pysmi/parser/dialect.py 2015-10-01 10:46:05.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/parser/dialect.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,8 +1,14 @@ # +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# + +# # Preconfigured sets of parser options. # Individual options could be used in certain combinations. # - smiV2 = {} smiV1 = smiV2.copy() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/parser/null.py new/pysmi-0.0.7/pysmi/parser/null.py --- old/pysmi-0.0.6/pysmi/parser/null.py 2015-10-01 10:44:51.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/parser/null.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# from pysmi.parser.base import AbstractParser class NullParser(AbstractParser): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/parser/smi.py new/pysmi-0.0.7/pysmi/parser/smi.py --- old/pysmi-0.0.6/pysmi/parser/smi.py 2015-10-01 10:43:41.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/parser/smi.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import inspect import os import sys diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/parser/smiv1.py new/pysmi-0.0.7/pysmi/parser/smiv1.py --- old/pysmi-0.0.6/pysmi/parser/smiv1.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/parser/smiv1.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# from pysmi.parser.smi import parserFactory from pysmi.parser.dialect import smiV1 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/parser/smiv1compat.py new/pysmi-0.0.7/pysmi/parser/smiv1compat.py --- old/pysmi-0.0.6/pysmi/parser/smiv1compat.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/parser/smiv1compat.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# from pysmi.parser.smi import parserFactory from pysmi.parser.dialect import smiV1Relaxed diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/parser/smiv2.py new/pysmi-0.0.7/pysmi/parser/smiv2.py --- old/pysmi-0.0.6/pysmi/parser/smiv2.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/parser/smiv2.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# from pysmi.parser.smi import parserFactory from pysmi.parser.dialect import smiV2 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/reader/base.py new/pysmi-0.0.7/pysmi/reader/base.py --- old/pysmi-0.0.6/pysmi/reader/base.py 2015-10-01 10:07:36.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/reader/base.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import os class AbstractReader(object): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/reader/callback.py new/pysmi-0.0.7/pysmi/reader/callback.py --- old/pysmi-0.0.6/pysmi/reader/callback.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/reader/callback.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import time from pysmi.reader.base import AbstractReader from pysmi.mibinfo import MibInfo diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/reader/ftpclient.py new/pysmi-0.0.7/pysmi/reader/ftpclient.py --- old/pysmi-0.0.6/pysmi/reader/ftpclient.py 2015-10-01 10:12:19.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/reader/ftpclient.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys import time import ftplib diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/reader/httpclient.py new/pysmi-0.0.7/pysmi/reader/httpclient.py --- old/pysmi-0.0.6/pysmi/reader/httpclient.py 2015-10-01 10:13:28.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/reader/httpclient.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys import time try: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/reader/localfile.py new/pysmi-0.0.7/pysmi/reader/localfile.py --- old/pysmi-0.0.6/pysmi/reader/localfile.py 2015-10-01 10:16:38.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/reader/localfile.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import os import sys import time diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/reader/url.py new/pysmi-0.0.7/pysmi/reader/url.py --- old/pysmi-0.0.6/pysmi/reader/url.py 2015-10-01 10:09:37.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/reader/url.py 2016-02-13 19:11:14.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys try: import urlparse diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/searcher/base.py new/pysmi-0.0.7/pysmi/searcher/base.py --- old/pysmi-0.0.6/pysmi/searcher/base.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/searcher/base.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# class AbstractSearcher(object): def fileExists(self, mibname, mtime, rebuild=False): raise NotImplementedError() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/searcher/pyfile.py new/pysmi-0.0.7/pysmi/searcher/pyfile.py --- old/pysmi-0.0.6/pysmi/searcher/pyfile.py 2015-10-01 10:06:08.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/searcher/pyfile.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import os import sys import time @@ -52,7 +58,7 @@ if pyTime >= mtime: raise error.PySmiFileNotModifiedError() else: - raise error.PySmiFileNotFoundError('older file %s exists %s' % mibname, searcher=self) + raise error.PySmiFileNotFoundError('older file %s exists' % mibname, searcher=self) else: debug.logger & debug.flagSearcher and debug.logger('bad magic in %s' % f) continue diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/searcher/pypackage.py new/pysmi-0.0.7/pysmi/searcher/pypackage.py --- old/pysmi-0.0.6/pysmi/searcher/pypackage.py 2015-10-01 10:05:57.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/searcher/pypackage.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import os import time import imp @@ -56,9 +62,11 @@ self.__loader = p.__loader__ self._package = self._package.replace('.', os.sep) debug.logger & debug.flagSearcher and debug.logger('%s is an importable egg at %s' % (self._package, os.path.split(p.__file__)[0])) - else: + elif hasattr(p, '__file__'): debug.logger & debug.flagSearcher and debug.logger('%s is not an egg, trying it as a package directory' % self._package) return PyFileSearcher(os.path.split(p.__file__)[0]).fileExists(mibname, mtime, rebuild=rebuild) + else: + raise error.PySmiFileNotFoundError('%s is neither importable nor a file' % self._package, searcher=self) except ImportError: raise error.PySmiFileNotFoundError('%s is not importable, trying as a path' % self._package, searcher=self) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/searcher/stub.py new/pysmi-0.0.7/pysmi/searcher/stub.py --- old/pysmi-0.0.6/pysmi/searcher/stub.py 2015-10-01 10:06:44.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/searcher/stub.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# from pysmi.searcher.base import AbstractSearcher from pysmi import debug from pysmi import error diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/writer/base.py new/pysmi-0.0.7/pysmi/writer/base.py --- old/pysmi-0.0.6/pysmi/writer/base.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/writer/base.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# class AbstractWriter(object): def setOptions(self, **kwargs): for k in kwargs: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/writer/callback.py new/pysmi-0.0.7/pysmi/writer/callback.py --- old/pysmi-0.0.6/pysmi/writer/callback.py 2015-10-01 11:18:44.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/writer/callback.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys from pysmi.writer.base import AbstractWriter from pysmi import debug diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi/writer/pyfile.py new/pysmi-0.0.7/pysmi/writer/pyfile.py --- old/pysmi-0.0.6/pysmi/writer/pyfile.py 2015-10-01 11:19:29.000000000 +0200 +++ new/pysmi-0.0.7/pysmi/writer/pyfile.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import os import sys import imp diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi.egg-info/PKG-INFO new/pysmi-0.0.7/pysmi.egg-info/PKG-INFO --- old/pysmi-0.0.6/pysmi.egg-info/PKG-INFO 2015-10-01 19:28:53.000000000 +0200 +++ new/pysmi-0.0.7/pysmi.egg-info/PKG-INFO 2016-02-13 19:25:39.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: pysmi -Version: 0.0.6 +Version: 0.0.7 Summary: SNMP SMI/MIB Parser Home-page: http://sourceforge.net/projects/pysmi/ Author: Ilya Etingof <i...@glas.net> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/pysmi.egg-info/requires.txt new/pysmi-0.0.7/pysmi.egg-info/requires.txt --- old/pysmi-0.0.6/pysmi.egg-info/requires.txt 2015-10-01 19:28:53.000000000 +0200 +++ new/pysmi-0.0.7/pysmi.egg-info/requires.txt 2016-02-13 19:25:39.000000000 +0100 @@ -1 +1 @@ -ply \ No newline at end of file +ply diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/scripts/mibdump.py new/pysmi-0.0.7/scripts/mibdump.py --- old/pysmi-0.0.6/scripts/mibdump.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/scripts/mibdump.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,8 +1,11 @@ #!/usr/bin/env python # -# SNMP SMI/MIB data management tool +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html # -# Written by Ilya Etingof <i...@glas.net>, 2015 +# SNMP SMI/MIB data management tool # import os import sys @@ -156,8 +159,8 @@ mibStubs = [ x for x in baseMibs if x not in fakeMibs ] if not mibSources: - mibSources = [ 'file:///usr/share/snmp/mibs', - 'http://mibs.snmplabs.com/asn1/@mib@' ] + mibSources = ['file:///usr/share/snmp/mibs', + 'http://mibs.snmplabs.com/asn1/@mib@'] if not mibBorrowers: mibBorrowers = [ ('http://mibs.snmplabs.com/pysnmp/notexts/@mib@', False), diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/setup.cfg new/pysmi-0.0.7/setup.cfg --- old/pysmi-0.0.6/setup.cfg 2015-10-01 19:28:53.000000000 +0200 +++ new/pysmi-0.0.7/setup.cfg 2016-02-13 19:25:39.000000000 +0100 @@ -2,7 +2,7 @@ universal = 1 [egg_info] +tag_build = tag_date = 0 tag_svn_revision = 0 -tag_build = diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/setup.py new/pysmi-0.0.7/setup.py --- old/pysmi-0.0.6/setup.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/setup.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,4 +1,10 @@ #!/usr/bin/env python +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# """SNMP SMI/MIB Parser A pure-Python implementation of SNMP/SMI MIB parsing and conversion library. @@ -44,10 +50,7 @@ try: from setuptools import setup, Command - params = { - 'install_requires': [ 'ply' ], - 'zip_safe': True - } + params = {'install_requires': ['ply'], 'zip_safe': True} except ImportError: for arg in sys.argv: @@ -57,13 +60,13 @@ from distutils.core import setup, Command params = {} if sys.version_info[:2] > (2, 4): - params['requires'] = [ 'ply' ] + params['requires'] = ['ply'] -doclines = [ x.strip() for x in __doc__.split('\n') if x ] +doclines = [x.strip() for x in (__doc__ or '').split('\n') if x] -params.update( { +params.update({ 'name': 'pysmi', - 'version': open(os.path.join('pysmi','__init__.py')).read().split('\'')[1], + 'version': open(os.path.join('pysmi', '__init__.py')).read().split('\'')[1], 'description': doclines[0], 'long_description': ' '.join(doclines[1:]), 'maintainer': 'Ilya Etingof <i...@glas.net>', @@ -71,22 +74,22 @@ 'author_email': 'i...@glas.net', 'url': 'http://sourceforge.net/projects/pysmi/', 'platforms': ['any'], - 'classifiers': [ x for x in classifiers.split('\n') if x ], + 'classifiers': [x for x in classifiers.split('\n') if x], 'license': 'BSD', - 'packages': [ 'pysmi', - 'pysmi.reader', - 'pysmi.searcher', - 'pysmi.lexer', - 'pysmi.parser', - 'pysmi.codegen', - 'pysmi.borrower', - 'pysmi.writer' ], - 'scripts': [ os.path.join('scripts','mibdump.py') ] -} ) + 'packages': ['pysmi', + 'pysmi.reader', + 'pysmi.searcher', + 'pysmi.lexer', + 'pysmi.parser', + 'pysmi.codegen', + 'pysmi.borrower', + 'pysmi.writer'], + 'scripts': [os.path.join('scripts', 'mibdump.py')] +}) # handle unittest discovery feature if sys.version_info[0:2] < (2, 7) or \ - sys.version_info[0:2] in ( (3, 0), (3, 1) ): + sys.version_info[0:2] in ((3, 0), (3, 1)): try: import unittest2 as unittest except ImportError: @@ -105,6 +108,6 @@ suite = unittest.defaultTestLoader.discover('tests') unittest.TextTestRunner(verbosity=2).run(suite) - params['cmdclass'] = { 'test': PyTest } + params['cmdclass'] = {'test': PyTest} setup(**params) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/suite.py new/pysmi-0.0.7/tests/suite.py --- old/pysmi-0.0.6/tests/suite.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/suite.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import test_moduleidentity_smiv2_pysnmp import test_imports_smiv2_pysnmp import test_agentcapabilities_smiv2_pysnmp diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_agentcapabilities_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_agentcapabilities_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_agentcapabilities_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_agentcapabilities_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_imports_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_imports_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_imports_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_imports_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_modulecompliance_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_modulecompliance_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_modulecompliance_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_modulecompliance_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_moduleidentity_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_moduleidentity_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_moduleidentity_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_moduleidentity_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_notificationgroup_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_notificationgroup_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_notificationgroup_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_notificationgroup_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_notificationtype_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_notificationtype_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_notificationtype_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_notificationtype_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_objectgroup_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_objectgroup_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_objectgroup_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_objectgroup_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_objectidentity_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_objectidentity_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_objectidentity_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_objectidentity_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_objecttype_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_objecttype_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_objecttype_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_objecttype_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_smiv1_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_smiv1_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_smiv1_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_smiv1_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_traptype_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_traptype_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_traptype_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_traptype_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_typedeclaration_smiv1_pysnmp.py new/pysmi-0.0.7/tests/test_typedeclaration_smiv1_pysnmp.py --- old/pysmi-0.0.6/tests/test_typedeclaration_smiv1_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_typedeclaration_smiv1_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_typedeclaration_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_typedeclaration_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_typedeclaration_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_typedeclaration_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pysmi-0.0.6/tests/test_valuedeclaration_smiv2_pysnmp.py new/pysmi-0.0.7/tests/test_valuedeclaration_smiv2_pysnmp.py --- old/pysmi-0.0.6/tests/test_valuedeclaration_smiv2_pysnmp.py 2015-10-01 09:30:43.000000000 +0200 +++ new/pysmi-0.0.7/tests/test_valuedeclaration_smiv2_pysnmp.py 2016-02-13 19:11:15.000000000 +0100 @@ -1,3 +1,9 @@ +# +# This file is part of pysmi software. +# +# Copyright (c) 2015-2016, Ilya Etingof <i...@glas.net> +# License: http://pysmi.sf.net/license.html +# import sys if sys.version_info[0:2] < (2, 7) or \ sys.version_info[0:2] in ( (3, 0), (3, 1) ):