Discussion:
[issue25594] enum docs outdated re attribute access
SilentGhost
2015-11-10 08:27:47 UTC
Permalink
Color.red.blue
Traceback (most recent call last):
...
AttributeError: 'Color' object has no attribute 'blue'

which is demonstrably wrong in either 3.5 or 3.6. I presume that's a doc issue and I'd be glad to propose the patch as soon as someone more familiar with the module could confirm that.

[0] https://docs.python.org/3.6/library/enum.html#finer-points

----------
assignee: ***@python
components: Documentation, Library (Lib)
messages: 254436
nosy: SilentGhost, barry, ***@python, eli.bendersky, ethan.furman
priority: normal
severity: normal
status: open
title: enum docs outdated re attribute access
versions: Python 3.5, Python 3.6

_______________________________________
Python tracker <***@bugs.python.org>
<http://bugs.python.org/issue25594>
_______________________________________
Ethan Furman
2015-11-10 15:47:03 UTC
Permalink
Ethan Furman added the comment:

Nope, that would be a bug.

----------
assignee: ***@python -> ethan.furman
stage: -> test needed
type: -> behavior

_______________________________________
Python tracker <***@bugs.python.org>
<http://bugs.python.org/issue25594>
_______________________________________
SilentGhost
2015-11-10 17:53:25 UTC
Permalink
SilentGhost added the comment:

Here is the test, it seems to have been 2545bfe0d273 that caused it (issue23486): test passes prior to it and fails on it (and I assume uniformly after).

----------
keywords: +patch
Added file: http://bugs.python.org/file41003/test_issue25594.diff

_______________________________________
Python tracker <***@bugs.python.org>
<http://bugs.python.org/issue25594>
_______________________________________
SilentGhost
2015-11-10 20:09:27 UTC
Permalink
Changes by SilentGhost <***@gmail.com>:


----------
components: -Documentation
stage: test needed -> needs patch
title: enum docs outdated re attribute access -> enum instance attribute access possible

_______________________________________
Python tracker <***@bugs.python.org>
<http://bugs.python.org/issue25594>
_______________________________________

Loading...