Would it make sense to use the `enum34` package, which is a backport of teh enum package from py3k?
Alex On Mon, Dec 9, 2013 at 7:37 PM, Adam Young <ayo...@redhat.com> wrote: > While Python 3 has enumerated types, Python 2 does not, and the standard > package to provide id, Flufl.enum, is not yet part of our code base. Is > there any strong objection to including Flufl.enum? > > http://pythonhosted.org/flufl.enum/ > > It makes for some very elegant code, especially for enumerated integer > types. > > For an example See ScopeType in > > https://review.openstack.org/#/c/55908/4/keystone/contrib/revoke/core.py > > Line 62. > > the getter/setter in RevokeEvent do not need to do any conditional logic > if passed either an integer or a ScopeType. > > > _______________________________________________ > OpenStack-dev mailing list > OpenStack-dev@lists.openstack.org > http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev > -- "I disapprove of what you say, but I will defend to the death your right to say it." -- Evelyn Beatrice Hall (summarizing Voltaire) "The people's good is the highest law." -- Cicero GPG Key fingerprint: 125F 5C67 DFE9 4084
_______________________________________________ OpenStack-dev mailing list OpenStack-dev@lists.openstack.org http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev