Jason R. Coombs <jar...@jaraco.com> added the comment:

For posterity, I'll share my motivation.

> Why is it a problem that people are using something which is documented as a 
> tuple?

It's not a problem that they access it by tuple if it's documented.

The problem is that it's documented for access as a tuple when there is a 
superior method to access (by attribute) that's less opaque than the historical 
method by index.

I apologize for not documenting that in the original post. It seemed obvious to 
me at the time that having one obvious way to access the items would be 
preferred.

For example, `uname()[0]` doesn't mean anything to me without a comment or 
referencing the documetation, whereas `uname().system` does.

Access by numerical index hearkens back to C-style arrays and in my mind is an 
anti-pattern.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue40578>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to