.. module:: mhlib
:synopsis: Manipulate MH mailboxes from Python.
+ :deprecated:
+
+.. deprecated:: 2.6
+ The :mod:`mhlib` module has been removed in Python 3.0. Use the
+ :mod:`mailbox` instead.
+
.. sectionauthor:: Skip Montanaro <skip@pobox.com>
The :mod:`mhlib` module provides a Python interface to MH folders and their
s = m.getbodytext() # text of message's body, decoded
s = m.getbodytext(0) # text of message's body, not decoded
"""
+from warnings import warnpy3k
+warnpy3k("the mhlib module has been removed in Python 3.0; use the mailbox "
+ "module instead", stacklevel=2)
+del warnpy3k
# XXX To do, functionality:
# - annotate messages
### mhlib. It should.
import unittest
-from test.test_support import run_unittest, TESTFN, TestSkipped
+from test.test_support import run_unittest, TESTFN, TestSkipped, import_module
import os, StringIO
import sys
-import mhlib
+mhlib = import_module('mhlib', deprecated=True)
if (sys.platform.startswith("win") or sys.platform=="riscos" or
sys.platform.startswith("atheos")):
# import side-effect.
all_platforms = ('audiodev', 'imputil', 'mutex', 'user', 'new', 'rexec',
'Bastion', 'compiler', 'dircache', 'fpformat',
- 'ihooks')
+ 'ihooks', 'mhlib')
inclusive_platforms = {'irix':('pure',)}
# XXX Don't know if lib-tk is only installed if _tkinter is built.
optional_modules = ('bsddb185', 'Canvas', 'dl', 'linuxaudiodev')
# These were once about the 10 longest modules
cm('random', ignore=('Random',)) # from _random import Random as CoreGenerator
cm('cgi', ignore=('log',)) # set with = in module
- cm('mhlib')
cm('urllib', ignore=('getproxies_registry',
'proxy_bypass_registry',
'open_https',
Library
-------
+- The mhlib module has been deprecated for removal in Python 3.0.
+
- The linuxaudiodev module has been deprecated for removal in Python 3.0.
- The ihooks module has been deprecated for removal in Python 3.0.