Mercurial > p > roundup > code
changeset 4994:868db43b302a
Remove anypy.sets_
The anypy.sets_ package module is no longer used in the roundup codebase
because python v2.4 is no longer supported. The anypy VERSION has been
bumped to 0.3 to reflect this removal, but the version has probably
never changed when other features were added in the past so this bump
may be pointless.
| author | John Kristensen <john@jerrykan.com> |
|---|---|
| date | Thu, 08 May 2014 18:44:29 +1000 |
| parents | ae12b4b3ea9e |
| children | 0a05c4d9a221 |
| files | 2to3-done.txt roundup/anypy/README.txt roundup/anypy/TODO.txt roundup/anypy/__init__.py roundup/anypy/sets_.py share/roundup/templates/devel/detectors/nosyreaction.py share/roundup/templates/responsive/detectors/nosyreaction.py test/test_mailgw.py website/issues/detectors/nosyreaction.py |
| diffstat | 9 files changed, 1 insertions(+), 66 deletions(-) [+] |
line wrap: on
line diff
--- a/2to3-done.txt Wed Jul 01 16:11:12 2015 +0200 +++ b/2to3-done.txt Thu May 08 18:44:29 2014 +1000 @@ -147,7 +147,6 @@ ./roundup/__init__.py ./roundup/actions.py ./roundup/anypy/__init__.py -./roundup/anypy/sets_.py ./roundup/backends/blobfiles.py ./roundup/backends/indexer_xapian.py ./roundup/backends/tsearch2_setup.py
--- a/roundup/anypy/README.txt Wed Jul 01 16:11:12 2015 +0200 +++ b/roundup/anypy/README.txt Thu May 08 18:44:29 2014 +1000 @@ -11,29 +11,4 @@ Use the modules in this package to preserve Roundup's compatibility. -sets_: sets compatibility module -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -Since Python 2.4, there is a built-in type 'set'; therefore, the 'sets' -module is deprecated since version 2.6. As far as Roundup is concerned, -the usage is identical; see -http://docs.python.org/library/sets.html#comparison-to-the-built-in-set-types - -Uses the built-in type 'set' if available, and thus avoids -deprecation warnings. Simple usage: - -Change all:: - from sets import Set - -to:: - from roundup.anypy.sets_ import set - -and use 'set' instead of 'Set' (or sets.Set, respectively). -To avoid unnecessary imports, you can:: - - try: - set - except NameError: - from roundup.anypy.sets_ import set - # vim: si
--- a/roundup/anypy/TODO.txt Wed Jul 01 16:11:12 2015 +0200 +++ b/roundup/anypy/TODO.txt Thu May 08 18:44:29 2014 +1000 @@ -1,6 +1,4 @@ Python compatiblity TODO ~~~~~~~~~~~~~~~~~~~~~~~~ -Remove sets_ included for Python 2.3 compatibility. - Remove support for Python versions < 2.5. As they are not supported anymore.
--- a/roundup/anypy/__init__.py Wed Jul 01 16:11:12 2015 +0200 +++ b/roundup/anypy/__init__.py Thu May 08 18:44:29 2014 +1000 @@ -3,5 +3,5 @@ """ VERSION = '.'.join(map(str, (0, - 2, # set_ + 3, )))
--- a/roundup/anypy/sets_.py Wed Jul 01 16:11:12 2015 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,30 +0,0 @@ -""" -anypy.sets_: sets compatibility module - -uses the built-in type 'set' if available, and thus avoids -deprecation warnings. Simple usage: - -Change all - from sets import Set -to - from roundup.anypy.sets_ import set - -and use 'set' instead of 'Set'. -To avoid unnecessary imports, you can: - - try: - set - except NameError: - from roundup.anypy.sets_ import set - -see: -http://docs.python.org/library/sets.html#comparison-to-the-built-in-set-types - -""" - -try: - set = set # built-in since Python 2.4 -except (NameError, TypeError): - from sets import Set as set # deprecated as of Python 2.6 - -# vim: ts=8 sts=4 sw=4 si et
--- a/share/roundup/templates/devel/detectors/nosyreaction.py Wed Jul 01 16:11:12 2015 +0200 +++ b/share/roundup/templates/devel/detectors/nosyreaction.py Thu May 08 18:44:29 2014 +1000 @@ -1,5 +1,3 @@ -from roundup.anypy.sets_ import set - from roundup import roundupdb, hyperdb def nosyreaction(db, cl, nodeid, oldvalues):
--- a/share/roundup/templates/responsive/detectors/nosyreaction.py Wed Jul 01 16:11:12 2015 +0200 +++ b/share/roundup/templates/responsive/detectors/nosyreaction.py Thu May 08 18:44:29 2014 +1000 @@ -1,5 +1,3 @@ -from roundup.anypy.sets_ import set - from roundup import roundupdb, hyperdb def nosyreaction(db, cl, nodeid, oldvalues):
--- a/test/test_mailgw.py Wed Jul 01 16:11:12 2015 +0200 +++ b/test/test_mailgw.py Thu May 08 18:44:29 2014 +1000 @@ -31,7 +31,6 @@ from roundup.mailgw import MailGW, Unauthorized, uidFromAddress, \ parseContent, IgnoreLoop, IgnoreBulk, MailUsageError, MailUsageHelp from roundup import init, instance, password, __version__ -from roundup.anypy.sets_ import set #import db_test_base import memorydb
