Re: Bug in email package?

2005-02-21 Thread Roman Suzi
On Sun, 20 Feb 2005, Steven Bethard wrote: Erik Max Francis wrote: Roman Suzi wrote: I think that if any object (from standard library at least) doesn't support iteration, it should clearly state so. My guess is that 'for' causes the use of 'm[0]', which is (rightfully) an error... Can this

Bug in email package?

2005-02-20 Thread Roman Suzi
I was playing with email package and discovrered this strange kind of behaviour: import email.Message m = email.Message.Message() m['a'] = '123' print m From nobody Mon Feb 21 00:12:27 2005 a: 123 for i in m: print i ... Traceback (most recent call last): File stdin, line 1, in ? File

Re: Bug in email package?

2005-02-20 Thread Erik Max Francis
Roman Suzi wrote: I think that if any object (from standard library at least) doesn't support iteration, it should clearly state so. My guess is that 'for' causes the use of 'm[0]', which is (rightfully) an error... Can this behaviour of email be considered a bug? Is there a good case to iterate

Re: Bug in email package?

2005-02-20 Thread Tim Roberts
Roman Suzi [EMAIL PROTECTED] wrote: I was playing with email package and discovrered this strange kind of behaviour: import email.Message m = email.Message.Message() m['a'] = '123' print m From nobody Mon Feb 21 00:12:27 2005 a: 123 for i in m: print i ... Traceback (most recent call