RELEASED email 2.0 (standalone)

Tino Lange tl_news at nexgo.de
Wed Apr 10 01:40:38 EDT 2002


On Mon, 8 Apr 2002 17:43:36 -0400, barry at zope.com (Barry A. Warsaw)
wrote:

>
>I've just released version 2.0 of the standalone email package.  This
>will likely be the last official standalone release, as I intend to
>complete the merge of the package into the Python 2.3 cvs tree.

>The email package is compatible with both Python 2.1 and Python 2.2.
>Online documentation is available at

Hi Barry!

I've installed it on my Python 2.1.x - boxes (Win and Linux).
But the test fails and there are deprecation warnings?!

Here's the test_email.py - output:

tinux:/usr/local/src/email-2.0/tests # python test_email.py
........................./usr/local/lib/python2.1/site-packages/email/MIMEText.py:43:
DeprecationWarning: _encoder argument is obsolete.
  DeprecationWarning, 1)
..........test_email.py:483: DeprecationWarning: add_payload() is
deprecated, use attach() instead.
  self.msg.add_payload("""\
.............test_email.py:664: DeprecationWarning: add_payload() is
deprecated, use attach() instead.
  container.add_payload(intro)
test_email.py:665: DeprecationWarning: add_payload() is deprecated,
use attach() instead.
  container.add_payload(image)
......./usr/local/lib/python2.1/site-packages/email/Utils.py:145:
DeprecationWarning: Use Header.Header.encode() instead.
  warnings.warn('Use Header.Header.encode() instead.',
DeprecationWarning, 1)
.test_email.py:816: DeprecationWarning: Use Header.decode_header()
instead.
  eq(Utils.decode(s), 'this is some text')
test_email.py:818: DeprecationWarning: Use Header.decode_header()
instead.
  eq(Utils.decode(s), u'Keld J\xf8rn Simonsen')
test_email.py:821: DeprecationWarning: Use Header.decode_header()
instead.
  eq(Utils.decode(s), 'If you can read this you understand the
example.')
test_email.py:823: DeprecationWarning: Use Header.decode_header()
instead.
  eq(Utils.decode(s),
test_email.py:826: DeprecationWarning: Use Header.decode_header()
instead.
  eq(Utils.decode(s), u'this issome text')
test_email.py:828: DeprecationWarning: Use Header.decode_header()
instead.
  eq(Utils.decode(s), u'this is some text')
..test_email.py:965: DeprecationWarning: add_payload() is deprecated,
use attach() instead.
  msg.add_payload(msg1)
test_email.py:966: DeprecationWarning: add_payload() is deprecated,
use attach() instead.
  msg.add_payload(msg2)
.test_email.py:869: DeprecationWarning: add_payload() is deprecated,
use attach() instead.
  m.add_payload('Here is the body of the message.\n')
....................FF..........................test_email.py:1634:
RuntimeWarning: test_japanese_codecs() skipped
  warnings.warn('test_japanese_codecs() skipped', RuntimeWarning, 1)
.....
======================================================================
FAIL: test_formatdate (__main__.TestMiscellaneous)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "test_email.py", line 1180, in test_formatdate
    time.gmtime(now)[:7])
  File "/usr/local/lib/python2.1/site-packages/unittest.py", line 273,
in failUnlessEqual
    raise self.failureException, (msg or '%s != %s' % (first, second))
AssertionError: (2002, 4, 10, 5, 35, 32, 0) != (2002, 4, 10, 5, 35,
32, 2)
======================================================================
FAIL: test_formatdate_localtime (__main__.TestMiscellaneous)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "test_email.py", line 1186, in test_formatdate_localtime
    time.localtime(now)[:7])
  File "/usr/local/lib/python2.1/site-packages/unittest.py", line 273,
in failUnlessEqual
    raise self.failureException, (msg or '%s != %s' % (first, second))
AssertionError: (2002, 4, 10, 7, 35, 32, 0) != (2002, 4, 10, 7, 35,
32, 2)
----------------------------------------------------------------------
Ran 112 tests in 1.968s

FAILED (failures=2)
tinux:/usr/local/src/email-2.0/tests #

What's wrong? Why those failures and warnings?
Best regards

Tino




More information about the Python-list mailing list