[Mailman-Users] Need Script to Apend to acceptable_aliases
Barry Finkel
bsfinkel at anl.gov
Thu Jan 13 21:42:12 CET 2011
On 01/12/11 19:08, Mark Sapiro wrote:
> Barry Finkel wrote:
>>
>> I have not looked at the Mailman source, so I am not sure what is
>> failing. Is it the case that the
>>
>> accept_these_nonmembers
>>
>> is stored in a different internal format than
>>
>> acceptable_aliases
>>
>> is? This is a 2.1.14 package built from the SourceForge source.
>
>
> Yes. accept_these_nonmembers is a Python list whose elements are
> strings equal to email addresses or regexps matching email addresses.
> accept_these_nonmembers is a single string consisting of zero or more
> email addresses separated by newlines.
>
> You could do a few different things in your config_list input. One such
> would be
>
> if mlist.acceptable_aliases:
> mlist.acceptable_aliases += '\ntestuser at example.com'
> else:
> mlist.acceptable_aliases = 'testuser at example.com'
>
I revised my script, and I ran some tests. On a list where I had not
previously specified an acceptable_aliases string, what was placed in
that item was
\ntestuser at example.com
Is the leading "\n" going to cause problems?
When I ran it again on the same list using a different e-mail address,
the resulting item had
\ntestuser at example.com\nusertwo at example.com
--
----------------------------------------------------------------------
Barry S. Finkel
Computing and Information Systems Division
Argonne National Laboratory Phone: +1 (630) 252-7277
9700 South Cass Avenue Facsimile:+1 (630) 252-4601
Building 240, Room 5.B.8 Internet: BSFinkel at anl.gov
Argonne, IL 60439-4828 IBMMAIL: I1004994
More information about the Mailman-Users
mailing list