On 8/20/19 4:14 PM, Russell Clemings wrote:
> This appears to do what I want -- removes everything except the names of
> the list subscriptions:
> 
> diff --git a/mailpasswds b/mailpasswds
> index f194dc6..5f91f34 100644
> --- a/mailpasswds
> +++ b/mailpasswds
> @@ -151,19 +151,8 @@ def main():
>                      continue
>                  # Group by the lower-cased address, since Mailman always
>                  # treates per...@dom.ain the same as per...@dom.ain.
> -                try:
> -                    password = mlist.getMemberPassword(member)
> -                except Errors.NotAMemberError:
> -                    # Here's a member with no passwords, which I think was
> -                    # possible in older versions of Mailman.  Log this and
> -                    # move on.
> -                    syslog('error', 'password-less member %s for list %s',
> -                           member, mlist.internal_name())
> -                    continue
> -
> -
> -                optionsurl = mlist.GetOptionsURL(member)
> -
> +                password = ''
> +                optionsurl = ''
>                  lang = mlist.getMemberLanguage(member)
>                  info = (listaddr, password, optionsurl, lang)
>                  userinfo.setdefault(member, []).append(info)
> @@ -221,8 +210,7 @@ def main():
>                  i18n.set_language(poplang)
>                  # Craft table header after language was set
>                  header = '%-40s %-10s\n%-40s %-10s' % (
> -                         _('List'), _('Password // URL'), '----', '--------')
> -
> +                         _('Your subscriptions'), _(''), '----', ' ')
>                  header = tounicode(header, enc)
>                  # Add the table to the end so it doesn't get wrapped/filled
>                  text += (header + '\n' + NL.join(table))


There are multiple ways to do this, but the above is as good as any.

-- 
Mark Sapiro <m...@msapiro.net>        The highway is for gamblers,
San Francisco Bay Area, California    better use your sense - B. Dylan
------------------------------------------------------
Mailman-Users mailing list Mailman-Users@python.org
https://mail.python.org/mailman/listinfo/mailman-users
Mailman FAQ: http://wiki.list.org/x/AgA3
Security Policy: http://wiki.list.org/x/QIA9
Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/
Unsubscribe: 
https://mail.python.org/mailman/options/mailman-users/archive%40jab.org

Reply via email to