Re: [Mailman-Developers] New to mailman
On Dec 21, 2012, at 02:49 PM, Sandesh Agrawal wrote:
from mailman.commands.tests.test_control import make_config
i got the following error:
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "mailman/__init__.py", line 50, in <module> from mailman.core.i18n import initialize File "mailman/core/i18n.py", line 31, in <module> from flufl.i18n import PackageStrategy, registry ImportError: No module named flufl.i18n
flufl.i18n is present in "eggs" directory which is above the mailman directory in hierarchy , so just mentioning "from flufl.i18n" can not detect the required python module.
How can this problem be fixed ?
Did you type this into the interpreter prompt? If so, how did you start Python? Where exactly did you "run this"?
Note that the standard Python interpreter doesn't have its sys.path set up to import from the eggs directory. Use bin/py for that.
(If you're wondering what the difference is between bin/py
and bin/mailman shell
, it's that the latter does all the Mailman initializations necessary to
operate Mailman. E.g. it inits the log system, the ZCA, etc.)
Cheers, -Barry
Did you type this into the interpreter prompt? If so, how did you start Python? Where exactly did you "run this"?
Yes i was using python's default interpreter which was causing problems. /bin/py worked.
While making "class FakeArgs" for starting master process in mailman, i am doing config = make_config(), which gives the following error :
[config_file = os.path.join(os.path.dirname(config.filename), new_config) File "/usr/lib/python2.6/posixpath.py", line 119, in dirname i = p.rfind('/') + 1 AttributeError: 'NoneType' object has no attribute 'rfind'
i searched everything regarding this but could not find how to resolve it
participants (2)
-
Barry Warsaw
-
Sandesh Agrawal