Message197008
On Wed, Sep 4, 2013 at 3:05 PM, Ethan Furman <report@bugs.python.org> wrote:
>
> Ethan Furman added the comment:
>
> Yes, as a matter of fact:
>
> --> Test.this
> <Test.this: 'that'>
> --> Test.this = 'other'
> --> Test.this
> 'other'
> --> Test('that')
> <Test.this: 'that'>
> --> list(Test)
> [<Test.this: 'that'>]
>
> As you can see, the Test Enum becomes inconsistent if this is allowed.
>
Again, this is fully in accordance to the Python philosophy of allowing
monkey-patching in the first place. There's any number of way
monkey-patching objects can lead to inconsistent states, because the
internal invariants are only guaranteed to be preserved through public,
documented interfaces.
I'm still -1. |
|
Date |
User |
Action |
Args |
2013-09-05 15:54:24 | eli.bendersky | set | recipients:
+ eli.bendersky, barry, ethan.furman, eric.snow |
2013-09-05 15:54:24 | eli.bendersky | link | issue18924 messages |
2013-09-05 15:54:24 | eli.bendersky | create | |
|