[Mailman-Developers] Mailman 3 lmtp queue runners

Barry Warsaw barry at list.org
Thu Jul 3 17:43:47 CEST 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Jul 3, 2008, at 7:59 AM, William Mead wrote:

> Hello fellow Mailman developers,
>
> My name is William Mead, I'm a new Mailman developer and currently as
> an intern for Ian Elioart at the university of Sussex.
>
> We have started working on Mailman 3.0. At the moment we are looking
> at the lmtp part of Mailman, however we have come up against a few
> problems. We are able to get all the queue runners started except for
> the lmtp queue runner. We have set lmtp to be used in the Defaults.py
> file, but this doesn't start the lmtp queue runner.
>
> We are currently looking at the lmtp.txt file in
> 3.0/Mailman/queue/docs. To start a lmtp queue runner we need to be
> able to run these 3 lines of code :
>
>>>> from mailman.tests import helper
>>>> master = helpers.TestableMaster()
>>>> master.start('lmtp')
>
> However the second line of code gives us an error and prevents us from
> starting the lmtp runner.
>
> The python code contained in this file produces errors when trying to
> doctest it. Once we've run the doctest :
>
>>>> import doctest
>>>> doctest.testfile("lmtp.txt")
>
> here is the first error :
>
> **********************************************************************
> File "./lmtp.txt", line 14, in lmtp.txt
> Failed example:
>    master = helpers.TestableMaster()
> Exception raised:
>    Traceback (most recent call last):
>      File "/System/Library/Frameworks/Python.framework/Versions/2.5/ 
> lib/python2.5/doctest.py",
> line 1212, in __run
>      File "<doctest lmtp.txt[1]>", line 1, in <module>
>        master = helpers.TestableMaster()
>      File "/Library/Python/2.5/site-packages/mailman-3.0.0a1_- 
> py2.5.egg/mailman/tests/helpers.py",
> line 114, in __init__
>        restartable=False, config_file=config.filename)
>    AttributeError: 'Configuration' object has no attribute 'filename'
> **********************************************************************
>
> which correctly corresponds to the second line of code needed, we  
> saw earlier.
>
> Do we have to import any other files or set any specific variables ?

Hi William.

First, I just want to be sure you're running the test suite the way  
it's (currently) intended.  Here's what I do in a pristine branch:

% mkdir staging
% pushd staging
% export PYTHONPATH=`pwd`:$PYTHONPATH
% popd
% python setup.py develop -d staging
% staging/bin/testall lmtp

You might want to run testall with -v and/or -e.  The former produces  
a bit more verbosity, such as the config file its loading.  The latter  
propagates any exceptions in the child process to the console.

- -Barry

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Darwin)

iEYEARECAAYFAkhs87MACgkQ2YZpQepbvXHprQCfXMV5OuFF8dGtUNlSxQtfI33Y
LhoAoJVaI0fa4ZY6jNB47g09QEfzocCH
=eK9s
-----END PGP SIGNATURE-----


More information about the Mailman-Developers mailing list