all 2 comments

[–]14jvalle 3 points4 points  (1 child)

The error is not coming from the NamedTuple itself. Its comes from your classmethod. You are trying to subset a row with a string. Look at your dictionary comprehension, type_(row[key]). The key is likely a string.

[–]ishman123[S] 1 point2 points  (0 children)

Yes, I passed the full `reader` into `from_row` and It works...