TypeError: unsubscriptable object

K.S.Sreeram sreeram at tachyontech.net
Fri Jun 9 19:47:06 CEST 2006


k.retheesh at gmail.com wrote:
>     print template % (ID, IID, Function[:10], Description[:10],
> ErrorNumber, StatusCD)
> TypeError: unsubscriptable object

It means either 'Function' or 'Description' is not a sequence.
Try inserting print statements to see what values they are.

e.g:

a = 2
a[:10]

will give me an 'unsubscriptable object'

Regards
Sreeram

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 260 bytes
Desc: OpenPGP digital signature
URL: <http://mail.python.org/pipermail/python-list/attachments/20060609/b16fd9f8/attachment.sig>


More information about the Python-list mailing list