Skip to content

Should we use an 'enum' type for enumerated values? #1031

@tseaver

Description

@tseaver

E.g., wherever the back-end takes a string value, but requires that it be one of a set of known values? Likewise for integers which map protobuf enum values.

@dhermes suggested using https://pypi.python.org/pypi/enum.

I favor using the PEP-435-compatible https://pypi.python.org/pypi/enum34/, which backports the enum from the Python 3.4 stdlib.

Metadata

Metadata

Assignees

Labels

type: questionRequest for information or clarification. Not an issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions