Eric V. Smith <[email protected]> added the comment:
See https://docs.python.org/2/library/collections.html#collections.namedtuple
namedtuple is called as:
collections.namedtuple(typename, field_names[, verbose=False][, rename=False])
So you are passing in
typename = 'Name'
field_names = 'a'
verbose = 'b'
rename = 'c'
'b' is a True value, so that's why it's showing the output.
You want to be using:
sample = namedtuple('Name', ['a', 'b', 'c'])
----------
nosy: +eric.smith
resolution: -> not a bug
stage: -> resolved
status: open -> closed
_______________________________________
Python tracker <[email protected]>
<https://bugs.python.org/issue32961>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com